16:11:13 2018-05-31T16:08:28,928 | WARN | Blueprint Extender: 2 | Providers | 197 - org.glassfish.jersey.core.jersey-common - 2.25.1 | A provider org.opendaylight.netconf.sal.restconf.impl.ControllerContext registered in SERVER runtime does not implement any provider interfaces applicable in the SERVER runtime. Due to constraint configuration problems the provider org.opendaylight.netconf.sal.restconf.impl.ControllerContext will be ignored.
16:11:13 2018-05-31T16:08:28,929 | WARN | Blueprint Extender: 2 | Providers | 197 - org.glassfish.jersey.core.jersey-common - 2.25.1 | A provider org.opendaylight.netconf.sal.restconf.impl.BrokerFacade registered in SERVER runtime does not implement any provider interfaces applicable in the SERVER runtime. Due to constraint configuration problems the provider org.opendaylight.netconf.sal.restconf.impl.BrokerFacade will be ignored.
We shouldn't return ControllerContext and BrokerFacade as singletons.
Change-Id: I64aa7c6da97fa12f0203b8664d07c1af04f93c6b
Signed-off-by: Tom Pantelis <tompantelis@gmail.com>
import org.opendaylight.netconf.md.sal.rest.schema.SchemaExportContentYangBodyWriter;
import org.opendaylight.netconf.md.sal.rest.schema.SchemaExportContentYinBodyWriter;
import org.opendaylight.netconf.md.sal.rest.schema.SchemaRetrievalServiceImpl;
import org.opendaylight.netconf.md.sal.rest.schema.SchemaExportContentYangBodyWriter;
import org.opendaylight.netconf.md.sal.rest.schema.SchemaExportContentYinBodyWriter;
import org.opendaylight.netconf.md.sal.rest.schema.SchemaRetrievalServiceImpl;
-import org.opendaylight.netconf.sal.restconf.impl.BrokerFacade;
import org.opendaylight.netconf.sal.restconf.impl.ControllerContext;
import org.opendaylight.netconf.sal.restconf.impl.StatisticsRestconfServiceWrapper;
public class RestconfApplication extends Application {
private final ControllerContext controllerContext;
import org.opendaylight.netconf.sal.restconf.impl.ControllerContext;
import org.opendaylight.netconf.sal.restconf.impl.StatisticsRestconfServiceWrapper;
public class RestconfApplication extends Application {
private final ControllerContext controllerContext;
- private final BrokerFacade brokerFacade;
private final StatisticsRestconfServiceWrapper statsServiceWrapper;
private final StatisticsRestconfServiceWrapper statsServiceWrapper;
- public RestconfApplication(ControllerContext controllerContext, BrokerFacade brokerFacade,
+ public RestconfApplication(ControllerContext controllerContext,
StatisticsRestconfServiceWrapper statsServiceWrapper) {
this.controllerContext = controllerContext;
StatisticsRestconfServiceWrapper statsServiceWrapper) {
this.controllerContext = controllerContext;
- this.brokerFacade = brokerFacade;
this.statsServiceWrapper = statsServiceWrapper;
}
this.statsServiceWrapper = statsServiceWrapper;
}
public Set<Object> getSingletons() {
final Set<Object> singletons = new HashSet<>();
final SchemaRetrievalServiceImpl schemaRetrieval = new SchemaRetrievalServiceImpl(controllerContext);
public Set<Object> getSingletons() {
final Set<Object> singletons = new HashSet<>();
final SchemaRetrievalServiceImpl schemaRetrieval = new SchemaRetrievalServiceImpl(controllerContext);
- singletons.add(controllerContext);
- singletons.add(brokerFacade);
singletons.add(schemaRetrieval);
singletons.add(new RestconfCompositeWrapper(statsServiceWrapper, schemaRetrieval));
singletons.add(new RestconfDocumentedExceptionMapper(controllerContext));
singletons.add(schemaRetrieval);
singletons.add(new RestconfCompositeWrapper(statsServiceWrapper, schemaRetrieval));
singletons.add(new RestconfDocumentedExceptionMapper(controllerContext));
<bean id="restconfApplication" class="org.opendaylight.netconf.sal.rest.impl.RestconfApplication">
<argument ref="controllerContext"/>
<bean id="restconfApplication" class="org.opendaylight.netconf.sal.rest.impl.RestconfApplication">
<argument ref="controllerContext"/>
- <argument ref="brokerFacade"/>
<argument ref="statsServiceWrapper"/>
</bean>
<argument ref="statsServiceWrapper"/>
</bean>