Try with the ant copy task associated with a mapper:
<copy file="deploy.wsdd" todir="${configuration.dir}">
<mapper type="glob" from="*.wsdd" to="myservice-*.wsdd" />
</copy>
Christophe
> -----Original Message-----
> From: Jerome Lacoste [mailto:[EMAIL PROTECTED]
> Sent: Monday, August 16, 2004 6:23 PM
> To: [EMAIL PROTECTED]
> Subject: overwritten un/deploy.wsdd files when using axis-wsdl2java task
> for webservices with identical mapped package names
>
> Hi,
>
> I am using the axis-wsdl2java ant task in a build file where I generate
> code for several web services. Each axis-wsdl2java generates several
> file, including a deploy.wsdd and undeploy.wsdd.
>
> Some of these web services have the same 'generated' package. But that
> makes the last ant call overwrite the wsdd files generated by the former
> ones.
>
> Unfortunately I've found out that it isn't possible to modify the name
> of the wsdd files, as they are hardcoded (in
> org.apache.axis.wsdl.toJava.Java*DeployWriter).
>
> E.g.
>
> <target name="gen.wsdd">
> <mkdir dir="${build.dir.wsdd}"/>
> <axis-wsdl2java output="${build.dir.wsdd}" verbose="false"
> url="${build.dir.wsdl}/${service.name}.wsdl"
> serverside="true" debug="false">
> <mapping
> namespace="${ws.namespace}"
> package="${generated.ws.package}"/>
> </axis-wsdl2java>
> </target>
>
> <target name="build.wsdd"
> description="Builds the wsdd based on interfaces." depends="build">
> <delete dir="${build.dir.wsdd}"/>
> <antcall target="gen.wsdd">
> <param name="service.name" value="Calculator"/>
> <param name="generated.ws.package" value="org.cb.test"/>
> </antcall>
> <antcall target="gen.wsdd">
> <param name="service.name" value="OtherService"/>
> <param name="generated.ws.package" value="org.cb.test"/>
> </antcall>
> </target>
>
> With this code, I will have a single org/cb/test/deploy.wsdd containing
> info about the OtherService web service
>
> So I am wondering if:
>
> - it would be interesting to have a way to modify these DeployWriter
> files to accept a parametrized wsdd output file name. For example, I
> would be happy with something like deploy-${service.name}.wsdd.
>
> - if not, could someone give me the reason as why these file names have
> to be hardcoded and what solutions are you using to avoid name clashes.
> I don't like much forcing my package names to be different, nor moving
> the generated files using ant. Maybe one can convince me otherwise.
>
> Cheers,
>
> Jerome