cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cschnei...@apache.org
Subject cxf git commit: CXF-6199 Make sure concurrentConsumers can be configured on JMSEndpoint
Date Mon, 19 Jan 2015 23:04:00 GMT
Repository: cxf
Updated Branches:
  refs/heads/master c216071d5 -> a3fa00bcc


CXF-6199 Make sure concurrentConsumers can be configured on JMSEndpoint


Project: http://git-wip-us.apache.org/repos/asf/cxf/repo
Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/a3fa00bc
Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/a3fa00bc
Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/a3fa00bc

Branch: refs/heads/master
Commit: a3fa00bcc1816dda0dc5500709d024c6959a3e0b
Parents: c216071
Author: Christian Schneider <chris@die-schneider.net>
Authored: Tue Jan 20 00:02:19 2015 +0100
Committer: Christian Schneider <chris@die-schneider.net>
Committed: Tue Jan 20 00:02:19 2015 +0100

----------------------------------------------------------------------
 .../java/org/apache/cxf/transport/jms/JMSConfigFactory.java  | 1 +
 .../org/apache/cxf/transport/jms/JMSConfigFactoryTest.java   | 8 ++++++++
 2 files changed, 9 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cxf/blob/a3fa00bc/rt/transports/jms/src/main/java/org/apache/cxf/transport/jms/JMSConfigFactory.java
----------------------------------------------------------------------
diff --git a/rt/transports/jms/src/main/java/org/apache/cxf/transport/jms/JMSConfigFactory.java
b/rt/transports/jms/src/main/java/org/apache/cxf/transport/jms/JMSConfigFactory.java
index e5ec995..464fc7a 100644
--- a/rt/transports/jms/src/main/java/org/apache/cxf/transport/jms/JMSConfigFactory.java
+++ b/rt/transports/jms/src/main/java/org/apache/cxf/transport/jms/JMSConfigFactory.java
@@ -85,6 +85,7 @@ public final class JMSConfigFactory {
         jmsConfig.setConduitSelectorPrefix(endpoint.getConduitIdSelectorPrefix());
         jmsConfig.setUserName(endpoint.getUsername());
         jmsConfig.setPassword(endpoint.getPassword());
+        jmsConfig.setConcurrentConsumers(endpoint.getConcurrentConsumers());
 
         TransactionManager tm = getTransactionManager(bus, endpoint);
         jmsConfig.setTransactionManager(tm);

http://git-wip-us.apache.org/repos/asf/cxf/blob/a3fa00bc/rt/transports/jms/src/test/java/org/apache/cxf/transport/jms/JMSConfigFactoryTest.java
----------------------------------------------------------------------
diff --git a/rt/transports/jms/src/test/java/org/apache/cxf/transport/jms/JMSConfigFactoryTest.java
b/rt/transports/jms/src/test/java/org/apache/cxf/transport/jms/JMSConfigFactoryTest.java
index 1198b9e..9008732 100644
--- a/rt/transports/jms/src/test/java/org/apache/cxf/transport/jms/JMSConfigFactoryTest.java
+++ b/rt/transports/jms/src/test/java/org/apache/cxf/transport/jms/JMSConfigFactoryTest.java
@@ -79,4 +79,12 @@ public class JMSConfigFactoryTest extends AbstractJMSTester {
         Assert.assertEquals("java:/comp/TransactionManager", endpoint.getJndiTransactionManagerName());
         // TODO Check JNDI lookup
     }
+    
+    @Test
+    public void testConcurrentConsumers() {
+        JMSEndpoint endpoint = new JMSEndpoint("jms:queue:Foo.Bar?concurrentConsumers=4");
+        JMSConfiguration jmsConfig = JMSConfigFactory.createFromEndpoint(bus, endpoint);
+        Assert.assertEquals(4, jmsConfig.getConcurrentConsumers());
+
+    }
 }


Mime
View raw message