You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cxf.apache.org by "Christian Schneider (JIRA)" <ji...@apache.org> on 2017/04/19 14:26:41 UTC
[jira] [Resolved] (CXF-6624) [SOAP][JMS]
javax.jms.IllegalStateException when setting the exception listener
[ https://issues.apache.org/jira/browse/CXF-6624?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Christian Schneider resolved CXF-6624.
--------------------------------------
Resolution: Not A Problem
I don't think this is an issue in the CXF JMS transport. It looks like the resource adapter you use in jboss simply does not support this method.
> [SOAP][JMS] javax.jms.IllegalStateException when setting the exception listener
> -------------------------------------------------------------------------------
>
> Key: CXF-6624
> URL: https://issues.apache.org/jira/browse/CXF-6624
> Project: CXF
> Issue Type: Bug
> Components: JMS, Transports
> Affects Versions: 3.1.1
> Reporter: Frédéric Pirson
> Assignee: Christian Schneider
>
> Hello,
> I need to use soap over jms via tibco for some service.
> Spring config :
> {code:xml}
> <jaxws:endpoint
> xmlns:tns="http://blabla.be/WSDL/BE/BE_RiskAcceptance_BUS/1/GetRiskAcceptanceStatus/1"
> id="GetRiskAcceptanceStatus"
> serviceName="tns:GetRiskAcceptanceStatus"
> endpointName="tns:GetRiskAcceptanceStatus_Binding_JMS"
> implementor="#GetRiskAcceptanceStatusService" transportId="http://cxf.apache.org/transports/jms"
> address="jms:jndi:ESB.BE.BS.RiskAcceptance.BE_RiskAcceptance_BUS.1.GetRiskAcceptanceStatus.1.Request"
> >
> <jaxws:features>
> <ref bean="jmsConfigFeatureGetRiskAcceptanceStatus"/>
> </jaxws:features>
> </jaxws:endpoint>
> {code}
> When deployment occurs, I see every 5s some reconnection.
> I analyzed what occurs and it comes from org.apache.cxf.transport.jms.JMSDestination.
> {code:java}
> private JMSListenerContainer createTargetDestinationListener() {
> Session session = null;
> try {
> connection = JMSFactory.createConnection(jmsConfig);
> connection.setExceptionListener(new ExceptionListener() {
> public void onException(JMSException exception) {
> if (!shutdown) {
> LOG.log(Level.WARNING, "Exception on JMS connection. Trying to reconnect", exception);
> restartConnection();
> }
> }
> });
> session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
> Destination destination = jmsConfig.getTargetDestination(session);
> PollingMessageListenerContainer container = new PollingMessageListenerContainer(connection,
> destination, this);
> container.setConcurrentConsumers(jmsConfig.getConcurrentConsumers());
> container.setTransactionManager(jmsConfig.getTransactionManager());
> container.setMessageSelector(jmsConfig.getMessageSelector());
> container.setTransacted(jmsConfig.isSessionTransacted());
> container.setDurableSubscriptionName(jmsConfig.getDurableSubscriptionName());
> Executor executor = JMSFactory.createExecutor(bus, "jms-destination");
> container.setExecutor(executor);
> container.start();
> suspendedContinuations.setListenerContainer(container);
> connection.start();
> return container;
> } catch (JMSException e) {
> throw JMSUtil.convertJmsException(e);
> } finally {
> ResourceCloser.close(session);
> }
> }
> {code}
> The setExceptionListener invoked on a org.jboss.resource.adapter.jms.JmsSessionFactory throw directly that exception with message : "This method is not applicable inside the application server. See the J2EE spec, e.g. J2EE1.4 Section 6.6";
> For the specs : http://java.cnam.fr/iagl/biblio/spec/j2ee-1_4-fr-spec.pdf page 103 + 104
> Something I do wrong or issue in jms transport ?
> Regards
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)