users@jax-rpc.java.net

Re: comparing JAX-RPC web service created with deploytool and with plain wsdeploy (Sun J2EE 1.4 RI)

From: Merten Schumann <Merten.Schumann_at_asg.com>
Date: Mon, 19 Jul 2004 13:09:16 +0200

Thank you, Doug!
I think I have understood now that there are two ways to make
"deployable" .war files for Sun App Server.

One is with wsdeploy (plain JAX-RPC), there you need to write a
jaxrpc-ri.xml file to specify the endpoint.

The other one (J2EE 1.4 tutorial one) is with the file webservices.xml
(referencing wscompile generated mapping file and WSDL) (and
sun-web.xml, obviously not really needed, if web.xml contains servlet
information). In this approach, some classes (which are created by
wsdeploy step to the cooked .war in the wsdeploy approach) are obviously
created under the hood.

A bit confusing for me was: in wsdeploy approach, it seems web.xml in
the raw .war file should contain an empty <web-app>.

In the other approach, web.xml has to contain some content, like
<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns="http://java.sun.com/xml/ns/j2ee" version="2.4"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
<display-name>HelloServiceExample</display-name>
<servlet>
<servlet-name>HelloServiceImpl</servlet-name>
<servlet-class>helloservice.HelloServiceImpl</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>HelloServiceImpl</servlet-name>
<url-pattern>/hello</url-pattern>
</servlet-mapping>
</web-app>

When I used such an web.xml in wsdeploy approach, I got at deploy time
WARNING|sun-appserver-pe8.0|javax.enterprise.system.tools.deployment|_Th
readID=11;|Deployment Error
com.sun.enterprise.deployment.backend.IASDeploymentException: Error
loading deployment descriptors for HelloService Line 3 Column
176 -- Attribute "xmlns:xsi" must be declared for element type
"servlet".


My next lessons will be to add authentication and to assemble an .ear
...

cu
   Merten

> -----Original Message-----
> From: Doug Kohlert [mailto:Doug.Kohlert_at_Sun.COM]
> Sent: Friday, July 16, 2004 7:25 PM
> To: users_at_jax-rpc.dev.java.net
> Subject: Re: comparing JAX-RPC web service created with
> deploytool and with plain wsdeploy (Sun J2EE 1.4 RI)
>
> Merten,
> Once you have a war files that contains a Tie class and serializer
> classes, it will only run on app servers configured with the
> JAXRPC RI runtime.
>
> Merten Schumann wrote:
>
> >Hello,
> >
> >playing with Sun J2EE RI 1.4, I followed the whitepapers
> >
> >
> >
> >>-----Original Message-----
> >>From: Doug Kohlert
> >>Sent: Monday, July 12, 2004 7:26 PM
> >>To: users_at_jax-rpc.dev.java.net
> >>Subject: Re: Attention JAXRPC RI Users: FeedBack needed
> >>
> >>Merten,
> >>On the JAXRPC java.net page at: https://jax-rpc.dev.java.net/
> >>there is a section on documentation. I believe the whitepaper on
> >>Understanding your JAX-RPC SI Environment has documentation
> on the ant
> >>
> >>
> >
> >
> >
> >>tasks.
> >>
> >>
> >...
> >
> >to create a JAXRPC web service by hand, not by using
> deploytool. I want
> >to understand what's going on behind the scenes.
> >
> >The interesting thing is, when I create the HelloService sample
> >according to the white papers, I do end up with a lot more classes in
> >the .war file (...RequestStruct.class, ...Tie.class). In the .war
> >created by deploytool, I have this sun-web.xml and webservices.xml
> >stuff, which is not mentioned in whitepapers (since it's not
> portable, I
> >guess).
> >
> >Makes the mapping file (created in wscompile step) the
> difference? It's
> >in the deploytool generated .war. In the white papers it's
> not used in
> >the wsdeploy step ...
> >
> >Is the .war file generated by wsdeploy (AAA) portable? When
> I do open it
> >in deploytool, its different from the deploytool generated
> (BBB) one. In
> >example, on tab "General", AAA is shown there as a servlet
> with Servlet
> >Class "com.sun.xml.rpc.server.http.JAXRPCServlet", for BBB is shown
> >under "Service Endpoint Implementation" "helloservice.HelloImpl". And
> >for BBB there is an "Endpoint" tab, which not exists for AAA. I guess
> >this all is just due to missing "sun-web.xml" and "webservices.xml"
> >files in AAA and AAA is portable.
> >
> >Thank you!
> > Merten
> >
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: users-unsubscribe_at_jax-rpc.dev.java.net
> >For additional commands, e-mail: users-help_at_jax-rpc.dev.java.net
> >
> >
> >
> >
>
> --
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> Doug Kohlert
>
> Sun Microsystems, Inc.
> doug.kohlert_at_sun.com
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_jax-rpc.dev.java.net
> For additional commands, e-mail: users-help_at_jax-rpc.dev.java.net
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe_at_jax-rpc.dev.java.net
For additional commands, e-mail: users-help_at_jax-rpc.dev.java.net