You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@servicemix.apache.org by Klaus Alfert <ka...@zuehlke.com> on 2006/08/21 18:42:21 UTC

Exceptions in servicemix-jms with WebSphereMQ

Hi Folks, 

I have a problem connecting service mix via the servicemix-jms component to
a WebSphereMQ Queue. 

My provider configuration is as follows:
<!-- Reads a message from the NMR and writes them to XNEAIDV3.SMIX.TEST.2
-->
		<jms:endpoint service="dz:MyProviderService" 
		endpoint="myProvider"
		role="provider" 
		destinationStyle="queue"
		jmsProviderDestinationName="XNEAIDV3.SMIX.TEST.2"
		connectionFactory="#jmsFactory"
		/>

The message sent is as follows:
<?xml version="1.0" encoding="UTF-8"?>
<sample id="0">
  here is some testdata
</sample>


I get the following exception:
javax.jms.MessageFormatException: MQJMS1058: Invalid message property name:
Content-Type
        at
com.ibm.jms.JMSMessage.newMessageFormatException(JMSMessage.java:4674)
        at com.ibm.jms.JMSMessage.setStringProperty(JMSMessage.java:5658)
        at
org.apache.servicemix.jms.multiplexing.MultiplexingProviderProcessor.process(MultiplexingProviderProcessor.java:182)
        at
org.apache.servicemix.common.AsyncBaseLifeCycle.processExchange(AsyncBaseLifeCycle.java:398)
        at
org.apache.servicemix.common.BaseLifeCycle.onMessageExchange(BaseLifeCycle.java:43)
        at
org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.processInBound(DeliveryChannelImpl.java:623)
        at
org.apache.servicemix.jbi.nmr.flow.AbstractFlow.doRouting(AbstractFlow.java:169)
        at
org.apache.servicemix.jbi.nmr.flow.seda.SedaFlow.doRouting(SedaFlow.java:177)
        at
org.apache.servicemix.jbi.nmr.flow.seda.SedaQueue$1.run(SedaQueue.java:227)
        at
org.apache.geronimo.connector.work.WorkerContext.run(WorkerContext.java:291)
        at
EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(Unknown Source)
        at java.lang.Thread.run(Thread.java:595)

