camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a.@apache.org
Subject camel git commit: reduce info logs for atmosphere-websocket and ahc-ws
Date Tue, 11 Nov 2014 11:23:49 GMT
Repository: camel
Updated Branches:
  refs/heads/camel-2.14.x 44f8b71c9 -> 1a56b41d4


reduce info logs for atmosphere-websocket and ahc-ws


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

Branch: refs/heads/camel-2.14.x
Commit: 1a56b41d4491202a10082353e1d8ae0d39cdd60d
Parents: 44f8b71
Author: Akitoshi Yoshida <ay@apache.org>
Authored: Tue Nov 11 12:22:21 2014 +0100
Committer: Akitoshi Yoshida <ay@apache.org>
Committed: Tue Nov 11 12:23:27 2014 +0100

----------------------------------------------------------------------
 .../apache/camel/component/ahc/ws/WsEndpoint.java   | 16 ++++++++--------
 .../atmosphere/websocket/WebsocketHandler.java      | 16 ++++++++--------
 .../atmosphere/websocket/WebsocketProducer.java     |  2 +-
 .../websocket/WebsocketStreamHandler.java           |  8 ++++----
 4 files changed, 21 insertions(+), 21 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/1a56b41d/components/camel-ahc-ws/src/main/java/org/apache/camel/component/ahc/ws/WsEndpoint.java
