Open r-alto opened 4 years ago
It works if I create for every subscriber a connection factory with the paramter "clientID=xyz" and don't use the "setClientID" of the connection. But this solution is not verry useable, because i can't add subscribers dynamically.
Hi @r-alto , please, can you provide a simple to follow scenario how to reproduce this? A reproducer should ideally follow the SSCCE rules: http://www.sscce.org/. It will greatly help us to find the cause and fix it.
Please add the domain.xml file with all required configuration or a script with asadmin commands to set up the JMS resources. The Asadmin recorder might be helpful to generate the asadmin commands if you configure everything in Admin Console.
Be sure the the "JMS Resoources -> Connection Factories" "jms/OrgaCardTopicConnectionFactory" and the "JMS Resoources -> JMS Destination Resources" "jms/orgacard/entity/topic" are defined.
Use project "jmslistenernative1" Open a remote debugging with the payara. Set a breakpoint at row "connection.setClientID("4712"); " and deploy the listener "jmslistenernative1". Step Over this instruction the exception is thrown. It doesn't matter what value you write into setClientID(), it only works if you set the parameter "clientID" in payaras "jms/OrgaCardTopicConnectionFactory". If you don't set the parameter "clientID" the durable subscriber doen't work.
Hi @r-alto,
I have been able to reproduce the issue in 5.2020.6, I raised internal ticket FISH-789
. We encourage you to submit a PR if you know the cause of the issue - since it may be a while before we get to fully investigate the cause of the error.
Thank you, Alan
Sorry I don't know the cause of the issue.
I don't know if you solved, by the way I had the same issue. I was trying to deploy a project on a GlassFish server but already another project that used my jms/ConnectionFactory was deployed and I think the problem was that it couldn't find a free ConnectionFactory. By the way I undeployed the old project and I was able to deploy the new one. I hope that helps
Hallo,
I'm using "Payara Server 5.201 #badassfish (build 512)" from Docker.
I create: "JMS Ressource"->"Connection Factory"->"javax.jms.TopicConnectionFactory" as "jms/MyTopicConnectionFactory" with the parameter "clientID=4711".
If I try to create a DurableSubscriber I got an exception (javax.jms.JMSException: MQJMSRA_DC2001: Unsupported:setClientID():inACC=false:connectionId=2726772599957665024) if setting the client id of the connection (connection.setClientID("4711")).
This error occurs also if I don't set the parameter "clientID=4711" for the "Connection Factory".
If I don't set the client id the exception (com.sun.messaging.jms.IllegalStateException: createConsumer on JMSService:jmsdirect failed for connectionId:2726772600233384448 and sessionId:2726772600233924864 due to [B4135]: Cannot add durable consumer consumer. No ClientID was set on connection.) occurs it I do "session.createDurableSubscriber(topic, "consumer", "", false)".
What is wrong?
Thanks Ralf