RE: jms client

2008-01-22 Thread Mayank Thakore
Hi,

After getting the service I could add the port to it and then get the
service proxy.

service.addPort(portName,
"http://schemas.xmlsoap.org/soap/";,
endPointURL);
NotificationConsumer consumer = service.getPort(portName,
NotificationConsumer.class);

But, problem is that this port does not have JMS information which we
provide per port in the wsdl.

  




Hence, when trying to use the proxy, it fails with exception similar to when
wsdl is not provided in the service annotation.

So, now that I can add the port, how to provide the jms destination specific
information?

Thanks!

Regards
Mayank

-Original Message-
From: Mayank Thakore [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, January 23, 2008 11:53
To: cxf-user@incubator.apache.org
Subject: jms client

Hi,

I need to write client to contact several JMS service instances. I will know
their queue names only at runtime.

If I provide wsdl to the client code, then it only contacts the port listed
in the wsdl.

(In http I could provide the server's wsdl by appending ?wsdl to the url,
but this can't be done for jms urls)

 

How to contact server? The service definition is same. The jndi is also
same. Only the queue names will differ.

 

Thanks!

 

Regards

Mayank

 



 This e-mail and attachments contain confidential information from HUAWEI,
which is intended only for the person or entity whose address is listed
above. Any use of the information contained herein in any way (including,
but not limited to, total or partial disclosure, reproduction, or
dissemination) by persons other than the intended recipient's) is
prohibited. If you receive this e-mail in error, please notify the sender by
phone or email immediately and delete it!

 





Creating and publishing services from wsdl

2008-01-22 Thread Rob Barrett
Hi,

I have a large set of existing WSDL describing ~200 business
interfaces, and a set of classes that bind SOAP to the underlying
services and vice-versa.

I'm trying to publish these services through CXF, and so far have had
mixed results

My approach has been to subclass the CXFServlet, and on init() read
the WSDL files from a jar on the classpath and use the
WSDLServiceFactory to load these definitions. That worked ok.

Now I want to

1. publish the services
and
2. register custom databinders and invokers for them

I'm not sure how to do that. Rather than messing about at what i
suspect is too low a level I thought I'd ask if there's a better way.

Cheers, Rob


jms client

2008-01-22 Thread Mayank Thakore
Hi,

I need to write client to contact several JMS service instances. I will know
their queue names only at runtime.

If I provide wsdl to the client code, then it only contacts the port listed
in the wsdl.

(In http I could provide the server's wsdl by appending ?wsdl to the url,
but this can't be done for jms urls)

 

How to contact server? The service definition is same. The jndi is also
same. Only the queue names will differ.

 

Thanks!

 

Regards

Mayank

 



 This e-mail and attachments contain confidential information from HUAWEI,
which is intended only for the person or entity whose address is listed
above. Any use of the information contained herein in any way (including,
but not limited to, total or partial disclosure, reproduction, or
dissemination) by persons other than the intended recipient's) is
prohibited. If you receive this e-mail in error, please notify the sender by
phone or email immediately and delete it!

 



RE: Any book written on xfire

2008-01-22 Thread Mayank Thakore
 I would definitely buy a book if it goes into the details of using cxf. Not
just jasws or wsdl or stuff but also about cxf interceptors, arch etc.

Regards
Mayank 


 This e-mail and attachments contain confidential information from HUAWEI,
which is intended only for the person or entity whose address is listed
above. Any use of the information contained herein in any way (including,
but not limited to, total or partial disclosure, reproduction, or
dissemination) by persons other than the intended recipient's) is
prohibited. If you receive this e-mail in error, please notify the sender by
phone or email immediately and delete it!

-Original Message-
From: Adrian Trenaman [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, January 22, 2008 20:15
To: cxf-user@incubator.apache.org
Subject: Re: Any book written on xfire


Hi Anshul ,

I've written a 2-day training course on JAX-WS development using CXF; am
delivering a cut down version of this at OOP in Munich later this week. I've
been toying with the idea of producing a developer's handbook for CXF; would
be interested to know if you think there's a market for it!

For the minute, I concur with Glen that the online documentation for CXF is
a pretty good start. You might also want to take a look at the Fuse Service
Framework documentation, available on open.iona.com 

http://open.iona.com/documentation/fuse-service-framework-documentation

Warm regards,
Ade.


Glen Mazza-2 wrote:
> 
> I like Hansen's book[1], although it is about JAX-WS in general (either
> CXF or GlassFish Metro).  Presently our online user's guide[2] is the
> best source for CXF-specific information.  
> 
> HTH,
> Glen
> 
> [1] http://www.jroller.com/gmazza/date/20070809
> [2] http://cwiki.apache.org/CXF20DOC/index.html
> 
> 
> Am Dienstag, den 22.01.2008, 09:09 + schrieb Anshul Dutta:
>> Does any one knows about a good book on xfire or cxf?
>> Or any SOA book that includes these topics?
>> 
>> Thanks,
>> ad
>> 
>> 
>> 
>> This email has been scanned for all known viruses by the MessageLabs
>> Email Security Service and the Macro 4 plc internal virus protection
>> system.
>> 
> 
> 
> 

-- 
View this message in context:
http://www.nabble.com/Any-book-written-on-xfire-tp15015038p15019897.html
Sent from the cxf-user mailing list archive at Nabble.com.





Re: WSS4J - Protection Order

2008-01-22 Thread Mayank Mishra

Hi Fred,

Yes, you are right. I am talking about the scenario when we have 
multiple EncryptedData elements and I want to sign only one of them. 
Yes, I agree XPath would have been much better to handle such scenario.


But AFAIK, we can specify parts (WSEncryptionPart) during 
SignatureAction by initializing part structure with element Id (I guess 
it is wsu:id, which we can get from map populated during encryptionAction).


I am yet to test it. I will let you know about it.

With Regards,
Mayank


Fred Dushin wrote:

Hi Mayank,

When you say "one way to achieve this is to specify the URI of the 
EncryptedData", do you mean QName, instead of URI?


I get the sense from what you are saying that your message may have 
multiple EncryptedData elements in it, and you want to sign one, but 
not others.  Is that right?


If you have only one EncryptedData, then you should be able to direct 
the WSS4J toolkit to sign it, by specifying the EncryptedData QName, 
in configuration of the interceptor.


Unfortunately, WSS4J does not provide XPath support for protecting 
(signing/encrypting) message parts, so using QNames is inherently 
ambiguous.


-Fred

On Jan 18, 2008, at 2:24 AM, Mayank Mishra wrote:


Any reply to this thread will be highly appreciated.

Thanking in advance,

With Regards,
Mayank

Mayank Mishra wrote:

Hi,

Usually we use, Sign and then Encrypt action for any particular xml 
element. If I want to use Encrypt and then Sign for a particular xml 
element, then SignatureAction fails to find the xml element. The 
reason is it has been encrypted and hence corresponding 
EncryptedData element will be there.


One way to achieve this, is to specify, URI of EncryptedData itself 
in the signature parts. (It should work, though I haven't tested 
it). But this is not a full proof solution if I want only specific 
element only to be encrypted and eventually signed.


*Is there any mechanism to achieve this?* The only way I can think 
of achieving this is to maintain a list of wsu:id's of corresponding 
EncryptedData elements and add URI of them to Signature Parts during 
.SignatureAction. This may be performed in adding another 
interceptor which handles the message after encryption has been done.


Please let me know your views/suggestions about this.

Thanking in advance. :)

With Regards,
Mayank










Re: problem using local transport

2008-01-22 Thread Willem Jiang

Hi,

Did you do any setting up the transportIds for the local transport  in 
CXF bus?
You need to override the CXF bus default loading transport factory to 
local transport.


Here are an example of setting the bus with code in the jaxws front end 
test module[1],

and a spring configuration file [2] for the local transport factory.

[1]https://svn.apache.org/repos/asf/incubator/cxf/trunk/rt/frontend/jaxws/src/test/java/org/apache/cxf/jaxws/AbstractJaxWsTest.java
[2]https://svn.apache.org/repos/asf/incubator/cxf/trunk/rt/frontend/jaxws/src/test/java/org/apache/cxf/jaxws/spring/servers.xml

Willem.

Mayank Thakore wrote:

Hi,
I am trying to use local transport. Like this:

String url = "local://HelloService";
Endpoint.publish(url, new HelloServiceImpl());

This client code I found at bottom of user guide's local transport page:
ClientProxyFactoryBean cf = new ClientProxyFactoryBean();
cf.setAddress(url);
cf.setServiceClass(HelloService.class);
HelloService h = (HelloService) cf.create();
System.out.println(h.inverse(false));

HelloService is defined as below:
@WebService
public interface HelloService {
public boolean inverse(
boolean value);

}

I have placed the client code immediately below the publish code. But I get
an exception:



Exception in thread "main" org.apache.cxf.binding.soap.SoapFault: null while
invoking public boolean
com.huawei.imap.nbiframework.testutil.webservice.HelloServiceImpl.inverse(bo
olean) with params [null].
at
org.apache.cxf.binding.soap.interceptor.Soap11FaultInInterceptor.handleMessa
ge(Soap11FaultInInterceptor.java:70)
at
org.apache.cxf.binding.soap.interceptor.Soap11FaultInInterceptor.handleMessa
ge(Soap11FaultInInterceptor.java:35)
at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain
.java:207)
at
org.apache.cxf.interceptor.AbstractFaultChainInitiatorObserver.onMessage(Abs
tractFaultChainInitiatorObserver.java:90)
at
org.apache.cxf.binding.soap.interceptor.ReadHeadersInterceptor.handleMessage
(ReadHeadersInterceptor.java:179)
at
org.apache.cxf.binding.soap.interceptor.ReadHeadersInterceptor.handleMessage
(ReadHeadersInterceptor.java:56)
at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain
.java:207)
at org.apache.cxf.endpoint.ClientImpl.onMessage(ClientImpl.java:402)
at
org.apache.cxf.transport.local.LocalDestination$SynchronousConduit$1.run(Loc
alDestination.java:88)
at java.lang.Thread.run(Unknown Source)



