camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bvah...@apache.org
Subject svn commit: r1358539 - in /camel/trunk: camel-core/src/test/java/org/apache/camel/processor/enricher/ components/camel-bindy/src/main/java/org/apache/camel/dataformat/bindy/ components/camel-core-xml/src/main/java/org/apache/camel/core/xml/ components/...
Date Sat, 07 Jul 2012 10:55:41 GMT
Author: bvahdat
Date: Sat Jul  7 10:55:40 2012
New Revision: 1358539

URL: http://svn.apache.org/viewvc?rev=1358539&view=rev
Log:
Polished and fixed one CS error.

Modified:
    camel/trunk/camel-core/src/test/java/org/apache/camel/processor/enricher/PollEnricherTest.java
    camel/trunk/components/camel-bindy/src/main/java/org/apache/camel/dataformat/bindy/BindyAbstractFactory.java
    camel/trunk/components/camel-core-xml/src/main/java/org/apache/camel/core/xml/AbstractCamelContextFactoryBean.java
    camel/trunk/components/camel-jms/src/main/java/org/apache/camel/component/jms/JmsEndpoint.java
    camel/trunk/components/camel-lucene/src/main/java/org/apache/camel/component/lucene/LuceneSearcher.java
    camel/trunk/components/camel-soap/src/test/java/org/apache/camel/dataformat/soap/TestUtil.java
    camel/trunk/platforms/karaf/commands/src/main/java/org/apache/camel/karaf/commands/ContextList.java

Modified: camel/trunk/camel-core/src/test/java/org/apache/camel/processor/enricher/PollEnricherTest.java
URL: http://svn.apache.org/viewvc/camel/trunk/camel-core/src/test/java/org/apache/camel/processor/enricher/PollEnricherTest.java?rev=1358539&r1=1358538&r2=1358539&view=diff
==============================================================================
--- camel/trunk/camel-core/src/test/java/org/apache/camel/processor/enricher/PollEnricherTest.java
(original)
+++ camel/trunk/camel-core/src/test/java/org/apache/camel/processor/enricher/PollEnricherTest.java
Sat Jul  7 10:55:40 2012
@@ -16,7 +16,6 @@
  */
 package org.apache.camel.processor.enricher;
 
-import java.util.ArrayList;
 import java.util.List;
 
 import org.apache.camel.ContextTestSupport;
@@ -129,7 +128,7 @@ public class PollEnricherTest extends Co
         template.sendBody("seda:foo5", "msg3");
         template.sendBody("seda:foo5", "msg4");
 
-        List<Exchange> polledExchanges = mock.getExchanges().get(0).getIn().getBody(List.class);
+        List<?> polledExchanges = mock.getExchanges().get(0).getIn().getBody(List.class);
         assertEquals(2, polledExchanges.size());
 
         mock.expectedHeaderReceived(Exchange.TO_ENDPOINT, "seda://foo5");
@@ -147,7 +146,7 @@ public class PollEnricherTest extends Co
 
         Thread.sleep(500);
 
-        List<Exchange> polledExchanges = mock.getExchanges().get(0).getIn().getBody(List.class);
+        List<?> polledExchanges = mock.getExchanges().get(0).getIn().getBody(List.class);
         assertEquals(4, polledExchanges.size());
 
         mock.expectedHeaderReceived(Exchange.TO_ENDPOINT, "seda://foo6");

Modified: camel/trunk/components/camel-bindy/src/main/java/org/apache/camel/dataformat/bindy/BindyAbstractFactory.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-bindy/src/main/java/org/apache/camel/dataformat/bindy/BindyAbstractFactory.java?rev=1358539&r1=1358538&r2=1358539&view=diff
==============================================================================
--- camel/trunk/components/camel-bindy/src/main/java/org/apache/camel/dataformat/bindy/BindyAbstractFactory.java
(original)
+++ camel/trunk/components/camel-bindy/src/main/java/org/apache/camel/dataformat/bindy/BindyAbstractFactory.java
Sat Jul  7 10:55:40 2012
@@ -63,7 +63,7 @@ public abstract class BindyAbstractFacto
         this.type = type;
 
         if (LOG.isDebugEnabled()) {
-                LOG.debug("Class name: {}", type.getName());
+            LOG.debug("Class name: {}", type.getName());
         }
 
         initModel();

Modified: camel/trunk/components/camel-core-xml/src/main/java/org/apache/camel/core/xml/AbstractCamelContextFactoryBean.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-core-xml/src/main/java/org/apache/camel/core/xml/AbstractCamelContextFactoryBean.java?rev=1358539&r1=1358538&r2=1358539&view=diff
==============================================================================
--- camel/trunk/components/camel-core-xml/src/main/java/org/apache/camel/core/xml/AbstractCamelContextFactoryBean.java
(original)
+++ camel/trunk/components/camel-core-xml/src/main/java/org/apache/camel/core/xml/AbstractCamelContextFactoryBean.java
Sat Jul  7 10:55:40 2012
@@ -343,7 +343,7 @@ public abstract class AbstractCamelConte
             agent.setRegisterAlways(CamelContextHelper.parseBoolean(getContext(), camelJMXAgent.getRegisterAlways()));
             agent.setRegisterNewRoutes(CamelContextHelper.parseBoolean(getContext(), camelJMXAgent.getRegisterNewRoutes()));
 
-            ManagementStrategy managementStrategy = new ManagedManagementStrategy(agent);
+            ManagementStrategy managementStrategy = new ManagedManagementStrategy(getContext(),
agent);
             getContext().setManagementStrategy(managementStrategy);
 
             // clear the existing lifecycle strategies define by the DefaultCamelContext
