Re: A novice for CXF, woking on SOAP/JMS

2009-04-23 Thread liucong

Hi All,

   Any quest, suggest, advice or help will be welcome. Thank you very much.

Liu Cong
I am Liu Cong. My nick in irc is liucong.I'm so excited as I am 
accepted by CXF as gsoc student.I will work on SOAP/JMS project, which 
will update the SOAP/JMS support in CXF to be completely specification 
compliant. My mentor is Willem Jiang.
Thanks for all you guys' help very much. Everyone please feels free to 
connect me.







my blog for gsoc, SOAP/JMS

2009-04-25 Thread liucong
Hi everyone,

I have just started my first technical blog in google Blog
(http://liucong07.blogspot.com/), and posted some articles about Google
Summer of Code. My project is SOAP/JMS. I'll do some updates about my
project in here, and post some questions or my understanding about CXF
and Web Services.

I am a new guy for open source and CXF. Any comments, advices and help
are welcome :-) .
Thank you for your attention.

Any one who is interested in this project, please feel free to contact
with me :-)

Best regards,

Liu


MTOM over SOAP/JMS

2009-04-26 Thread liucong
Hi all,

I'm working on SOAP over JMS as a GSoCer. I'm investigating the current
implementation of SOAP/JMS, and find a question about MTOM over SOAP/JMS.
I have modified the example jms_queue in CXF-2.2 and made the example
support MTOM. Throught the client send the attachement and the server
get the attachment, the size of the attachment which is got by the
server is not the same with the size of the attachment which is sent by
the client.
Is there something wrong with this?
I'll try to debug what's wrong. Is there some prompts or advice to do
this job?

Thank you!

Best regards,
Liu


WSDL Usage for SOAP/JMS specification

2009-04-27 Thread liucong
Hi, All, Willem,

In the past several days, We have discussed the usage of JMS transport,
MTOM over SOAP/JMS. By debugging the code of CXF and JMS Transport, I
think I have know the overview of the CXF and JMS Transport.(Except
Spring configuration).

I want to learn another eara about WSDL usage for
SOAP/JMS(http://www.w3.org/TR/2008/WD-soapjms-20081121/#wsdl-extensions).
In the current JMS implementation, you use the WSDL extension to get the
WSDL information(Is it right?). In the SOAP/JMS specification, the
properties about SOAP/JMS can be placed in three places(Binding,
Serivce, Port). I should get these information.
There are several methods to finish it.
1. I parse the WSDL, and get information what I need. It is not good.
2. I use the WSDL extension to get information and SOAP/JMS URI.

After I get the information from WSDL. What I need to do is to parse
these information, and to get the right configuration which obey the
overriding rules specified in the SOAP/JMS spec.
The orerriding rules is: If a property is specified at multiple levels,
the most specific setting will take precedence (port first, then
service, then binding).

How can I get the WSDL information for SOAP/JMS specification? Are there
some methods to finish this job or help documentation?
Are the overriding rules already implementation in WSDL parser? If not,
I should consider how to implementation the orverriding rules easily.


Best regards
Liu


How to determine whether a soap message have an attachment

2009-05-04 Thread liucong
Hi all,

When I want to add MTOM support for SOAP/JMS, I should know whether a
soap message have an attachment. But I don't know the details how to
judge wheter the message have an attachment.
Is anyone give me any prompt about where the code is? Or some code example?

Thank you very much.

Best regards

Liu


Re: How to determine whether a soap message have an attachment

2009-05-06 Thread liucong
Hi,
It already supports MTOM. But there may be a bug for the MTOM.
The current implementation send all the messages as TextMessage because
jmsConfig variable in JMSConduit is not initialized according to the
MessageType of SOAPMessage. So it is wrong when the message has an
attachment.

Sorry, I use the wrong word 'add MTOM support'. I just want to make the
'MTOM-support' work right.

Yes, I have followed some codes. I think it use a OutputStream to
generate the MTOM message. But before I send the message, I want to know
whether it is a MTOM message, because I should set ByteMessage or
TextMessage for JMS message depends on whether it is a MTOM message.
So far, I can't find a way to finish this.

Daniel Kulp 写道:
> Doesn't it already support MTOM?
>
> Basically, it provides a OutputSteam to the dispatching and if the runtime 
> needs to handle attachments and such, it will write it as mime stuff to the 
> stream. 
>
> Dan
>
>
>
> On Tue May 5 2009 12:53:48 am liucong wrote:
>   
>> Hi all,
>>
>> When I want to add MTOM support for SOAP/JMS, I should know whether a
>> soap message have an attachment. But I don't know the details how to
>> judge wheter the message have an attachment.
>> Is anyone give me any prompt about where the code is? Or some code example?
>>
>> Thank you very much.
>>
>> Best regards
>>
>> Liu
>> 
>
>   



Re: How to determine whether a soap message have an attachment

2009-05-06 Thread liucong
If the config  doesn't appear in the
WSDL of the service. The current implementation of JMS Transport will
send MTOM message as TextMessage. So in current implementation, if one
wants to use JMS MTOM-support, the config  must be set, then the MTOM message will be sent as
ByteMessage.

Willem Jiang wrote:
> After digging the code, I found we could know if the Message has
> attachments by looking the message in the JMSConduit.sendExchange()
> method. We can tell if the message is MTOM enabled and has the
> attachement message, then we just make sure the JMS Message type is
> BytesMessage that should be OK.
>
> BTW, Freeman did some work to make the JMS transport support MTOM[1]
>
> [1] http://issues.apache.org/jira/browse/CXF-1760
>
> Willem
>
> Willem Jiang wrote:
>   
>> Hi,
>>
>> If we defer the creation of JMS Message until we know the Content-Type
>> for the client, we still need to flight with the miss configuration of
>> MTOM with TextMessage on the server side.
>>
>> Current solution , I discussed with Liu Cong is if the MTOM is enabled,
>> CXF JMS transport will check the configuration of the JMS message type,
>> and make sure the JMS message type is BytesMessage, if not, the JMS
>> transport will throw an Exception for it.
>>
>> Any thought?
>>
>> Willem
>>
>> Daniel Kulp wrote:
>> 
>>> On Wed May 6 2009 9:15:54 am Willem Jiang wrote:
>>>   
>>>> Hi
>>>>
>>>> I think MTOM message should have the attachment info, we could check
>>>> that for it. We have some trouble to send the MTOM message if we send
>>>> the message in Text model, and Liu Cong is working on the patch.
>>>> 
>>> Hmmthe message won't have the attachment info at "prepare" time.   
>>> Whether to switch to mtom/mime or not is done later on, in the 
>>> AttachmentOutInterceptor.The actual creation of the JMS message might 
>>> need 
>>> to be deferred until the first call to write on the cached output stream or 
>>> something.   At that point, the Content-Type should be set to the mime 
>>> version 
>>> and thus could be determined if it needs to be a binary message or not.
>>>
>>> Dan
>>>
>>>
>>>
>>>   
>>>> Willem
>>>>
>>>> Daniel Kulp wrote:
>>>> 
>>>>> Doesn't it already support MTOM?
>>>>>
>>>>> Basically, it provides a OutputSteam to the dispatching and if the
>>>>> runtime needs to handle attachments and such, it will write it as mime
>>>>> stuff to the stream.
>>>>>
>>>>> Dan
>>>>>
>>>>> On Tue May 5 2009 12:53:48 am liucong wrote:
>>>>>   
>>>>>> Hi all,
>>>>>>
>>>>>> When I want to add MTOM support for SOAP/JMS, I should know whether a
>>>>>> soap message have an attachment. But I don't know the details how to
>>>>>> judge wheter the message have an attachment.
>>>>>> Is anyone give me any prompt about where the code is? Or some code
>>>>>> example?
>>>>>>
>>>>>> Thank you very much.
>>>>>>
>>>>>> Best regards
>>>>>>
>>>>>> Liu
>>>>>> 
>> 
>
>
>   



a question when I run the JUnit test in eclipse.

2009-06-07 Thread liucong
Hi all,

I have encountered a question when I run the JUnit test in eclipse.

I have set up my eclipse workspace(eclipse 3.4.1) following the orders
in http://cxf.apache.org/setting-up-eclipse.html.
Than I run a JUnit test
org.apache.cxf.systest.fault.IntFaultClientServerTest.java in
cxf-systests. I encountered the Exception as follows:
java.io.IOException: CreateProcess:
D:\software\Java\jdk1.5.0_08\jre\bin\java -ea
-Djavax.xml.ws.spi.Provider=org.apache.cxf.jaxws.spi.ProviderImpl
-classpath
"E:\cxf\cxf-src\trunk\systests\target\test-classes;E:\cxf\cxf-src\trunk\systests\target\classes;C:\Documents
and
Settings\jason\.m2\repository\org\apache\abdera\abdera-core\0.4.0-incubating\abdera-core-0.4.0-incubating.jar;C:\Documents
and
Settings\jason\.m2\repository\org\apache\abdera\abdera-extensions-json\0.4.0-incubating\abdera-extensions-json-0.4.0-incubating.jar;C:\Documents
and
Settings\jason\.m2\repository\org\apache\abdera\abdera-extensions-main\0.4.0-incubating\abdera-extensions-main-0.4.0-incubating.jar;C:\Documents
and
Settings\jason\.m2\repository\org\apache\abdera\abdera-i18n\0.4.0-incubating\abdera-i18n-0.4.0-incubating.jar;C:\Documents
and
Settings\jason\.m2\repository\org\apache\abdera\abdera-parser\0.4.0-incubating\abdera-parser-0.4.0-incubating.jar;C:\Documents
and
Settings\jason\.m2\repository\org\apache\activemq\activeio-core\3.0.0-incubator\activeio-c�
at java.lang.ProcessImpl.create(Native Method)
at java.lang.ProcessImpl.(ProcessImpl.java:81)
at java.lang.ProcessImpl.start(ProcessImpl.java:30)
at java.lang.ProcessBuilder.start(ProcessBuilder.java:451)
at
org.apache.cxf.testutil.common.ServerLauncher.launchServer(ServerLauncher.java:199)
at
org.apache.cxf.testutil.common.AbstractClientServerTestBase.launchServer(AbstractClientServerTestBase.java:61)
at
org.apache.cxf.systest.fault.IntFaultClientServerTest.startServers(IntFaultClientServerTest.java:39)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.junit.internal.runners.ClassRoadie.runBefores(ClassRoadie.java:49)
at org.junit.internal.runners.ClassRoadie.runProtected(ClassRoadie.java:36)
at
org.junit.internal.runners.JUnit4ClassRunner.run(JUnit4ClassRunner.java:42)
at
org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:45)
at
org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196)