Regards
Mayank



 This e-mail and attachments contain confidential information from HUAWEI,
which is intended only for the person or entity whose address is listed
above. Any use of the information contained herein in any way (including,
but not limited to, total or partial disclosure, reproduction, or
dissemination) by persons other than the intended recipient's) is
prohibited. If you receive this e-mail in error, please notify the sender by
phone or email immediately and delete it!




  




RE: JSON and JAX-RS

2008-01-22 Thread Vespa, Anthony J
Interesting.  Would that mean I would have to use seekAlso and list all of the 
objects that could possibly be returned - I have currently about six types of 
custom objects.  What if I was returning a type like a boolean or just a string?



From: Daniel Kulp [mailto:[EMAIL PROTECTED]
Sent: Tue 1/22/2008 5:31 PM
To: cxf-user@incubator.apache.org
Cc: Vespa, Anthony J
Subject: Re: JSON and JAX-RS




Well, looking at the code, it seems to create a new JAXBContext for each
top level type, which really sucks.   IMO, it should use our
JAXBDatabinding in some way which would allow it/you to configure things
via spring or something so one one JAXBContext is created/used that
would have all the required types in it.   Actually, checking if there
is an ObjectFactory in the package and creating the context based on
that would also go a long way to helping. 

That said,  with JAXB 2.1, you can probably add an @XmlSeeAlso annation
on the wsResponse that points to the wsMessage to make the JAXBContext
for the wsResponse be able to marshal the wsMessage as well.

Dan


On Tuesday 22 January 2008, Vespa, Anthony J wrote:
> So I spent some time playing with JAX-RS and I seem to have
> encountered an issue.
>
> I can return single objects from my service as JSON (standard Java
> types as well as my custom objects) but if I try to return my wrapper
> object which contains an anytype generic list, I get an exception.
>
> Effectively I have an object called wsResponse that, in this case, is
> returning an array of messages (wsMessage) - I have decorated both
> objects with the XMLType.  I am looking into this exception and see
> references to JAXB; is it possible to get around this?
>
>
>
> Jan 22, 2008 4:45:26 PM
> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor handleMessage
> INFO: Available content types for response is: application/json,
> Jan 22, 2008 4:45:26 PM
> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor handleMessage
> INFO: Response EntityProvider is:
> org.apache.cxf.jaxrs.provider.JSONProvider
> Jan 22, 2008 4:45:26 PM
> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor handleMessage
> INFO: Response content type is: application/json
> javax.xml.bind.MarshalException
>  - with linked exception:
> [javax.xml.bind.JAXBException: class com.cbs.bos.data.ws.wsMessage nor
> any of its super class is known to this context.]
> at
> com.sun.xml.bind.v2.runtime.MarshallerImpl.write(MarshallerImpl.java:2
>95 )
> at
> com.sun.xml.bind.v2.runtime.MarshallerImpl.marshal(MarshallerImpl.java
>:1 48)
> at
> org.apache.cxf.jaxrs.provider.JSONProvider.writeTo(JSONProvider.java:9
>0) at
> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.handleMessage(JAX
>RS OutInterceptor.java:99)
> at
> org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseIntercepto
>rC hain.java:208)
> at
> org.apache.cxf.interceptor.OutgoingChainInterceptor.handleMessage(Outg
>oi ngChainInterceptor.java:74)
> at
> org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseIntercepto
>rC hain.java:208)
> at
> org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitia
>ti onObserver.java:78)
> at
> org.apache.cxf.transport.servlet.ServletDestination.doMessage(ServletD
>es tination.java:79)
> at
> org.apache.cxf.transport.servlet.ServletController.invokeDestination(S
>er vletController.java:264)
> at
> org.apache.cxf.transport.servlet.ServletController.invoke(ServletContr
>ol ler.java:123)
> at
> org.apache.cxf.transport.servlet.AbstractCXFServlet.invoke(AbstractCXF
>Se rvlet.java:170)
> at
> org.apache.cxf.transport.servlet.AbstractCXFServlet.doGet(AbstractCXFS
>er vlet.java:152)
> at
> javax.servlet.http.HttpServlet.service(HttpServlet.java:690) at
> javax.servlet.http.HttpServlet.service(HttpServlet.java:803) at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appli
>ca tionFilterChain.java:290)
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFi
>lt erChain.java:206)
> at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperVa
>lv e.java:233)
> at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextVa
>lv e.java:175)
> at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.ja
>va
>
> :128)
>
> at
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.ja
>va
>
> :102)
>
> at
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValv
>e. java:109)
> at
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java
>:2 63)
> at
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:
>84 4)
> at
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.proces
>s( Http11Protocol.java:584)
> at
> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoin

Re: JSON and JAX-RS

2008-01-22 Thread Daniel Kulp

Well, looking at the code, it seems to create a new JAXBContext for each 
top level type, which really sucks.   IMO, it should use our 
JAXBDatabinding in some way which would allow it/you to configure things 
via spring or something so one one JAXBContext is created/used that 
would have all the required types in it.   Actually, checking if there 
is an ObjectFactory in the package and creating the context based on 
that would also go a long way to helping.  

That said,  with JAXB 2.1, you can probably add an @XmlSeeAlso annation 
on the wsResponse that points to the wsMessage to make the JAXBContext 
for the wsResponse be able to marshal the wsMessage as well.

Dan


On Tuesday 22 January 2008, Vespa, Anthony J wrote:
> So I spent some time playing with JAX-RS and I seem to have
> encountered an issue.
>
> I can return single objects from my service as JSON (standard Java
> types as well as my custom objects) but if I try to return my wrapper
> object which contains an anytype generic list, I get an exception.
>
> Effectively I have an object called wsResponse that, in this case, is
> returning an array of messages (wsMessage) - I have decorated both
> objects with the XMLType.  I am looking into this exception and see
> references to JAXB; is it possible to get around this?
>
>
>
> Jan 22, 2008 4:45:26 PM
> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor handleMessage
> INFO: Available content types for response is: application/json,
> Jan 22, 2008 4:45:26 PM
> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor handleMessage
> INFO: Response EntityProvider is:
> org.apache.cxf.jaxrs.provider.JSONProvider
> Jan 22, 2008 4:45:26 PM
> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor handleMessage
> INFO: Response content type is: application/json
> javax.xml.bind.MarshalException
>  - with linked exception:
> [javax.xml.bind.JAXBException: class com.cbs.bos.data.ws.wsMessage nor
> any of its super class is known to this context.]
> at
> com.sun.xml.bind.v2.runtime.MarshallerImpl.write(MarshallerImpl.java:2
>95 )
> at
> com.sun.xml.bind.v2.runtime.MarshallerImpl.marshal(MarshallerImpl.java
>:1 48)
> at
> org.apache.cxf.jaxrs.provider.JSONProvider.writeTo(JSONProvider.java:9
>0) at
> org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.handleMessage(JAX
>RS OutInterceptor.java:99)
> at
> org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseIntercepto
>rC hain.java:208)
> at
> org.apache.cxf.interceptor.OutgoingChainInterceptor.handleMessage(Outg
>oi ngChainInterceptor.java:74)
> at
> org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseIntercepto
>rC hain.java:208)
> at
> org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitia
>ti onObserver.java:78)
> at
> org.apache.cxf.transport.servlet.ServletDestination.doMessage(ServletD
>es tination.java:79)
> at
> org.apache.cxf.transport.servlet.ServletController.invokeDestination(S
>er vletController.java:264)
> at
> org.apache.cxf.transport.servlet.ServletController.invoke(ServletContr
>ol ler.java:123)
> at
> org.apache.cxf.transport.servlet.AbstractCXFServlet.invoke(AbstractCXF
>Se rvlet.java:170)
> at
> org.apache.cxf.transport.servlet.AbstractCXFServlet.doGet(AbstractCXFS
>er vlet.java:152)
> at
> javax.servlet.http.HttpServlet.service(HttpServlet.java:690) at
> javax.servlet.http.HttpServlet.service(HttpServlet.java:803) at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appli
>ca tionFilterChain.java:290)
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFi
>lt erChain.java:206)
> at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperVa
>lv e.java:233)
> at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextVa
>lv e.java:175)
> at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.ja
>va
>
> :128)
>
> at
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.ja
>va
>
> :102)
>
> at
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValv
>e. java:109)
> at
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java
>:2 63)
> at
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:
>84 4)
> at
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.proces
>s( Http11Protocol.java:584)
> at
> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447
>)



-- 
J. Daniel Kulp
Principal Engineer, IONA
[EMAIL PROTECTED]
http://www.dankulp.com/blog


RE: JSON and JAX-RS

2008-01-22 Thread Vespa, Anthony J
I did try that, and I get the same error. 

