cxf-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From liucong <liucon...@gmail.com>
Subject Re: Capturing Jms headers data
Date Fri, 11 Sep 2009 08:55:20 GMT
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: liucong07@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
>   


Mime
View raw message