dev@glassfish.java.net

Re: domain.xml/hk2 broken

From: Ludovic Champenois <ludovic.champenois_at_oracle.com>
Date: Thu, 19 Aug 2010 08:16:45 -0700

On 8/19/10 8:10 AM, Justin Lee wrote:
> The practice of not writing out elements whose attributes are all
> default values (essentially empty nodes) breaks thing silently. If I
> create a protocol then create the nested element "http-redirect" with
> default values, the <http-redirect> is not written out to domain.xml.
> However, it remains visible in memory so that subsequent attempts to
> create that same element fail properly. When restarting glassfish,
> that element does not exist in the document and is not recreated in
> memory on restart thereby breaking the configuration. We need to have
> that feature rolled back. I can file an issue against this with these
> details, I just need to know if I should file against glassfish or
> hk2. But it's definitely a problem.
>
hk2.
We should keep the feature, but fix the bug: having a child element is
not the default setting, so this setting should be stored, even if all
the attributes of the parent are default, the @Element side is not
default...

Ludo
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: dev-help_at_glassfish.dev.java.net
>