You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by Arun Gupta <ar...@gmail.com> on 2006/03/24 23:15:56 UTC

XmlProperty caching values

Here is an excerpt from my build script:

-- cut here --
    <target name="retailer-client">
        <xmlproperty file="etc/retailer-client-binding.xml"
validate="false" collapseattributes="true"/>
        <echo message="${bindings.wsdlLocation}"/>
    </target>

    <target name="warehouse-client">
        <xmlproperty file="etc/warehouse-client-binding.xml"
validate="false" collapseattributes="true"/>
        <echo message="${bindings.wsdlLocation}"/>
    </target>
-- cut here --

Depending upon the order of invocation of these targets, <echo> always
dumps the exact same value of ${bindings.wsdlLocation} in both the
targets.

The value, however, is different depending upon the invocation order.
So for instance, if the order is "retailer-client warehouse-client",
then the correct value from retailer-client-binding.xml is displayed
in both the targets. If the order is "warehouse-client
retailer-client", then the correct value from
warehouse-client-binding.xml is displayed in both the targets.

Seems like only the first invocation of xmlproperty is cached and
results are returned.

Any ideas what is wrong ?

-Arun

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Re: XmlProperty caching values

Posted by Jeffrey E Care <ca...@us.ibm.com>.
Ant properties are immutable.

____________________________________________________________________________________________ 

Jeffrey E. (Jeff) Care 
carej@us.ibm.com 
IBM WebSphere Application Server Development 
WAS Pyxis Lead Release Engineer 




"Arun Gupta" <ar...@gmail.com> wrote on 03/24/2006 05:15:56 PM:

> Here is an excerpt from my build script:
> 
> -- cut here --
>     <target name="retailer-client">
>         <xmlproperty file="etc/retailer-client-binding.xml"
> validate="false" collapseattributes="true"/>
>         <echo message="${bindings.wsdlLocation}"/>
>     </target>
> 
>     <target name="warehouse-client">
>         <xmlproperty file="etc/warehouse-client-binding.xml"
> validate="false" collapseattributes="true"/>
>         <echo message="${bindings.wsdlLocation}"/>
>     </target>
> -- cut here --
> 
> Depending upon the order of invocation of these targets, <echo> always
> dumps the exact same value of ${bindings.wsdlLocation} in both the
> targets.
> 
> The value, however, is different depending upon the invocation order.
> So for instance, if the order is "retailer-client warehouse-client",
> then the correct value from retailer-client-binding.xml is displayed
> in both the targets. If the order is "warehouse-client
> retailer-client", then the correct value from
> warehouse-client-binding.xml is displayed in both the targets.
> 
> Seems like only the first invocation of xmlproperty is cached and
> results are returned.
> 
> Any ideas what is wrong ?
> 
> -Arun
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
>