Return-Path: Delivered-To: apmail-geronimo-activemq-commits-archive@www.apache.org Received: (qmail 63364 invoked from network); 8 Apr 2006 16:48:39 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 8 Apr 2006 16:48:39 -0000 Received: (qmail 1272 invoked by uid 500); 8 Apr 2006 16:48:39 -0000 Delivered-To: apmail-geronimo-activemq-commits-archive@geronimo.apache.org Received: (qmail 1250 invoked by uid 500); 8 Apr 2006 16:48:38 -0000 Mailing-List: contact activemq-commits-help@geronimo.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: activemq-dev@geronimo.apache.org Delivered-To: mailing list activemq-commits@geronimo.apache.org Received: (qmail 1241 invoked by uid 99); 8 Apr 2006 16:48:38 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 08 Apr 2006 09:48:38 -0700 X-ASF-Spam-Status: No, hits=-8.6 required=10.0 tests=ALL_TRUSTED,INFO_TLD,NO_REAL_NAME X-Spam-Check-By: apache.org Received: from [209.237.227.194] (HELO minotaur.apache.org) (209.237.227.194) by apache.org (qpsmtpd/0.29) with SMTP; Sat, 08 Apr 2006 09:48:37 -0700 Received: (qmail 63242 invoked by uid 65534); 8 Apr 2006 16:48:17 -0000 Message-ID: <20060408164817.63239.qmail@minotaur.apache.org> Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r392556 - /incubator/activemq/trunk/activemq-ra/src/main/java/org/apache/activemq/ra/ActiveMQManagedConnectionFactory.java Date: Sat, 08 Apr 2006 16:48:16 -0000 To: activemq-commits@geronimo.apache.org From: chirino@apache.org X-Mailer: svnmailer-1.0.7 X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Author: chirino Date: Sat Apr 8 09:48:15 2006 New Revision: 392556 URL: http://svn.apache.org/viewcvs?rev=392556&view=rev Log: Fix for problem reported by: Christopher G. Stach II We're using Resin and trying to use 4.0-RC2. It just so happens that Resin makes this call in ConnectionPool.init(ManagedConnectionFactory): ManagedConnection mConn = mcf.createManagedConnection(subject, null); So, eventually that null info gets dereferenced and BOOM! com.caucho.server.webapp.Application.start java.lang.NullPointerException at org.apache.activemq.ra.ActiveMQResourceAdapter.createConnectionFactory(ActiveMQResourceAdapter.java:156) at org.apache.activemq.ra.ActiveMQResourceAdapter.makeConnection(ActiveMQResourceAdapter.java:100) at org.apache.activemq.ra.ActiveMQManagedConnectionFactory.createManagedConnection(ActiveMQManagedConnectionFactory.java:103) at com.caucho.jca.ConnectionPool.init(ConnectionPool.java:462) Modified: incubator/activemq/trunk/activemq-ra/src/main/java/org/apache/activemq/ra/ActiveMQManagedConnectionFactory.java Modified: incubator/activemq/trunk/activemq-ra/src/main/java/org/apache/activemq/ra/ActiveMQManagedConnectionFactory.java URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/activemq-ra/src/main/java/org/apache/activemq/ra/ActiveMQManagedConnectionFactory.java?rev=392556&r1=392555&r2=392556&view=diff ============================================================================== --- incubator/activemq/trunk/activemq-ra/src/main/java/org/apache/activemq/ra/ActiveMQManagedConnectionFactory.java (original) +++ incubator/activemq/trunk/activemq-ra/src/main/java/org/apache/activemq/ra/ActiveMQManagedConnectionFactory.java Sat Apr 8 09:48:15 2006 @@ -99,6 +99,9 @@ */ public ManagedConnection createManagedConnection(Subject subject, ConnectionRequestInfo info) throws ResourceException { try { + if( info == null ) { + info = this.info; + } ActiveMQConnectionRequestInfo amqInfo = (ActiveMQConnectionRequestInfo) info; return new ActiveMQManagedConnection(subject, adapter.makeConnection(amqInfo), amqInfo); }