-Original Message-
From: Beryozkin, Sergey [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, January 22, 2008 5:14 PM
To: cxf-user@incubator.apache.org
Subject: RE: JSON and JAX-RS

Hi

org.apache.cxf.jaxrs.provider.JSONProvider checks XMLRootElement
annotations.
Would it make a difference if you annotate both wsResponse and wsMessage
classes with this annotation ?

Cheers, Sergey



-Original Message-
From: Vespa, Anthony J [mailto:[EMAIL PROTECTED] 
Sent: 22 January 2008 21:48
To: cxf-user@incubator.apache.org
Subject: JSON and JAX-RS

So I spent some time playing with JAX-RS and I seem to have encountered
an issue.

I can return single objects from my service as JSON (standard Java types
as well as my custom objects) but if I try to return my wrapper object
which contains an anytype generic list, I get an exception.

Effectively I have an object called wsResponse that, in this case, is
returning an array of messages (wsMessage) - I have decorated both
objects with the XMLType.  I am looking into this exception and see
references to JAXB; is it possible to get around this?



Jan 22, 2008 4:45:26 PM
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor handleMessage
INFO: Available content types for response is: application/json,
Jan 22, 2008 4:45:26 PM
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor handleMessage
INFO: Response EntityProvider is:
org.apache.cxf.jaxrs.provider.JSONProvider
Jan 22, 2008 4:45:26 PM
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor handleMessage
INFO: Response content type is: application/json
javax.xml.bind.MarshalException
 - with linked exception:
[javax.xml.bind.JAXBException: class com.cbs.bos.data.ws.wsMessage nor
any of its super class is known to this context.]
at
com.sun.xml.bind.v2.runtime.MarshallerImpl.write(MarshallerImpl.java:295
)
at
com.sun.xml.bind.v2.runtime.MarshallerImpl.marshal(MarshallerImpl.java:1
48)
at
org.apache.cxf.jaxrs.provider.JSONProvider.writeTo(JSONProvider.java:90)
at
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.handleMessage(JAXRS
OutInterceptor.java:99)
at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorC
hain.java:208)
at
org.apache.cxf.interceptor.OutgoingChainInterceptor.handleMessage(Outgoi
ngChainInterceptor.java:74)
at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorC
hain.java:208)
at
org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiati
onObserver.java:78)
at
org.apache.cxf.transport.servlet.ServletDestination.doMessage(ServletDes
tination.java:79)
at
org.apache.cxf.transport.servlet.ServletController.invokeDestination(Ser
vletController.java:264)
at
org.apache.cxf.transport.servlet.ServletController.invoke(ServletControl
ler.java:123)
at
org.apache.cxf.transport.servlet.AbstractCXFServlet.invoke(AbstractCXFSe
rvlet.java:170)
at
org.apache.cxf.transport.servlet.AbstractCXFServlet.doGet(AbstractCXFSer
vlet.java:152)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:690)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
tionFilterChain.java:290)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
erChain.java:206)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv
e.java:233)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValv
e.java:175)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java
:128)
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java
:102)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.
java:109)
at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:2
63)
at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:84
4)
at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(
Http11Protocol.java:584)
at
org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)


IONA Technologies PLC (registered in Ireland)
Registered Number: 171387
Registered Address: The IONA Building, Shelbourne Road, Dublin 4,
Ireland


RE: JSON and JAX-RS

2008-01-22 Thread Beryozkin, Sergey
Hi

org.apache.cxf.jaxrs.provider.JSONProvider checks XMLRootElement
annotations.
Would it make a difference if you annotate both wsResponse and wsMessage
classes with this annotation ?

Cheers, Sergey



-Original Message-
From: Vespa, Anthony J [mailto:[EMAIL PROTECTED] 
Sent: 22 January 2008 21:48
To: cxf-user@incubator.apache.org
Subject: JSON and JAX-RS

So I spent some time playing with JAX-RS and I seem to have encountered
an issue.

I can return single objects from my service as JSON (standard Java types
as well as my custom objects) but if I try to return my wrapper object
which contains an anytype generic list, I get an exception.

Effectively I have an object called wsResponse that, in this case, is
returning an array of messages (wsMessage) - I have decorated both
objects with the XMLType.  I am looking into this exception and see
references to JAXB; is it possible to get around this?



Jan 22, 2008 4:45:26 PM
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor handleMessage
INFO: Available content types for response is: application/json,
Jan 22, 2008 4:45:26 PM
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor handleMessage
INFO: Response EntityProvider is:
org.apache.cxf.jaxrs.provider.JSONProvider
Jan 22, 2008 4:45:26 PM
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor handleMessage
INFO: Response content type is: application/json
javax.xml.bind.MarshalException
 - with linked exception:
[javax.xml.bind.JAXBException: class com.cbs.bos.data.ws.wsMessage nor
any of its super class is known to this context.]
at
com.sun.xml.bind.v2.runtime.MarshallerImpl.write(MarshallerImpl.java:295
)
at
com.sun.xml.bind.v2.runtime.MarshallerImpl.marshal(MarshallerImpl.java:1
48)
at
org.apache.cxf.jaxrs.provider.JSONProvider.writeTo(JSONProvider.java:90)
at
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.handleMessage(JAXRS
OutInterceptor.java:99)
at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorC
hain.java:208)
at
org.apache.cxf.interceptor.OutgoingChainInterceptor.handleMessage(Outgoi
ngChainInterceptor.java:74)
at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorC
hain.java:208)
at
org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiati
onObserver.java:78)
at
org.apache.cxf.transport.servlet.ServletDestination.doMessage(ServletDes
tination.java:79)
at
org.apache.cxf.transport.servlet.ServletController.invokeDestination(Ser
vletController.java:264)
at
org.apache.cxf.transport.servlet.ServletController.invoke(ServletControl
ler.java:123)
at
org.apache.cxf.transport.servlet.AbstractCXFServlet.invoke(AbstractCXFSe
rvlet.java:170)
at
org.apache.cxf.transport.servlet.AbstractCXFServlet.doGet(AbstractCXFSer
vlet.java:152)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:690)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
tionFilterChain.java:290)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
erChain.java:206)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv
e.java:233)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValv
e.java:175)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java
:128)
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java
:102)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.
java:109)
at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:2
63)
at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:84
4)
at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(
Http11Protocol.java:584)
at
org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)


IONA Technologies PLC (registered in Ireland)
Registered Number: 171387
Registered Address: The IONA Building, Shelbourne Road, Dublin 4, Ireland


JSON and JAX-RS

2008-01-22 Thread Vespa, Anthony J
So I spent some time playing with JAX-RS and I seem to have encountered
an issue.

I can return single objects from my service as JSON (standard Java types
as well as my custom objects) but if I try to return my wrapper object
which contains an anytype generic list, I get an exception.

Effectively I have an object called wsResponse that, in this case, is
returning an array of messages (wsMessage) - I have decorated both
objects with the XMLType.  I am looking into this exception and see
references to JAXB; is it possible to get around this?



Jan 22, 2008 4:45:26 PM
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor handleMessage
INFO: Available content types for response is: application/json,
Jan 22, 2008 4:45:26 PM
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor handleMessage
INFO: Response EntityProvider is:
org.apache.cxf.jaxrs.provider.JSONProvider
Jan 22, 2008 4:45:26 PM
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor handleMessage
INFO: Response content type is: application/json
javax.xml.bind.MarshalException
 - with linked exception:
[javax.xml.bind.JAXBException: class com.cbs.bos.data.ws.wsMessage nor
any of its super class is known to this context.]
at
com.sun.xml.bind.v2.runtime.MarshallerImpl.write(MarshallerImpl.java:295
)
at
com.sun.xml.bind.v2.runtime.MarshallerImpl.marshal(MarshallerImpl.java:1
48)
at
org.apache.cxf.jaxrs.provider.JSONProvider.writeTo(JSONProvider.java:90)
at
org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor.handleMessage(JAXRS
OutInterceptor.java:99)
at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorC
hain.java:208)
at
org.apache.cxf.interceptor.OutgoingChainInterceptor.handleMessage(Outgoi
ngChainInterceptor.java:74)
at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorC
hain.java:208)
at
org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiati
onObserver.java:78)
at
org.apache.cxf.transport.servlet.ServletDestination.doMessage(ServletDes
tination.java:79)
at
org.apache.cxf.transport.servlet.ServletController.invokeDestination(Ser
vletController.java:264)
at
org.apache.cxf.transport.servlet.ServletController.invoke(ServletControl
ler.java:123)
at
org.apache.cxf.transport.servlet.AbstractCXFServlet.invoke(AbstractCXFSe
rvlet.java:170)
at
org.apache.cxf.transport.servlet.AbstractCXFServlet.doGet(AbstractCXFSer
vlet.java:152)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:690)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
tionFilterChain.java:290)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
erChain.java:206)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv
e.java:233)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValv
e.java:175)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java
:128)
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java
:102)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.
java:109)
at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:2
63)
at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:84
4)
at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(
Http11Protocol.java:584)
at
org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)


Re: Generating headers

2008-01-22 Thread Daniel Kulp
On Monday 21 January 2008, Frederick N. Brier wrote:
> The WSDL2Java CXF generated web service is not sending a SOAP header.
> Perhaps it is because it is an implicit header?  I tried the -exsh,
> but that did not cause the header to be generated.  The doc seems to
> indicate that it causes the header to be processed if it is not there,
> implying that this is more a server side feature than the client.  Is
> that correct?  Is there another (easy ) way of
> forcing SOAP header to be generated?  Thank you.

I'd probably have to see the wsdl to see if the code generator would even 
pick it up with the "-exsh true" stuff.   The exsh grabs headers that 
are declared in the soap:binding, but aren't in the same message as the 
other parameters of the method.

If you just want to send a header that ISN'T really declared as a header 
in the wsdl, you can do it, it's just a bit more complex as the JAX-WS 
spec doesn't really address how to do that other than to use an SAAJ 
handler thing, which kind of sucks.

With CXF, you can pass additional headers in through the request context.  
The test case could be used as an example:
http://svn.apache.org/repos/asf/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/outofband/header/OOBHeaderTest.java

Basically, you create your header object (JAXB or DOM is fine), add it to 
a List thing, add that to the context, and they'll get sent off.   
Likewise, headers coming in off the wire would be in the response 
context.

-- 
J. Daniel Kulp
Principal Engineer, IONA
[EMAIL PROTECTED]
http://www.dankulp.com/blog


Re: Interceptor performance tips

2008-01-22 Thread Daniel Kulp

Christian,

