- private static final Logger LOG = LoggerFactory.getLogger(RpcManager.class);
-
- private SchemaContext schemaContext;
- private final ClusterWrapper clusterWrapper;
- private ActorRef rpcBroker;
- private ActorRef rpcRegistry;
- private final Broker.ProviderSession brokerSession;
- private RpcListener rpcListener;
- private RoutedRpcListener routeChangeListener;
- private RemoteRpcImplementation rpcImplementation;
- private final RpcProvisionRegistry rpcProvisionRegistry;
-
- private RpcManager(ClusterWrapper clusterWrapper, SchemaContext schemaContext,
- Broker.ProviderSession brokerSession, RpcProvisionRegistry rpcProvisionRegistry) {
- this.clusterWrapper = clusterWrapper;
- this.schemaContext = schemaContext;
- this.brokerSession = brokerSession;
- this.rpcProvisionRegistry = rpcProvisionRegistry;
-
- createRpcActors();
- startListeners();
- }
-
-
- public static Props props(final ClusterWrapper clusterWrapper, final SchemaContext schemaContext,
- final Broker.ProviderSession brokerSession, final RpcProvisionRegistry rpcProvisionRegistry) {
- return Props.create(new Creator<RpcManager>() {
- @Override
- public RpcManager create() throws Exception {
- return new RpcManager(clusterWrapper, schemaContext, brokerSession, rpcProvisionRegistry);
+ private static final Logger LOG = LoggerFactory.getLogger(RpcManager.class);
+
+ private SchemaContext schemaContext;
+ private ActorRef rpcBroker;
+ private ActorRef rpcRegistry;
+ private final RemoteRpcProviderConfig config;
+ private RpcListener rpcListener;
+ private RoutedRpcListener routeChangeListener;
+ private RemoteRpcImplementation rpcImplementation;
+ private final DOMRpcProviderService rpcProvisionRegistry;
+ private final DOMRpcService rpcServices;
+
+ private RpcManager(final SchemaContext schemaContext,
+ final DOMRpcProviderService rpcProvisionRegistry,
+ final DOMRpcService rpcSevices) {
+ this.schemaContext = schemaContext;
+ this.rpcProvisionRegistry = rpcProvisionRegistry;
+ rpcServices = rpcSevices;
+ config = new RemoteRpcProviderConfig(getContext().system().settings().config());
+
+ createRpcActors();
+ startListeners();
+ }
+
+
+ public static Props props(final SchemaContext schemaContext,
+ final DOMRpcProviderService rpcProvisionRegistry, final DOMRpcService rpcServices) {
+ Preconditions.checkNotNull(schemaContext, "SchemaContext can not be null!");
+ Preconditions.checkNotNull(rpcProvisionRegistry, "RpcProviderService can not be null!");
+ Preconditions.checkNotNull(rpcServices, "RpcService can not be null!");
+ return Props.create(RpcManager.class, schemaContext, rpcProvisionRegistry, rpcServices);