You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Jason Etherton <je...@astro.livjm.ac.uk> on 2004/07/05 15:11:14 UTC
Deployment Descriptor - deploy.wsdd vs. web.xml
Please,
When I added an Axis Ant task (war) to my build file it told me I needed
the "webxml" atttribute. Upon looking this up I found that it is the
URL of the deployment descriptor, so I added the URL for the
WSDL2Java-generated 'deploy.wsdd'.
I know this is wrong, but what I don't know is how to generate/write the
web.xml deployment decriptor.
Will someone please tell me why 2 deployment descriptors and what the difference is?
Also, if the WSDD is not the deployment descriptor, why is it generated
as such?
Please help,
Jason
Re: Deployment Descriptor - deploy.wsdd vs. web.xml
Posted by "matthew.hawthorne" <ma...@apache.org>.
Jason Etherton wrote:
> When I added an Axis Ant task (war) to my build file it told me I needed
> the "webxml" atttribute. Upon looking this up I found that it is the
> URL of the deployment descriptor, so I added the URL for the
> WSDL2Java-generated 'deploy.wsdd'.
>
> I know this is wrong, but what I don't know is how to generate/write the
> web.xml deployment decriptor.
>
> Will someone please tell me why 2 deployment descriptors and what the
> difference is?
>
> Also, if the WSDD is not the deployment descriptor, why is it generated
> as such?
It seems like there are a few distinct concepts that are being mixed
together here.
web.xml and *.wsdd are 2 different descriptor types, with 2 different
purposes.
As far as I know, the Ant "war" task has nothing to do with Axis -- it
just provides a way
to build a standard war file.
To run the Axis server, you need to have the Axis war file deployed on
your servlet
container somewhere. If you were to jar up the webapps/axis directory
of the Axis distribution, and
name it (for example axis.war), this would be a deployable Axis
installation, typically reached at
http://localhost:8080/axis.
Now, in order to use the *.wsdd file, you need to send it to the Axis
server and tell it to deploy.
I do it like this:
<axis-admin
port="8080"
hostname="localhost"
failonerror="true"
servletpath="axis/services/AdminService"
debug="false"
xmlfile="deploy.wsdd"/>
Any classes referenced in your wsdd must be visible to the Axis server.
I do this by bundling Axis
inside of my ear file, but a simpler way may just be to put your classes
in axis.war/WEB-INF/classes, just
like it was your own war file.
I've touched a few different topics here, sorry if things are jumbled.
Basically, you don't need a web.xml to use Axis,
but you do need a wsdd file.
You should take a look at http://ws.apache.org/axis/, especially
"Installation" and "User's Guide". They give more detailed
explanations of the things I've said here.