• Post Reply Bookmark Topic Watch Topic
  • New Topic

Contract First JAXWS/ Endpoint without an implementor  RSS feed

 
Mike De
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I need to directly access the XML that comes in from a web service request.

The goal is to provide a wsdl have JAXWS manage the http traffic, routing and xsd validation(from within the wsdl) and then use transforms on the data and pass it on to in the translated form.

The issue is there is no Java class representation of the input message and both the payload of the message and the transforms are user defined... So its not an option to create a class via a translation utility.

As far as I can tell the only way to create an endpoint is using an annotated class:


Instead I would like to provide a class that has a callback or something which would be fired with a string of the content of the web service request:


I suppose I only need a subset of the functionality JAX-WS provides, I just don't want the part that does the xml to java binding.

1. Can I do this with the JAX WS api?
2. Any suggestion of another framework that will allow me to do just this?
3. Any other forums or resources that would be helpful?
Thanks

 
Ivan Krizsan
Ranch Hand
Posts: 2198
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi!
I don't know if it is exactly what you want, but have you had a look at javax.xml.ws.Provider?
Reference: Section 5.1 of the JAX-WS 2.1 Specification document.
Best wishes!
 
Mike De
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ivan Krizsan wrote:Hi!
I don't know if it is exactly what you want, but have you had a look at javax.xml.ws.Provider?
Reference: Section 5.1 of the JAX-WS 2.1 Specification document.
Best wishes!


Thanks, it looks to do what I want. Following the example on this page actually walks you through a transform example:
http://java.sun.com/mailers/techtips/enterprise/2006/TechTips_July06.html
It uses a glass fish, is that just a product of how old the article is, or can I use the Endpoint API passing a provider? I'm not sure how to ask Google that question I'll post the answer if I find it first.
 
Ivan Krizsan
Ranch Hand
Posts: 2198
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi!
GlassFish contains, if not the absolutely newest version of Metro (the reference implementation of JAX-WS), a very recent version of Metro.
If you go for GlassFish v2.1.1 or even better v3, then you can be assured that you are at the cutting edge!
Best wishes!
 
Mike De
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Ivan,
The dispatcher and provider are exactly what I want.
I found a good example here:
http://blogs.sun.com/artf/entry/operating_at_the_xml_message
If you want you can pass the WebServiceProvider into the Endpoint class and publish it just like an annotated WebService

Wsdl:


public static void main(String args):
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!