I just created the following simple unit test:
public class MemoryTest extends TestCase
{

   public void test() throws Exception
   {
      BoundedBuffer buffer = new BoundedBuffer(200000);

      Object[] a = new Object[200000];
      a[0] = "foo";
      a[100000] = "foo2";

      buffer.put("abc");
      buffer.put("abcdefg");
   }
}

And ran that through Jprofiler. These are the top objects consuming memory in 
Jprofiler:

Java.lang.String - 1516 instances - 36384 bytes
Char[] - 1489 instances - 197,144 bytes
Short[] - 740 instances - 45,392 bytes
Int[] - 669 instances - 57,984 bytes
Byte[] - 635 instances - 170,736 bytes
Java.lang.Class - 565 instances - 192,928 bytes
[] - 455 instances - 1,623,680 bytes

Nothing else is noteworthy. Can you try running the cut&pasted unit test and 
see what kind of results you get?


View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3923504#3923504

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3923504


-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
_______________________________________________
JBoss-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to