Updated Branches: refs/heads/camel-2.10.x ab8dfa70c -> 83cdfe4ac refs/heads/camel-2.11.x 274d018da -> b5439f06d refs/heads/master c90f92441 -> 17eabf535
CAMEL-6488: camel-netty-http allow to share port in OSGi environment. Work in progress. Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/17eabf53 Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/17eabf53 Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/17eabf53 Branch: refs/heads/master Commit: 17eabf535673b8400f4b46d7a3c37255773a4948 Parents: c90f924 Author: Claus Ibsen <davscl...@apache.org> Authored: Wed Jun 26 09:46:28 2013 +0200 Committer: Claus Ibsen <davscl...@apache.org> Committed: Wed Jun 26 09:46:28 2013 +0200 ---------------------------------------------------------------------- .../component/netty/http/DefaultNettySharedHttpServer.java | 7 +++++++ 1 file changed, 7 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/camel/blob/17eabf53/components/camel-netty-http/src/main/java/org/apache/camel/component/netty/http/DefaultNettySharedHttpServer.java ---------------------------------------------------------------------- diff --git a/components/camel-netty-http/src/main/java/org/apache/camel/component/netty/http/DefaultNettySharedHttpServer.java b/components/camel-netty-http/src/main/java/org/apache/camel/component/netty/http/DefaultNettySharedHttpServer.java index 0917d51..eae6669 100644 --- a/components/camel-netty-http/src/main/java/org/apache/camel/component/netty/http/DefaultNettySharedHttpServer.java +++ b/components/camel-netty-http/src/main/java/org/apache/camel/component/netty/http/DefaultNettySharedHttpServer.java @@ -24,12 +24,16 @@ import org.apache.camel.support.ServiceSupport; import org.apache.camel.util.ObjectHelper; import org.apache.camel.util.ServiceHelper; import org.jboss.netty.channel.ChannelPipelineFactory; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; /** * A default {@link NettySharedHttpServer} to make sharing Netty server in Camel applications easier. */ public class DefaultNettySharedHttpServer extends ServiceSupport implements NettySharedHttpServer { + private static final Logger LOG = LoggerFactory.getLogger(DefaultNettySharedHttpServer.class); + private NettyServerBootstrapConfiguration configuration; private HttpServerConsumerChannelFactory channelFactory; private HttpServerBootstrapFactory bootstrapFactory; @@ -63,6 +67,8 @@ public class DefaultNettySharedHttpServer extends ServiceSupport implements Nett throw new IllegalArgumentException("Port must be configured on NettyServerBootstrapConfiguration " + configuration); } + LOG.info("Starting NettySharedHttpServer using configuration: {} on port: {}", configuration, configuration.getPort()); + // force using tcp as the underlying transport configuration.setProtocol("tcp"); @@ -78,6 +84,7 @@ public class DefaultNettySharedHttpServer extends ServiceSupport implements Nett @Override protected void doStop() throws Exception { + LOG.info("Stopping NettySharedHttpServer using configuration: {} on port: {}", configuration, configuration.getPort()); ServiceHelper.stopServices(bootstrapFactory, channelFactory); } }