As Fred mentioned, doing the SAAJ stuff is definitely expensive, 
especially if the body of the message is large.   With SAAJ, the entire 
message pretty much gets sucked into memory consuming memory, causeing 
extra garbage collections, etc...  The Sun RI SAAJ impl isn't exactly 
quick either.If you CAN avoid it, it's recommended to try.

If all you need is the headers to process yourself, you could just stick 
an interceptor anytime after the SOAP   ReadHeadersInterceptor (runs in 
the READ phase) and at that point, the Message will be a SoapMessage 
that has a "List getHeaders()" method on it.   You can grab the 
information you need directly out of there.Doing this allows 
the "body" part of the message to stream directly into the jaxb objects 
like it normally would without having to SAAJ parse it all.

Dan




On Monday 21 January 2008, Christian Vest Hansen wrote:
> Hi,
>
> We've rolled our own specialized WS-Security in-interceptor
> (implementing PhaseInterceptor) to integrate with our single sign-on
> system.
>
> This is all nice, except that this interceptor seems to add quite an
> overhead to our web services.
>
> The interceptor operates in the UNMARSHAL phase and specifies its
> placement in the PhaseInterceptorChain to be AFTER a SAAJInInterceptor
> and an RPCInInterceptor.
>
> It uses the SAAJInInterceptor's SOAPMessage to read the WS-Security
> headers, and the RPCInInterceptor is used for improved fault handling.
>
> I haven't done any real profiling on it yet (shame on me), but I'm
> thinking that maybe the SAAJInInterceptor is one of bad guys,
> performance wise, and we've discusses if we should read the wss
> headers with stax instead.
>
> I wonder if you have any performance tips, or other ideas that might
> help improve this setup?



-- 
J. Daniel Kulp
Principal Engineer, IONA
[EMAIL PROTECTED]
http://www.dankulp.com/blog


Re: JCA demo raises java.lang.UnsupportedOperation when deployed in JBOSS

2008-01-22 Thread YI (William) ZHU

Hi,

I met some similar troubles with JBoss 4.2.2, CXF2.0.2 and JDK 1.5.0_14.

When I deploy the JCA J2ee connector on JBoss, I found the following error
messages on JBoss console:

ERROR [STDERR] Jan 22, 2008 3:27:29 PM 
org.apache.cxf.jca.cxf.ManagedConnectionFactoryImpl 

ERROR [STDERR] Jan 22, 2008 3:27:29 PM
org.apache.cxf.jca.cxf.AssociatedManagedConnectionFactoryImpl 

ERROR [STDERR] Jan 22, 2008 3:27:29 PM
org.apache.cxf.jca.cxf.AssociatedManagedConnectionFactoryImpl
setResourceAdapter
INFO: Associate Resource Adapter with ManagedConnectionFactory by appserver.
ra = null

ERROR [STDERR] Jan 22, 2008 3:27:29 PM
org.apache.cxf.jca.cxf.ManagedConnectionFactoryImpl createConnectionFactory

Could someone tell me that the CXF j2ee connector (CXF2.0.2) tested with
JBoss4.2.2?

Thanks,