constructor

Modified: camel/trunk/components/camel-jms/src/main/java/org/apache/camel/component/jms/JmsEndpoint.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-jms/src/main/java/org/apache/camel/component/jms/JmsEndpoint.java?rev=1358539&r1=1358538&r2=1358539&view=diff
==============================================================================
--- camel/trunk/components/camel-jms/src/main/java/org/apache/camel/component/jms/JmsEndpoint.java
(original)
+++ camel/trunk/components/camel-jms/src/main/java/org/apache/camel/component/jms/JmsEndpoint.java
Sat Jul  7 10:55:40 2012
@@ -75,7 +75,6 @@ public class JmsEndpoint extends Default
     private String selector;
     private JmsConfiguration configuration;
     private final AtomicBoolean running = new AtomicBoolean();
-    private volatile boolean destroying;
 
     public JmsEndpoint() {
         this(null, null);
@@ -150,22 +149,9 @@ public class JmsEndpoint extends Default
     }
 
     public JmsConsumer createConsumer(Processor processor) throws Exception {
-        synchronized (this) {
-            while (destroying) {
-                wait();
-            }
-        }
         AbstractMessageListenerContainer listenerContainer = createMessageListenerContainer();
         return createConsumer(processor, listenerContainer);
     }
-    
-    private void destroyMessageListenerContainerInternal(AbstractMessageListenerContainer
listenerContainer) {
-        listenerContainer.destroy();
-        destroying = false;
-        synchronized (this) {
-            notifyAll();
-        }
-    }
 
     public AbstractMessageListenerContainer createMessageListenerContainer() throws Exception
{
         return configuration.createMessageListenerContainer(this);

Modified: camel/trunk/components/camel-lucene/src/main/java/org/apache/camel/component/lucene/LuceneSearcher.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-lucene/src/main/java/org/apache/camel/component/lucene/LuceneSearcher.java?rev=1358539&r1=1358538&r2=1358539&view=diff
==============================================================================
--- camel/trunk/components/camel-lucene/src/main/java/org/apache/camel/component/lucene/LuceneSearcher.java
(original)
+++ camel/trunk/components/camel-lucene/src/main/java/org/apache/camel/component/lucene/LuceneSearcher.java
Sat Jul  7 10:55:40 2012
@@ -43,9 +43,9 @@ public class LuceneSearcher {
 
     public void open(File indexDirectory, Analyzer analyzer) throws IOException {
         if (indexDirectory != null) {
-            indexSearcher = new IndexSearcher(IndexReader.open(new NIOFSDirectory(indexDirectory),
true));
+            indexSearcher = new IndexSearcher(IndexReader.open(new NIOFSDirectory(indexDirectory)));
         } else {
-            indexSearcher = new IndexSearcher(IndexReader.open(new NIOFSDirectory(new File("./indexDirectory")),
true));
+            indexSearcher = new IndexSearcher(IndexReader.open(new NIOFSDirectory(new File("./indexDirectory"))));
         }
         this.analyzer = analyzer;
     }

Modified: camel/trunk/components/camel-soap/src/test/java/org/apache/camel/dataformat/soap/TestUtil.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-soap/src/test/java/org/apache/camel/dataformat/soap/TestUtil.java?rev=1358539&r1=1358538&r2=1358539&view=diff
==============================================================================
--- camel/trunk/components/camel-soap/src/test/java/org/apache/camel/dataformat/soap/TestUtil.java
(original)
+++ camel/trunk/components/camel-soap/src/test/java/org/apache/camel/dataformat/soap/TestUtil.java
Sat Jul  7 10:55:40 2012
@@ -22,7 +22,6 @@ import java.io.InputStream;
 import java.io.InputStreamReader;
 
 import org.apache.camel.util.IOHelper;
-import org.apache.camel.util.ObjectHelper;
 
 public final class TestUtil {
     private TestUtil() {

Modified: camel/trunk/platforms/karaf/commands/src/main/java/org/apache/camel/karaf/commands/ContextList.java
URL: http://svn.apache.org/viewvc/camel/trunk/platforms/karaf/commands/src/main/java/org/apache/camel/karaf/commands/ContextList.java?rev=1358539&r1=1358538&r2=1358539&view=diff
==============================================================================
--- camel/trunk/platforms/karaf/commands/src/main/java/org/apache/camel/karaf/commands/ContextList.java
(original)
+++ camel/trunk/platforms/karaf/commands/src/main/java/org/apache/camel/karaf/commands/ContextList.java
Sat Jul  7 10:55:40 2012
@@ -25,9 +25,6 @@ import org.apache.camel.CamelContext;
 import org.apache.felix.gogo.commands.Command;
 import org.apache.karaf.shell.console.OsgiCommandSupport;
 
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
 /**
  * List the Camel contexts available in the Karaf instance.
  */
@@ -88,7 +85,7 @@ public class ContextList extends OsgiCom
                 maxUptimeLen = java.lang.Math.max(maxUptimeLen, uptime == null ? 0 : uptime.length());
             }
 
-            final Map<String, Integer> retval = new Hashtable(3);
+            final Map<String, Integer> retval = new Hashtable<String, Integer>(3);
             retval.put(NAME_COLUMN_LABEL, maxNameLen);
             retval.put(STATUS_COLUMN_LABEL, maxStatusLen);
             retval.put(UPTIME_COLUMN_LABEL, maxUptimeLen);



Mime
View raw message