----------------------------------------------------------------------
diff --git a/components/camel-ahc-ws/src/main/java/org/apache/camel/component/ahc/ws/WsEndpoint.java
b/components/camel-ahc-ws/src/main/java/org/apache/camel/component/ahc/ws/WsEndpoint.java
index d3cd243..589de49 100644
--- a/components/camel-ahc-ws/src/main/java/org/apache/camel/component/ahc/ws/WsEndpoint.java
+++ b/components/camel-ahc-ws/src/main/java/org/apache/camel/component/ahc/ws/WsEndpoint.java
@@ -160,12 +160,12 @@ public class WsEndpoint extends AhcEndpoint {
         
         @Override
         public void onOpen(WebSocket websocket) {
-            LOG.info("websocket opened");
+            LOG.debug("websocket opened");
         }
 
         @Override
         public void onClose(WebSocket websocket) {
-            LOG.info("websocket closed");
+            LOG.debug("websocket closed");
         }
 
         @Override
@@ -175,7 +175,7 @@ public class WsEndpoint extends AhcEndpoint {
 
         @Override
         public void onMessage(byte[] message) {
-            LOG.info("received message --> {}", message);
+            LOG.debug("received message --> {}", message);
             for (WsConsumer consumer : consumers) {
                 consumer.sendMessage(message);
             }
@@ -183,8 +183,8 @@ public class WsEndpoint extends AhcEndpoint {
 
         @Override
         public void onFragment(byte[] fragment, boolean last) {
-            if (LOG.isInfoEnabled()) {
-                LOG.info("received fragment({}) --> {}", last, fragment);
+            if (LOG.isDebugEnabled()) {
+                LOG.debug("received fragment({}) --> {}", last, fragment);
             }
             // for now, construct a memory based stream. In future, we provide a fragmented
stream that can
             // be consumed before the final fragment is added.
@@ -208,7 +208,7 @@ public class WsEndpoint extends AhcEndpoint {
 
         @Override
         public void onMessage(String message) {
-            LOG.info("received message --> {}", message);
+            LOG.debug("received message --> {}", message);
             for (WsConsumer consumer : consumers) {
                 consumer.sendMessage(message);
             }
@@ -216,8 +216,8 @@ public class WsEndpoint extends AhcEndpoint {
 
         @Override
         public void onFragment(String fragment, boolean last) {
-            if (LOG.isInfoEnabled()) {
-                LOG.info("received fragment({}) --> {}", last, fragment);
+            if (LOG.isDebugEnabled()) {
+                LOG.debug("received fragment({}) --> {}", last, fragment);
             }
             // for now, construct a memory based stream. In future, we provide a fragmented
stream that can
             // be consumed before the final fragment is added.

http://git-wip-us.apache.org/repos/asf/camel/blob/1a56b41d/components/camel-atmosphere-websocket/src/main/java/org/apache/camel/component/atmosphere/websocket/WebsocketHandler.java
----------------------------------------------------------------------
diff --git a/components/camel-atmosphere-websocket/src/main/java/org/apache/camel/component/atmosphere/websocket/WebsocketHandler.java
b/components/camel-atmosphere-websocket/src/main/java/org/apache/camel/component/atmosphere/websocket/WebsocketHandler.java
index f0f03fb..fc9e812 100644
--- a/components/camel-atmosphere-websocket/src/main/java/org/apache/camel/component/atmosphere/websocket/WebsocketHandler.java
+++ b/components/camel-atmosphere-websocket/src/main/java/org/apache/camel/component/atmosphere/websocket/WebsocketHandler.java
@@ -40,10 +40,10 @@ public class WebsocketHandler implements WebSocketProtocol {
     
     @Override
     public void onClose(WebSocket webSocket) {
-        LOG.info("closing websocket");
+        LOG.debug("closing websocket");
         store.removeWebSocket(webSocket);
         
-        LOG.info("websocket closed");
+        LOG.debug("websocket closed");
     }
 
     @Override
@@ -53,24 +53,24 @@ public class WebsocketHandler implements WebSocketProtocol {
 
     @Override
     public void onOpen(WebSocket webSocket) {
-        LOG.info("opening websocket");
+        LOG.debug("opening websocket");
         String connectionKey = UUID.randomUUID().toString();
         store.addWebSocket(connectionKey, webSocket);
-        LOG.info("websocket opened");
+        LOG.debug("websocket opened");
     }
 
     @Override
     public List<AtmosphereRequest> onMessage(WebSocket webSocket, String data) {
-        LOG.info("processing text message {}", data);
+        LOG.debug("processing text message {}", data);
         String connectionKey = store.getConnectionKey(webSocket);
         consumer.sendMessage(connectionKey, data);
-        LOG.info("text message sent");
+        LOG.debug("text message sent");
         return null;
     }
     
     @Override
     public List<AtmosphereRequest> onMessage(WebSocket webSocket, byte[] data, int
offset, int length) {
-        LOG.info("processing byte message {}", data);
+        LOG.debug("processing byte message {}", data);
         String connectionKey = store.getConnectionKey(webSocket);
         if (length < data.length) {
             // create a copy that contains the relevant section as camel expects bytes without
offset.
@@ -80,7 +80,7 @@ public class WebsocketHandler implements WebSocketProtocol {
             System.arraycopy(rawdata, offset, data, 0, length);
         }
         consumer.sendMessage(connectionKey, data);
-        LOG.info("byte message sent");
+        LOG.debug("byte message sent");
         return null;
     }
 

http://git-wip-us.apache.org/repos/asf/camel/blob/1a56b41d/components/camel-atmosphere-websocket/src/main/java/org/apache/camel/component/atmosphere/websocket/WebsocketProducer.java
----------------------------------------------------------------------
diff --git a/components/camel-atmosphere-websocket/src/main/java/org/apache/camel/component/atmosphere/websocket/WebsocketProducer.java
b/components/camel-atmosphere-websocket/src/main/java/org/apache/camel/component/atmosphere/websocket/WebsocketProducer.java
index d3e02af..7fda043 100644
--- a/components/camel-atmosphere-websocket/src/main/java/org/apache/camel/component/atmosphere/websocket/WebsocketProducer.java
+++ b/components/camel-atmosphere-websocket/src/main/java/org/apache/camel/component/atmosphere/websocket/WebsocketProducer.java
@@ -51,7 +51,7 @@ public class WebsocketProducer extends DefaultProducer {
         //TODO support binary data
         Object message = in.getBody();
         if (message == null) {
-            LOG.info("Ignoring a null message");
+            LOG.debug("Ignoring a null message");
             return;
         }
         

http://git-wip-us.apache.org/repos/asf/camel/blob/1a56b41d/components/camel-atmosphere-websocket/src/main/java/org/apache/camel/component/atmosphere/websocket/WebsocketStreamHandler.java
----------------------------------------------------------------------
diff --git a/components/camel-atmosphere-websocket/src/main/java/org/apache/camel/component/atmosphere/websocket/WebsocketStreamHandler.java
b/components/camel-atmosphere-websocket/src/main/java/org/apache/camel/component/atmosphere/websocket/WebsocketStreamHandler.java
index cb6b5af..adb6a55 100644
--- a/components/camel-atmosphere-websocket/src/main/java/org/apache/camel/component/atmosphere/websocket/WebsocketStreamHandler.java
+++ b/components/camel-atmosphere-websocket/src/main/java/org/apache/camel/component/atmosphere/websocket/WebsocketStreamHandler.java
@@ -31,19 +31,19 @@ public class WebsocketStreamHandler extends WebsocketHandler implements
WebSocke
 
     @Override
     public List<AtmosphereRequest> onTextStream(WebSocket webSocket, Reader data) {
-        LOG.info("processing reader message {}", data);
+        LOG.debug("processing reader message {}", data);
         String connectionKey = store.getConnectionKey(webSocket);
         consumer.sendMessage(connectionKey, data);
-        LOG.info("reader message sent");
+        LOG.debug("reader message sent");
         return null;
     }
 
     @Override
     public List<AtmosphereRequest> onBinaryStream(WebSocket webSocket, InputStream
data) {
-        LOG.info("processing inputstream message {}", data);
+        LOG.debug("processing inputstream message {}", data);
         String connectionKey = store.getConnectionKey(webSocket);
         consumer.sendMessage(connectionKey, data);
-        LOG.info("reader message sent");
+        LOG.debug("reader message sent");
         return null;
     }
 }


Mime
View raw message