users@glassfish.java.net

Re: Slow to instaniate an object in Glassfish

From: <glassfish_at_javadesktop.org>
Date: Wed, 28 May 2008 10:47:46 PDT

Is there any way you can get a finer read on where the bottleneck may be? Can you, for example, not create a zillion objects, but just create 1 or 2 (can you make your grid as small as possible, for example)?

Again, it's one thing to load a class and another thing to instantiate it.

Now, I don't know what happens when you create a Wicket grid cell, what work it may need to do. Perhaps this is a Wicket issue with Glassfish, rather than a generic object creation issue.

But from the generic object point of view, once the class is loaded, instantiating should be, effectively, "free" plus whatever code is run in the constructor. So, maybe it's the wicket constructor that's having the problems. Can you look at its code and see what it might be doing?
[Message sent by forum member 'whartung' (whartung)]

http://forums.java.net/jive/thread.jspa?messageID=277062