besides the fix you've implemented by clearing this metadata
as soon as you can, you could also make the inspector temporarily
null it out while it computes the size of things.  then the inspector
would give you results more in line with production sizes.


Eelco Hillenius wrote:
> 
> Hi,
> 
> I'd like to discuss the recent introduced functionality of line
> precise error reporting - this time specifically in it's own thread.
> 
> It is a new facility that records the stack trace when a component is
> created and when it is added to a container. A relevant representation
> of the stack trace (a couple of lines) is saved as meta data on the
> component.
> 
> It is used when you created and added a component, but fail to
> reference it in the right place in your markup. For example, if I
> remove the reference in HelloWorld.html from wicket-examples, I get an
> exception like:
> 
> WicketMessage: The component(s) below failed to render. A common
> problem is that you have added a component in code but forgot to
> reference it in the markup (thus the component will never be
> rendered).
> 
> 1. [Component id = message, page =
> org.apache.wicket.examples.helloworld.HelloWorld, path =
> 0:message.Label, isVisible = true, isVersioned = false]
> The label with id 'message' that failed to render was constructed
> at
> org.apache.wicket.examples.helloworld.HelloWorld.<init>(HelloWorld.java:35)
> 
> The label with id 'message' that failed to render was added
> at
> org.apache.wicket.examples.helloworld.HelloWorld.<init>(HelloWorld.java:35)
> 
> This is all nice, but comes at a price: slower execution and more
> memory consumption. If this was just a little bit, I wouldn't be too
> worried. However, in the project I'm working on, the slowdown is
> definitively noticable, and the memory consumption is too. For
> example, some of our heavier pages:
> 
> deployment -> development
> 25.1K            -> 680.1K
> 82.7K            -> 1.7M
> 47.3K            -> 814.6K
> 37.2K            -> 644.8K
> 
> This is not a small difference, and I'm really wondering whether it is
> a good idea to do this by default. I find it personally anoying that
> the inspector pages (which I use regularly) don't give me the right
> information anymore. And for Wicket in general, I fear that people
> won't be aware of this difference (no matter how loud we shout out,
> most people will just miss this unless they experience a problem) and
> think Wicket is slow and consumes a lot of memory. I would prefer to
> keep this alive as a separate setting (note that it is now folded in
> with the IDebugSettings#componentUseCheck setting) and not have it on
> by default.
> 
> WDYT?
> 
> Eelco
> 
> 

-- 
View this message in context: 
http://www.nabble.com/line-precise-error-reporting%3A-should-this-be-on-by-default--tf3886097.html#a11021049
Sent from the Wicket - Dev mailing list archive at Nabble.com.

Reply via email to