Adrian Trenaman wrote:
> 
> Hi,
> 
> Has anyone experienced any problems deploying the JCA adaptor into JBoss?
> I was experiencing problems and have reproduced with the demo in
> samples/integration/jca/hello_world. When the servlet invokes on the
> proxy, we get: 
> 
> java.lang.UnsupportedOperationException: setProperty must be
> overridden by all subclasses of SOAP Message
> 
> I'm using JDK 1.5.0_09, CXF 2.0.1 and JBoss 4.2.1. Have also gotten the
> same problem with JBoss 5.0.0 Beta 2. 
> 
> Google shows that others have also experienced this problem; some
> workarounds are suggested around putting libraries (jboss-jaxrpc.jar,
> jboss-saaj.jar, jaxb-api.jar and jaxws-api.jar) into the JBoss
> lib/endorsed directory. I note that the demo already places files in
> lib/endorsed - do we need to add more? 
> 
> Finally (I'm not sure whether this is related or not) - I'm noting that
> the stack trace uses CXF classes right down to
> sun.reflect.NativeMethodAccessorImpl, and then JBossWS classes are used to
> create the SOAP message. is this right? I would have thought that the
> entire interaction should be handled by CXF classes?
> 
> Curious,
> Ade.
> 

-- 
View this message in context: 
http://www.nabble.com/JCA-demo-raises-java.lang.UnsupportedOperation-when-deployed-in-JBOSS-tp12197014p15028522.html
Sent from the cxf-user mailing list archive at Nabble.com.



Re: About sample "integration\JBI\external_provider_internal_consumer"

2008-01-22 Thread YI (William) ZHU

Thanks for your reply!

Actually I'm using ServiceMix 3.2.1, and also using the CXF component with
ServiceMix (not the one with CXF2.0.2).

I just wondering that this maybe a bug in CXF component, if someone can
confirm that.


Regards,



gnodet wrote:
> 
> Could you please try with the servicemix CXF components instead ? They are
> much more tested than this one AFAIK.  I'm not very familiar with this
> very component, so I can't help much, but I think it would be wise to try
> and start the CXF components that come with ServiceMix instead.
> ServiceMix distribution also comes with an example that you will be able
> to deploy.
> 
> 
> YI (William) ZHU wrote:
>> 
>> Hi,
>> 
>> I'm studing the sample
>> "integration\JBI\external_provider_internal_consumer" of CXF 2.0.2.
>> 
>> I followed the README, when I started the "CXF Service Engine", I found
>> the following message on ServiceMix console:
>> 
>> ...
>> SEVERE: Could not find Apache CXF configuration in 
>>  
>> C:\apps\servicemix321\data\smx\components\CXFServiceEngine\version_1\META-INF
>> ...
>> ...ServiceEngineShutdown changeState
>> INFO: in shutdown state
>> ...
>> 
>> It seems that CXF Service Engine was shutdown, but when I continue 
>> to Deploy and start CXF demo service assembly, everything were working.
>> 
>> First, I don't understand why when there is a "SEVERE" error, the example
>> still works;
>> Second, actually there is a file "cxf-config.xml" under that folder, but
>> with empty contents;
>> 
>> Could anyone help answer this question?
>> 
>> 
>> Thanks,
>> YI ZHU
>> 
>> (details as below)
>> 
>> Jan 16, 2008 1:50:15 PM org.apache.cxf.jbi.se.CXFBootstrap init
>> INFO: Bootstrap.init called
>> Jan 16, 2008 1:50:15 PM org.apache.cxf.jbi.se.CXFBootstrap onInstall
>> INFO: Bootstrap.onInstall called
>> Jan 16, 2008 1:50:16 PM org.apache.cxf.jbi.se.CXFBootstrap cleanUp
>> INFO: Bootstrap.cleanUp called
>> INFO  - ComponentMBeanImpl - Starting component:
>> CXFServiceEngine
>> INFO  - ComponentMBeanImpl - Initializing component:
>> CXFServiceEngine
>> Jan 16, 2008 1:50:33 PM org.apache.cxf.jbi.se.state.ServiceEngineShutdown
>> changeState
>> INFO: in shutdown state
>> Jan 16, 2008 1:50:33 PM org.apache.cxf.jbi.se.state.ServiceEngineShutdown
>> initSE
>> SEVERE: Could not find Apache CXF configuration in  
>> C:\apps\servicemix321\data\smx\components\CXFServiceEngine\version_1\META-INF
>> Jan 16, 2008 1:50:33 PM org.apache.cxf.jbi.se.state.ServiceEngineShutdown
>> initializeBus
>> INFO: initializing bus
>> Jan 16, 2008 1:50:41 PM org.apache.cxf.jbi.se.state.ServiceEngineShutdown
>> initializeBus
>> INFO: init bus complete
>> Jan 16, 2008 1:50:41 PM org.apache.cxf.transport.jbi.JBITransportFactory
>> setDeliveryChannel
>> INFO: configuring DeliveryChannel:  DeliveryChannel{CXFServiceEngine}
>> Jan 16, 2008 1:50:41 PM org.apache.cxf.jbi.se.state.ServiceEngineShutdown
>> initSE
>> INFO: Apache CXF Service Engine installation
>> root:C:\apps\servicemix321\data\smx\components\CXFServiceEngine\version_1
>> Jan 16, 2008 1:50:41 PM org.apache.cxf.jbi.se.state.ServiceEngineShutdown
>> initSE
>> INFO: CXF Service Engine init complete
>> Jan 16, 2008 1:50:41 PM org.apache.cxf.jbi.se.CXFServiceEngine start
>> INFO: CXFServiceEngine starting
>> Jan 16, 2008 1:50:41 PM org.apache.cxf.jbi.se.state.ServiceEngineStop
>> changeState
>> INFO: in stop state
>> Jan 16, 2008 1:50:41 PM org.apache.cxf.transport.jbi.JBITransportFactory
>> setDeliveryChannel
>> INFO: configuring DeliveryChannel:  DeliveryChannel{CXFServiceEngine}
>> Jan 16, 2008 1:50:41 PM org.apache.cxf.jbi.se.state.ServiceEngineStop
>> startSE
>> INFO: CXFServiceEngine startup complete
>> 
>> 
>> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/About-sample-%22integration%5CJBI%5Cexternal_provider_internal_consumer%22-tp14889400p15028317.html
Sent from the cxf-user mailing list archive at Nabble.com.



Re: WSDL retrieval at runtime, is it required?

2008-01-22 Thread Daniel Kulp

This is part of the JAX-WS spec:

Greeter port = service.getSoapPort();

BindingProvider provider = (BindingProvider)port;
provider.getRequestContext().put(
  BindingProvider.ENDPOINT_ADDRESS_PROPERTY,
  address);

Dan



On Tuesday 22 January 2008, Yadav, Yogendra (IT) wrote:
> Hi Dan,
> I looked hard could not find out how to set ENDPOINT_ADDRESS on the
> client. The generated service class has nothing to this effect. Do you
> have an example for this ?
>
> Thanx
> -yogen
>
>
>
> -Original Message-
> From: Daniel Kulp [mailto:[EMAIL PROTECTED]
> Sent: Monday, January 21, 2008 4:16 PM
> To: cxf-user@incubator.apache.org
> Cc: Yadav, Yogendra (IT)
> Subject: Re: WSDL retrieval at runtime, is it required?
>
>
> It's not "totally required".You CAN call the service constructor
> passing "null" for the wsdl and it should create the service fine.
> You'll need to manually set the ENDPOINT_ADDRESS property on the
> client to tell it the URL to hit, but that's not too hard to do.
>
> One note: when you run wsdl2java, you CAN specify a "wsdlLocation"
> flag to specify a different location to be burned in.   A popular
> setting would be the URL of the endpoint with the ?wsdl on it.
>
> Dan
>
> On Friday 18 January 2008, Yadav, Yogendra (IT) wrote:
> > Hi,
> > I have already used "wsdl2java -client" to generate client code to
> > access a CXF service. The WSDL that I provided does include service
> > endpoint information. I see that, now at runtime the client code
> > tries
> >
> > to retrieve the WSDL again (see the stacktrace below), why? Does it
> > only do it to extract the service location information? Why didn't
> > the
> >
> > generated code cache location information? Is there anyway to avoid
> > it?
> >
> > Exception in thread "main" javax.xml.ws.WebServiceException:
> > org.apache.cxf.service.factory.ServiceConstructionException: Failed
> > to
> >
> >create service.
> > at org.apache.cxf.jaxws.ServiceImpl.(ServiceImpl.java:132)
> > at
> > org.apache.cxf.jaxws.spi.ProviderImpl.createServiceDelegate(Provider
> >Im pl .java:65)
> > at javax.xml.ws.Service.(Service.java:56)
> > at
> > msjava.examples.calculator.client.CalculatorService.(Calculato
> >rS er vice.java:41)
> > at
> > msjava.examples.calculator.client.Calculator_CalculatorJettyHTTPPort
> >_C li ent.main(Calculator_CalculatorJettyHTTPPort_Client.java:53)
> > Caused by:
> > org.apache.cxf.service.factory.ServiceConstructionException: Failed
> > to
> >
> >create service.
> > at
> > org.apache.cxf.wsdl11.WSDLServiceFactory.(WSDLServiceFactory.j
> >av a: 83)
> > at
> > org.apache.cxf.jaxws.ServiceImpl.initializePorts(ServiceImpl.java:13
> >8) at org.apache.cxf.jaxws.ServiceImpl.(ServiceImpl.java:130)
> > ... 4 more
> > Caused by: javax.wsdl.WSDLException: WSDLException:
> > faultCode=PARSER_ERROR: Problem parsing
> > 'http://pa912c1n5:8091/Calculator/Calculator'.:
> > java.net.ConnectException: Connection refused: connect
> > at com.ibm.wsdl.xml.WSDLReaderImpl.getDocument(Unknown Source)
> > at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(Unknown Source)
> > at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(Unknown Source)
> > at
> > org.apache.cxf.wsdl11.WSDLManagerImpl.loadDefinition(WSDLManagerImpl
> >.j av a:199)
> > at
> > org.apache.cxf.wsdl11.WSDLManagerImpl.getDefinition(WSDLManagerImpl.
> >ja va
> >
> > :163)
> >
> > at
> > org.apache.cxf.wsdl11.WSDLServiceFactory.(WSDLServiceFactory.j
> >av a: 81)
> >
> > Thanx
> > -yogen
> > 
> >
> > NOTICE: If received in error, please destroy and notify sender.
> > Sender
> >
> > does not intend to waive confidentiality or privilege. Use of this
> > email is prohibited when received in error.
>
> --
> J. Daniel Kulp
> Principal Engineer, IONA
> [EMAIL PROTECTED]
> http://www.dankulp.com/blog
> 
>
> NOTICE: If received in error, please destroy and notify sender. Sender
> does not intend to waive confidentiality or privilege. Use of this
> email is prohibited when received in error.



-- 
J. Daniel Kulp
Principal Engineer, IONA
[EMAIL PROTECTED]
http://www.dankulp.com/blog


RE: WSDL retrieval at runtime, is it required?

2008-01-22 Thread Yadav, Yogendra (IT)
Hi Dan,
I looked hard could not find out how to set ENDPOINT_ADDRESS on the
client. The generated service class has nothing to this effect. Do you
have an example for this ?

Thanx
-yogen



-Original Message-
From: Daniel Kulp [mailto:[EMAIL PROTECTED] 
Sent: Monday, January 21, 2008 4:16 PM
To: cxf-user@incubator.apache.org
Cc: Yadav, Yogendra (IT)
Subject: Re: WSDL retrieval at runtime, is it required?


It's not "totally required".You CAN call the service constructor 
passing "null" for the wsdl and it should create the service fine.   
You'll need to manually set the ENDPOINT_ADDRESS property on the client
to tell it the URL to hit, but that's not too hard to do.

One note: when you run wsdl2java, you CAN specify a "wsdlLocation" flag 
to specify a different location to be burned in.   A popular setting 
would be the URL of the endpoint with the ?wsdl on it.   

Dan


On Friday 18 January 2008, Yadav, Yogendra (IT) wrote:
> Hi,
> I have already used "wsdl2java -client" to generate client code to 
> access a CXF service. The WSDL that I provided does include service 
> endpoint information. I see that, now at runtime the client code tries

> to retrieve the WSDL again (see the stacktrace below), why? Does it 
> only do it to extract the service location information? Why didn't the

> generated code cache location information? Is there anyway to avoid 
> it?
>
> Exception in thread "main" javax.xml.ws.WebServiceException:
> org.apache.cxf.service.factory.ServiceConstructionException: Failed to

>create service.
>   at org.apache.cxf.jaxws.ServiceImpl.(ServiceImpl.java:132)
>   at
> org.apache.cxf.jaxws.spi.ProviderImpl.createServiceDelegate(ProviderIm
>pl .java:65)
>   at javax.xml.ws.Service.(Service.java:56)
>   at
> msjava.examples.calculator.client.CalculatorService.(CalculatorS
>er vice.java:41)
>   at
> msjava.examples.calculator.client.Calculator_CalculatorJettyHTTPPort_C
>li ent.main(Calculator_CalculatorJettyHTTPPort_Client.java:53)
> Caused by:
> org.apache.cxf.service.factory.ServiceConstructionException: Failed to

>create service.
>   at
> org.apache.cxf.wsdl11.WSDLServiceFactory.(WSDLServiceFactory.jav
>a: 83)
>   at
> org.apache.cxf.jaxws.ServiceImpl.initializePorts(ServiceImpl.java:138)
>   at org.apache.cxf.jaxws.ServiceImpl.(ServiceImpl.java:130)
>   ... 4 more
> Caused by: javax.wsdl.WSDLException: WSDLException:
> faultCode=PARSER_ERROR: Problem parsing
> 'http://pa912c1n5:8091/Calculator/Calculator'.:
> java.net.ConnectException: Connection refused: connect
>   at com.ibm.wsdl.xml.WSDLReaderImpl.getDocument(Unknown Source)
>   at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(Unknown Source)
>   at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(Unknown Source)
>   at
> org.apache.cxf.wsdl11.WSDLManagerImpl.loadDefinition(WSDLManagerImpl.j
>av a:199)
>   at
> org.apache.cxf.wsdl11.WSDLManagerImpl.getDefinition(WSDLManagerImpl.ja
>va
>
> :163)
>
>   at
> org.apache.cxf.wsdl11.WSDLServiceFactory.(WSDLServiceFactory.jav
>a: 81)
>
> Thanx
> -yogen
> 
>
> NOTICE: If received in error, please destroy and notify sender. Sender

> does not intend to waive confidentiality or privilege. Use of this 
> email is prohibited when received in error.



--
J. Daniel Kulp
Principal Engineer, IONA
[EMAIL PROTECTED]
http://www.dankulp.com/blog


NOTICE: If received in error, please destroy and notify sender. Sender does not 
intend to waive confidentiality or privilege. Use of this email is prohibited 
when received in error.


Re: Problem Using Dynamic Client

2008-01-22 Thread Daniel Kulp


Hmm...  I was hoping for an easy answer to this and, unfortunately, I 
don't have one.  :-(

I don't know Groovy, but if you can do something like:

Map context = new HashMap();
Map reqContext = new HashMap();
reqContext.put(Message.ENDPOINT_ADDRESS, newAddress)
context.put(Client.REQUEST_CONTEXT, reqContext);

And then call the client.invoke method that looks like:

Object[] invoke(BindingOperationInfo oi, Object[] params, 
   Map context)

That kind of sucks though.


Alternatively, BEFORE you do any invoke, you MAY be able to do:

client.getEndpoint().getEndpointInfo().setAddress(newAddress);

The problem is if it connects at anypoint before then, that call will be 
ignored.Usually if you call before the first invokation, you should 
be OK.

Dan



   


On Tuesday 22 January 2008, keke wrote:
> Hi,
>
> I am trying to using Dynamic Client + Groovy for my project.
>
> I can create a client using a WSDL file. However, the target service
> url is not the one specified in the WSDL file.
>
> How can I enable the dynamic client to access a target service other
> than the one in WSDL?
>
> I have checked the user list but can not find a clear answer.
>
> Could anyone please give me a hint?
>
> Thanks in advanced.
>
> Cheers,
> Keke



-- 
J. Daniel Kulp
Principal Engineer, IONA
[EMAIL PROTECTED]
http://www.dankulp.com/blog


RE: Snapshot JAR file

2008-01-22 Thread Vespa, Anthony J
It does seem to work now in my IDE.  Thanks. =)

-Original Message-
From: Daniel Kulp [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, January 22, 2008 11:32 AM
To: cxf-user@incubator.apache.org
Cc: Vespa, Anthony J
Subject: Re: Snapshot JAR file

On Tuesday 22 January 2008, Vespa, Anthony J wrote:
> I hadn't heard any more on this..I know it seems like a minor thing,
> just wondering if this will be fixed for the 2.0.4 release.

You tell me  :-) The release candidates are at:
http://people.apache.org/~dkulp/stage_cxf/2.0.4-incubator/
(Seriously, it should be fixed)


I'm still double checking them right now.   If my checks look ok, I'll
be 
calling the vote later today.

Dan


>
> -Original Message-
> From: Vespa, Anthony J
> Sent: Tuesday, January 15, 2008 2:52 PM
> To: cxf-user@incubator.apache.org
> Subject: RE: Snapshot JAR file
>
> Thanks for looking into this, I just thought it was me being crazy at
> first. =)
>
> -Original Message-
> From: Daniel Kulp [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, January 15, 2008 1:33 PM
> To: cxf-user@incubator.apache.org
> Subject: Re: Snapshot JAR file
>
>
> Yep.  Bug in shade plugin.I've just fixed it, but it will require
> a new release of the shade plugin to get it working.   :-(
>
> Dan
>
> On Tuesday 15 January 2008, Daniel Kulp wrote:
> > OK.   Looks like a bug in the latest shade plugin.Using unzip, I
> > see:
> >
> >
> >  Length   MethodSize  Ratio   Date   Time   CRC-32Name
> >   --  --- -         --
> >0  Defl:N2   0%  01-13-08 19:17    META-INF
> > ...
> >
> > but for a javadoc jar, I see:
> >  Length   MethodSize  Ratio   Date   Time   CRC-32Name
> >   --  --- -         --
> >0  Stored0   0%  01-13-08 19:18    META-INF/
> >
> > Looks like the dirs are being stored as files.   Not good.   I'll
> > dig into it.
> >
> > Dan
> >
> > On Tuesday 15 January 2008, Vespa, Anthony J wrote:
> > > Sorry for not including more info, my bad.
> > >
> > > I'm grabbing the zip version of the nightly 2.1 snapshot and just
> > > unpacking the .jar and dropping it into my lib dir.  I noticed
> > > this occurred with the last 2 or 3 snapshots of 2.1.
> > >
> > > -Original Message-
> > > From: Daniel Kulp [mailto:[EMAIL PROTECTED]
> > > Sent: Tuesday, January 15, 2008 12:36 PM
> > > To: cxf-user@incubator.apache.org
> > > Cc: Vespa, Anthony J
> > > Subject: Re: Snapshot JAR file
> > >
> > >
> > > Tony,
> > >
> > > Are you grabbing the jar from a maven dependency (like cxf-bundle)
> > > or by
> > >
> > > downloading the distribution and unpacking it?   Also, 2.1 or
> > > 2.0.4? Just wanted to know where to start looking.
> > >
> > > Dan
> > >
> > > On Tuesday 15 January 2008, Vespa, Anthony J wrote:
> > > > Hello,
> > > >
> > > > Odd question - I feel like I am missing something obvious.  For
> > > > some reason, my IDE (intelliJ 7) won't recognize the snapshot of
> > > > the main CXF jar, and I can't use winzip to open it.  I can
> > > > extract single files from it.  I think the IDE code analyzer
> > > > can't decompress it either - am I missing something obvious?
> > > >
> > > > Not a huge issue, just a minor nit - things compile fine.
> > > >
> > > > -Tony



-- 
J. Daniel Kulp
Principal Engineer, IONA
[EMAIL PROTECTED]
http://www.dankulp.com/blog


Re: Snapshot JAR file

2008-01-22 Thread Daniel Kulp
On Tuesday 22 January 2008, Vespa, Anthony J wrote:
> I hadn't heard any more on this..I know it seems like a minor thing,
> just wondering if this will be fixed for the 2.0.4 release.

You tell me  :-) The release candidates are at:
http://people.apache.org/~dkulp/stage_cxf/2.0.4-incubator/
(Seriously, it should be fixed)


I'm still double checking them right now.   If my checks look ok, I'll be 
calling the vote later today.

Dan


>
> -Original Message-
> From: Vespa, Anthony J
> Sent: Tuesday, January 15, 2008 2:52 PM
> To: cxf-user@incubator.apache.org
> Subject: RE: Snapshot JAR file
>
> Thanks for looking into this, I just thought it was me being crazy at
> first. =)
>
> -Original Message-
> From: Daniel Kulp [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, January 15, 2008 1:33 PM
> To: cxf-user@incubator.apache.org
> Subject: Re: Snapshot JAR file
>
>
> Yep.  Bug in shade plugin.I've just fixed it, but it will require
> a new release of the shade plugin to get it working.   :-(
>
> Dan
>
> On Tuesday 15 January 2008, Daniel Kulp wrote:
> > OK.   Looks like a bug in the latest shade plugin.Using unzip, I
> > see:
> >
> >
> >  Length   MethodSize  Ratio   Date   Time   CRC-32Name
> >   --  --- -         --
> >0  Defl:N2   0%  01-13-08 19:17    META-INF
> > ...
> >
> > but for a javadoc jar, I see:
> >  Length   MethodSize  Ratio   Date   Time   CRC-32Name
> >   --  --- -         --
> >0  Stored0   0%  01-13-08 19:18    META-INF/
> >
> > Looks like the dirs are being stored as files.   Not good.   I'll
> > dig into it.
> >
> > Dan
> >
> > On Tuesday 15 January 2008, Vespa, Anthony J wrote:
> > > Sorry for not including more info, my bad.
> > >
> > > I'm grabbing the zip version of the nightly 2.1 snapshot and just
> > > unpacking the .jar and dropping it into my lib dir.  I noticed
> > > this occurred with the last 2 or 3 snapshots of 2.1.
> > >
> > > -Original Message-
> > > From: Daniel Kulp [mailto:[EMAIL PROTECTED]
> > > Sent: Tuesday, January 15, 2008 12:36 PM
> > > To: cxf-user@incubator.apache.org
> > > Cc: Vespa, Anthony J
> > > Subject: Re: Snapshot JAR file
> > >
> > >
> > > Tony,
> > >
> > > Are you grabbing the jar from a maven dependency (like cxf-bundle)
> > > or by
> > >
> > > downloading the distribution and unpacking it?   Also, 2.1 or
> > > 2.0.4? Just wanted to know where to start looking.
> > >
> > > Dan
> > >
> > > On Tuesday 15 January 2008, Vespa, Anthony J wrote:
> > > > Hello,
> > > >
> > > > Odd question - I feel like I am missing something obvious.  For
> > > > some reason, my IDE (intelliJ 7) won't recognize the snapshot of
> > > > the main CXF jar, and I can't use winzip to open it.  I can
> > > > extract single files from it.  I think the IDE code analyzer
> > > > can't decompress it either - am I missing something obvious?
> > > >
> > > > Not a huge issue, just a minor nit - things compile fine.
> > > >
> > > > -Tony



-- 
J. Daniel Kulp
Principal Engineer, IONA
[EMAIL PROTECTED]
http://www.dankulp.com/blog


Re: WSS4J - Protection Order

2008-01-22 Thread Fred Dushin

Hi Mayank,

When you say "one way to achieve this is to specify the URI of the  
EncryptedData", do you mean QName, instead of URI?


I get the sense from what you are saying that your message may have  
multiple EncryptedData elements in it, and you want to sign one, but  
not others.  Is that right?


If you have only one EncryptedData, then you should be able to direct  
the WSS4J toolkit to sign it, by specifying the EncryptedData QName,  
in configuration of the interceptor.


Unfortunately, WSS4J does not provide XPath support for protecting  
(signing/encrypting) message parts, so using QNames is inherently  
ambiguous.


-Fred

On Jan 18, 2008, at 2:24 AM, Mayank Mishra wrote:


Any reply to this thread will be highly appreciated.

Thanking in advance,

With Regards,
Mayank

Mayank Mishra wrote:

Hi,

Usually we use, Sign and then Encrypt action for any particular xml  
element. If I want to use Encrypt and then Sign for a particular  
xml element, then SignatureAction fails to find the xml element.  
The reason is it has been encrypted and hence corresponding  
EncryptedData element will be there.


One way to achieve this, is to specify, URI of EncryptedData itself  
in the signature parts. (It should work, though I haven't tested  
it). But this is not a full proof solution if I want only specific  
element only to be encrypted and eventually signed.


*Is there any mechanism to achieve this?* The only way I can think  
of achieving this is to maintain a list of wsu:id's of  
corresponding EncryptedData elements and add URI of them to  
Signature Parts during .SignatureAction. This may be performed in  
adding another interceptor which handles the message after  
encryption has been done.


Please let me know your views/suggestions about this.

Thanking in advance. :)

With Regards,
Mayank








RE: Snapshot JAR file

2008-01-22 Thread Vespa, Anthony J
I hadn't heard any more on this..I know it seems like a minor thing,
just wondering if this will be fixed for the 2.0.4 release.

-Original Message-
From: Vespa, Anthony J 
Sent: Tuesday, January 15, 2008 2:52 PM
To: cxf-user@incubator.apache.org
Subject: RE: Snapshot JAR file

Thanks for looking into this, I just thought it was me being crazy at
first. =)

-Original Message-
From: Daniel Kulp [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, January 15, 2008 1:33 PM
To: cxf-user@incubator.apache.org
Subject: Re: Snapshot JAR file


Yep.  Bug in shade plugin.I've just fixed it, but it will require a 
new release of the shade plugin to get it working.   :-(

Dan


On Tuesday 15 January 2008, Daniel Kulp wrote:
> OK.   Looks like a bug in the latest shade plugin.Using unzip, I
> see:
>
>
>  Length   MethodSize  Ratio   Date   Time   CRC-32Name
>   --  --- -         --
>0  Defl:N2   0%  01-13-08 19:17    META-INF
> ...
>
> but for a javadoc jar, I see:
>  Length   MethodSize  Ratio   Date   Time   CRC-32Name
>   --  --- -         --
>0  Stored0   0%  01-13-08 19:18    META-INF/
>
> Looks like the dirs are being stored as files.   Not good.   I'll dig
> into it.
>
> Dan
>
> On Tuesday 15 January 2008, Vespa, Anthony J wrote:
> > Sorry for not including more info, my bad.
> >
> > I'm grabbing the zip version of the nightly 2.1 snapshot and just
> > unpacking the .jar and dropping it into my lib dir.  I noticed this
> > occurred with the last 2 or 3 snapshots of 2.1.
> >
> > -Original Message-
> > From: Daniel Kulp [mailto:[EMAIL PROTECTED]
> > Sent: Tuesday, January 15, 2008 12:36 PM
> > To: cxf-user@incubator.apache.org
> > Cc: Vespa, Anthony J
> > Subject: Re: Snapshot JAR file
> >
> >
> > Tony,
> >
> > Are you grabbing the jar from a maven dependency (like cxf-bundle)
> > or by
> >
> > downloading the distribution and unpacking it?   Also, 2.1 or 2.0.4?
> > Just wanted to know where to start looking.
> >
> > Dan
> >
> > On Tuesday 15 January 2008, Vespa, Anthony J wrote:
> > > Hello,
> > >
> > > Odd question - I feel like I am missing something obvious.  For
> > > some reason, my IDE (intelliJ 7) won't recognize the snapshot of
> > > the main CXF jar, and I can't use winzip to open it.  I can
> > > extract single files from it.  I think the IDE code analyzer can't
> > > decompress it either - am I missing something obvious?
> > >
> > > Not a huge issue, just a minor nit - things compile fine.
> > >
> > > -Tony



-- 
J. Daniel Kulp
Principal Engineer, IONA
[EMAIL PROTECTED]
http://www.dankulp.com/blog


Re: Interceptor performance tips

2008-01-22 Thread Fred Dushin
This performance hit is likely due to the fact that the WSS4J  
interceptors require DOM structures for processing through the WSS4J  
interfaces.  So you are paying for DOM-ifying your entire message.


If you are using WS-Security to simply propagate security tokens  
(E.g., UsernameTokens), then you should consider managing this yourself.


If, on the other hand, you require the full functionality of WSS4J,  
e.g., to sign and/or encrypt messages, then you'll need to stick with  
the current approach.  (In which case the cost you'll pay for DOM will  
likely be eclipsed by the overhead associated with public-key crypto,  
c14n, etc.)


-Fred

On Jan 21, 2008, at 5:38 AM, Christian Vest Hansen wrote:


Hi,

We've rolled our own specialized WS-Security in-interceptor
(implementing PhaseInterceptor) to integrate with our single sign-on
system.

This is all nice, except that this interceptor seems to add quite an
overhead to our web services.

The interceptor operates in the UNMARSHAL phase and specifies its
placement in the PhaseInterceptorChain to be AFTER a SAAJInInterceptor
and an RPCInInterceptor.

It uses the SAAJInInterceptor's SOAPMessage to read the WS-Security
headers, and the RPCInInterceptor is used for improved fault handling.

I haven't done any real profiling on it yet (shame on me), but I'm
thinking that maybe the SAAJInInterceptor is one of bad guys,
performance wise, and we've discusses if we should read the wss
headers with stax instead.

I wonder if you have any performance tips, or other ideas that might
help improve this setup?



--
Venlig hilsen / Kind regards,
Christian Vest Hansen.





Re: Some more issues with jax-rs RESTful service

2008-01-22 Thread Frank Lynch
Hi Priya,
On your #1 - its unfortunate that we throw a NullPointerException, but
the actual issue is outlined in the log: 

SEVERE: No operation found for path: /, contentType: */*, Accept contentType: 
*/*

i.e. your sending a request to a path that doesn't have an operation
associated with it. You'd get this with the basic jax-rs demo if you
send a request to http://127.0.0.1:9000/ instead of
http://127.0.0.1:9000/customerservice/customers/123 
Feel free to log a Jira for the NullPointerException if you like - we
really should throw a more meaningful exception.
  
On your second issue, could you post some sample code (perhaps a diff vs
the basic demo)  so we can get a clear idea of what your doing here?
thanks & regards,
--Frank


On Mon, 2008-01-21 at 02:56 -0800, priya j wrote:
> Hi All,
> First of all thanks a lot for your support. I have sort off done with my
> implemented. Still i have the following error.
> Kindly do help me in solving this also
> 
> 1) When i run my server for the first time i get the null pointer exception
> stating no method found but my client works fine.
> 
> ERROR:
> Jan 21, 2008 6:09:02 PM org.apache.coyote.http11.Http11Protocol start
> INFO: Starting Coyote HTTP/1.1 on http-8080
> Jan 21, 2008 6:09:02 PM org.apache.coyote.http11.Http11Protocol start
> INFO: Starting Coyote HTTP/1.1 on http-8443
> Jan 21, 2008 6:09:02 PM org.apache.jk.common.ChannelSocket init
> INFO: JK: ajp13 listening on /0.0.0.0:8009
> Jan 21, 2008 6:09:02 PM org.apache.jk.server.JkMain start
> INFO: Jk running ID=0 time=0/141  config=null
> Jan 21, 2008 6:09:02 PM org.apache.catalina.startup.Catalina start
> INFO: Server startup in 12883 ms
> Jan 21, 2008 6:09:03 PM org.apache.cxf.jaxrs.interceptor.JAXRSInInterceptor
> handleMessage
> INFO: Request path is: /
> Jan 21, 2008 6:09:03 PM org.apache.cxf.jaxrs.interceptor.JAXRSInInterceptor
> handleMessage
> INFO: Request HTTP method is: GET
> Jan 21, 2008 6:09:03 PM org.apache.cxf.jaxrs.interceptor.JAXRSInInterceptor
> handleMessage
> INFO: Request contentType is: */*
> Jan 21, 2008 6:09:03 PM org.apache.cxf.jaxrs.interceptor.JAXRSInInterceptor
> handleMessage
> INFO: Accept contentType is: */*
> Jan 21, 2008 6:09:03 PM org.apache.cxf.jaxrs.interceptor.JAXRSInInterceptor
> handleMessage
> SEVERE: No operation found for path: /, contentType: */*, Accept
> contentType: */*
> Jan 21, 2008 6:09:03 PM org.apache.cxf.phase.PhaseInterceptorChain
> doIntercept
> INFO: Interceptor has thrown exception, unwinding now
> java.lang.NullPointerException
> at
> org.apache.cxf.jaxrs.interceptor.JAXRSInInterceptor.handleMessage(JAXRSInInterceptor.java:102)
> at
> org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:207)
> at
> org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationObserver.java:78)
> at
> org.apache.cxf.transport.servlet.ServletDestination.doMessage(ServletDestination.java:79)
> at
> org.apache.cxf.transport.servlet.ServletController.invokeDestination(ServletController.java:264)
> at
> org.apache.cxf.transport.servlet.ServletController.invoke(ServletController.java:160)
> at
> org.apache.cxf.transport.servlet.AbstractCXFServlet.invoke(AbstractCXFServlet.java:170)
> at
> org.apache.cxf.transport.servlet.AbstractCXFServlet.doGet(AbstractCXFServlet.java:152)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:690)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
> at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
> at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
> at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
> at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
> at
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
> at
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
> at
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:263)
> at
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
> at
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:584)
> at
> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
> at java.lang.Thread.run(Unknown Source)
> 
> 2) Another issue is with the output format, for ProductMime - XML it works
> fine.
> The issue arise for json, if there is more than one resultset the
> application fails. It process the data but fails for
> display-java.lang.ClassCastException. Here is the error message
> 
> ERROR:
> Jan 21, 2008 6:38:03 PM org.apache.cxf.jaxrs.interceptor.JAXRSOutInterceptor
> handleMessage
> INFO: Available content types for response is: a

