From: Tom Pantelis Date: Mon, 28 Jan 2019 16:45:00 +0000 (-0500) Subject: Move BP xml files to standard OSGI-INF/blueprint X-Git-Tag: release/neon~8 X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=commitdiff_plain;h=76c7d1c35087b26fc6c48f4aadce4039b43ae708;hp=99ba97d681e448ef23b52b523781faef8809bbe6;p=netconf.git Move BP xml files to standard OSGI-INF/blueprint Change-Id: I879cabdb7591fccfbe22d84cd64d4cdae66a9cc8 Signed-off-by: Tom Pantelis --- diff --git a/netconf/aaa-authn-odl-plugin/src/main/resources/org/opendaylight/blueprint/aaa-authn-netconf.xml b/netconf/aaa-authn-odl-plugin/src/main/resources/OSGI-INF/blueprint/aaa-authn-netconf.xml similarity index 100% rename from netconf/aaa-authn-odl-plugin/src/main/resources/org/opendaylight/blueprint/aaa-authn-netconf.xml rename to netconf/aaa-authn-odl-plugin/src/main/resources/OSGI-INF/blueprint/aaa-authn-netconf.xml diff --git a/netconf/callhome-provider/src/main/resources/org/opendaylight/blueprint/callhome-topology.xml b/netconf/callhome-provider/src/main/resources/OSGI-INF/blueprint/callhome-topology.xml similarity index 100% rename from netconf/callhome-provider/src/main/resources/org/opendaylight/blueprint/callhome-topology.xml rename to netconf/callhome-provider/src/main/resources/OSGI-INF/blueprint/callhome-topology.xml diff --git a/netconf/mdsal-netconf-connector/src/main/resources/org/opendaylight/blueprint/mdsal-netconf-connector.xml b/netconf/mdsal-netconf-connector/src/main/resources/OSGI-INF/blueprint/mdsal-netconf-connector.xml similarity index 100% rename from netconf/mdsal-netconf-connector/src/main/resources/org/opendaylight/blueprint/mdsal-netconf-connector.xml rename to netconf/mdsal-netconf-connector/src/main/resources/OSGI-INF/blueprint/mdsal-netconf-connector.xml diff --git a/netconf/mdsal-netconf-impl/src/main/resources/org/opendaylight/blueprint/mdsal-netconf-impl.xml b/netconf/mdsal-netconf-impl/src/main/resources/OSGI-INF/blueprint/mdsal-netconf-impl.xml similarity index 97% rename from netconf/mdsal-netconf-impl/src/main/resources/org/opendaylight/blueprint/mdsal-netconf-impl.xml rename to netconf/mdsal-netconf-impl/src/main/resources/OSGI-INF/blueprint/mdsal-netconf-impl.xml index 8f41697528..999294f0fb 100755 --- a/netconf/mdsal-netconf-impl/src/main/resources/org/opendaylight/blueprint/mdsal-netconf-impl.xml +++ b/netconf/mdsal-netconf-impl/src/main/resources/OSGI-INF/blueprint/mdsal-netconf-impl.xml @@ -70,7 +70,7 @@ + class="org.opendaylight.netconf.impl.ServerChannelInitializer"> diff --git a/netconf/mdsal-netconf-monitoring/src/main/resources/org/opendaylight/blueprint/mdsal-netconf-monitoring.xml b/netconf/mdsal-netconf-monitoring/src/main/resources/OSGI-INF/blueprint/mdsal-netconf-monitoring.xml similarity index 100% rename from netconf/mdsal-netconf-monitoring/src/main/resources/org/opendaylight/blueprint/mdsal-netconf-monitoring.xml rename to netconf/mdsal-netconf-monitoring/src/main/resources/OSGI-INF/blueprint/mdsal-netconf-monitoring.xml diff --git a/netconf/mdsal-netconf-notification/src/main/resources/org/opendaylight/blueprint/mdsal-netconf-notification.xml b/netconf/mdsal-netconf-notification/src/main/resources/OSGI-INF/blueprint/mdsal-netconf-notification.xml similarity index 100% rename from netconf/mdsal-netconf-notification/src/main/resources/org/opendaylight/blueprint/mdsal-netconf-notification.xml rename to netconf/mdsal-netconf-notification/src/main/resources/OSGI-INF/blueprint/mdsal-netconf-notification.xml diff --git a/netconf/mdsal-netconf-ssh/src/main/resources/org/opendaylight/blueprint/netconf-ssh.xml b/netconf/mdsal-netconf-ssh/src/main/resources/OSGI-INF/blueprint/netconf-ssh.xml similarity index 100% rename from netconf/mdsal-netconf-ssh/src/main/resources/org/opendaylight/blueprint/netconf-ssh.xml rename to netconf/mdsal-netconf-ssh/src/main/resources/OSGI-INF/blueprint/netconf-ssh.xml diff --git a/netconf/mdsal-netconf-tcp/src/main/resources/org/opendaylight/blueprint/netconf-tcp.xml b/netconf/mdsal-netconf-tcp/src/main/resources/OSGI-INF/blueprint/netconf-tcp.xml similarity index 100% rename from netconf/mdsal-netconf-tcp/src/main/resources/org/opendaylight/blueprint/netconf-tcp.xml rename to netconf/mdsal-netconf-tcp/src/main/resources/OSGI-INF/blueprint/netconf-tcp.xml diff --git a/netconf/mdsal-netconf-yang-library/src/main/resources/org/opendaylight/blueprint/mdsal-netconf-yang-library.xml b/netconf/mdsal-netconf-yang-library/src/main/resources/OSGI-INF/blueprint/mdsal-netconf-yang-library.xml similarity index 100% rename from netconf/mdsal-netconf-yang-library/src/main/resources/org/opendaylight/blueprint/mdsal-netconf-yang-library.xml rename to netconf/mdsal-netconf-yang-library/src/main/resources/OSGI-INF/blueprint/mdsal-netconf-yang-library.xml diff --git a/netconf/messagebus-netconf/src/main/resources/org/opendaylight/blueprint/messagebus-netconf.xml b/netconf/messagebus-netconf/src/main/resources/OSGI-INF/blueprint/messagebus-netconf.xml similarity index 100% rename from netconf/messagebus-netconf/src/main/resources/org/opendaylight/blueprint/messagebus-netconf.xml rename to netconf/messagebus-netconf/src/main/resources/OSGI-INF/blueprint/messagebus-netconf.xml diff --git a/netconf/netconf-client/src/main/resources/org/opendaylight/blueprint/netconf-client.xml b/netconf/netconf-client/src/main/resources/OSGI-INF/blueprint/netconf-client.xml similarity index 100% rename from netconf/netconf-client/src/main/resources/org/opendaylight/blueprint/netconf-client.xml rename to netconf/netconf-client/src/main/resources/OSGI-INF/blueprint/netconf-client.xml diff --git a/netconf/netconf-config/pom.xml b/netconf/netconf-config/pom.xml index 6f2643e929..b67a2977fd 100644 --- a/netconf/netconf-config/pom.xml +++ b/netconf/netconf-config/pom.xml @@ -21,24 +21,4 @@ 1.6.0-SNAPSHOT Configuration files for netconf bundle - - - - - org.apache.felix - maven-bundle-plugin - true - - - ${project.artifactId} - - org.opendaylight.controller.config.threadpool.util, - org.opendaylight.controller.config.threadpool, - * - - - - - - diff --git a/netconf/netconf-config/src/main/resources/org/opendaylight/blueprint/netconf-config.xml b/netconf/netconf-config/src/main/resources/OSGI-INF/blueprint/netconf-config.xml similarity index 100% rename from netconf/netconf-config/src/main/resources/org/opendaylight/blueprint/netconf-config.xml rename to netconf/netconf-config/src/main/resources/OSGI-INF/blueprint/netconf-config.xml diff --git a/netconf/netconf-console/src/main/resources/org/opendaylight/blueprint/netconf-command.xml b/netconf/netconf-console/src/main/resources/OSGI-INF/blueprint/netconf-command.xml similarity index 100% rename from netconf/netconf-console/src/main/resources/org/opendaylight/blueprint/netconf-command.xml rename to netconf/netconf-console/src/main/resources/OSGI-INF/blueprint/netconf-command.xml diff --git a/netconf/netconf-impl/src/main/java/org/opendaylight/netconf/impl/NetconfServerDispatcherImpl.java b/netconf/netconf-impl/src/main/java/org/opendaylight/netconf/impl/NetconfServerDispatcherImpl.java index 67fd0208f8..e740655069 100644 --- a/netconf/netconf-impl/src/main/java/org/opendaylight/netconf/impl/NetconfServerDispatcherImpl.java +++ b/netconf/netconf-impl/src/main/java/org/opendaylight/netconf/impl/NetconfServerDispatcherImpl.java @@ -7,16 +7,12 @@ */ package org.opendaylight.netconf.impl; -import io.netty.channel.Channel; import io.netty.channel.ChannelFuture; import io.netty.channel.EventLoopGroup; import io.netty.channel.local.LocalAddress; import io.netty.channel.local.LocalServerChannel; -import io.netty.util.concurrent.Promise; import java.net.InetSocketAddress; import org.opendaylight.netconf.api.NetconfServerDispatcher; -import org.opendaylight.netconf.impl.util.DeserializerExceptionHandler; -import org.opendaylight.netconf.nettyutil.AbstractChannelInitializer; import org.opendaylight.netconf.nettyutil.AbstractNetconfDispatcher; public class NetconfServerDispatcherImpl extends AbstractNetconfDispatcher { - - public static final String DESERIALIZER_EX_HANDLER_KEY = "deserializerExHandler"; - - private final NetconfServerSessionNegotiatorFactory negotiatorFactory; - - - public ServerChannelInitializer(NetconfServerSessionNegotiatorFactory negotiatorFactory) { - this.negotiatorFactory = negotiatorFactory; - - } - - @Override - protected void initializeMessageDecoder(Channel ch) { - super.initializeMessageDecoder(ch); - ch.pipeline().addLast(DESERIALIZER_EX_HANDLER_KEY, new DeserializerExceptionHandler()); - } - - @Override - protected void initializeSessionNegotiator(Channel ch, Promise promise) { - ch.pipeline().addAfter(DESERIALIZER_EX_HANDLER_KEY, AbstractChannelInitializer.NETCONF_SESSION_NEGOTIATOR, - negotiatorFactory.getSessionNegotiator(null, ch, promise)); - } - } } diff --git a/netconf/netconf-impl/src/main/java/org/opendaylight/netconf/impl/ServerChannelInitializer.java b/netconf/netconf-impl/src/main/java/org/opendaylight/netconf/impl/ServerChannelInitializer.java new file mode 100644 index 0000000000..df39613f8a --- /dev/null +++ b/netconf/netconf-impl/src/main/java/org/opendaylight/netconf/impl/ServerChannelInitializer.java @@ -0,0 +1,38 @@ +/* + * Copyright (c) 2013 Cisco Systems, Inc and others. All rights reserved. + * + * This program and the accompanying materials are made available under the + * terms of the Eclipse Public License v1.0 which accompanies this distribution, + * and is available at http://www.eclipse.org/legal/epl-v10.html + */ +package org.opendaylight.netconf.impl; + +import io.netty.channel.Channel; +import io.netty.util.concurrent.Promise; +import org.opendaylight.netconf.impl.util.DeserializerExceptionHandler; +import org.opendaylight.netconf.nettyutil.AbstractChannelInitializer; + +public class ServerChannelInitializer extends AbstractChannelInitializer { + + public static final String DESERIALIZER_EX_HANDLER_KEY = "deserializerExHandler"; + + private final NetconfServerSessionNegotiatorFactory negotiatorFactory; + + + public ServerChannelInitializer(NetconfServerSessionNegotiatorFactory negotiatorFactory) { + this.negotiatorFactory = negotiatorFactory; + + } + + @Override + protected void initializeMessageDecoder(Channel ch) { + super.initializeMessageDecoder(ch); + ch.pipeline().addLast(DESERIALIZER_EX_HANDLER_KEY, new DeserializerExceptionHandler()); + } + + @Override + protected void initializeSessionNegotiator(Channel ch, Promise promise) { + ch.pipeline().addAfter(DESERIALIZER_EX_HANDLER_KEY, AbstractChannelInitializer.NETCONF_SESSION_NEGOTIATOR, + negotiatorFactory.getSessionNegotiator(null, ch, promise)); + } +} diff --git a/netconf/netconf-impl/src/test/java/org/opendaylight/netconf/impl/ConcurrentClientsTest.java b/netconf/netconf-impl/src/test/java/org/opendaylight/netconf/impl/ConcurrentClientsTest.java index bd9eb070d1..a1fac6bdc5 100644 --- a/netconf/netconf-impl/src/test/java/org/opendaylight/netconf/impl/ConcurrentClientsTest.java +++ b/netconf/netconf-impl/src/test/java/org/opendaylight/netconf/impl/ConcurrentClientsTest.java @@ -171,8 +171,8 @@ public class ConcurrentClientsTest { .setBaseCapabilities(serverCaps) .build(); - NetconfServerDispatcherImpl.ServerChannelInitializer serverChannelInitializer = - new NetconfServerDispatcherImpl.ServerChannelInitializer(serverNegotiatorFactory); + ServerChannelInitializer serverChannelInitializer = + new ServerChannelInitializer(serverNegotiatorFactory); final NetconfServerDispatcherImpl dispatch = new NetconfServerDispatcherImpl(serverChannelInitializer, nettyGroup, nettyGroup); diff --git a/netconf/netconf-impl/src/test/java/org/opendaylight/netconf/impl/NetconfDispatcherImplTest.java b/netconf/netconf-impl/src/test/java/org/opendaylight/netconf/impl/NetconfDispatcherImplTest.java index c24aaf8cd5..2a1540d7d1 100644 --- a/netconf/netconf-impl/src/test/java/org/opendaylight/netconf/impl/NetconfDispatcherImplTest.java +++ b/netconf/netconf-impl/src/test/java/org/opendaylight/netconf/impl/NetconfDispatcherImplTest.java @@ -43,8 +43,8 @@ public class NetconfDispatcherImplTest { .setConnectionTimeoutMillis(5000) .build(); - NetconfServerDispatcherImpl.ServerChannelInitializer serverChannelInitializer = - new NetconfServerDispatcherImpl.ServerChannelInitializer(serverNegotiatorFactory); + ServerChannelInitializer serverChannelInitializer = + new ServerChannelInitializer(serverNegotiatorFactory); dispatch = new NetconfServerDispatcherImpl( serverChannelInitializer, nettyGroup, nettyGroup); diff --git a/netconf/netconf-topology-config/src/main/resources/org/opendaylight/blueprint/netconf-topology.xml b/netconf/netconf-topology-config/src/main/resources/OSGI-INF/blueprint/netconf-topology.xml similarity index 100% rename from netconf/netconf-topology-config/src/main/resources/org/opendaylight/blueprint/netconf-topology.xml rename to netconf/netconf-topology-config/src/main/resources/OSGI-INF/blueprint/netconf-topology.xml diff --git a/netconf/netconf-topology-singleton/src/main/resources/org/opendaylight/blueprint/netconf-topology-singleton.xml b/netconf/netconf-topology-singleton/src/main/resources/OSGI-INF/blueprint/netconf-topology-singleton.xml similarity index 100% rename from netconf/netconf-topology-singleton/src/main/resources/org/opendaylight/blueprint/netconf-topology-singleton.xml rename to netconf/netconf-topology-singleton/src/main/resources/OSGI-INF/blueprint/netconf-topology-singleton.xml diff --git a/netconf/netconf-util/src/main/resources/org/opendaylight/blueprint/netconf-util-blueprint.xml b/netconf/netconf-util/src/main/resources/OSGI-INF/blueprint/netconf-util-blueprint.xml similarity index 91% rename from netconf/netconf-util/src/main/resources/org/opendaylight/blueprint/netconf-util-blueprint.xml rename to netconf/netconf-util/src/main/resources/OSGI-INF/blueprint/netconf-util-blueprint.xml index 99cab21ca1..3539c4e47b 100644 --- a/netconf/netconf-util/src/main/resources/org/opendaylight/blueprint/netconf-util-blueprint.xml +++ b/netconf/netconf-util/src/main/resources/OSGI-INF/blueprint/netconf-util-blueprint.xml @@ -7,9 +7,7 @@ and is available at http://www.eclipse.org/legal/epl-v10.html --> + xmlns:cm="http://aries.apache.org/blueprint/xmlns/blueprint-cm/v1.1.0"> diff --git a/netconf/tools/netconf-testtool/src/main/java/org/opendaylight/netconf/test/tool/NetconfDeviceSimulator.java b/netconf/tools/netconf-testtool/src/main/java/org/opendaylight/netconf/test/tool/NetconfDeviceSimulator.java index 893582f433..321b202604 100644 --- a/netconf/tools/netconf-testtool/src/main/java/org/opendaylight/netconf/test/tool/NetconfDeviceSimulator.java +++ b/netconf/tools/netconf-testtool/src/main/java/org/opendaylight/netconf/test/tool/NetconfDeviceSimulator.java @@ -46,6 +46,7 @@ import org.opendaylight.netconf.api.capability.YangModuleCapability; import org.opendaylight.netconf.api.monitoring.NetconfMonitoringService; import org.opendaylight.netconf.impl.NetconfServerDispatcherImpl; import org.opendaylight.netconf.impl.NetconfServerSessionNegotiatorFactory; +import org.opendaylight.netconf.impl.ServerChannelInitializer; import org.opendaylight.netconf.impl.SessionIdProvider; import org.opendaylight.netconf.impl.osgi.AggregatedNetconfOperationServiceFactory; import org.opendaylight.netconf.mapping.api.NetconfOperationServiceFactory; @@ -128,8 +129,8 @@ public class NetconfDeviceSimulator implements Closeable { configuration.getGenerateConfigsTimeout(), monitoringService1, serverCapabilities); - final NetconfServerDispatcherImpl.ServerChannelInitializer serverChannelInitializer = - new NetconfServerDispatcherImpl.ServerChannelInitializer(serverNegotiatorFactory); + final ServerChannelInitializer serverChannelInitializer = + new ServerChannelInitializer(serverNegotiatorFactory); return new NetconfServerDispatcherImpl(serverChannelInitializer, nettyThreadgroup, nettyThreadgroup); } diff --git a/netconf/yanglib/src/main/resources/org/opendaylight/blueprint/yanglib.xml b/netconf/yanglib/src/main/resources/OSGI-INF/blueprint/yanglib.xml similarity index 100% rename from netconf/yanglib/src/main/resources/org/opendaylight/blueprint/yanglib.xml rename to netconf/yanglib/src/main/resources/OSGI-INF/blueprint/yanglib.xml diff --git a/restconf/restconf-nb-bierman02-auth/src/main/resources/org/opendaylight/blueprint/bierman02-auth.xml b/restconf/restconf-nb-bierman02-auth/src/main/resources/OSGI-INF/blueprint/bierman02-auth.xml similarity index 100% rename from restconf/restconf-nb-bierman02-auth/src/main/resources/org/opendaylight/blueprint/bierman02-auth.xml rename to restconf/restconf-nb-bierman02-auth/src/main/resources/OSGI-INF/blueprint/bierman02-auth.xml diff --git a/restconf/restconf-nb-bierman02-noauth/src/main/resources/org/opendaylight/blueprint/bierman02-noauth.xml b/restconf/restconf-nb-bierman02-noauth/src/main/resources/OSGI-INF/blueprint/bierman02-noauth.xml similarity index 100% rename from restconf/restconf-nb-bierman02-noauth/src/main/resources/org/opendaylight/blueprint/bierman02-noauth.xml rename to restconf/restconf-nb-bierman02-noauth/src/main/resources/OSGI-INF/blueprint/bierman02-noauth.xml diff --git a/restconf/restconf-nb-bierman02/src/main/resources/org/opendaylight/blueprint/restconf-config.xml b/restconf/restconf-nb-bierman02/src/main/resources/OSGI-INF/blueprint/restconf-config.xml similarity index 100% rename from restconf/restconf-nb-bierman02/src/main/resources/org/opendaylight/blueprint/restconf-config.xml rename to restconf/restconf-nb-bierman02/src/main/resources/OSGI-INF/blueprint/restconf-config.xml diff --git a/restconf/restconf-nb-rfc8040/src/main/resources/org/opendaylight/blueprint/restconf-bp.xml b/restconf/restconf-nb-rfc8040/src/main/resources/OSGI-INF/blueprint/restconf-bp.xml similarity index 100% rename from restconf/restconf-nb-rfc8040/src/main/resources/org/opendaylight/blueprint/restconf-bp.xml rename to restconf/restconf-nb-rfc8040/src/main/resources/OSGI-INF/blueprint/restconf-bp.xml diff --git a/restconf/sal-rest-docgen/src/main/resources/org/opendaylight/blueprint/blueprint.xml b/restconf/sal-rest-docgen/src/main/resources/OSGI-INF/blueprint/blueprint.xml similarity index 100% rename from restconf/sal-rest-docgen/src/main/resources/org/opendaylight/blueprint/blueprint.xml rename to restconf/sal-rest-docgen/src/main/resources/OSGI-INF/blueprint/blueprint.xml