As the documentation mentions, you can disable the property name restrictions if you desire, using the "jms.validatePropertyNames" URI option, http://qpid.apache.org/releases/qpid-jms-0.33.0/docs/index.html#jms-configuration-options. Be aware that using any such non-JMS identifiers means your code may not be portable to other JMS implementations in future.
As I noted before, you may also be able to reach into the newer JMS clients message implementation to set the content type using reflection if you really want. Its not quite as simple as with the older prototype client you reference below, and there is no plan to expose it in a similar way. The bit of interest would be in the JmsMessage objects 'facade' field, where the implementation class, AmqpJmsMessageFacade, currently has a setContentType method for internal usage. Robbie On 22 June 2018 at 15:33, akabhishek1 <[email protected]> wrote: > Hi Robbie, > > Thanks a lot for reply and detail explanation. > > I went through > "http://docs.oasis-open.org/amqp/core/v1.0/amqp-core-messaging-v1.0.html#section-message-format" > and > understood that there could be the infrastructure property as well. > > Some Difference between AMQP and JMS standard > 1. AMQP support property name as String but JMS supports only letter, > digit, symbol, punctuation character etc which allows "java.lang.Character > -> isJavaIdentifierPart" > SO JMS can not allow property name with dot, hyphen. > 2. AMQP supports infrastructure property as part of header property. > Qpid-Client-JMS does not provide facility to insert infrastructure property. > We can not change ContentType as well(part of header property). > > > My understanding is that Service Bus is probably using AMQP compatible > messages, but we are using the "qpid-jms-client" library to handle these > messages. > This seems to cause a mismatch between what AMQP / Service Bus is sending in > messages and what the JMS client can manage. > Is using the JMS client the bst approach? Are there other options? > > I also did some research based on "qpid-amqp-1-0-client-jms-0.32". With the > use of this, i can get hold on > "org.apache.qpid.amqp_1_0.jms.impl.MessageImpl". > I am able to set "ContentType". Please find attached example. The main > problem - "qpid-amqp-1-0-client-jms-0.32" is a old library and no release > after "Mar, 2015". > > Is that possible for you to provide same functionality in "qpid-jms-client" > ? Please suggest. > > We are worried about "ContentType" only. We can use ASIS message id and > default partition key. > > Please suggest your opinion depends on your input we will proceed further. > > Regards, > Abhishek Kumar > > TestQpid_1_0_JMS_TemplateSend.java > <http://qpid.2158936.n2.nabble.com/file/t396358/TestQpid_1_0_JMS_TemplateSend.java> > > > > -- > Sent from: http://qpid.2158936.n2.nabble.com/Apache-Qpid-users-f2158936.html > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