RE: Any book written on xfire

2008-01-22 Thread Amir Alagic
Hi

Online documentation is ok but I think that many would buy
book if it has more details than documentation and explain
how to solve some real world problems...

Regards,
Amir

-Original Message-
From: Adrian Trenaman [mailto:[EMAIL PROTECTED] 
Sent: 22. januar 2008 15:45
To: cxf-user@incubator.apache.org
Subject: Re: Any book written on xfire


Hi Anshul ,

I've written a 2-day training course on JAX-WS development using CXF; am
delivering a cut down version of this at OOP in Munich later this week.
I've
been toying with the idea of producing a developer's handbook for CXF;
would
be interested to know if you think there's a market for it!

For the minute, I concur with Glen that the online documentation for CXF
is
a pretty good start. You might also want to take a look at the Fuse
Service
Framework documentation, available on open.iona.com 

http://open.iona.com/documentation/fuse-service-framework-documentation

Warm regards,
Ade.


Glen Mazza-2 wrote:
> 
> I like Hansen's book[1], although it is about JAX-WS in general
(either
> CXF or GlassFish Metro).  Presently our online user's guide[2] is the
> best source for CXF-specific information.  
> 
> HTH,
> Glen
> 
> [1] http://www.jroller.com/gmazza/date/20070809
> [2] http://cwiki.apache.org/CXF20DOC/index.html
> 
> 
> Am Dienstag, den 22.01.2008, 09:09 + schrieb Anshul Dutta:
>> Does any one knows about a good book on xfire or cxf?
>> Or any SOA book that includes these topics?
>> 
>> Thanks,
>> ad
>> 
>> 
>>

>> This email has been scanned for all known viruses by the MessageLabs
>> Email Security Service and the Macro 4 plc internal virus protection
>> system.
>>

> 
> 
> 

-- 
View this message in context:
http://www.nabble.com/Any-book-written-on-xfire-tp15015038p15019897.html
Sent from the cxf-user mailing list archive at Nabble.com.



Re: More than one Element in Request Wrapper?

2008-01-22 Thread silithus

Yep, Cxf has JIRA for this one, and its only one with blocker status.
https://issues.apache.org/jira/browse/CXF-1388.

as oposed to Axis2 16 'Blocker' issues.
http://issues.apache.org/jira/secure/IssueNavigator.jspa?reset=true&pid=10611&priority=1&resolution=-1.

Its shame to have this one and only blocker with fix already done but not
distributed.




-- 
View this message in context: 
http://www.nabble.com/More-than-one-Element-in-Request-Wrapper--tp14753520p15020269.html
Sent from the cxf-user mailing list archive at Nabble.com.



Re: Any book written on xfire

2008-01-22 Thread Adrian Trenaman

Hi Anshul ,

I've written a 2-day training course on JAX-WS development using CXF; am
delivering a cut down version of this at OOP in Munich later this week. I've
been toying with the idea of producing a developer's handbook for CXF; would
be interested to know if you think there's a market for it!

For the minute, I concur with Glen that the online documentation for CXF is
a pretty good start. You might also want to take a look at the Fuse Service
Framework documentation, available on open.iona.com 

http://open.iona.com/documentation/fuse-service-framework-documentation

Warm regards,
Ade.


Glen Mazza-2 wrote:
> 
> I like Hansen's book[1], although it is about JAX-WS in general (either
> CXF or GlassFish Metro).  Presently our online user's guide[2] is the
> best source for CXF-specific information.  
> 
> HTH,
> Glen
> 
> [1] http://www.jroller.com/gmazza/date/20070809
> [2] http://cwiki.apache.org/CXF20DOC/index.html
> 
> 
> Am Dienstag, den 22.01.2008, 09:09 + schrieb Anshul Dutta:
>> Does any one knows about a good book on xfire or cxf?
>> Or any SOA book that includes these topics?
>> 
>> Thanks,
>> ad
>> 
>> 
>> 
>> This email has been scanned for all known viruses by the MessageLabs
>> Email Security Service and the Macro 4 plc internal virus protection
>> system.
>> 
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Any-book-written-on-xfire-tp15015038p15019897.html
Sent from the cxf-user mailing list archive at Nabble.com.



