aspose file tools*
The moose likes Web Services and the fly likes Deploying the webservice Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Web Services
Bookmark "Deploying the webservice" Watch "Deploying the webservice" New topic
Author

Deploying the webservice

vijay kumar
Ranch Hand

Joined: Nov 05, 2005
Posts: 58
how to deploy the webservice in to tomcat webapplication
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41489
    
  53
Assuming that your are using Axis, you would use the AdminClient tool. The details are in the Axis documentation. Being a Java class, running AdminClient can also be started through Ant.


Ping & DNS - my free Android networking tools app
vijay kumar
Ranch Hand

Joined: Nov 05, 2005
Posts: 58
I want to pack the webservice as part of web application.
i have created .wsdl file and webservices.xml file also.w
where to place deploy.wsdd file.
server-config.wsdd is must in war file.
mapping.xml is must?

what r the steps involved?
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41489
    
  53
Which SOAP engine are you using? To my knowledge, Axis does not use files called mapping.xml and webservices.xml.

But if it is Axis, you need to add the Axis jar files to your WEB-INF/lib directory, add the Axis servlet to your web.xml, and put server-config.wsdd into WEB-INF. deploy.wsdd is not needed, assuming that server-config.wsdd already contains that information. The WSDL file isn't needed either.
[ January 04, 2006: Message edited by: Ulf Dittmer ]
vijay kumar
Ranch Hand

Joined: Nov 05, 2005
Posts: 58
Thanks for prompt reply.
i'm using Apache Axis engine.

what is the content of server-config.wsdd file.

i'm getting error that is not a servlet
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41489
    
  53
Why would a .wsdd file be a servlet - what are you trying to do with it?

server-config.wsdd contains configuration data for Axis, as well as information about the web services you have deployed. After deploying your web services on your development machine, you should take the file as it is and add it to the war file you're building.
vijay kumar
Ranch Hand

Joined: Nov 05, 2005
Posts: 58
i'm talking abt webservice end point servlet.
and i want my wsdl file to be taken.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41489
    
  53
To say anything about that error message, one would need to know the URL you're trying to access and the relevant contents of the web.xml file (servlet declaration and mapping).

What do you mean by "i want my wsdl file to be taken"? Once the WS is developed and deployed, you don't need the WSDL any more. Your users might, but you can let Axis serve it to them dynamically. I wouldn't recommend that for a production service, though. Better to put the file somewhere on the server, and add a link to it on some page, so that the users can download it.
vijay kumar
Ranch Hand

Joined: Nov 05, 2005
Posts: 58
after deploying, it creates wsdl file

with it's own naming conventions and giving error that the deserializer not found while accessing that service.
But i have defined the deserializer mapping with existing naming conventions
Tauri Valor
Ranch Hand

Joined: Aug 03, 2005
Posts: 166
Can I deploy a webservice developed using Sun Application Server in Tomcat server??

--jd


A Moment's insight is sometimes worth a Life's experience.
vijay kumar
Ranch Hand

Joined: Nov 05, 2005
Posts: 58
can anyone give some example for servlet end point implementation.

wheter it has to extend ServletLifeCycle method of jax-rpc
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41489
    
  53
javadheer,

please don't hijack an existing thread by adding unrelated questions. It's perfectly OK to start a new thread, and if you give it a meaningful topic name, it's much more likely that you'll get an answer that way.
[ January 05, 2006: Message edited by: Ulf Dittmer ]
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41489
    
  53
kumar sanu write:
after deploying, it creates wsdl file

By deploying, do you mean the initial deployment of the WS into the WS engine, or the deployment of the complete war file that already includes the WS? Axis does not create WSDL files; it can only serve the information dynamically.
So, without knowing what exactly you're doing, and what errors or exceptions you're getting, it's hard to guess what might be going wrong.
vijay kumar
Ranch Hand

Joined: Nov 05, 2005
Posts: 58
i'm writitng webservice in an existing webapplication.

i'm having one service endpoint interface and implementation(servlet end point but ordinary class).
i have included in web.xml

i have written .wsdl file and webservices.xml and server-config.wsdd and

i'm using axis engine.

i have deployed .war file.

i'm not able to access the end point .it's giving error that it's not a servlet.

but i want to have a to give input and get output of the webservice in that page.

this is scenario.

thanks for help
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41489
    
  53
I'll repeat once more what I said earlier: without knowing which URL you're trying to access, and seeing the relevant excerpts from the web.xml (servlet and mapping), and the exact error message, one won't be able to guess what might be going wrong.

I also don't fully understand the architecture -e.g., why are you creating your own endpoint servlet when you also include Axis, and could just use its servlet?-, or why -within the same web app- you have a page accessing a WS and the WS itself. That seems a rather roundabout way to access functionality.
vijay kumar
Ranch Hand

Joined: Nov 05, 2005
Posts: 58
axis is putting all the services under http://localhost ortno/services

directory . it's showing the service with operation name. like

below

servicename(wsdl)

operationname.

if we click the wsdl link it will show the generated .wsdl file.

this is slightly different from the handwritten one.

ok.if we dont go for Specific End point servlet ,

we have to access the operation from the jsp directly.
the war file is deployed in to tomcat.


one more thing not able to download the wsdl file(manual) file from the specified location
vijay kumar
Ranch Hand

Joined: Nov 05, 2005
Posts: 58
what is the namespace uri. i have to use to refer endpoint
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41489
    
  53
axis is putting all the services under...

If you integrate Axis into your web app, you can map the Axis servlet to any directory you like.

this is slightly different from the handwritten one.

Then I would tweak the WS until the automatically generated WSDL matches what you are trying to achieve manually (if the differences even matter to you).

if we dont go for Specific End point servlet, we have to access the operation from the jsp directly.

This makes no sense. Whether you use the Axis servlet as endpoint, or create your own, has no bearing whatsoever on how you access the WS.

not able to download the wsdl file(manual) file from the specified location

There's nothing to download. You simple save the web page that gets displayed when you click on the "WSDL" link.
[ January 05, 2006: Message edited by: Ulf Dittmer ]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Deploying the webservice