activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jeffrey Starker (JIRA)" <>
Subject [jira] [Reopened] (AMQ-4130) Duplicated Classes in activemq-spring and activemq-pool artifacts
Date Fri, 30 Nov 2012 17:37:58 GMT


Jeffrey Starker reopened AMQ-4130:

Hello, not to be a pain, but I think there is a duplication. Here are more steps to show you
what I am talking about. Sorry for being unclear before.


# Download the activemq-pool-5.7.0.jar and activemq-spring-5.7.0.jar via Maven. Using the
central maven repository. You can also find them via the web at:
# Expand the jar files in to a directory:
jar -xvf activemq-spring-5.7.0.jar
jar -xvf activemq-pool-5.7.0.jar
# You will notice that the org.apache.activemq.pool package is also included in activemq-spring-5.7.0.jar
file when expanded.
# After extracting the two jar files, you can do a diff on any file I listed above in the
previous comment to show they are identical:
diff ${directory_of_pool_jar_extract}/org/apache/activemq/pool/ActiveMQResourceManager.class

> Duplicated Classes in activemq-spring and activemq-pool artifacts
> -----------------------------------------------------------------
>                 Key: AMQ-4130
>                 URL:
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: activemq-pool
>    Affects Versions: 5.7.0
>         Environment: Maven integration
>            Reporter: Jeffrey Starker
>            Priority: Minor
> When adding activemq-spring as a dependency in a java maven projects, the activemq-spring
includes the artifact activemq-pool as a dependency. However, this causes a problem as activemq-spring
duplicates many of the classes that are in activemq-pool.
> If you do a directory and file comparision between activemq-spring-5.7.0.jar and activemq-pool-5.7.0.jar,
the following files are duplicated in activemq-spring:
> {noformat}
> [WARNING] Found duplicate classes in [org.apache.activemq:activemq-pool:5.7.0,org.apache.activemq:activemq-spring:5.7.0]
> [WARNING]   org.apache.activemq.pool.ActiveMQResourceManager
> [WARNING]   org.apache.activemq.pool.AmqJNDIPooledConnectionFactory
> [WARNING]   org.apache.activemq.pool.ConnectionKey
> [WARNING]   org.apache.activemq.pool.ConnectionPool
> [WARNING]   org.apache.activemq.pool.JcaConnectionPool
> [WARNING]   org.apache.activemq.pool.JcaPooledConnectionFactory
> [WARNING]   org.apache.activemq.pool.PooledConnection
> [WARNING]   org.apache.activemq.pool.PooledConnectionFactory
> [WARNING]   org.apache.activemq.pool.PooledMessageConsumer
> [WARNING]   org.apache.activemq.pool.PooledProducer
> [WARNING]   org.apache.activemq.pool.PooledQueueSender
> [WARNING]   org.apache.activemq.pool.PooledSession
> [WARNING]   org.apache.activemq.pool.PooledSessionEventListener
> [WARNING]   org.apache.activemq.pool.PooledTopicPublisher
> [WARNING]   org.apache.activemq.pool.SessionKey
> [WARNING]   org.apache.activemq.pool.XaConnectionPool
> [WARNING]   org.apache.activemq.pool.XaPooledConnectionFactory
> {noformat}
> This can cause classloader problems as there are duplicated classes located on the path
if activemq-pool or activemq-spring classes changed in a later version. This problem has also
happened in previous versions of activemq.
> Current workaround is to simply add exclusion to activemq-pool:
> {code:xml}
> <dependency>
> 	<groupId>org.apache.activemq</groupId>
> 	<artifactId>activemq-spring</artifactId>
> 	<version>5.7.0</version>
> 	<exclusions>
> 		<exclusion>
> 			<artifactId>activemq-pool</artifactId>
> 			<groupId>org.apache.activemq</groupId>
> 		</exclusion>
> 	</exclusions>
> </dependency>
> {code}
> Suggested fix is to remove the classes from activemq-spring package and instead include
the classes located in activemq-pool as a required dependency.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:

View raw message