Re: More than one Element in Request Wrapper?

2008-01-22 Thread Benson Margulies

On Tue, 2008-01-22 at 06:14 -0800, silithus wrote:
> This seems more blocking issue than we initally thought. We use Java first
> approach, and Cxf-2.0.3.
> 
> For example when we use List etc we get that error, when we use
> List everything goes ok.
> 
> We would really appreciate any news/info regarding this: when it will be
> fixed (put into Cxf binary distro since it is already fixed
> https://issues.apache.org/jira/browse/WSCOMMONS-273), any workarounds, does
> this affect older stable versions of Cxf etc. Even if you dont plan to
> distribute in weeks to come it would be welcomed to know so we know what to
> expect, so we can either fix ourselves or move to the next library.

At last count, XmlSchema has not made a release containing this. They
have a lot of overhang of fixed issues unreleased while they wait for
some Axis release to complete.

Is there a CXF JIRA on this? I don't have enough context to be more
informative.

> 
> With this one its highly doubtful we will get approval from management to
> use Cxf  in production(though its not Cxf direct problem), and would have to
> go to other solutions.
> 
> Thanks 



Re: More than one Element in Request Wrapper?

2008-01-22 Thread silithus

This seems more blocking issue than we initally thought. We use Java first
approach, and Cxf-2.0.3.

For example when we use List etc we get that error, when we use
List everything goes ok.

We would really appreciate any news/info regarding this: when it will be
fixed (put into Cxf binary distro since it is already fixed
https://issues.apache.org/jira/browse/WSCOMMONS-273), any workarounds, does
this affect older stable versions of Cxf etc. Even if you dont plan to
distribute in weeks to come it would be welcomed to know so we know what to
expect, so we can either fix ourselves or move to the next library.

With this one its highly doubtful we will get approval from management to
use Cxf  in production(though its not Cxf direct problem), and would have to
go to other solutions.

Thanks 
-- 
View this message in context: 
http://www.nabble.com/More-than-one-Element-in-Request-Wrapper--tp14753520p15019483.html
Sent from the cxf-user mailing list archive at Nabble.com.



Re: More than one Element in Request Wrapper?

2008-01-22 Thread silithus

Sorry fior bringing this one again, but I am having the same issues with
Cxf-2.0.3 with java2wsdl approach.

Is there any official workaround for this before XmlSchema team releases
binary?

Also I cant find the "java2ws" tool
(http://cwiki.apache.org/CXF20DOC/java-to-ws.html), is it only usable with
Maven?
In the bin folder of Cxf I dont see it, did full text search on both and
source distribution of Cxf and cant find not a singel ant task reference to
the "java2ws".

Any link/advice appreciated.

Thanks


ben27 wrote:
> 
> Thank you for your replies.
> I will try to change my code in a way that it will work :-(
> 
> 
> 
> dkulp wrote:
>> 
>> 
>> You've hit a known bug in XmlSchema:
>> 
>> https://issues.apache.org/jira/browse/WSCOMMONS-273
>> 
>> We're waiting for a new version of XmlSchema to be released that fixes 
>> that bug (and a bunch of others we reported).
>> 
>> Dan
>> 
>> -- 
>> J. Daniel Kulp
>> Principal Engineer, IONA
>> [EMAIL PROTECTED]
>> http://www.dankulp.com/blog
>> 
>> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/More-than-one-Element-in-Request-Wrapper--tp14753520p15018510.html
Sent from the cxf-user mailing list archive at Nabble.com.



Re: [CXF][Bug] SOAPwAttachment bad received.

2008-01-22 Thread Cencio

Forgot to say:

service just display attachments id and echo the request back.

Thx for any help to solve this.

Bye!
-- 
View this message in context: 
http://www.nabble.com/-CXF--Bug--SOAPwAttachment-bad-received.-tp15017531p15017690.html
Sent from the cxf-user mailing list archive at Nabble.com.



[CXF][Bug] SOAPwAttachment bad received.

2008-01-22 Thread Cencio

After many test i find why sending a soap message with 2 attachments with an
Axis client  only one is received. As you can see in this Wireshark log the
response is send before the message is completely received. With Wireshark
packet viewer is easy to notice that client send the message, but server
reply between the 2 attachments. In fact the 2nd one is trasmitted after the
reply.

This not happen all times.. with my client and server happens 90% of times.
if i put a tcpmon between client and server the percentage of this error
drop to 10%.. 

If u need something to replicate the bug just ask me.



 



POST /openspcoop/PD/HelloWorld HTTP/1.0

Content-Type: multipart/related; type="text/xml";
start="";
.boundary="=_Part_0_32755292.1201002904839"

Accept: application/soap+xml, application/dime, multipart/related, text/*

User-Agent: Axis/1.4

Host: localhost:8080

Cache-Control: no-cache

Pragma: no-cache

SOAPAction: ""

Content-Length: 1443





--=_Part_0_32755292.1201002904839

Content-Type: text/xml; charset=UTF-8

Content-Transfer-Encoding: binary

Content-Id: 



http://schemas.xmlsoap.org/soap/envelope/";
xmlns:xsd="http://www.w3.org/2001/XMLSchema";
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";>http://spcoop.it/cart/pdd-test";>



PK.US5.~S.prova.xmlUT...$;7E$;7EUxd..I.L...H./.Ip..PK...US5.~S...
...prova.xmlUT...$;7EUx..PK..D...S.HTTP/1.1 200 OK

Server: Apache-Coyote/1.1

X-Powered-By: Servlet 2.4; JBoss-4.0.5.GA (build: CVSTag=Branch_4_0
date=200610162339)/Tomcat-5.5

Accept: text/xml, text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2

Content-Type: multipart/related; type="text/xml";
boundary="=_Part_149_7828053.1201002905051"

Content-Length: 925

Date: Tue, 22 Jan 2008 11:55:05 GMT

Connection: close



--=_Part_149_7828053.1201002905051

Content-Type: text/xml; charset=utf-8



http://schemas.xmlsoap.org/soap/envelope/";
xmlns:xsd="http://www.w3.org/2001/XMLSchema";
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";>http://spcoop.it/cart/pdd-test";>

--=_Part_149_7828053.1201002905051

Content-Type: application/octet-stream

Content-ID: <7D3142D3FF2B53A1B86D95C3F7B31360>

content-transfer-encoding: binary



PK.US5.~S.prova.xmlUT...$;7E$;7EUxd..I.L...H./.Ip..PK...US5.~S.x..PK..D...S.

--=_Part_149_7828053.1201002905051--

--=_Part_0_32755292.1201002904839

Content-Type: application/octet-stream

Content-Transfer-Encoding: binary

Content-Id: <8D8807258A5C72ADF6DE8C3CF38EBE96>



PK.US5.~S.prova.xmlUT...$;7E$;7EUxd..I.L...H./.Ip..PK...US5.~S...
...prova.xmlUT...$;7EUx..PK..D...S.

--=_Part_0_32755292.1201002904839--


-- 
View this message in context: 
http://www.nabble.com/-CXF--Bug--SOAPwAttachment-bad-received.-tp15017531p15017531.html
Sent from the cxf-user mailing list archive at Nabble.com.



Any book written on xfire

2008-01-22 Thread Anshul Dutta
Does any one knows about a good book on xfire or cxf?
Or any SOA book that includes these topics?

Thanks,
ad



This email has been scanned for all known viruses by the MessageLabs Email 
Security Service and the Macro 4 plc internal virus protection system.