geronimo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Aaron Mulder" <>
Subject Re: Removing attributes and refs from the config.xml
Date Fri, 24 Feb 2006 22:56:49 GMT
What's wrong with just listing the attribute or reference with no
content but without the new "empty=true"?  As in:

<gbean name="TomcatEngine">
  <reference name="TomcatValveChain" />


On 2/24/06, Jeff Genender <> wrote:
> The config.xml allows us to declare new GBeans and override references
> and attributes of already existing Gbeans. But there is a missing
> configuration item here, which is the ability to *remove* a reference or
> attribute value from the configuration.  Currently there is no way to do
> this.
> Matt Hogstrom and I ran into this when trying to remove a logging
> reference in one of the GBeans.
> An example of this is the TomcatValveChain on the TomcatEngine.  As it
> stands, our default implementation installs an AccessLogValve into the
> TomcatValveChain reference.  We wanted to shut off logging to test
> different performance numbers and found that there was no way to "clear"
> or remove a reference that was set in the car plan via the config.xml,
> without rebuilding the car from the source.
> On further discussion with David J and Dain, we came up with a new xml
> attribute to place on refs and attribute tags. You would use:
> empty="true"
> Example:  You want to remove the access logger to improve web container
> performance, you would declare the following in the config.xml, which
> would remove the TomcatValveChain from the TomcatEngine:
> ...
> <configuration name="geronimo/tomcat/1.1-SNAPSHOT/car">
>     ...
>     <gbean name="FirstValve" load="false"/>
>     <gbean name="TomcatEngine">
>         <reference name="TomcatValveChain" empty="true"/>
>     </gbean>
>     ...
> </configuration>
> ...
> You would do the same for attributes that needed to be removed.
> I have this all coded up and ready to check in, but wanted to get any
> feedback or issues before I went ahead and did it.
> Comments?
> Jeff

View raw message