Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 9C1A4200D28 for ; Mon, 23 Oct 2017 15:03:09 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 9ADFB1609CE; Mon, 23 Oct 2017 13:03:09 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id E074C1609E0 for ; Mon, 23 Oct 2017 15:03:08 +0200 (CEST) Received: (qmail 49789 invoked by uid 500); 23 Oct 2017 13:03:08 -0000 Mailing-List: contact issues-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@activemq.apache.org Delivered-To: mailing list issues@activemq.apache.org Received: (qmail 49780 invoked by uid 99); 23 Oct 2017 13:03:08 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 23 Oct 2017 13:03:08 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id 5352BC4D42 for ; Mon, 23 Oct 2017 13:03:07 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -99.202 X-Spam-Level: X-Spam-Status: No, score=-99.202 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, RP_MATCHES_RCVD=-0.001, SPF_PASS=-0.001, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id yEtsJYpo3ytJ for ; Mon, 23 Oct 2017 13:03:02 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTP id BBE1E5FCA7 for ; Mon, 23 Oct 2017 13:03:01 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id E346FE0D54 for ; Mon, 23 Oct 2017 13:03:00 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id 8A06421EE4 for ; Mon, 23 Oct 2017 13:03:00 +0000 (UTC) Date: Mon, 23 Oct 2017 13:03:00 +0000 (UTC) From: "ASF GitHub Bot (JIRA)" To: issues@activemq.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (ARTEMIS-1475) NPE when deploying 2 MDBs with same clientID/subscriptionName MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Mon, 23 Oct 2017 13:03:09 -0000 [ https://issues.apache.org/jira/browse/ARTEMIS-1475?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16215098#comment-16215098 ] ASF GitHub Bot commented on ARTEMIS-1475: ----------------------------------------- GitHub user jmesnil opened a pull request: https://github.com/apache/activemq-artemis/pull/1603 [ARTEMIS-1475] Fix NPE in ActiveMQMessageHandler#setup * initialize ActiveMQActivationSpec#shareSubscriptions to false * i18n of the exception thrown by ActiveMQMessageHandler if it is not possible to create a non-shared subscriber JIRA: https://issues.apache.org/jira/browse/ARTEMIS-1475 You can merge this pull request into a Git repository by running: $ git pull https://github.com/jmesnil/activemq-artemis ARTEMIS-1475_ActiveMQMessageHandler_NPE Alternatively you can review and apply these changes as the patch at: https://github.com/apache/activemq-artemis/pull/1603.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #1603 ---- commit 9d06338da8112a551085d7c9af006914dae70895 Author: Jeff Mesnil Date: 2017-10-23T12:01:30Z [ARTEMIS-1475] Fix NPE in ActiveMQMessageHandler#setup * initialize ActiveMQActivationSpec#shareSubscriptions to false * i18n of the exception thrown by ActiveMQMessageHandler if it is not possible to create a non-shared subscriber JIRA: https://issues.apache.org/jira/browse/ARTEMIS-1475 ---- > NPE when deploying 2 MDBs with same clientID/subscriptionName > ------------------------------------------------------------- > > Key: ARTEMIS-1475 > URL: https://issues.apache.org/jira/browse/ARTEMIS-1475 > Project: ActiveMQ Artemis > Issue Type: Bug > Components: Broker > Affects Versions: 1.5.5 > Reporter: Jeff Mesnil > > Steps to reproduce: > * deploy an application in an app server using the Artemis Resource adapters with 2 MDBs that have the same clientID and subscriptionName activation config properties: > {code} > @MessageDriven(name = "HelloWorldQTopicMDB2", activationConfig = { > @ActivationConfigProperty(propertyName = "destinationLookup", propertyValue = "topic/HELLOWORLDMDBTopic"), > @ActivationConfigProperty(propertyName = "destinationType", propertyValue = "javax.jms.Topic"), > @ActivationConfigProperty(propertyName = "subscriptionName", propertyValue = "mySubscription"), > @ActivationConfigProperty(propertyName = "clientID", propertyValue = "myClientId"), > @ActivationConfigProperty(propertyName = "subscriptionDurability", propertyValue = "Durable"), > @ActivationConfigProperty(propertyName = "acknowledgeMode", propertyValue = "Auto-acknowledge")}) > {code} > Result: > * when the application is deployed, it fails with the error: > {code} > 13:38:40,187 ERROR [org.apache.activemq.artemis.ra] (default-threads - 3) AMQ154003: Unable to reconnect org.apache.activemq.artemis.ra.inflow.ActiveMQActivatio > nSpec(ra=org.wildfly.extension.messaging.activemq.ActiveMQResourceAdapter@2bd07716 destination=topic/HELLOWORLDMDBTopic destinationType=javax.jms.Topic ack=Auto > -acknowledge durable=true clientID=myClientId subscription=mySubscription user=null maxSession=15): java.lang.NullPointerException > at org.apache.activemq.artemis.ra.inflow.ActiveMQMessageHandler.setup(ActiveMQMessageHandler.java:125) > at org.apache.activemq.artemis.ra.inflow.ActiveMQActivation.setup(ActiveMQActivation.java:314) > at org.apache.activemq.artemis.ra.inflow.ActiveMQActivation.reconnect(ActiveMQActivation.java:658) > at org.apache.activemq.artemis.ra.inflow.ActiveMQActivation$SetupActivation.run(ActiveMQActivation.java:698) > {code} > Expected outcome: > The deployment should fail with the correct exception from throw new javax.jms.IllegalStateException("Cannot create a subscriber on the durable subscription since it already has subscriber(s)"); > > The NPE is caused by ActiveMQActivationSpec#shareSubscriptions that is not instantiated to false in the default constructor. > In addition, the error message should be i18nized. -- This message was sent by Atlassian JIRA (v6.4.14#64029)