From fbba01063cf4f79d83d58700f1e19486c8b26f16 Mon Sep 17 00:00:00 2001 From: Anton Tananaev Date: Sat, 23 Feb 2013 19:12:24 +1300 Subject: Merge logging changes --- src/org/traccar/BasePipelineFactory.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/org') diff --git a/src/org/traccar/BasePipelineFactory.java b/src/org/traccar/BasePipelineFactory.java index 71f257541..5bebda925 100644 --- a/src/org/traccar/BasePipelineFactory.java +++ b/src/org/traccar/BasePipelineFactory.java @@ -66,7 +66,8 @@ public abstract class BasePipelineFactory implements ChannelPipelineFactory { MessageEvent event = (MessageEvent) e; StringBuilder msg = new StringBuilder(); - msg.append("[").append(((InetSocketAddress) e.getChannel().getLocalAddress()).getPort()).append(" - "); + msg.append("[").append(((InetSocketAddress) e.getChannel().getLocalAddress()).getPort()); + msg.append((e instanceof DownstreamMessageEvent) ? " -> " : " <- "); msg.append(((InetSocketAddress) event.getRemoteAddress()).getAddress().getHostAddress()).append("]"); // Append hex message @@ -121,4 +122,4 @@ public abstract class BasePipelineFactory implements ChannelPipelineFactory { return pipeline; } -} \ No newline at end of file +} -- cgit v1.2.3