What's wrong?

Thank you very much.

Best regards,
Liu


How to implement the SOAP Fault for JMS Transport?

2009-06-07 Thread liucong
Hi all,

When I implement the SOAP Over JMS Specification, I don’t know how to
implement SOAP fault for it.

I use the org.apache.cxf.interceptor.Fault to record the Fault
information. For example, I create a Fault instance for SOAP fault
subcode contentTypeMismatch
(http://www.w3.org/TR/2008/WD-soapjms-20080723/#binding-faults). If I
check the fault the cxf-rt-transports-jms module, I don’t know how to
deal with the fault which is checked out.

If I added an Interceptor for JMS transport, I can use the interceptor
to deal with the fault. Is It right?

If it is Ok, how is the interceptor added to the interceptors according
to whether the jms transport is used or not?

Are there any materials for interceptors, phases, and phase order?

Thank you very much!

Best regards,

Liu



Re: GSoC projects for CXF

2009-06-07 Thread liucong

Hi,
   My  cwiki.apache.org/CXF's  User Name: liucon...@gmail.com, Full 
Name: jason.
   I have create a project for my project in gitHub. 
(http://github.com/liucong/jms4cxf2/tree/master).

   If it is needed, I'll do it following 3) One "interesting" thought:

Best regards,
Liu

Willem Jiang Writes:

Hi Dan,

LiuCong created a wiki page[1] of his project working status on apache
wiki , he doesn't have the write right of cwiki.apache.org/CXF, neither
to me (njiang) :(.  Could you grand the karma for us? So we can move the
page into CXF.

I just talked to LiuCong today on IRC , he will creates some JIRAs
according his development plan shortly.

[1] http://wiki.apache.org/general/soapjms4cxf
Cheers,

Willem

Daniel Kulp wrote:
  
Now that the "implementation/code" phase for the GSoC stuff has begun, it 
would definitely be good to start getting some additional communications 
flowing to see how progress is coming, resolve any roadblocks, answer 
questions, etc


Thus, here are some ideas I thought of...
1)  File some JIRA tasks on our JIRA:  
https://issues.apache.org/jira/browse/CXF
It would be good to get a "base" jira created for your project and then start 
adding sub tasks to it.As things are implemented, the sub-projects can be 
resolved so we can see progress and such.   Also provides a good "checklist" 
of what remains and such.  (also, patches can be attached to the jiras so we 
can apply them)


2) I'd also like to start seeing regular "status" updates to the dev list just 
to keep tabs.   Remember, part of your final evaluation with Google involves 
how involved you got with the community.   Thus, speaking up on the dev list 
is a very good thing.


3) One "interesting" thought:  I'd encourage you to get a github.com account 
and "fork" the CXF project (http://github.com/apache/cxf)  and start pushing 
changes as you work in there.   Thus, we can really see what you are doing, 
how it all works together, etc   Additionally, if the "patch" starts 
getting complex, git does a MUCH better job of dealing with complex patches 
than subversion.


Anyway, at this point, it's kind of important to get some information flowing.  





  




Re: How to implement the SOAP Fault for JMS Transport?

2009-06-07 Thread liucong
Hi,
In the cxf-rt-transports-jms module,
org.apahce.cxf.transport.jms.JMSDestination.onMessage receive the JMS
message and create a CXF message.
If there is something wrong with the JMS message. I can't throw the
Fault here.
I should throw the Fault in the process of Message processing.
how to deal with this?


Best regards,
Liu

Willem Jiang Writes:
> Hi,
>
> I think you mean how to throw the fault from the JMS transport.
> Basically , if you throw the fault from a CXF interceptor, CXF's
> interceptors chain will take care of it and build the fault message and
> throw it out.
>
> If you want to check the Content type , you could write an interceptor
> and load it with your soap jms transport. But I think  you could take
> the soap binding (SoapBindingFactory) as an example, and put this kind
> of checking as a work of soap jms binding.
>
> Just my 2 cents,
>
> Willem
>
>
> liucong wrote:
>   
>> Hi all,
>>
>> When I implement the SOAP Over JMS Specification, I don’t know how to
>> implement SOAP fault for it.
>>
>> I use the org.apache.cxf.interceptor.Fault to record the Fault
>> information. For example, I create a Fault instance for SOAP fault
>> subcode contentTypeMismatch
>> (http://www.w3.org/TR/2008/WD-soapjms-20080723/#binding-faults). If I
>> check the fault the cxf-rt-transports-jms module, I don’t know how to
>> deal with the fault which is checked out.
>>
>> If I added an Interceptor for JMS transport, I can use the interceptor
>> to deal with the fault. Is It right?
>>
>> If it is Ok, how is the interceptor added to the interceptors according
>> to whether the jms transport is used or not?
>>
>> Are there any materials for interceptors, phases, and phase order?
>>
>> Thank you very much!
>>
>> Best regards,
>>
>> Liu
>>
>>
>> 
>
>
>   



Re: How to implement the SOAP Fault for JMS Transport?

2009-06-08 Thread liucong
Hi,

Willem Jiang 写道:
> Hi,
>
> I think you mean how to throw the fault from the JMS transport.
> Basically , if you throw the fault from a CXF interceptor, CXF's
> interceptors chain will take care of it and build the fault message and
> throw it out.
>
> If you want to check the Content type , you could write an interceptor
> and load it with your soap jms transport. But I think  you could take
> the soap binding (SoapBindingFactory) as an example, and put this kind
> of checking as a work of soap jms binding.
>
>   
SoapBindingFactory gets the binding information according to the
bindingid, for example, http://schemas.xmlsoap.org/wsdl/soap/. SOAP/JMS
may not provide a SOAP JMS binding id or something like that. I think we
should not add bindingid, too.
> Just my 2 cents,
>
> Willem
>
>
> liucong wrote:
>   
>> Hi all,
>>
>> When I implement the SOAP Over JMS Specification, I don’t know how to
>> implement SOAP fault for it.
>>
>> I use the org.apache.cxf.interceptor.Fault to record the Fault
>> information. For example, I create a Fault instance for SOAP fault
>> subcode contentTypeMismatch
>> (http://www.w3.org/TR/2008/WD-soapjms-20080723/#binding-faults). If I
>> check the fault the cxf-rt-transports-jms module, I don’t know how to
>> deal with the fault which is checked out.
>>
>> If I added an Interceptor for JMS transport, I can use the interceptor
>> to deal with the fault. Is It right?
>>
>> If it is Ok, how is the interceptor added to the interceptors according
>> to whether the jms transport is used or not?
>>
>> Are there any materials for interceptors, phases, and phase order?
>>
>> Thank you very much!
>>
>> Best regards,
>>
>> Liu
>>
>>
>> 
>
>
>   



Re: How to implement the SOAP Fault for JMS Transport?

2009-06-08 Thread liucong
Hi,

Willem Jiang Writes:
> Hi,
>
> I think you mean how to throw the fault from the JMS transport.
> Basically , if you throw the fault from a CXF interceptor, CXF's
> interceptors chain will take care of it and build the fault message and
> throw it out.
>
> If you want to check the Content type , you could write an interceptor
> and load it with your soap jms transport. 
How to load an interceptor with my soap jms transport? Is there any
material for help?

Thank you.
> But I think  you could take
> the soap binding (SoapBindingFactory) as an example, and put this kind
> of checking as a work of soap jms binding.
>
> Just my 2 cents,
>
> Willem
>
>
> liucong wrote:
>   
>> Hi all,
>>
>> When I implement the SOAP Over JMS Specification, I don’t know how to
>> implement SOAP fault for it.
>>
>> I use the org.apache.cxf.interceptor.Fault to record the Fault
>> information. For example, I create a Fault instance for SOAP fault
>> subcode contentTypeMismatch
>> (http://www.w3.org/TR/2008/WD-soapjms-20080723/#binding-faults). If I
>> check the fault the cxf-rt-transports-jms module, I don’t know how to
>> deal with the fault which is checked out.
>>
>> If I added an Interceptor for JMS transport, I can use the interceptor
>> to deal with the fault. Is It right?
>>
>> If it is Ok, how is the interceptor added to the interceptors according
>> to whether the jms transport is used or not?
>>
>> Are there any materials for interceptors, phases, and phase order?
>>
>> Thank you very much!
>>
>> Best regards,
>>
>> Liu
>>
>>
>> 
>
>
>   



SOAP/JMS specification for CXF [Project Status]

2009-06-10 Thread liucong
Hi all,

Project Description:
SOAP over JMS specification (http://www.w3.org/TR/soapjms/) is aimed at
a set of standards for the transport of SOAP messages over JMS (Java
Message Service). The main purpose is to ensure interoperability between
the implementations of different Web services vendors.
CXF does support SOAP over JMS, but it does not meet the current draft
specification defined at http://www.w3.org/TR/soapjms/ and instead uses
some proprietary formats, headers, URL formats, etc. This project would
update the SOAP/JMS support in CXF to be completely specification
compliant.
Any advice or help are welcome!

Project Information:
1.Project Status: http://wiki.apache.org/general/soapjms4cxf
2.Project Code: http://github.com/liucong/jms4cxf2/tree/master
3.Project JIRA task: https://issues.apache.org/jira/browse/CXF-2253

What I have done:
1.Implement a simple JMS URI
(http://tools.ietf.org/html/draft-merrick-jms-uri-05 )
2.Integrate the JMS URI into current jms-transport. It is compatible
with the specification.
3.Modify the JMS Header Properties and JMS Properties and make it
compatible with the specification.
4.Modify some code about SOAP fault and MEPs.

Liu



Re: How to implement the SOAP Fault for JMS Transport?

2009-06-10 Thread liucong
So, the JMS transport just copy JMS message properties to somewhere(For 
example, Message.PROTOCOL_HEADERS map). Then the SOAP binding add some 
extra interceptors (How to add these interceptors?) to deal with these 
properties (check the properties, throw some SOAP Faults, and so on).


Does it work? Is it Ok?



Daniel Kulp Writes:
Ideally, to me, this type of fault mapping needs to be in the SOAP binding, 
not the JMS transport.The JMS transport needs to be somewhat independent 
of soap so that it's usable for things like XML over JMS and possibly even 
some resty things.


Basically, the SOAP binding should examine it's transportId and if it's the 
SOAP/JMS spec defined ID, it should add some extra interceptors to handle the 
mapping of the "soap specific" things into the non-soap specific things in the 
transport.  

For example:  all the funky JMS headers that the SOAP/JMS spec requires should 
be done from an interceptor provided by the SOAP binding (put them in the 
Message.PROTOCOL_HEADERS map) that the JMS transport would just copy across.


That said, I really haven't read the SOAP/JMS spec in very much detail so I'm 
not sure if it's completely possible.   :-)


Dan


On Mon June 8 2009 10:54:18 pm liucong wrote:
  

Hi,

Willem Jiang Writes:


Hi,

I think you mean how to throw the fault from the JMS transport.
Basically , if you throw the fault from a CXF interceptor, CXF's
interceptors chain will take care of it and build the fault message and
throw it out.

If you want to check the Content type , you could write an interceptor
and load it with your soap jms transport.
  

How to load an interceptor with my soap jms transport? Is there any
material for help?

Thank you.



But I think  you could take
the soap binding (SoapBindingFactory) as an example, and put this kind
of checking as a work of soap jms binding.

Just my 2 cents,

Willem

liucong wrote:
  

Hi all,

When I implement the SOAP Over JMS Specification, I don’t know how to
implement SOAP fault for it.

I use the org.apache.cxf.interceptor.Fault to record the Fault
information. For example, I create a Fault instance for SOAP fault
subcode contentTypeMismatch
(http://www.w3.org/TR/2008/WD-soapjms-20080723/#binding-faults). If I
check the fault the cxf-rt-transports-jms module, I don’t know how to
deal with the fault which is checked out.

If I added an Interceptor for JMS transport, I can use the interceptor
to deal with the fault. Is It right?

If it is Ok, how is the interceptor added to the interceptors according
to whether the jms transport is used or not?

Are there any materials for interceptors, phases, and phase order?

Thank you very much!

Best regards,

Liu



  




Re: How to implement the SOAP Fault for JMS Transport?

2009-06-16 Thread liucong

Hi,
   I have added a simple interceptor in the SOAP binding. If the 
transport uri is http://www.w3.org/2008/07/soap/bindings/JMS/, the jms 
interceptor will be added. But I have some question for that:

   1. I feel a little weird to add a transport-related interceptor here.
   2. Program Problem. I have declared some constants in the 
jms-transport module. I need use some of these constants in the jms 
interceptor. I think it is a little weird to add project dependency to 
jms-transport for soap-binding module. Do I need to declare these 
constants again in the soap-binding module?
   3. How to deal with soapjms:isFault property. If the soapjms:isFault 
is true, it indicates that the response is a SOAP fault. How to deal 
with this property.


best regards,
liu

Daniel Kulp Writes:

On Wed June 10 2009 4:38:37 am liucong wrote:
  

So, the JMS transport just copy JMS message properties to somewhere(For
example, Message.PROTOCOL_HEADERS map). Then the SOAP binding add some
extra interceptors (How to add these interceptors?) to deal with these
properties (check the properties, throw some SOAP Faults, and so on).

Does it work? Is it Ok?



Yep.  That seems right.

To add your interceptors, it would be in the SoapBindingFactory class.   The 
createBinding(BindingInfo) method is where the interceptors for the SOAP stuff 
is setup.That would be the starting place to look.


Dan


  

Daniel Kulp Writes:


Ideally, to me, this type of fault mapping needs to be in the SOAP
binding, not the JMS transport.The JMS transport needs to be somewhat
independent of soap so that it's usable for things like XML over JMS and
possibly even some resty things.

Basically, the SOAP binding should examine it's transportId and if it's
the SOAP/JMS spec defined ID, it should add some extra interceptors to
handle the mapping of the "soap specific" things into the non-soap
specific things in the transport.

For example:  all the funky JMS headers that the SOAP/JMS spec requires
should be done from an interceptor provided by the SOAP binding (put them
in the Message.PROTOCOL_HEADERS map) that the JMS transport would just
copy across.

That said, I really haven't read the SOAP/JMS spec in very much detail so
I'm not sure if it's completely possible.   :-)

Dan

On Mon June 8 2009 10:54:18 pm liucong wrote:
  

Hi,

Willem Jiang Writes:


Hi,

I think you mean how to throw the fault from the JMS transport.
Basically , if you throw the fault from a CXF interceptor, CXF's
interceptors chain will take care of it and build the fault message and
throw it out.

If you want to check the Content type , you could write an interceptor
and load it with your soap jms transport.
  

How to load an interceptor with my soap jms transport? Is there any
material for help?

Thank you.



But I think  you could take
the soap binding (SoapBindingFactory) as an example, and put this kind
of checking as a work of soap jms binding.

Just my 2 cents,

Willem

liucong wrote:
  

Hi all,

When I implement the SOAP Over JMS Specification, I don’t know how to
implement SOAP fault for it.

I use the org.apache.cxf.interceptor.Fault to record the Fault
information. For example, I create a Fault instance for SOAP fault
subcode contentTypeMismatch
(http://www.w3.org/TR/2008/WD-soapjms-20080723/#binding-faults). If I
check the fault the cxf-rt-transports-jms module, I don’t know how to
deal with the fault which is checked out.

If I added an Interceptor for JMS transport, I can use the interceptor
to deal with the fault. Is It right?

If it is Ok, how is the interceptor added to the interceptors
according to whether the jms transport is used or not?

Are there any materials for interceptors, phases, and phase order?

Thank you very much!

Best regards,

Liu



  




How to add wsdl extension for SOAP/JMS.

2009-06-23 Thread liucong
Hi,
I want to add wsdl extension for SOAP/JMS according to
http://www.w3.org/TR/2008/WD-soapjms-20081121/#wsdl-extensions.

For example, I want add wsdl extension for DeliveryMode property. I edit
the wsdl file like[1]:

http://www.w3.org/2008/07/soap/bindings/JMS/"/>

PERSISTENT










...


If I add the extension schema like this[2]:




















But I can't get the extension in the wsdl.
If I change the wsdl like this[3]:

http://www.w3.org/2008/07/soap/bindings/JMS/"/>

PERSISTENT










...


I'll get the result of deliveryMode extension.
I think the wsdl extension just can add attributes, element to a
extension element in CXF. But I can't get the extension element's value.
Is it right?

My question is: how to get the extension information in [1]. What does
the extension schema look like?

thanks.
Liu



Re: How to add wsdl extension for SOAP/JMS.

2009-06-24 Thread liucong

Hi, Dan,
  
   Thank you very much for your advice.  By some experiments for the 
WSDL extension. I think it is right that this WSDL extension needs some 
changes to CXF wsdl processing. And the CXF wsdl processing will supoort 
the entension in SOAP/JMS.  I think this kind of extension is necessary 
for CXF wsdl processing.
   Are there any documents which help me finish this kind of 
extension?  thank you! :-)


Liu


Daniel Kulp wrote:
Hmm...   I'm not really sure.   I don't think there IS a schema that would 
work properly for this.   My gut feeling was something like:






   
   
   



but I know that doesn't work. 

This will probably need some changes to CXF wsdl processing to really get this 
to work well.   Actually, this could provide a good opportunity to cleanup the 
JAXB WSDL   extension mechanism to NOT require that the schema extends the 
wsdl:tExtensibilityElement type.   I'm actually thinking a xjc plugin that 
would make all the generated types automatically implement the wsdl4j 
ExtensibiltyElement interface and add the methods/fields for that. 

That can significantly cleanup the CXF schemas for all the extensors.   It 
would be completely automatic.


Dan

On Tue June 23 2009 11:51:43 am liucong wrote:
  

Hi,
I want to add wsdl extension for SOAP/JMS according to
http://www.w3.org/TR/2008/WD-soapjms-20081121/#wsdl-extensions.

For example, I want add wsdl extension for DeliveryMode property. I edit
the wsdl file like[1]:

http://www.w3.org/2008/07/soap/bindings/JMS/"/>

PERSISTENT










...


If I add the extension schema like this[2]:




















But I can't get the extension in the wsdl.
If I change the wsdl like this[3]:

http://www.w3.org/2008/07/soap/bindings/JMS/"/>

PERSISTENT










...


I'll get the result of deliveryMode extension.
I think the wsdl extension just can add attributes, element to a
extension element in CXF. But I can't get the extension element's value.
Is it right?

My question is: how to get the extension information in [1]. What does
the extension schema look like?

thanks.
Liu



  




Re: SOAP/JMS specification for CXF [Project Status]

2009-06-24 Thread liucong
Hi all,

I have submitted a patch for my work in transport-jms.
https://issues.apache.org/jira/browse/CXF-2253. It is not complete, and
I'll continue to work on it to make it complete.

Any suggests are welcome!

liu

liucong wrote:
> Hi all,
>
> Project Description:
> SOAP over JMS specification (http://www.w3.org/TR/soapjms/) is aimed at
> a set of standards for the transport of SOAP messages over JMS (Java
> Message Service). The main purpose is to ensure interoperability between
> the implementations of different Web services vendors.
> CXF does support SOAP over JMS, but it does not meet the current draft
> specification defined at http://www.w3.org/TR/soapjms/ and instead uses
> some proprietary formats, headers, URL formats, etc. This project would
> update the SOAP/JMS support in CXF to be completely specification
> compliant.
> Any advice or help are welcome!
>
> Project Information:
> 1.Project Status: http://wiki.apache.org/general/soapjms4cxf
> 2.Project Code: http://github.com/liucong/jms4cxf2/tree/master
> 3.Project JIRA task: https://issues.apache.org/jira/browse/CXF-2253
>
> What I have done:
> 1.Implement a simple JMS URI
> (http://tools.ietf.org/html/draft-merrick-jms-uri-05 )
> 2.Integrate the JMS URI into current jms-transport. It is compatible
> with the specification.
> 3.Modify the JMS Header Properties and JMS Properties and make it
> compatible with the specification.
> 4.Modify some code about SOAP fault and MEPs.
>
> Liu
>
>
>   



Re: How to add wsdl extension for SOAP/JMS.

2009-07-01 Thread liucong
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.java:210)
   at 
org.apache.cxf.wsdl11.WSDLManagerImpl.getDefinition(WSDLManagerImpl.java:175)
   at 
org.apache.cxf.wsdl11.WSDLServiceFactory.(WSDLServiceFactory.java:91)

   ... 14 more

So I have a question. What's wrong? Could the xjc solve this exception?

thank you.
liu

Daniel Kulp wrote:

On Thu June 25 2009 1:39:34 am liucong wrote:
  

Hi, Dan,

Thank you very much for your advice.  By some experiments for the
WSDL extension. I think it is right that this WSDL extension needs some
changes to CXF wsdl processing. And the CXF wsdl processing will supoort
the entension in SOAP/JMS.  I think this kind of extension is necessary
for CXF wsdl processing.



The best place to look is in the cxf trunk/common/xjc/ts project.   That 
project is an XJC plugin that adds "toString" methods to all the generated 
types.  



For MOST cases, you would need make the superclass be 
TExtensibilityElementImpl instead of Object.   


In other cases, it's a bit more complex:
1) For stuff that sublasses JAXBElement, you would need to make it implement 
ExtensibilityElement and add those methods and field.


2) For Enums - I think the stuff from (1) applies as well, not really sure 
though.


Technically, it PROBABLY just needs to apply to "root" elements.  (Stuff with 
@XmlRootElement annotations).  



Dan




  

Are there any documents which help me finish this kind of
extension?  thank you! :-)

Liu

Daniel Kulp wrote:


Hmm...   I'm not really sure.   I don't think there IS a schema that
would work properly for this.   My gut feeling was something like:





   
   
   



but I know that doesn't work.

This will probably need some changes to CXF wsdl processing to really get
this to work well.   Actually, this could provide a good opportunity to
cleanup the JAXB WSDL   extension mechanism to NOT require that the
schema extends the wsdl:tExtensibilityElement type.   I'm actually
thinking a xjc plugin that would make all the generated types
automatically implement the wsdl4j ExtensibiltyElement interface and add
the methods/fields for that.

That can significantly cleanup the CXF schemas for all the extensors.  
It would be completely automatic.


Dan

On Tue June 23 2009 11:51:43 am liucong wrote:
  

Hi,
I want to add wsdl extension for SOAP/JMS according to
http://www.w3.org/TR/2008/WD-soapjms-20081121/#wsdl-extensions.

For example, I want add wsdl extension for DeliveryMode property. I edit
the wsdl file like[1]:
 http://www.w3.org/2008/07/soap/bindings/JMS/"/>

PERSISTENT










...


If I add the extension schema like this[2]:




















But I can't get the extension in the wsdl.
If I change the wsdl like this[3]:
 http://www.w3.org/2008/07/soap/bindings/JMS/"/>

PERSISTENT










...


I'll get the result of deliveryMode extension.
I think the wsdl extension just can add attributes, element to a
extension element in CXF. But I can't get the extension element's value.
Is it right?

My question is: how to get the extension information in [1]. What does
the extension schema look like?

thanks.
Liu



  




Re: How to add wsdl extension for SOAP/JMS.

2009-07-01 Thread liucong

Hi,
  
   Thank you for you advice. I do a small experiment. I use 
ExtensibilityElement to replace TExtensibilityElementImpl. Also I 
modified some codes in the cxf-api project.

   It works now.

best regards,
liu

Daniel Kulp wrote:

Liu,

I think for stuff that are "simple" (basically, complexTypes with 
simpleContent and simpleType object), you cannot extend 
TExtensibilityElementImpl.   Instead, you would need to make it implement 
ExtensibilityElement interface and add the QName and required fields and such.   


Dan


On Wed July 1 2009 12:18:15 pm liucong wrote:
  

Hi,

I do a simple experiment about the design sugguest by Dan.
First, I use jaxb, not xjc. I think they have the principle.

The schema like this[1]:








The generated class for DeliveryModeType like this[2]:
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "deliveryModeType", propOrder = {
"value"
})
public class DeliveryModeType{

@XmlValue
protected String value;

/**
 * Gets the value of the value property.
 *
 * @return
 * possible object is
 * {...@link String }
 *
 */
public String getValue() {
return value;
}

/**
 * Sets the value of the value property.
 *
 * @param value
 * allowed object is
 * {...@link String }
 *
 */
public void setValue(String value) {
this.value = value;
}

public boolean isSetValue() {
return (this.value!= null);
}
}

The DeliveryModeType doesn't extend TExtensibilityElementImpl. So I just
modify the class and make it look like this[3]:
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "deliveryModeType", propOrder = {
"value"
})
public class DeliveryModeType extends TExtensibilityElementImpl{

@XmlValue
protected String value;

/**
 * Gets the value of the value property.
 *
 * @return
 * possible object is
 * {...@link String }
 *
 */
public String getValue() {
return value;
}

/**
 * Sets the value of the value property.
 *
 * @param value
 * allowed object is
 * {...@link String }
 *
 */
public void setValue(String value) {
this.value = value;
}

public boolean isSetValue() {
return (this.value!= null);
}
}

Then when I publish a service, I get an exception[4]
Creating Service {http://cxf.apache.org/jms_greeter}JMSGreeterService
from WSDL: file:./wsdl/jms_greeter.wsdl
Exception in thread "main" javax.xml.ws.WebServiceException:
org.apache.cxf.service.factory.ServiceConstructionException: Failed to
create service.
at org.apache.cxf.jaxws.EndpointImpl.doPublish(EndpointImpl.java:275)
at org.apache.cxf.jaxws.EndpointImpl.publish(EndpointImpl.java:209)
at
org.apache.cxf.jaxws.spi.ProviderImpl.createAndPublishEndpoint(ProviderImpl
.java:84) at javax.xml.ws.Endpoint.publish(Endpoint.java:47)
at demo.jms_greeter.server.Server.(Server.java:30)
at demo.jms_greeter.server.Server.main(Server.java:34)
Caused by: org.apache.cxf.service.factory.ServiceConstructionException:
Failed to create service.
at
org.apache.cxf.wsdl11.WSDLServiceFactory.(WSDLServiceFactory.java:93)
at
org.apache.cxf.service.factory.ReflectionServiceFactoryBean.buildServiceFro
mWSDL(ReflectionServiceFactoryBean.java:317) at
org.apache.cxf.service.factory.ReflectionServiceFactoryBean.initializeServi
ceModel(ReflectionServiceFactoryBean.java:437) at
org.apache.cxf.service.factory.ReflectionServiceFactoryBean.create(Reflecti
onServiceFactoryBean.java:195) at
org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean.create(JaxWsServiceFac
toryBean.java:163) at
org.apache.cxf.frontend.AbstractWSDLBasedEndpointFactory.createEndpoint(Abs
tractWSDLBasedEndpointFactory.java:100) at
org.apache.cxf.frontend.ServerFactoryBean.create(ServerFactoryBean.java:117
) at
org.apache.cxf.jaxws.JaxWsServerFactoryBean.create(JaxWsServerFactoryBean.j
ava:167) at
org.apache.cxf.jaxws.EndpointImpl.getServer(EndpointImpl.java:346) at
org.apache.cxf.jaxws.EndpointImpl.doPublish(EndpointImpl.java:259) ... 5
more
Caused by: javax.wsdl.WSDLException: WSDLException (at
/wsdl:definitions/wsdl:binding/soapjms:deliveryMode):
faultCode=PARSER_ERROR: Error reading element
{http://www.w3.org/2008/07/soap/bindings/JMS/}deliveryMode:
java.lang.RuntimeException:
com.sun.xml.bind.v2.runtime.IllegalAnnotationsException: 1 counts of
IllegalAnnotationExceptions
@XmlValue is not allowed on a class that derives another class.
this problem is related to the following location:
at protected java.lang.String
org.apache.cxf.transport.jms.spec.DeliveryModeType.value
at org.apache.cxf.transport.jms.spec.DeliveryModeType
at public org.apache.cxf.transport.jms.spec.DeliveryModeType
org.apache.cxf.tra

Re: How to add wsdl extension for SOAP/JMS.

2009-07-03 Thread liucong

Hi,
   I am writing a plugin for xjc.
   First I just modify the cxf-xjc-ts and cxf-xjc-ts-test, and make it 
work with the -Xwsdlextension, not -Xts. The pom file is also changed. 
And it works rightly.
   Then I copy the modified projects into cxf-xjc-wsdlextension and 
cxf-xjc-wsdlextension-test, and make the cxf-xjc-ts the same with the 
subversion.

   It failed. The exception is:
   [INFO] 


[INFO] Building Apache CXF XJC WSDL Extension Plugin Tests
[INFO]task-segment: [install]
[INFO] 


[INFO] [cxf-xml2fastinfoset:xml2fastinfoset {execution: xml2fastinfoset}]
[INFO] [jaxb2:xjc {execution: default}]
[INFO] Generating source...
[INFO] 


[ERROR] BUILD ERROR
[INFO] 


[INFO] unrecognized parameter -Xwsdlextension

   What's wrong? Do I need to do more configuration for ths xjc plugin?

thanks!

Daniel Kulp wrote:

Liu,

I think for stuff that are "simple" (basically, complexTypes with 
simpleContent and simpleType object), you cannot extend 
TExtensibilityElementImpl.   Instead, you would need to make it implement 
ExtensibilityElement interface and add the QName and required fields and such.   


Dan


On Wed July 1 2009 12:18:15 pm liucong wrote:
  

Hi,

I do a simple experiment about the design sugguest by Dan.
First, I use jaxb, not xjc. I think they have the principle.

The schema like this[1]:








The generated class for DeliveryModeType like this[2]:
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "deliveryModeType", propOrder = {
"value"
})
public class DeliveryModeType{

@XmlValue
protected String value;

/**
 * Gets the value of the value property.
 *
 * @return
 * possible object is
 * {...@link String }
 *
 */
public String getValue() {
return value;
}

/**
 * Sets the value of the value property.
 *
 * @param value
 * allowed object is
 * {...@link String }
 *
 */
public void setValue(String value) {
this.value = value;
}

public boolean isSetValue() {
return (this.value!= null);
}
}

The DeliveryModeType doesn't extend TExtensibilityElementImpl. So I just
modify the class and make it look like this[3]:
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "deliveryModeType", propOrder = {
"value"
})
public class DeliveryModeType extends TExtensibilityElementImpl{

@XmlValue
protected String value;

/**
 * Gets the value of the value property.
 *
 * @return
 * possible object is
 * {...@link String }
 *
 */
public String getValue() {
return value;
}

/**
 * Sets the value of the value property.
 *
 * @param value
 * allowed object is
 * {...@link String }
 *
 */
public void setValue(String value) {
this.value = value;
}

public boolean isSetValue() {
return (this.value!= null);
}
}

Then when I publish a service, I get an exception[4]
Creating Service {http://cxf.apache.org/jms_greeter}JMSGreeterService
from WSDL: file:./wsdl/jms_greeter.wsdl
Exception in thread "main" javax.xml.ws.WebServiceException:
org.apache.cxf.service.factory.ServiceConstructionException: Failed to
create service.
at org.apache.cxf.jaxws.EndpointImpl.doPublish(EndpointImpl.java:275)
at org.apache.cxf.jaxws.EndpointImpl.publish(EndpointImpl.java:209)
at
org.apache.cxf.jaxws.spi.ProviderImpl.createAndPublishEndpoint(ProviderImpl
.java:84) at javax.xml.ws.Endpoint.publish(Endpoint.java:47)
at demo.jms_greeter.server.Server.(Server.java:30)
at demo.jms_greeter.server.Server.main(Server.java:34)
Caused by: org.apache.cxf.service.factory.ServiceConstructionException:
Failed to create service.
at
org.apache.cxf.wsdl11.WSDLServiceFactory.(WSDLServiceFactory.java:93)
at
org.apache.cxf.service.factory.ReflectionServiceFactoryBean.buildServiceFro
mWSDL(ReflectionServiceFactoryBean.java:317) at
org.apache.cxf.service.factory.ReflectionServiceFactoryBean.initializeServi
ceModel(ReflectionServiceFactoryBean.java:437) at
org.apache.cxf.service.factory.ReflectionServiceFactoryBean.create(Reflecti
onServiceFactoryBean.java:195) at
org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean.create(JaxWsServiceFac
toryBean.java:163) at
org.apache.cxf.frontend.AbstractWSDLBasedEndpointFactory.createEndpoint(Abs
tractWSDLBasedEndpointFactory.java:100) at
org.apache.cxf.frontend.ServerFactoryBean.create(ServerFactoryBean.java:117
) at
org.apache.cxf.jaxws.JaxWsServerFactoryBean.create(JaxWsServe

Re: How to add wsdl extension for SOAP/JMS.

2009-07-03 Thread liucong

yeah.
The pom file in the cxf-xjc-wsdlextension:
http://maven.apache.org/POM/4.0.0"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 
http://maven.apache.org/maven-v4_0_0.xsd";>

   4.0.0
   org.apache.cxf
   cxf-xjc-wsdlextension
   jar
   2.3.0-SNAPSHOT
   Apache CXF XJC WSDL Extension Plugin
   http://cxf.apache.org

   
   org.apache.cxf
   cxf-parent
   2.3.0-SNAPSHOT
   ../../../parent/pom.xml
   

   
   true
   

   
   
   org.apache.cxf
   cxf-common-utilities
   ${project.version}
   
   
   com.sun.xml.bind
   jaxb-xjc
   
   
   com.sun.xml.bind
   jaxb-impl
   
   
   commons-lang
   commons-lang
   
   

   
   
scm:svn:http://svn.apache.org/repos/asf/cxf/trunk/common/xjc/wsdlextension
   
scm:svn:https://svn.apache.org/repos/asf/cxf/trunk/common/xjc/wsdlextension

   



The pom file in the cxf-xjc-wsdlextension-test is:
http://maven.apache.org/POM/4.0.0"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 
http://maven.apache.org/maven-v4_0_0.xsd";>

   4.0.0
   org.apache.cxf
   cxf-xjc-wsdlextension-test
   jar
   2.3.0-SNAPSHOT
   Apache CXF XJC WSDL Extension Plugin Tests
   http://cxf.apache.org

   
   org.apache.cxf
   cxf-parent
   2.3.0-SNAPSHOT
   ../../../parent/pom.xml
   

   

   
   javax.xml.bind
   jaxb-api
   
   
   com.sun.xml.bind
   jaxb-impl
   
   
   com.sun.xml.bind
   jaxb-xjc
   
   
   junit
   junit
   test
   
   
   org.apache.cxf
   cxf-common-utilities
   ${project.version}
   
   
  commons-lang
  commons-lang
   
   

   
   
   
   org.codehaus.mojo
   jaxb2-maven-plugin
   1.2
   
   
   
   xjc
   
   
   
   
   
${basedir}/target/generated/src/test/java
   
${basedir}/src/test/resources/schemas/configuration

   -Xwsdlextension
   true
   true
   

   
   
   org.apache.cxf
   cxf-xjc-dv
   ${project.version}
   
   
   org.apache.cxf
   cxf-xjc-wsdlextension
   ${project.version}
   
   
   
   
   


   
   
scm:svn:http://svn.apache.org/repos/asf/cxf/trunk/common/xjc/wsdlextension-test
   
scm:svn:https://svn.apache.org/repos/asf/cxf/trunk/common/xjc/wsdlextension-test

   





Willem Jiang wrote:

I guess you have something wrong on the plugin's pom.
Maybe you need to show the code to let us help you :)

Willem

liucong wrote:

Hi,
I am writing a plugin for xjc.
First I just modify the cxf-xjc-ts and cxf-xjc-ts-test, and make 
it work with the -Xwsdlextension, not -Xts. The pom file is also 
changed. And it works rightly.
Then I copy the modified projects into cxf-xjc-wsdlextension and 
cxf-xjc-wsdlextension-test, and make the cxf-xjc-ts the same with the 
subversion.

It failed. The exception is:
[INFO] 


[INFO] Building Apache CXF XJC WSDL Extension Plugin Tests
[INFO]task-segment: [install]
[INFO] 

[INFO] [cxf-xml2fastinfoset:xml2fastinfoset {execution: 
xml2fastinfoset}]

[INFO] [jaxb2:xjc {execution: default}]
[INFO] Generating source...
[INFO] 


[ERROR] BUILD ERROR
[INFO] 


[INFO] unrecognized parameter -Xwsdlextension

What's wrong? Do I need to do more configuration for ths xjc plugin?

thanks!

Daniel Kulp wrote:

Liu,

I think for stuff that are "simple" (basically, complexTypes with 
simpleContent and simpleType object), you cannot extend 
TExtensibilityElementImpl.   Instead, you would need to make it 
implement ExtensibilityElement interface and add the QName and 
required fields and such.  
Dan



On Wed July 1 2009 12:18:15 pm liucong wrote:
 

Hi,

I do a simple experiment about the design sugguest by Dan.
First, I use jaxb, not xjc. I think they have the principle.

The schema like this[1]:








The generated class for DeliveryModeType like this

Properties Overriding in WSDL usage

2009-07-03 Thread liucong
Hi all,

In the
SOAP/JMS(http://www.w3.org/TR/2008/WD-soapjms-20081121/#wsdl-11-properties).
If a property is specified at multiple levels, the most specific setting
will take precedence (port first, then service, then binding).

But I invetigate the code of CXF. I find someting int
org.apache.cxf.service.model.EndpointInfo.getTraversedExtensor(T
defaultValue, Class type):
@Override
public  T getTraversedExtensor(T defaultValue, Class type) {
T value = getExtensor(type);

if (value == null) {
if (value == null && binding != null) {
value = binding.getExtensor(type);
}

if (service != null && value == null) {
value = service.getExtensor(type);
}

if (value == null) {
value = defaultValue;
}
}

return value;
}

The code shou that:port first, then binding, then service.

Now. Which is right?

thanks.


An Exception occurs when use wsdl extension in the port

2009-07-04 Thread liucong
Hi all,
When I implement the WSDL usage for SOAP/JMS, I encountered an exception.
I create an service and invoke it using wsdl-first.

If the wsdl file looks like this[1] :




1000




This service works well.

But if the wsdl file looks like this[2] :



1000





The service is created correctly, but there is an error happen when I
invoke this service.
By debugging, I find that JMSTransportFactory.getConduit(EndpointInfo
endpointInfo, EndpointReferenceType target)'s target parameter is null.
It should be
"jms:jndi:dynamicQueues/test.cxf.jmstransport.queue?jndiInitialContextFactory=org.apache.activemq.jndi.ActiveMQInitialContextFactory&jndiConnectionFactoryName=ConnectionFactory&jndiURL=tcp://localhost:61616&targetService=greeterService".

I think there are someting wrong with port parsing in wsdl.
Any ideas?

best regards
liu


Re: An Exception occurs when use wsdl extension in the port

2009-07-06 Thread liucong
Thank you, Dan.

I just found the problem as you said.
I can make the JMSTransportFactory implement WSDLEndpointFactory
interface. And then the SOAPAddress can be used to create
createEndpointInfo. Then the problem will be solved. I'm trying to do this.

liu

Daniel Kulp wrote:
> A test case (attached to a JIRA) would be good if you cannot figure this out.
>
> However, here is a pointer:
> When CXF looks in the WSDL to determine the transport factory, it looks at 
> the 
> FIRST extensor on the port that has a namespace that matches a transport 
> factory.  In your first example, it would be "soap" and thus would match the 
> "soap" transport.
>
> In the second, it would be "soapjms" and thus probably matches the JMS 
> transport and not the soap transport.   The jms transport probably doesn't 
> look for "soap:address".
>
> Not sure on the best course of action to solve this.   :-( Possibly the 
> soap binding could reset the address on the transport or something.   Would 
> be 
> good to check if this is the case before diving in too deep.  
>
> Dan
>
>
>
>
>
> On Sat July 4 2009 7:51:40 am liucong wrote:
>   
>> Hi all,
>> When I implement the WSDL usage for SOAP/JMS, I encountered an exception.
>> I create an service and invoke it using wsdl-first.
>>
>> If the wsdl file looks like this[1] :
>> 
>> 
>> 
>> > location="jms:jndi:dynamicQueues/test.cxf.jmstransport.queue?jndiInitialCon
>> textFactory=org.apache.activemq.jndi.ActiveMQInitialContextFactory&jndiC
>> onnectionFactoryName=ConnectionFactory&jndiURL=tcp://localhost:61616&
>> ;targetService=greeterService" />
>> 1000
>> 
>> 
>> 
>>
>> This service works well.
>>
>> But if the wsdl file looks like this[2] :
>> 
>> 
>> 
>> 1000
>> > location="jms:jndi:dynamicQueues/test.cxf.jmstransport.queue?jndiInitialCon
>> textFactory=org.apache.activemq.jndi.ActiveMQInitialContextFactory&jndiC
>> onnectionFactoryName=ConnectionFactory&jndiURL=tcp://localhost:61616&
>> ;targetService=greeterService" />
>> 
>> 
>> 
>>
>> The service is created correctly, but there is an error happen when I
>> invoke this service.
>> By debugging, I find that JMSTransportFactory.getConduit(EndpointInfo
>> endpointInfo, EndpointReferenceType target)'s target parameter is null.
>> It should be
>> "jms:jndi:dynamicQueues/test.cxf.jmstransport.queue?jndiInitialContextFacto
>> ry=org.apache.activemq.jndi.ActiveMQInitialContextFactory&jndiConnection
>> FactoryName=ConnectionFactory&jndiURL=tcp://localhost:61616&targetSe
>> rvice=greeterService".
>>
>> I think there are someting wrong with port parsing in wsdl.
>> Any ideas?
>>
>> best regards
>> liu
>> 
>
>   



Re: An Exception occurs when use wsdl extension in the port

2009-07-06 Thread liucong
Hi Dan,

Thank you for your good advice. I think keeping the "soap" stuff in the
soap binding is a very good idea.
https://issues.apache.org/jira/browse/CXF-2264?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12727756#action_12727756
<https://issues.apache.org/jira/browse/CXF-2264?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12727756#action_12727756>

liu

Daniel Kulp wrote:
> A test case (attached to a JIRA) would be good if you cannot figure this out.
>
> However, here is a pointer:
> When CXF looks in the WSDL to determine the transport factory, it looks at 
> the 
> FIRST extensor on the port that has a namespace that matches a transport 
> factory.  In your first example, it would be "soap" and thus would match the 
> "soap" transport.
>
> In the second, it would be "soapjms" and thus probably matches the JMS 
> transport and not the soap transport.   The jms transport probably doesn't 
> look for "soap:address".
>
> Not sure on the best course of action to solve this.   :-( Possibly the 
> soap binding could reset the address on the transport or something.   Would 
> be 
> good to check if this is the case before diving in too deep.  
>
> Dan
>
>
>
>
>
> On Sat July 4 2009 7:51:40 am liucong wrote:
>   
>> Hi all,
>> When I implement the WSDL usage for SOAP/JMS, I encountered an exception.
>> I create an service and invoke it using wsdl-first.
>>
>> If the wsdl file looks like this[1] :
>> 
>> 
>> 
>> > location="jms:jndi:dynamicQueues/test.cxf.jmstransport.queue?jndiInitialCon
>> textFactory=org.apache.activemq.jndi.ActiveMQInitialContextFactory&jndiC
>> onnectionFactoryName=ConnectionFactory&jndiURL=tcp://localhost:61616&
>> ;targetService=greeterService" />
>> 1000
>> 
>> 
>> 
>>
>> This service works well.
>>
>> But if the wsdl file looks like this[2] :
>> 
>> 
>> 
>> 1000
>> > location="jms:jndi:dynamicQueues/test.cxf.jmstransport.queue?jndiInitialCon
>> textFactory=org.apache.activemq.jndi.ActiveMQInitialContextFactory&jndiC
>> onnectionFactoryName=ConnectionFactory&jndiURL=tcp://localhost:61616&
>> ;targetService=greeterService" />
>> 
>> 
>> 
>>
>> The service is created correctly, but there is an error happen when I
>> invoke this service.
>> By debugging, I find that JMSTransportFactory.getConduit(EndpointInfo
>> endpointInfo, EndpointReferenceType target)'s target parameter is null.
>> It should be
>> "jms:jndi:dynamicQueues/test.cxf.jmstransport.queue?jndiInitialContextFacto
>> ry=org.apache.activemq.jndi.ActiveMQInitialContextFactory&jndiConnection
>> FactoryName=ConnectionFactory&jndiURL=tcp://localhost:61616&targetSe
>> rvice=greeterService".
>>
>> I think there are someting wrong with port parsing in wsdl.
>> Any ideas?
>>
>> best regards
>> liu
>> 
>
>   



how to design a systest framework for SOAP/JMS test suite

2009-07-13 Thread liucong
Hi,

I'm working on SOAP/JMS test suite
(http://dev.w3.org/2008/ws/soapjms/testcases/).

For each test case, I need to check the JMS message properties. So I
need to get the outgoing and incoming message of each mep. But I don't
know how to get the JMS message from the JMS transport.

If I store the JMS message in the request and responce context, I can
get the JMS message easily. In the client, I think it is easy for me to
store the response JMS message. But it is a little hard to store the
request JMS message. Because I use spring-jms to send the JMS message. I
don't know exactly what message is sent by the spring-jms.

So my question is: Is there any way to get the outgoing and incoming JMS
message easily?

Thanks a lot.

liu


request-response patterns.

2009-07-23 Thread liucong
Hi,

Some information about JMS Correlation ID patten and Message ID pattern
on request-response patterns
(http://edocs.bea.com/alsb/docs25/interopjms/MsgIDPatternforJMS.html).

By digging into the code about jms-transport, I know the current
jms-transport uses the Correlation ID Pattern. But the SOAP/JMS
specification uses Message ID Pattern.

What should I do?
1. To keep Correlation ID Pattern. But it is not compatible with the
specification.
2. To use Message ID Pattern. I see some code which use spring-jms, I
can't get the id of the message which is sent by spring-jms. I don't
know how to get the message id which is used to correlated the response
message.

Thank you for your sugguest in advance.

liu


Re: request-response patterns.

2009-07-23 Thread liucong
Hi,

Should I change to use Message ID Pattern and make it compatible with
the specification?


liucong wrote:
> Hi,
>
> Some information about JMS Correlation ID patten and Message ID pattern
> on request-response patterns
> (http://edocs.bea.com/alsb/docs25/interopjms/MsgIDPatternforJMS.html).
>
> By digging into the code about jms-transport, I know the current
> jms-transport uses the Correlation ID Pattern. But the SOAP/JMS
> specification uses Message ID Pattern.
>
> What should I do?
> 1. To keep Correlation ID Pattern. But it is not compatible with the
> specification.
> 2. To use Message ID Pattern. I see some code which use spring-jms, I
> can't get the id of the message which is sent by spring-jms. I don't
> know how to get the message id which is used to correlated the response
> message.
>
> Thank you for your sugguest in advance.
>
> liu
>
>   



How to generate the CorrelationID in the client in jms transport?

2009-07-24 Thread liucong
Hi,

I'm very confused with the CorrelationID which is generated by the
jms-transport.

The configuration piece as follows:








I think the rules generating the CorrelationID should be as follows:

userCID -> userCID
userCID + conduitSelectorPrefix -> userCID
userCID + conduitSelectorPrefix + useConduitIdSelector(true) -> userCID
userCID + conduitSelectorPrefix + useConduitIdSelector(false) -> userCID

conduitSelectorPrefix + useConduitIdSelector(true) ->
conduitSelectorPrefix + conduitId + index
conduitSelectorPrefix + useConduitIdSelector(false) ->
conduitSelectorPrefix + index

useConduitIdSelector(true) -> conduitId + index
useConduitIdSelector(false) -> the request message's messageID

->'s left side is the condition.
->'s right side is rule for generation of CorrelationID.
userCID means that the client gives a CorrelationID.
conduitSelectorPrefix means that the client configures in the wsdl.
useConduitIdSelector means that the client configures in the wsdl.
conduitId means that the string generated by the jms-tranport's JMSConduit.
index is a autoincreasing number which indicates the uniqueness of the
CorrelationID.


Is it right?
I want to use this rules for the generation of CorrelationID.

best regards


Re: test suite patch.

2009-07-26 Thread liucong
Hi,
The list of changes is as follows:
(1) Some SOAPFault processing int cxf-rt-bindings-soap subproject.
(2) To generate the CorrelationID in the client of jms transport
according to the following rules. And I change the systest for the
correlationid according to this.

userCID -> userCID
userCID + conduitSelectorPrefix -> userCID
userCID + conduitSelectorPrefix + useConduitIdSelector(true) ->
userCID
userCID + conduitSelectorPrefix + useConduitIdSelector(false) ->
userCID
conduitSelectorPrefix + useConduitIdSelector(true) ->
conduitSelectorPrefix + conduitId + index
conduitSelectorPrefix + useConduitIdSelector(false) ->
conduitSelectorPrefix + index

useConduitIdSelector(true) -> conduitId + index
useConduitIdSelector(false) -> the request message's messageID

->'s left side is the condition.
->'s right side is rule for generation of CorrelationID.
userCID means that the client gives a CorrelationID.
conduitSelectorPrefix means that the client configures in the wsdl.
useConduitIdSelector means that the client configures in the wsdl.
conduitId means that the string generated by the jms-tranport's 
JMSConduit.
index is a autoincreasing number which indicates the uniqueness of the
CorrelationID.

(3) The JMSListener of the response message.
(4) Some small changes about JMSMessage's properties which is not right
for specification.
(5) Add test suite
tests(http://dev.w3.org/2008/ws/soapjms/testcases/)(0001-1001). And
build the framework for test suite tests.

About the JMS low API to check the message:
(1) I have use SOAPJMSTestSuiteClientTest and SOAPJMSTestSuiteServerTest
to use JMS low API, and it does work. But it is a little complicated.
(2) I can get all the information for the JMSMessageHeadersType of the
Message. So it is ok for tests.
(3) If I use JMS low API, it is also ok. Use (1) to build all of the tests.

About JMSConduit unit test:
I commented it, because I can't get the response message because the
server's JMS Listener doesn't build. I think the test is not usefull.


best regards

JIRA (https://issues.apache.org/jira/browse/CXF-2253)

Willem Jiang wrote:
> Woo, it's a big patch. You did a amazing job over a night :)
>
> I noticed you commented some JMSConduit unit test. Can you give me a
> list of changes?
> It will help you to double check the back compatibility of the old JMS
> configuration.
>
> I found you didn't use the JMS low API to check the message, can you
> tell me the reason why you don't do that?
>
> Since it's big patch, can you write a brief description to highlight the
> changes that you made ?
>
> Finally, you can submit the patch to CXF JIRA with the description of
> patch and let other people to have a look at this :)
>
> Cheers,
>
> Willem
>
> liucong wrote:
>   
>> Hi
>>
>> I have created a test suite patch for jms-transport.
>> And I have modified some bugs in the code.
>>
>>
>>
>> 
>
>
>   



Re: request-response patterns.

2009-07-26 Thread liucong
Hi,
If the client doesn't configure something about the CorrelationID, I'll
use MessageId pattern.

The current implement use CorrelationId by default. So I think I should
change the rule. I use MessageId pattern by default.


Christian Schneider wrote:
> Hi Liu,
>
> the current code uses the MessageId Patternif the Correlation Id is empty.
> It sends the response to the specified replyTo queue. For CorrelationId
> Pattern it would always use the same queue.
>
> Greetings
>
> Christian
>
> liucong schrieb:
>   
>> Hi,
>>
>> Some information about JMS Correlation ID patten and Message ID pattern
>> on request-response patterns
>> (http://edocs.bea.com/alsb/docs25/interopjms/MsgIDPatternforJMS.html).
>>
>> By digging into the code about jms-transport, I know the current
>> jms-transport uses the Correlation ID Pattern. But the SOAP/JMS
>> specification uses Message ID Pattern.
>>
>> What should I do?
>> 1. To keep Correlation ID Pattern. But it is not compatible with the
>> specification.
>> 2. To use Message ID Pattern. I see some code which use spring-jms, I
>> can't get the id of the message which is sent by spring-jms. I don't
>> know how to get the message id which is used to correlated the response
>> message.
>>
>> Thank you for your sugguest in advance.
>>
>> liu
>>
>>   
>> 
>
>
>   



Re: How to generate the CorrelationID in the client in jms transport?

2009-07-26 Thread liucong
Hi

Willem Jiang wrote:
> Hi,
>
> You can choice what you want to generate the correlationID, and you
> just need to make sure the CorrelationID is unique.
>
> In you proposal, you give the user a choice to set the correlationID
> from the JMSMessageHeader which he set, it's OK for me.
> For the useConduitIdSelector, it's just for the client side to choice if
> it uses the MessageID pattern or CorrelationID pattern.
>
>   
useConduitIdSelector is just one of the three
condition(userCID==null,conduitSelectorPrefix==null,
useConduitIdSelector == false) for using MessageID pattern.
> There is not a clear definition on the server side, such as if server
> side is set to use MessageID pattern , it will ignore the
> CorrelationID which is already set on the request JMS message header to
> generation the response message CorrelationID.
> So I think we need add this server side definition as while.
>
>   

I think the messageId or Correlation ID pattern is determined by the
client. On the server side, if the JMSMessage's CorrelationID is not
null, we use CorrelationID pattern, if not, we use MessageID pattern.
The current implement uses this rule.
> BTW,  we need to add some documents for use about it CorrelationID
> generation rule on the wiki to make sure every body
> knows what is going on there :)
>
> Any other thoughts?
>
> Willem
>
> liucong wrote:
>   
>> Hi,
>>
>> I'm very confused with the CorrelationID which is generated by the
>> jms-transport.
>>
>> The configuration piece as follows:
>> 
>> > name="HelloWorldPortRuntimeCorrelationIDStaticPrefixEng">
>> > useConduitIdSelector="true"/>
>> 
>> > ...
>> 
>> 
>> 
>>
>> I think the rules generating the CorrelationID should be as follows:
>>
>> userCID -> userCID
>> userCID + conduitSelectorPrefix -> userCID
>> userCID + conduitSelectorPrefix + useConduitIdSelector(true) -> userCID
>> userCID + conduitSelectorPrefix + useConduitIdSelector(false) -> userCID
>>
>> conduitSelectorPrefix + useConduitIdSelector(true) ->
>> conduitSelectorPrefix + conduitId + index
>> conduitSelectorPrefix + useConduitIdSelector(false) ->
>> conduitSelectorPrefix + index
>>
>> useConduitIdSelector(true) -> conduitId + index
>> useConduitIdSelector(false) -> the request message's messageID
>>
>> ->'s left side is the condition.
>> ->'s right side is rule for generation of CorrelationID.
>> userCID means that the client gives a CorrelationID.
>> conduitSelectorPrefix means that the client configures in the wsdl.
>> useConduitIdSelector means that the client configures in the wsdl.
>> conduitId means that the string generated by the jms-tranport's JMSConduit.
>> index is a autoincreasing number which indicates the uniqueness of the
>> CorrelationID.
>>
>>
>> Is it right?
>> I want to use this rules for the generation of CorrelationID.
>>
>> best regards
>>
>> 
>
>
>   



Re: test suite patch for JMS transport specification

2009-07-26 Thread liucong
Sorry, I didn't give the detail information in the title.

liucong wrote:
> Hi,
> The list of changes is as follows:
> (1) Some SOAPFault processing int cxf-rt-bindings-soap subproject.
> (2) To generate the CorrelationID in the client of jms transport
> according to the following rules. And I change the systest for the
> correlationid according to this.
>
> userCID -> userCID
> userCID + conduitSelectorPrefix -> userCID
> userCID + conduitSelectorPrefix + useConduitIdSelector(true)
> -> userCID
> userCID + conduitSelectorPrefix + useConduitIdSelector(false)
> -> userCID
> conduitSelectorPrefix + useConduitIdSelector(true) ->
> conduitSelectorPrefix + conduitId + index
> conduitSelectorPrefix + useConduitIdSelector(false) ->
> conduitSelectorPrefix + index
>
> useConduitIdSelector(true) -> conduitId + index
> useConduitIdSelector(false) -> the request message's messageID
>
> ->'s left side is the condition.
> ->'s right side is rule for generation of CorrelationID.
> userCID means that the client gives a CorrelationID.
> conduitSelectorPrefix means that the client configures in the wsdl.
> useConduitIdSelector means that the client configures in the wsdl.
> conduitId means that the string generated by the jms-tranport's 
> JMSConduit.
> index is a autoincreasing number which indicates the uniqueness of the
> CorrelationID.
>
> (3) The JMSListener of the response message.
> (4) Some small changes about JMSMessage's properties which is not
> right for specification.
> (5) Add test suite
> tests(http://dev.w3.org/2008/ws/soapjms/testcases/)(0001-1001). And
> build the framework for test suite tests.
>
> About the JMS low API to check the message:
> (1) I have use SOAPJMSTestSuiteClientTest and
> SOAPJMSTestSuiteServerTest to use JMS low API, and it does work. But
> it is a little complicated.
> (2) I can get all the information for the JMSMessageHeadersType of the
> Message. So it is ok for tests.
> (3) If I use JMS low API, it is also ok. Use (1) to build all of the
> tests.
>
> About JMSConduit unit test:
> I commented it, because I can't get the response message because the
> server's JMS Listener doesn't build. I think the test is not usefull.
>
>
> best regards
>
> JIRA (https://issues.apache.org/jira/browse/CXF-2253)
>
> Willem Jiang wrote:
>> Woo, it's a big patch. You did a amazing job over a night :)
>>
>> I noticed you commented some JMSConduit unit test. Can you give me a
>> list of changes?
>> It will help you to double check the back compatibility of the old JMS
>> configuration.
>>
>> I found you didn't use the JMS low API to check the message, can you
>> tell me the reason why you don't do that?
>>
>> Since it's big patch, can you write a brief description to highlight the
>> changes that you made ?
>>
>> Finally, you can submit the patch to CXF JIRA with the description of
>> patch and let other people to have a look at this :)
>>
>> Cheers,
>>
>> Willem
>>
>> liucong wrote:
>>   
>>> Hi
>>>
>>> I have created a test suite patch for jms-transport.
>>> And I have modified some bugs in the code.
>>>
>>>
>>>
>>> 
>>
>>
>>   
>



Re: SOAP/JMS specification for CXF [Project Status]

2009-08-16 Thread liucong
Hi all,

I have finished the SOAP/JMS implementation for CXF. More details refers to:
Project Information:
1.Project Status: http://wiki.apache.org/general/soapjms4cxf
2.Project Code: http://github.com/liucong/jms4cxf2/tree/master
3.Project JIRA task: https://issues.apache.org/jira/browse/CXF-2253

Any sugguests are welcome!

best regards
liu

liucong wrote:
> Hi all,
>
> Project Description:
> SOAP over JMS specification (http://www.w3.org/TR/soapjms/) is aimed at
> a set of standards for the transport of SOAP messages over JMS (Java
> Message Service). The main purpose is to ensure interoperability between
> the implementations of different Web services vendors.
> CXF does support SOAP over JMS, but it does not meet the current draft
> specification defined at http://www.w3.org/TR/soapjms/ and instead uses
> some proprietary formats, headers, URL formats, etc. This project would
> update the SOAP/JMS support in CXF to be completely specification
> compliant.
> Any advice or help are welcome!
>
> Project Information:
> 1.Project Status: http://wiki.apache.org/general/soapjms4cxf
> 2.Project Code: http://github.com/liucong/jms4cxf2/tree/master
> 3.Project JIRA task: https://issues.apache.org/jira/browse/CXF-2253
>
> What I have done:
> 1.Implement a simple JMS URI
> (http://tools.ietf.org/html/draft-merrick-jms-uri-05 )
> 2.Integrate the JMS URI into current jms-transport. It is compatible
> with the specification.
> 3.Modify the JMS Header Properties and JMS Properties and make it
> compatible with the specification.
> 4.Modify some code about SOAP fault and MEPs.
>
> Liu
>
>
>   



Re: Capturing Jms headers data

2009-09-10 Thread liucong

Hi,


Eamonn Dwyer wrote:
Hi 
I would like to write an interceptor to capture all the JMS header data.  Would the following work?


for an inbound interceptor at the server side 
...

String buffer = new StringBuffer();
JMSMessageHeadersType jmsMessageHeadersType = 
(JMSMessageHeadersType)message.get("org.apache.cxf.jms.server.request.headers");

buffer.append("JMSCorrelationID" + "=" + jmsMessageHeadersType.getJMSCorrelationID()+ 
" ");
buffer.append("JMSMessageID" + "=" + jmsMessageHeadersType.getJMSMessageID()+ " 
");
and so on for all the attributes in JMSMessageHeadersType.

  
It is OK for the inbound interceptor. The JMS transport first get the 
values of JMS header data and store them in the "


org.apache.cxf.jms.server.request.headers". So the interceptor can get these 
data.

For the outbound interceptor at the server side the type would be got from 
JMSMessageHeadersType jmsMessageHeadersType = 



(JMSMessageHeadersType)message.get("org.apache.cxf.jms.server.reply.headers");

  
It is not right for the outbound interceptor. Because when the 
interceptor uses the value of "org.apache.cxf.jms.server.reply.headers" 
before the implementation generates it.

and then on the client side use "org.apache.cxf.jms.client.repsonse.headers" and 
"org.apache.cxf.jms.client.reply.headers"


Thanks for any help/suggestions,

Eamonn

_
Get 30 Free Emoticons for your Windows Live Messenger
http://www.livemessenger-emoticons.com/funfamily/en-ie/
  




Re: Capturing Jms headers data

2009-09-11 Thread liucong

Hi Eamonn,

Eamonn Dwyer wrote:

Hi Liu
thanks for that. So can you tell what I would be able to use to capture the JMS headers 
when the server is replying to the client if I shouldn't use 
"org.apache.cxf.jms.server.reply.headers"?

Actually when is "org.apache.cxf.jms.server.reply.headers" used?

  
Sorry, I think there is not a way to capture the JMS headers when the 
server is replying to the client. The only way is that the client get 
the replying message's headers.


"org.apache.cxf.jms.server.reply.headers" is used in the implementation.


Also is my assumption for the client side : "then on the client side use 
"org.apache.cxf.jms.client.repsonse.headers" and 
"org.apache.cxf.jms.client.reply.headers"" correct?

  
In the client,   "org.apache.cxf.jms.client.request.headers" and 
"org.apache.cxf.jms.client.repsonse.headers" are used.
After the client has sent the JMS message, you can check the 
"org.apache.cxf.jms.client.request.headers" to get the JMS headers.
You can use an interceptor to check the 
"org.apache.cxf.jms.client.repsonse.headers" to get the reply JMS 
message headers.
Thanks for the help 
Eamonn


  

Date: Fri, 11 Sep 2009 09:13:32 +0800
From: liucon...@gmail.com
To: dev@cxf.apache.org
Subject: Re: Capturing Jms headers data

Hi,


Eamonn Dwyer wrote:

Hi 
I would like to write an interceptor to capture all the JMS header data.  Would the following work?


for an inbound interceptor at the server side 
...

String buffer = new StringBuffer();
JMSMessageHeadersType jmsMessageHeadersType = 
(JMSMessageHeadersType)message.get("org.apache.cxf.jms.server.request.headers");

buffer.append("JMSCorrelationID" + "=" + jmsMessageHeadersType.getJMSCorrelationID()+ 
" ");
buffer.append("JMSMessageID" + "=" + jmsMessageHeadersType.getJMSMessageID()+ " 
");
and so on for all the attributes in JMSMessageHeadersType.

  
  
It is OK for the inbound interceptor. The JMS transport first get the 
values of JMS header data and store them in the "


org.apache.cxf.jms.server.request.headers". So the interceptor can get these 
data.


For the outbound interceptor at the server side the type would be got from 
JMSMessageHeadersType jmsMessageHeadersType = 



(JMSMessageHeadersType)message.get("org.apache.cxf.jms.server.reply.headers");

  
  
It is not right for the outbound interceptor. Because when the 
interceptor uses the value of "org.apache.cxf.jms.server.reply.headers" 
before the implementation generates it.


and then on the client side use "org.apache.cxf.jms.client.repsonse.headers" and 
"org.apache.cxf.jms.client.reply.headers"


Thanks for any help/suggestions,

Eamonn

_
Get 30 Free Emoticons for your Windows Live Messenger
http://www.livemessenger-emoticons.com/funfamily/en-ie/
  
  


_
With Windows Live, you can organize, edit, and share your photos.
http://www.microsoft.com/ireland/windows/windowslive/products/photo-gallery-edit.aspx
  




Re: GSoC Proposal:Implement the SOAP/JMS specification for CXF

2009-03-31 Thread liucong
Hi,

I have started to consider other ideas.

The project I attented is not public, so I can't give some links for it.
Though I have read some code about axis2, axis, mule, r-osgi, cxf-dosgi,
but I have not contributed some ideas to this project. I want to attend
the GSoC, and get me involved into open source.

GSoC will be a good start!


Liu


Willem Jiang 写道:
> Hi,
>
> Since there are more than 2 student choiced CXF-SOAP-JMS, do you
> consider to choice other ideas of CXF project ?
>
> Can you give us some reference of your projects or some link can show
> your coding ability?
>
>
> Willem
>
>
> jason wrote:
>   
>> Hi all,
>>
>> I want to take part in the GSoC. Aftter looking into the suggestions by 
>> Daniel Kulp, I have modified my proposal and published this proposal on GSoC.
>> I have published my proposal about cxf-soapjms on 
>> http://wiki.apache.org/general/soc2009-soapjms-proposal. The GSoC page is 
>> here:
>>
>> http://socghop.appspot.com/document/show/user/liucong/cxf_soapjms
>>
>>  
>> Any comments and suggestions are welcome.
>> Thanks in advance for your feedback.
>>
>>
>> Thank You,
>> Liu Cong
>>
>>
>>
>> 
>
>
>   



GSoC Proposal:Implement JiBX databinding for CXF

2009-04-01 Thread liucong
Hi all,

This is another proposal for cxf-jibx.
I have published my proposal about cxf-jibx on 
http://wiki.apache.org/general/soc2009-cxf-jibx-proposal. The GSoC page is 
here:http://socghop.appspot.com/document/show/user/liucong/cxf_jibx_databinding


Any comments and suggestions are welcome.
Thanks in advance for your feedback.


Thank You,
Liu Cong



Re: I'm working on SOAP/JMS, a question about current implementation

2009-04-20 Thread liucong

Hi Christian,

I want to know whether the current implementation fills the JMS message 
properties other than JMS headers. In new implementation, we should add 
this properties.


Best regards.
Liu

Christian Schneider 写道:

Hi 刘聪,

sorry that you got no response till now. I did not really understand 
your question. The current implementation already fills some JMS 
headers and properties. Of course they do not always match the 
specification you try to implement. What exactly was your question? Do 
you want to know where to add the new jms properties?


Greetings

Christian


Hi, all

 SOAP/JMS specification specifies the JMS header properties and message
properties, but the current implementation in CXF only has some 
information
about JMS header perperties. The more information should been added 
to JMS

messages.
 Am I missing something about JMS message properties for the current
implementation about SOAP/JMS?

Best regards