As far as I understand the code, in line 182 of
MultiplexingProviderProcessor the property "Content-Type" is set to the
value defined in the normalized message (according to
http://issues.apache.org/activemq/browse/SM-502). But "Content-Type" is not
a proper name for a JMS property (at least according to SM-398 and SM-403, I
did not check the JMS spec myself) and WebSphereMQ chokes immediately.

The discussion of SM-502 indicates that the Content-Type property is
required for SOAP and SAAJ. However, my configuration does not use SOAP at
all (which shall be the default case according to the docs). I am also not
sure whether it is needed to set the content type property to the JMS
message. I would expect the content-type as a part of the message payload
itself but I am by no means an expert of the SOAP/JMS on the wire format. 

A final remark: In contrast to the marshaler in the older lightweight jms
component, there is no checking of valid header names in the loop
immediately before line 182. This looks like an additionally potential error
source. 

A simple workaround is to catch and silently ignore exceptions when setting
the message properties. 

Cheers,
Klaus.

-- 
View this message in context: http://www.nabble.com/Exceptions-in-servicemix-jms-with-WebSphereMQ-tf2141329.html#a5910358
Sent from the ServiceMix - Dev forum at Nabble.com.


Re: Exceptions in servicemix-jms with WebSphereMQ

Posted by Klaus Alfert <ka...@zuehlke.com>.
Great. 

I'll give it a try. 

Klaus.



gnodet wrote:
> 
> I have just fixed that.
> You can now add the needJavaIdentifiers="true" attribute so that all
> non valid properties will be skipped.
> Note that the Content-Type property has been renamed to MimeContentType
> so that mime streams can still be sent.
> 
> On 8/21/06, Klaus Alfert <ka...@zuehlke.com> wrote:
>>
>> Hi Folks,
>>
>> I have a problem connecting service mix via the servicemix-jms component
>> to
>> a WebSphereMQ Queue.
>>
>> My provider configuration is as follows:
>> <!-- Reads a message from the NMR and writes them to XNEAIDV3.SMIX.TEST.2
>> -->
>>                 <jms:endpoint service="dz:MyProviderService"
>>                 endpoint="myProvider"
>>                 role="provider"
>>                 destinationStyle="queue"
>>                 jmsProviderDestinationName="XNEAIDV3.SMIX.TEST.2"
>>                 connectionFactory="#jmsFactory"
>>                 />
>>
>> The message sent is as follows:
>> <?xml version="1.0" encoding="UTF-8"?>
>> <sample id="0">
>>   here is some testdata
>> </sample>
>>
>>
>> I get the following exception:
>> javax.jms.MessageFormatException: MQJMS1058: Invalid message property
>> name:
>> Content-Type
>>         at
>> com.ibm.jms.JMSMessage.newMessageFormatException(JMSMessage.java:4674)
>>         at com.ibm.jms.JMSMessage.setStringProperty(JMSMessage.java:5658)
>>         at
>> org.apache.servicemix.jms.multiplexing.MultiplexingProviderProcessor.process(MultiplexingProviderProcessor.java:182)
>>         at
>> org.apache.servicemix.common.AsyncBaseLifeCycle.processExchange(AsyncBaseLifeCycle.java:398)
>>         at
>> org.apache.servicemix.common.BaseLifeCycle.onMessageExchange(BaseLifeCycle.java:43)
>>         at
>> org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.processInBound(DeliveryChannelImpl.java:623)
>>         at
>> org.apache.servicemix.jbi.nmr.flow.AbstractFlow.doRouting(AbstractFlow.java:169)
>>         at
>> org.apache.servicemix.jbi.nmr.flow.seda.SedaFlow.doRouting(SedaFlow.java:177)
>>         at
>> org.apache.servicemix.jbi.nmr.flow.seda.SedaQueue$1.run(SedaQueue.java:227)
>>         at
>> org.apache.geronimo.connector.work.WorkerContext.run(WorkerContext.java:291)
>>         at
>> EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(Unknown
>> Source)
>>         at java.lang.Thread.run(Thread.java:595)
>>
>> As far as I understand the code, in line 182 of
>> MultiplexingProviderProcessor the property "Content-Type" is set to the
>> value defined in the normalized message (according to
>> http://issues.apache.org/activemq/browse/SM-502). But "Content-Type" is
>> not
>> a proper name for a JMS property (at least according to SM-398 and
>> SM-403, I
>> did not check the JMS spec myself) and WebSphereMQ chokes immediately.
>>
>> The discussion of SM-502 indicates that the Content-Type property is
>> required for SOAP and SAAJ. However, my configuration does not use SOAP
>> at
>> all (which shall be the default case according to the docs). I am also
>> not
>> sure whether it is needed to set the content type property to the JMS
>> message. I would expect the content-type as a part of the message payload
>> itself but I am by no means an expert of the SOAP/JMS on the wire format.
>>
>> A final remark: In contrast to the marshaler in the older lightweight jms
>> component, there is no checking of valid header names in the loop
>> immediately before line 182. This looks like an additionally potential
>> error
>> source.
>>
>> A simple workaround is to catch and silently ignore exceptions when
>> setting
>> the message properties.
>>
>> Cheers,
>> Klaus.
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Exceptions-in-servicemix-jms-with-WebSphereMQ-tf2141329.html#a5910358
>> Sent from the ServiceMix - Dev forum at Nabble.com.
>>
>>
> 
> 
> -- 
> Cheers,
> Guillaume Nodet
> 
> 

-- 
View this message in context: http://www.nabble.com/Exceptions-in-servicemix-jms-with-WebSphereMQ-tf2141329.html#a5926206
Sent from the ServiceMix - Dev forum at Nabble.com.


Re: Exceptions in servicemix-jms with WebSphereMQ

Posted by Klaus Alfert <ka...@zuehlke.com>.
Wow, that was fast. I'll give it a try.

Klaus.

gnodet wrote:
> 
> Oops, sorry.
> This should be fixed now.
> 
> On 8/23/06, Klaus Alfert <ka...@zuehlke.com> wrote:
>>
>>
>> Guillaume,
>>
>> the saga continues...
>>
>> After changing to the standard processor WebSphere MQ works, but only for
>> one message. Our next testcase sends a bunch of messages, but never
>> sucessfully. So I recuded the set of messages to only two messages. But
>> receiving the second message from NMR which shall be enqueued to the same
>> Queue, results in Exceptions. These exceptions vary from case to case,
>> including the hint that the Session is already closed.
>>
>> I suspect that this is a threading issue: The session variable within
>> StandardProviderProcessor is member which is initialized during process
>> and
>> is afterwards set to null. So, if a single instance of
>> StandardProviderProcessor is used in several threads concurrently, this
>> would result in nasty race conditions. This would also explain why it is
>> possible to transport say 5 of 20 messages but not 2 of 2 successfully.
>> Our
>> examples run on a two processor Solaris machine.
>>
>> Klaus.
>>
>>
>> Ah, good point. Our simplest example is now running. So let's move on to
>> next tests.
>>
>> Thanx for your help.
>>
>> Klaus.
>>
>>
>>
>> gnodet wrote:
>> >
>> > You may want to try with the processorName="standard" attribute on the
>> > JMS endpoint.  The default processor uses multiplexing, which is not
>> > available on all jms providers.
>> >
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Exceptions-in-servicemix-jms-with-WebSphereMQ-tf2141329.html#a5943288
>> Sent from the ServiceMix - Dev forum at Nabble.com.
>>
>>
> 
> 
> -- 
> Cheers,
> Guillaume Nodet
> 
> 

-- 
View this message in context: http://www.nabble.com/Exceptions-in-servicemix-jms-with-WebSphereMQ-tf2141329.html#a5943628
Sent from the ServiceMix - Dev forum at Nabble.com.


Re: Exceptions in servicemix-jms with WebSphereMQ

Posted by Klaus Alfert <ka...@zuehlke.com>.
Looks good, first test results are very promising. 

Thanx a lot for your quick help!

Klaus.


gnodet wrote:
> 
> Oops, sorry.
> This should be fixed now.
> 
> On 8/23/06, Klaus Alfert <ka...@zuehlke.com> wrote:
>>
>>
>> Guillaume,
>>
>> the saga continues...
>>
>> After changing to the standard processor WebSphere MQ works, but only for
>> one message. Our next testcase sends a bunch of messages, but never
>> sucessfully. So I recuded the set of messages to only two messages. But
>> receiving the second message from NMR which shall be enqueued to the same
>> Queue, results in Exceptions. These exceptions vary from case to case,
>> including the hint that the Session is already closed.
>>
>> I suspect that this is a threading issue: The session variable within
>> StandardProviderProcessor is member which is initialized during process
>> and
>> is afterwards set to null. So, if a single instance of
>> StandardProviderProcessor is used in several threads concurrently, this
>> would result in nasty race conditions. This would also explain why it is
>> possible to transport say 5 of 20 messages but not 2 of 2 successfully.
>> Our
>> examples run on a two processor Solaris machine.
>>
>> Klaus.
>>
>>
>> Ah, good point. Our simplest example is now running. So let's move on to
>> next tests.
>>
>> Thanx for your help.
>>
>> Klaus.
>>
>>
>>
>> gnodet wrote:
>> >
>> > You may want to try with the processorName="standard" attribute on the
>> > JMS endpoint.  The default processor uses multiplexing, which is not
>> > available on all jms providers.
>> >
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Exceptions-in-servicemix-jms-with-WebSphereMQ-tf2141329.html#a5943288
>> Sent from the ServiceMix - Dev forum at Nabble.com.
>>
>>
> 
> 
> -- 
> Cheers,
> Guillaume Nodet
> 
> 

-- 
View this message in context: http://www.nabble.com/Exceptions-in-servicemix-jms-with-WebSphereMQ-tf2141329.html#a5944078
Sent from the ServiceMix - Dev forum at Nabble.com.


Re: Exceptions in servicemix-jms with WebSphereMQ

Posted by Guillaume Nodet <gn...@gmail.com>.
Oops, sorry.
This should be fixed now.

On 8/23/06, Klaus Alfert <ka...@zuehlke.com> wrote:
>
>
> Guillaume,
>
> the saga continues...
>
> After changing to the standard processor WebSphere MQ works, but only for
> one message. Our next testcase sends a bunch of messages, but never
> sucessfully. So I recuded the set of messages to only two messages. But
> receiving the second message from NMR which shall be enqueued to the same
> Queue, results in Exceptions. These exceptions vary from case to case,
> including the hint that the Session is already closed.
>
> I suspect that this is a threading issue: The session variable within
> StandardProviderProcessor is member which is initialized during process
> and
> is afterwards set to null. So, if a single instance of
> StandardProviderProcessor is used in several threads concurrently, this
> would result in nasty race conditions. This would also explain why it is
> possible to transport say 5 of 20 messages but not 2 of 2 successfully.
> Our
> examples run on a two processor Solaris machine.
>
> Klaus.
>
>
> Ah, good point. Our simplest example is now running. So let's move on to
> next tests.
>
> Thanx for your help.
>
> Klaus.
>
>
>
> gnodet wrote:
> >
> > You may want to try with the processorName="standard" attribute on the
> > JMS endpoint.  The default processor uses multiplexing, which is not
> > available on all jms providers.
> >
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/Exceptions-in-servicemix-jms-with-WebSphereMQ-tf2141329.html#a5943288
> Sent from the ServiceMix - Dev forum at Nabble.com.
>
>


-- 
Cheers,
Guillaume Nodet

Re: Exceptions in servicemix-jms with WebSphereMQ

Posted by Klaus Alfert <ka...@zuehlke.com>.
Guillaume,

the saga continues...

After changing to the standard processor WebSphere MQ works, but only for
one message. Our next testcase sends a bunch of messages, but never
sucessfully. So I recuded the set of messages to only two messages. But
receiving the second message from NMR which shall be enqueued to the same
Queue, results in Exceptions. These exceptions vary from case to case,
including the hint that the Session is already closed. 

I suspect that this is a threading issue: The session variable within
StandardProviderProcessor is member which is initialized during process and
is afterwards set to null. So, if a single instance of
StandardProviderProcessor is used in several threads concurrently, this
would result in nasty race conditions. This would also explain why it is
possible to transport say 5 of 20 messages but not 2 of 2 successfully. Our
examples run on a two processor Solaris machine. 

Klaus.


Ah, good point. Our simplest example is now running. So let's move on to
next tests. 

Thanx for your help.

Klaus.



gnodet wrote:
> 
> You may want to try with the processorName="standard" attribute on the
> JMS endpoint.  The default processor uses multiplexing, which is not
> available on all jms providers.
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Exceptions-in-servicemix-jms-with-WebSphereMQ-tf2141329.html#a5943288
Sent from the ServiceMix - Dev forum at Nabble.com.


Re: Exceptions in servicemix-jms with WebSphereMQ

Posted by Klaus Alfert <ka...@zuehlke.com>.
Ah, good point. Our simplest example is now running. So let's move on to next
tests. 

Thanx for your help.

Klaus.



gnodet wrote:
> 
> You may want to try with the processorName="standard" attribute on the
> JMS endpoint.  The default processor uses multiplexing, which is not
> available on all jms providers.
> 
> On 8/22/06, Klaus Alfert <ka...@zuehlke.com> wrote:
>>
>>
>> Thanx for you quick answer, it helped a lot.
>> But I am still tumbling from exception to exception. Now,  MQ chokes on
>> the
>> send-call  :-(
>>
>>     [junit] 26441 [Thread-0] INFO  smix.console  -
>> javax.jms.JMSException:
>> MQJMS1013: operation invalid whilst session is using asynchronous
>> delivery
>>     [junit] 26441 [Thread-0] INFO  smix.console  -      at
>> com.ibm.mq.jms.services.ConfigEnvironment.newException(
>> ConfigEnvironment.java:567)
>>     [junit] 26441 [Thread-0] INFO  smix.console  -      at
>> com.ibm.mq.jms.MQMessageProducer.send(MQMessageProducer.java:1051)
>>     [junit] 26441 [Thread-0] INFO  smix.console  -      at
>> com.ibm.mq.jms.MQMessageProducer.send(MQMessageProducer.java:1108)
>>     [junit] 26441 [Thread-0] INFO  smix.console  -      at
>>
>> org.apache.servicemix.jms.multiplexing.MultiplexingProviderProcessor.process
>> (MultiplexingProviderProcessor.java:164)
>>     [junit] 26442 [Thread-0] INFO  smix.console  -      at
>> org.apache.servicemix.common.AsyncBaseLifeCycle.processExchange(
>> AsyncBaseLifeCycle.java:399)
>>     [junit] 26442 [Thread-0] INFO  smix.console  -      at
>> org.apache.servicemix.common.BaseLifeCycle.onMessageExchange(
>> BaseLifeCycle.java:43)
>>     [junit] 26442 [Thread-0] INFO  smix.console  -      at
>> org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.processInBound(
>> DeliveryChannelImpl.java:623)
>>     [junit] 26442 [Thread-0] INFO  smix.console  -      at
>> org.apache.servicemix.jbi.nmr.flow.AbstractFlow.doRouting(
>> AbstractFlow.java:169)
>>     [junit] 26442 [Thread-0] INFO  smix.console  -      at
>> org.apache.servicemix.jbi.nmr.flow.seda.SedaFlow.doRouting(SedaFlow.java
>> :177)
>>     [junit] 26442 [Thread-0] INFO  smix.console  -      at
>> org.apache.servicemix.jbi.nmr.flow.seda.SedaQueue$1.run(SedaQueue.java
>> :227)
>>     [junit] 26442 [Thread-0] INFO  smix.console  -      at
>> org.apache.geronimo.connector.work.WorkerContext.run(WorkerContext.java
>> :291)
>>     [junit] 26442 [Thread-0] INFO  smix.console  -      at
>> EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(Unknown
>> Source)
>>     [junit] 26442 [Thread-0] INFO  smix.console  -      at
>> java.lang.Thread.run(Thread.java:595)
>>     [j
>>
>> I'll take a look on it tomorrow.
>>
>> Klaus.
>>
>>
>> gnodet wrote:
>> >
>> > I' m trying to fix this problem.
>> > If will disable geronimo module until the plugin works again.
>> > [..]
>> >
>> > --
>> > Cheers,
>> > Guillaume Nodet
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Exceptions-in-servicemix-jms-with-WebSphereMQ-tf2141329.html#a5928806
>> Sent from the ServiceMix - Dev forum at Nabble.com.
>>
>>
> 
> 
> -- 
> Cheers,
> Guillaume Nodet
> 
> 

-- 
View this message in context: http://www.nabble.com/Exceptions-in-servicemix-jms-with-WebSphereMQ-tf2141329.html#a5939451
Sent from the ServiceMix - Dev forum at Nabble.com.


Re: Exceptions in servicemix-jms with WebSphereMQ

Posted by Guillaume Nodet <gn...@gmail.com>.
You may want to try with the processorName="standard" attribute on the
JMS endpoint.  The default processor uses multiplexing, which is not
available on all jms providers.

On 8/22/06, Klaus Alfert <ka...@zuehlke.com> wrote:
>
>
> Thanx for you quick answer, it helped a lot.
> But I am still tumbling from exception to exception. Now,  MQ chokes on
> the
> send-call  :-(
>
>     [junit] 26441 [Thread-0] INFO  smix.console  - javax.jms.JMSException:
> MQJMS1013: operation invalid whilst session is using asynchronous delivery
>     [junit] 26441 [Thread-0] INFO  smix.console  -      at
> com.ibm.mq.jms.services.ConfigEnvironment.newException(
> ConfigEnvironment.java:567)
>     [junit] 26441 [Thread-0] INFO  smix.console  -      at
> com.ibm.mq.jms.MQMessageProducer.send(MQMessageProducer.java:1051)
>     [junit] 26441 [Thread-0] INFO  smix.console  -      at
> com.ibm.mq.jms.MQMessageProducer.send(MQMessageProducer.java:1108)
>     [junit] 26441 [Thread-0] INFO  smix.console  -      at
>
> org.apache.servicemix.jms.multiplexing.MultiplexingProviderProcessor.process
> (MultiplexingProviderProcessor.java:164)
>     [junit] 26442 [Thread-0] INFO  smix.console  -      at
> org.apache.servicemix.common.AsyncBaseLifeCycle.processExchange(
> AsyncBaseLifeCycle.java:399)
>     [junit] 26442 [Thread-0] INFO  smix.console  -      at
> org.apache.servicemix.common.BaseLifeCycle.onMessageExchange(
> BaseLifeCycle.java:43)
>     [junit] 26442 [Thread-0] INFO  smix.console  -      at
> org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.processInBound(
> DeliveryChannelImpl.java:623)
>     [junit] 26442 [Thread-0] INFO  smix.console  -      at
> org.apache.servicemix.jbi.nmr.flow.AbstractFlow.doRouting(
> AbstractFlow.java:169)
>     [junit] 26442 [Thread-0] INFO  smix.console  -      at
> org.apache.servicemix.jbi.nmr.flow.seda.SedaFlow.doRouting(SedaFlow.java
> :177)
>     [junit] 26442 [Thread-0] INFO  smix.console  -      at
> org.apache.servicemix.jbi.nmr.flow.seda.SedaQueue$1.run(SedaQueue.java
> :227)
>     [junit] 26442 [Thread-0] INFO  smix.console  -      at
> org.apache.geronimo.connector.work.WorkerContext.run(WorkerContext.java
> :291)
>     [junit] 26442 [Thread-0] INFO  smix.console  -      at
> EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(Unknown Source)
>     [junit] 26442 [Thread-0] INFO  smix.console  -      at
> java.lang.Thread.run(Thread.java:595)
>     [j
>
> I'll take a look on it tomorrow.
>
> Klaus.
>
>
> gnodet wrote:
> >
> > I' m trying to fix this problem.
> > If will disable geronimo module until the plugin works again.
> > [..]
> >
> > --
> > Cheers,
> > Guillaume Nodet
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/Exceptions-in-servicemix-jms-with-WebSphereMQ-tf2141329.html#a5928806
> Sent from the ServiceMix - Dev forum at Nabble.com.
>
>


-- 
Cheers,
Guillaume Nodet

Re: Exceptions in servicemix-jms with WebSphereMQ

Posted by Klaus Alfert <ka...@zuehlke.com>.
Thanx for you quick answer, it helped a lot. 
But I am still tumbling from exception to exception. Now,  MQ chokes on the
send-call  :-(

    [junit] 26441 [Thread-0] INFO  smix.console  - javax.jms.JMSException:
MQJMS1013: operation invalid whilst session is using asynchronous delivery
    [junit] 26441 [Thread-0] INFO  smix.console  -      at
com.ibm.mq.jms.services.ConfigEnvironment.newException(ConfigEnvironment.java:567)
    [junit] 26441 [Thread-0] INFO  smix.console  -      at
com.ibm.mq.jms.MQMessageProducer.send(MQMessageProducer.java:1051)
    [junit] 26441 [Thread-0] INFO  smix.console  -      at
com.ibm.mq.jms.MQMessageProducer.send(MQMessageProducer.java:1108)
    [junit] 26441 [Thread-0] INFO  smix.console  -      at
org.apache.servicemix.jms.multiplexing.MultiplexingProviderProcessor.process(MultiplexingProviderProcessor.java:164)
    [junit] 26442 [Thread-0] INFO  smix.console  -      at
org.apache.servicemix.common.AsyncBaseLifeCycle.processExchange(AsyncBaseLifeCycle.java:399)
    [junit] 26442 [Thread-0] INFO  smix.console  -      at
org.apache.servicemix.common.BaseLifeCycle.onMessageExchange(BaseLifeCycle.java:43)
    [junit] 26442 [Thread-0] INFO  smix.console  -      at
org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.processInBound(DeliveryChannelImpl.java:623)
    [junit] 26442 [Thread-0] INFO  smix.console  -      at
org.apache.servicemix.jbi.nmr.flow.AbstractFlow.doRouting(AbstractFlow.java:169)
    [junit] 26442 [Thread-0] INFO  smix.console  -      at
org.apache.servicemix.jbi.nmr.flow.seda.SedaFlow.doRouting(SedaFlow.java:177)
    [junit] 26442 [Thread-0] INFO  smix.console  -      at
org.apache.servicemix.jbi.nmr.flow.seda.SedaQueue$1.run(SedaQueue.java:227)
    [junit] 26442 [Thread-0] INFO  smix.console  -      at
org.apache.geronimo.connector.work.WorkerContext.run(WorkerContext.java:291)
    [junit] 26442 [Thread-0] INFO  smix.console  -      at
EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(Unknown Source)
    [junit] 26442 [Thread-0] INFO  smix.console  -      at
java.lang.Thread.run(Thread.java:595)
    [j

I'll take a look on it tomorrow. 

Klaus.


gnodet wrote:
> 
> I' m trying to fix this problem.
> If will disable geronimo module until the plugin works again.
> [..]
> 
> -- 
> Cheers,
> Guillaume Nodet
> 
> 

-- 
View this message in context: http://www.nabble.com/Exceptions-in-servicemix-jms-with-WebSphereMQ-tf2141329.html#a5928806
Sent from the ServiceMix - Dev forum at Nabble.com.


Re: Exceptions in servicemix-jms with WebSphereMQ

Posted by Guillaume Nodet <gn...@gmail.com>.
I' m trying to fix this problem.
If will disable geronimo module until the plugin works again.

On 8/22/06, Klaus Alfert <ka...@zuehlke.com> wrote:
>
>
> Sorry to bother you again, but I still get build errors. Do you have any
> advice what to do?
> Is there perhaps a profile to exclude the geronimo stuff - I am currently
> not interested into that.
>
> Klaus.
>
> [INFO]
>
> ----------------------------------------------------------------------------
> [INFO] Building ServiceMix :: Geronimo :: ServiceMix plugin
> [INFO]    task-segment: [install]
> [INFO]
>
> ----------------------------------------------------------------------------
> [INFO] [resources:resources]
> [INFO] Using default encoding to copy filtered resources.
> [INFO] [car:prepare-plan]
> [INFO] Generated:
>
> /home/alfert/src/service-mix/svn-trunk/trunk/geronimo/servicemix/target/plan/plan.xml
> [INFO] [car:package]
> [INFO] Packaging module configuration:
>
> /home/alfert/src/service-mix/svn-trunk/trunk/geronimo/servicemix/target/plan/plan.xml
> [INFO]
> ------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO]
> ------------------------------------------------------------------------
> [INFO] Invalid deployment descriptor:
>
> [/home/alfert/src/service-mix/svn-trunk/trunk/geronimo/servicemix/target/plan/plan.xml:18:
> error: cvc-complex-type.2.4a: Expected element
> 'environment@http://geronimo.apache.org/xml/ns/deployment-1.1' instead of
> 'environment@http://geronimo.apache.org/xml/ns/deployment-1.2' here in
> element module@http://geronimo.apache.org/xml/ns/deployment-1.1,
>
> /home/alfert/src/service-mix/svn-trunk/trunk/geronimo/servicemix/target/plan/plan.xml:184:
> error: cvc-complex-type.2.4a: Expected element
> 'environment@http://geronimo.apache.org/xml/ns/deployment-1.1' instead of
> 'gbean@http://geronimo.apache.org/xml/ns/deployment-1.1' here in element
> module@http://geronimo.apache.org/xml/ns/deployment-1.1,
>
> /home/alfert/src/service-mix/svn-trunk/trunk/geronimo/servicemix/target/plan/plan.xml:189:
> error: cvc-complex-type.2.4a: Expected element
> 'environment@http://geronimo.apache.org/xml/ns/deployment-1.1' instead of
> 'gbean@http://geronimo.apache.org/xml/ns/deployment-1.1' here in element
> module@http://geronimo.apache.org/xml/ns/deployment-1.1,
>
> /home/alfert/src/service-mix/svn-trunk/trunk/geronimo/servicemix/target/plan/plan.xml:203:
> error: cvc-complex-type.2.4a: Expected element
> 'environment@http://geronimo.apache.org/xml/ns/deployment-1.1' instead of
> 'gbean@http://geronimo.apache.org/xml/ns/deployment-1.1' here in element
> module@http://geronimo.apache.org/xml/ns/deployment-1.1,
>
> /home/alfert/src/service-mix/svn-trunk/trunk/geronimo/servicemix/target/plan/plan.xml:210:
> error: cvc-complex-type.2.4c: Expected element
> 'environment@http://geronimo.apache.org/xml/ns/deployment-1.1' before the
> end of the content in element
> module@http://geronimo.apache.org/xml/ns/deployment-1.1]
>
>
>
> gnodet wrote:
> >
> > Oops, sorry.
> > This is fixed.
> >
> > On 8/22/06, Klaus Alfert <ka...@zuehlke.com> wrote:
> >>
> >> Hi Guillaume,
> >>
> >> after an svn update (to revision 433641),  I got a compile error. Is
> >> there
> >> some checking pending?
> >>
> >> Compiling 24 source files to
> >>
> /home/alfert/src/service-mix/svn-trunk/trunk/servicemix-jms/target/classes
> >> [INFO]
> >>
> ------------------------------------------------------------------------
> >> [ERROR] BUILD FAILURE
> >> [INFO]
> >>
> ------------------------------------------------------------------------
> >> [INFO] Compilation failure
> >>
> >>
> /home/alfert/src/service-mix/svn-trunk/trunk/servicemix-jms/src/main/java/org/apache/servicemix/jms/AbstractJmsProcessor.java:[174,25]
> >> createContext(org.apache.servicemix.soap.marshalers.SoapMessage) in
> >> org.apache.servicemix.soap.SoapHelper cannot be applied to ()
> >>
> >>
> >> Klaus.
> >>
> >>
> >> gnodet wrote:
> >> >
> >> > I have just fixed that.
> >> > You can now add the needJavaIdentifiers="true" attribute so that all
> >> > non valid properties will be skipped.
> >> > Note that the Content-Type property has been renamed to
> MimeContentType
> >> > so that mime streams can still be sent.
> >> > [..]
> >> > --
> >> > Cheers,
> >> > Guillaume Nodet
> >> >
> >> >
> >>
> >> --
> >> View this message in context:
> >>
> http://www.nabble.com/Exceptions-in-servicemix-jms-with-WebSphereMQ-tf2141329.html#a5926623
> >> Sent from the ServiceMix - Dev forum at Nabble.com.
> >>
> >>
> >
> >
> > --
> > Cheers,
> > Guillaume Nodet
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/Exceptions-in-servicemix-jms-with-WebSphereMQ-tf2141329.html#a5927221
> Sent from the ServiceMix - Dev forum at Nabble.com.
>
>


-- 
Cheers,
Guillaume Nodet

Re: Exceptions in servicemix-jms with WebSphereMQ

Posted by Klaus Alfert <ka...@zuehlke.com>.
Sorry to bother you again, but I still get build errors. Do you have any
advice what to do?
Is there perhaps a profile to exclude the geronimo stuff - I am currently
not interested into that. 

Klaus.

[INFO]
----------------------------------------------------------------------------
[INFO] Building ServiceMix :: Geronimo :: ServiceMix plugin
[INFO]    task-segment: [install]
[INFO]
----------------------------------------------------------------------------
[INFO] [resources:resources]
[INFO] Using default encoding to copy filtered resources.
[INFO] [car:prepare-plan]
[INFO] Generated:
/home/alfert/src/service-mix/svn-trunk/trunk/geronimo/servicemix/target/plan/plan.xml
[INFO] [car:package]
[INFO] Packaging module configuration:
/home/alfert/src/service-mix/svn-trunk/trunk/geronimo/servicemix/target/plan/plan.xml
[INFO]
------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO]
------------------------------------------------------------------------
[INFO] Invalid deployment descriptor:
[/home/alfert/src/service-mix/svn-trunk/trunk/geronimo/servicemix/target/plan/plan.xml:18:
error: cvc-complex-type.2.4a: Expected element
'environment@http://geronimo.apache.org/xml/ns/deployment-1.1' instead of
'environment@http://geronimo.apache.org/xml/ns/deployment-1.2' here in
element module@http://geronimo.apache.org/xml/ns/deployment-1.1,
/home/alfert/src/service-mix/svn-trunk/trunk/geronimo/servicemix/target/plan/plan.xml:184:
error: cvc-complex-type.2.4a: Expected element
'environment@http://geronimo.apache.org/xml/ns/deployment-1.1' instead of
'gbean@http://geronimo.apache.org/xml/ns/deployment-1.1' here in element
module@http://geronimo.apache.org/xml/ns/deployment-1.1,
/home/alfert/src/service-mix/svn-trunk/trunk/geronimo/servicemix/target/plan/plan.xml:189:
error: cvc-complex-type.2.4a: Expected element
'environment@http://geronimo.apache.org/xml/ns/deployment-1.1' instead of
'gbean@http://geronimo.apache.org/xml/ns/deployment-1.1' here in element
module@http://geronimo.apache.org/xml/ns/deployment-1.1,
/home/alfert/src/service-mix/svn-trunk/trunk/geronimo/servicemix/target/plan/plan.xml:203:
error: cvc-complex-type.2.4a: Expected element
'environment@http://geronimo.apache.org/xml/ns/deployment-1.1' instead of
'gbean@http://geronimo.apache.org/xml/ns/deployment-1.1' here in element
module@http://geronimo.apache.org/xml/ns/deployment-1.1,
/home/alfert/src/service-mix/svn-trunk/trunk/geronimo/servicemix/target/plan/plan.xml:210:
error: cvc-complex-type.2.4c: Expected element
'environment@http://geronimo.apache.org/xml/ns/deployment-1.1' before the
end of the content in element
module@http://geronimo.apache.org/xml/ns/deployment-1.1]



gnodet wrote:
> 
> Oops, sorry.
> This is fixed.
> 
> On 8/22/06, Klaus Alfert <ka...@zuehlke.com> wrote:
>>
>> Hi Guillaume,
>>
>> after an svn update (to revision 433641),  I got a compile error. Is
>> there
>> some checking pending?
>>
>> Compiling 24 source files to
>> /home/alfert/src/service-mix/svn-trunk/trunk/servicemix-jms/target/classes
>> [INFO]
>> ------------------------------------------------------------------------
>> [ERROR] BUILD FAILURE
>> [INFO]
>> ------------------------------------------------------------------------
>> [INFO] Compilation failure
>>
>> /home/alfert/src/service-mix/svn-trunk/trunk/servicemix-jms/src/main/java/org/apache/servicemix/jms/AbstractJmsProcessor.java:[174,25]
>> createContext(org.apache.servicemix.soap.marshalers.SoapMessage) in
>> org.apache.servicemix.soap.SoapHelper cannot be applied to ()
>>
>>
>> Klaus.
>>
>>
>> gnodet wrote:
>> >
>> > I have just fixed that.
>> > You can now add the needJavaIdentifiers="true" attribute so that all
>> > non valid properties will be skipped.
>> > Note that the Content-Type property has been renamed to MimeContentType
>> > so that mime streams can still be sent.
>> > [..]
>> > --
>> > Cheers,
>> > Guillaume Nodet
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Exceptions-in-servicemix-jms-with-WebSphereMQ-tf2141329.html#a5926623
>> Sent from the ServiceMix - Dev forum at Nabble.com.
>>
>>
> 
> 
> -- 
> Cheers,
> Guillaume Nodet
> 
> 

-- 
View this message in context: http://www.nabble.com/Exceptions-in-servicemix-jms-with-WebSphereMQ-tf2141329.html#a5927221
Sent from the ServiceMix - Dev forum at Nabble.com.


Re: Exceptions in servicemix-jms with WebSphereMQ

Posted by Guillaume Nodet <gn...@gmail.com>.
Oops, sorry.
This is fixed.

On 8/22/06, Klaus Alfert <ka...@zuehlke.com> wrote:
>
> Hi Guillaume,
>
> after an svn update (to revision 433641),  I got a compile error. Is there
> some checking pending?
>
> Compiling 24 source files to
> /home/alfert/src/service-mix/svn-trunk/trunk/servicemix-jms/target/classes
> [INFO]
> ------------------------------------------------------------------------
> [ERROR] BUILD FAILURE
> [INFO]
> ------------------------------------------------------------------------
> [INFO] Compilation failure
>
> /home/alfert/src/service-mix/svn-trunk/trunk/servicemix-jms/src/main/java/org/apache/servicemix/jms/AbstractJmsProcessor.java:[174,25]
> createContext(org.apache.servicemix.soap.marshalers.SoapMessage) in
> org.apache.servicemix.soap.SoapHelper cannot be applied to ()
>
>
> Klaus.
>
>
> gnodet wrote:
> >
> > I have just fixed that.
> > You can now add the needJavaIdentifiers="true" attribute so that all
> > non valid properties will be skipped.
> > Note that the Content-Type property has been renamed to MimeContentType
> > so that mime streams can still be sent.
> > [..]
> > --
> > Cheers,
> > Guillaume Nodet
> >
> >
>
> --
> View this message in context: http://www.nabble.com/Exceptions-in-servicemix-jms-with-WebSphereMQ-tf2141329.html#a5926623
> Sent from the ServiceMix - Dev forum at Nabble.com.
>
>


-- 
Cheers,
Guillaume Nodet

Re: Exceptions in servicemix-jms with WebSphereMQ

Posted by Klaus Alfert <ka...@zuehlke.com>.
Hi Guillaume,

after an svn update (to revision 433641),  I got a compile error. Is there
some checking pending?

Compiling 24 source files to
/home/alfert/src/service-mix/svn-trunk/trunk/servicemix-jms/target/classes
[INFO]
------------------------------------------------------------------------
[ERROR] BUILD FAILURE
[INFO]
------------------------------------------------------------------------
[INFO] Compilation failure

/home/alfert/src/service-mix/svn-trunk/trunk/servicemix-jms/src/main/java/org/apache/servicemix/jms/AbstractJmsProcessor.java:[174,25]
createContext(org.apache.servicemix.soap.marshalers.SoapMessage) in
org.apache.servicemix.soap.SoapHelper cannot be applied to ()


Klaus.


gnodet wrote:
> 
> I have just fixed that.
> You can now add the needJavaIdentifiers="true" attribute so that all
> non valid properties will be skipped.
> Note that the Content-Type property has been renamed to MimeContentType
> so that mime streams can still be sent.
> [..]
> -- 
> Cheers,
> Guillaume Nodet
> 
> 

-- 
View this message in context: http://www.nabble.com/Exceptions-in-servicemix-jms-with-WebSphereMQ-tf2141329.html#a5926623
Sent from the ServiceMix - Dev forum at Nabble.com.


Re: Exceptions in servicemix-jms with WebSphereMQ

Posted by Marrad <ma...@hotmail.com>.
Exactly what we needed when using JBossMQ.
Just a little reminder, this attribute is missing in the documentation on
http://incubator.apache.org/servicemix/main/servicemix-jms.html. 

Regards,
Markus


gnodet wrote:
> 
> I have just fixed that.
> You can now add the needJavaIdentifiers="true" attribute so that all
> non valid properties will be skipped.
> Note that the Content-Type property has been renamed to MimeContentType
> so that mime streams can still be sent.
> 
> On 8/21/06, Klaus Alfert <ka...@zuehlke.com> wrote:
>>
>> Hi Folks,
>>
>> I have a problem connecting service mix via the servicemix-jms component
>> to
>> a WebSphereMQ Queue.
>>
>> My provider configuration is as follows:
>> <!-- Reads a message from the NMR and writes them to XNEAIDV3.SMIX.TEST.2
>> -->
>>                 <jms:endpoint service="dz:MyProviderService"
>>                 endpoint="myProvider"
>>                 role="provider"
>>                 destinationStyle="queue"
>>                 jmsProviderDestinationName="XNEAIDV3.SMIX.TEST.2"
>>                 connectionFactory="#jmsFactory"
>>                 />
>>
>> The message sent is as follows:
>> <?xml version="1.0" encoding="UTF-8"?>
>> <sample id="0">
>>   here is some testdata
>> </sample>
>>
>>
>> I get the following exception:
>> javax.jms.MessageFormatException: MQJMS1058: Invalid message property
>> name:
>> Content-Type
>>         at
>> com.ibm.jms.JMSMessage.newMessageFormatException(JMSMessage.java:4674)
>>         at com.ibm.jms.JMSMessage.setStringProperty(JMSMessage.java:5658)
>>         at
>> org.apache.servicemix.jms.multiplexing.MultiplexingProviderProcessor.process(MultiplexingProviderProcessor.java:182)
>>         at
>> org.apache.servicemix.common.AsyncBaseLifeCycle.processExchange(AsyncBaseLifeCycle.java:398)
>>         at
>> org.apache.servicemix.common.BaseLifeCycle.onMessageExchange(BaseLifeCycle.java:43)
>>         at
>> org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.processInBound(DeliveryChannelImpl.java:623)
>>         at
>> org.apache.servicemix.jbi.nmr.flow.AbstractFlow.doRouting(AbstractFlow.java:169)
>>         at
>> org.apache.servicemix.jbi.nmr.flow.seda.SedaFlow.doRouting(SedaFlow.java:177)
>>         at
>> org.apache.servicemix.jbi.nmr.flow.seda.SedaQueue$1.run(SedaQueue.java:227)
>>         at
>> org.apache.geronimo.connector.work.WorkerContext.run(WorkerContext.java:291)
>>         at
>> EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(Unknown
>> Source)
>>         at java.lang.Thread.run(Thread.java:595)
>>
>> As far as I understand the code, in line 182 of
>> MultiplexingProviderProcessor the property "Content-Type" is set to the
>> value defined in the normalized message (according to
>> http://issues.apache.org/activemq/browse/SM-502). But "Content-Type" is
>> not
>> a proper name for a JMS property (at least according to SM-398 and
>> SM-403, I
>> did not check the JMS spec myself) and WebSphereMQ chokes immediately.
>>
>> The discussion of SM-502 indicates that the Content-Type property is
>> required for SOAP and SAAJ. However, my configuration does not use SOAP
>> at
>> all (which shall be the default case according to the docs). I am also
>> not
>> sure whether it is needed to set the content type property to the JMS
>> message. I would expect the content-type as a part of the message payload
>> itself but I am by no means an expert of the SOAP/JMS on the wire format.
>>
>> A final remark: In contrast to the marshaler in the older lightweight jms
>> component, there is no checking of valid header names in the loop
>> immediately before line 182. This looks like an additionally potential
>> error
>> source.
>>
>> A simple workaround is to catch and silently ignore exceptions when
>> setting
>> the message properties.
>>
>> Cheers,
>> Klaus.
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Exceptions-in-servicemix-jms-with-WebSphereMQ-tf2141329.html#a5910358
>> Sent from the ServiceMix - Dev forum at Nabble.com.
>>
>>
> 
> 
> -- 
> Cheers,
> Guillaume Nodet
> 
> 

-- 
View this message in context: http://www.nabble.com/Exceptions-in-servicemix-jms-with-WebSphereMQ-tf2141329.html#a6402782
Sent from the ServiceMix - Dev mailing list archive at Nabble.com.


Re: Exceptions in servicemix-jms with WebSphereMQ

Posted by Guillaume Nodet <gn...@gmail.com>.
I have just fixed that.
You can now add the needJavaIdentifiers="true" attribute so that all
non valid properties will be skipped.
Note that the Content-Type property has been renamed to MimeContentType
so that mime streams can still be sent.

On 8/21/06, Klaus Alfert <ka...@zuehlke.com> wrote:
>
> Hi Folks,
>
> I have a problem connecting service mix via the servicemix-jms component to
> a WebSphereMQ Queue.
>
> My provider configuration is as follows:
> <!-- Reads a message from the NMR and writes them to XNEAIDV3.SMIX.TEST.2
> -->
>                 <jms:endpoint service="dz:MyProviderService"
>                 endpoint="myProvider"
>                 role="provider"
>                 destinationStyle="queue"
>                 jmsProviderDestinationName="XNEAIDV3.SMIX.TEST.2"
>                 connectionFactory="#jmsFactory"
>                 />
>
> The message sent is as follows:
> <?xml version="1.0" encoding="UTF-8"?>
> <sample id="0">
>   here is some testdata
> </sample>
>
>
> I get the following exception:
> javax.jms.MessageFormatException: MQJMS1058: Invalid message property name:
> Content-Type
>         at
> com.ibm.jms.JMSMessage.newMessageFormatException(JMSMessage.java:4674)
>         at com.ibm.jms.JMSMessage.setStringProperty(JMSMessage.java:5658)
>         at
> org.apache.servicemix.jms.multiplexing.MultiplexingProviderProcessor.process(MultiplexingProviderProcessor.java:182)
>         at
> org.apache.servicemix.common.AsyncBaseLifeCycle.processExchange(AsyncBaseLifeCycle.java:398)
>         at
> org.apache.servicemix.common.BaseLifeCycle.onMessageExchange(BaseLifeCycle.java:43)
>         at
> org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.processInBound(DeliveryChannelImpl.java:623)
>         at
> org.apache.servicemix.jbi.nmr.flow.AbstractFlow.doRouting(AbstractFlow.java:169)
>         at
> org.apache.servicemix.jbi.nmr.flow.seda.SedaFlow.doRouting(SedaFlow.java:177)
>         at
> org.apache.servicemix.jbi.nmr.flow.seda.SedaQueue$1.run(SedaQueue.java:227)
>         at
> org.apache.geronimo.connector.work.WorkerContext.run(WorkerContext.java:291)
>         at
> EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(Unknown Source)
>         at java.lang.Thread.run(Thread.java:595)
>
> As far as I understand the code, in line 182 of
> MultiplexingProviderProcessor the property "Content-Type" is set to the
> value defined in the normalized message (according to
> http://issues.apache.org/activemq/browse/SM-502). But "Content-Type" is not
> a proper name for a JMS property (at least according to SM-398 and SM-403, I
> did not check the JMS spec myself) and WebSphereMQ chokes immediately.
>
> The discussion of SM-502 indicates that the Content-Type property is
> required for SOAP and SAAJ. However, my configuration does not use SOAP at
> all (which shall be the default case according to the docs). I am also not
> sure whether it is needed to set the content type property to the JMS
> message. I would expect the content-type as a part of the message payload
> itself but I am by no means an expert of the SOAP/JMS on the wire format.
>
> A final remark: In contrast to the marshaler in the older lightweight jms
> component, there is no checking of valid header names in the loop
> immediately before line 182. This looks like an additionally potential error
> source.
>
> A simple workaround is to catch and silently ignore exceptions when setting
> the message properties.
>
> Cheers,
> Klaus.
>
> --
> View this message in context: http://www.nabble.com/Exceptions-in-servicemix-jms-with-WebSphereMQ-tf2141329.html#a5910358
> Sent from the ServiceMix - Dev forum at Nabble.com.
>
>


-- 
Cheers,
Guillaume Nodet