Results 1 to 7 of 7

Thread: OutOfMemmoryError: mmAlloc

  1. #1
    Sivaprakash is offline Registered User
    Name: Sivaprakash Selvaraj
    Organization: HTC Global Services
    Project: GOLD
    Join Date
    Apr 2006
    Posts
    6

    OutOfMemmoryError: mmAlloc

    Hi,

    While sending a huge string (size could be even 54 MB) to the ice servant, I am getting following exception. But sometimes, I am able to send the same string to the same Ice service. I guess this is not related to Ice framework. But it would be really helpful if anyone can provide some info about this problem.

    Is it just memory unavailablity problem?

    JDK : Jrockit 1.4.2.8

    Please let me know if any other info is required.

    java.lang.OutOfMemoryError: mmAllocLargeArray(jniGetVMThread(env), (ClassP)c, (ObjectP*)res, len) : mmAllocLargeArray(jniGetVMThread(env), (ClassP)c, (ObjectP*)res, len)
    java.lang.StringCoding.trim([BI)[B(Unknown Source)
    java.lang.StringCoding.access$700([BI)[B(Unknown Source)
    java.lang.StringCoding$CharsetSE.encode([CII)[B(Unknown Source)
    java.lang.StringCoding.encode(Ljava/lang/String;[CII)[B(Unknown Source)
    java.lang.String.getBytes(Ljava/lang/String;)[B(Unknown Source)
    IceInternal.BasicStream.writeString(Ljava/lang/String;)V(BasicStream.java:1031)
    com.gale.cs.vault.model.Document.__write(LIceInter nal/BasicStream;)V(Document.java:102)
    IceInternal.BasicStream.writeInstance(LIce/Object;Ljava/lang/Integer;)V(BasicStream.java:1554)
    IceInternal.BasicStream.writePendingObjects()V(Bas icStream.java:1467)
    com.gale.cs.vault._VaultServiceICEDelM.addDocument (Lcom/gale/cs/vault/model/Document;Ljava/util/Map;)Lcom/gale/cs/vault/model/DocumentId;(_VaultServiceICEDelM.java:28)
    com.gale.cs.vault.VaultServiceICEPrxHelper.addDocu ment(Lcom/gale/cs/vault/model/Document;Ljava/util/Map;)Lcom/gale/cs/vault/model/DocumentId;(VaultServiceICEPrxHelper.java:35)
    com.gale.cs.vault.VaultServiceICEPrxHelper.addDocu ment(Lcom/gale/cs/vault/model/Document;)Lcom/gale/cs/vault/model/DocumentId;(VaultServiceICEPrxHelper.java:20)
    jrockit.reflect.NativeMethodInvoker.invoke0(Ljava/lang/Object;ILjava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;(Unknown Source)
    jrockit.reflect.NativeMethodInvoker.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;(Unknown Source)
    jrockit.reflect.VirtualNativeMethodInvoker.invoke( Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;(Unknown Source)
    java.lang.reflect.Method.invoke(Ljava/lang/Object;[Ljava/lang/Object;I)Ljava/lang/Object;(Unknown Source)
    org.springframework.remoting.ice.IceClientIntercep tor.invoke(Lorg/aopalliance/intercept/MethodInvocation;)Ljava/lang/Object;(IceClientInterceptor.java:245)
    org.springframework.aop.framework.ReflectiveMethod Invocation.proceed()Ljava/lang/Object;(ReflectiveMethodInvocation.java:144)
    org.springframework.aop.framework.JdkDynamicAopPro xy.invoke(Ljava/lang/Object;Ljava/lang/reflect/Method;[Ljava/lang/Object;)Ljava/lang/Object;(JdkDynamicAopProxy.java:174)
    $Proxy32.addDocument(Lcom/gale/cs/vault/model/Document;)Lcom/gale/cs/vault/model/DocumentId;(Unknown Source)
    com.gale.cs.workflow.loadfeed.biz.service.impl.Loa dFeedWorkflowServiceImpl.checkinDocumentsToDeliver yVault(Lcom/gale/cs/workflow/WorkflowInput;Lcom/gale/cs/workflow/FeedInput;Ljava/util/List;)V(LoadFeedWorkflowServiceImpl.java:435)


    Thanks & Regards,
    Sivaprakash S

  2. #2
    xdm's Avatar
    xdm
    xdm is online now ZeroC Staff
    Name: Jose Gutierrez de la Concha
    Organization: ZeroC, Inc.
    Project: Ice Developer
    Join Date
    Sep 2003
    Location
    La Coruņa, Spain
    Posts
    588
    first of all be sure that your system has available memory when it crash

    if you are in linux side check if you are exceding system limits with ulimit, ulimit -a list you the limits for a user.

    You must adjust your jvm params to allow more memory, this option can help. I think the default is 32mb for clients and 64 for servers

    -Xmx256m
    //sets the maximum heap size to 256mb

    for a extensive list of jvm params check this url http://www.tagtraum.com/gcviewer-vmflags.html

    I hope this help you

  3. #3
    Sivaprakash is offline Registered User
    Name: Sivaprakash Selvaraj
    Organization: HTC Global Services
    Project: GOLD
    Join Date
    Apr 2006
    Posts
    6
    I observed that it is because of lack of memory. Also, I observed that it requires almost memory of 10 times more than the actual content to recieve from the ICE server. Is my observation correct?

    Suppose if I have to retreive content (assume size as 6MB) from an ICE server, i had to set memory heap size as 60MB while ruinning the client. I am using JDK1.4.2_8

    Thanks & Regards,
    Sivaprakash Selvaraj,
    HTC Global Services.
    Last edited by Sivaprakash; 05-08-2006 at 05:27 PM.

  4. #4
    michi's Avatar
    michi is offline Registered User
    Name: Michi Henning
    Organization: Triodia Technologies
    Project: I have a passing interest in Ice :-)
    Join Date
    Feb 2003
    Location
    Brisbane, Australia
    Posts
    1,055
    Before we can help you, can you please update your signatures as described in this thread.

    Cheers,

    Michi.

  5. #5
    marc's Avatar
    marc is offline ZeroC Staff
    Name: Marc Laukien
    Organization: ZeroC, Inc.
    Project: The Internet Communications Engine
    Join Date
    Feb 2003
    Location
    Florida
    Posts
    1,860
    Please let us also know which Ice version you are using.

  6. #6
    Sivaprakash is offline Registered User
    Name: Sivaprakash Selvaraj
    Organization: HTC Global Services
    Project: GOLD
    Join Date
    Apr 2006
    Posts
    6

    Ice Version

    I am using ICE Version 3.0.1
    Thanks & Regards,
    Sivaprakash Selvaraj,
    HTC Global Services (www.htcinc.com).
    Working for Thomson Gale

  7. #7
    mes's Avatar
    mes
    mes is offline ZeroC Staff
    Name: Mark Spruiell
    Organization: ZeroC, Inc.
    Project: Ice Developer
    Join Date
    Feb 2003
    Location
    California
    Posts
    1,441
    Hi,

    I've confirmed that Ice for Java is using a lot of memory when marshaling strings. We'll fix this in the next release.

    Thanks for reporting this problem.

    Take care,
    - Mark

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •