doAuth(clientSession);
break;
case Authenticated:
- doPostAuth(clientSession);
+ CallHomeSessionContext.getFrom(clientSession).openNetconfChannel();
break;
default:
break;
}
LOG.debug("SSH Session {} closed", session);
}
- };
- }
- private static void doPostAuth(final ClientSession session) {
- CallHomeSessionContext.getFrom(session).openNetconfChannel();
- }
-
- private void doAuth(final ClientSession session) {
- try {
- final AuthFuture authFuture = CallHomeSessionContext.getFrom(session).authorize();
- authFuture.addListener(newAuthSshFutureListener(session));
- } catch (IOException e) {
- LOG.error("Failed to authorize session {}", session, e);
- }
+ private void doAuth(final ClientSession session) {
+ try {
+ final AuthFuture authFuture = CallHomeSessionContext.getFrom(session).authorize();
+ authFuture.addListener(newAuthSshFutureListener(session));
+ } catch (IOException e) {
+ LOG.error("Failed to authorize session {}", session, e);
+ }
+ }
+ };
}
private SshFutureListener<AuthFuture> newAuthSshFutureListener(final ClientSession session) {
private AAAEncryptionService encryptionService;
public NetconfTopologySetupBuilder() {
+
}
- private ClusterSingletonServiceProvider getClusterSingletonServiceProvider() {
+ ClusterSingletonServiceProvider getClusterSingletonServiceProvider() {
return clusterSingletonServiceProvider;
}
return this;
}
- private DOMRpcProviderService getRpcProviderRegistry() {
+ DOMRpcProviderService getRpcProviderRegistry() {
return rpcProviderRegistry;
}
return this;
}
- private DOMActionProviderService getActionProviderRegistry() {
+ DOMActionProviderService getActionProviderRegistry() {
return actionProviderRegistry;
}
return this;
}
- private DataBroker getDataBroker() {
+ DataBroker getDataBroker() {
return dataBroker;
}
return this;
}
- private InstanceIdentifier<Node> getInstanceIdentifier() {
+ InstanceIdentifier<Node> getInstanceIdentifier() {
return instanceIdentifier;
}
return new NetconfTopologySetup(this);
}
- private ScheduledExecutorService getKeepaliveExecutor() {
+ ScheduledExecutorService getKeepaliveExecutor() {
return keepaliveExecutor;
}
return this;
}
- private ListeningExecutorService getProcessingExecutor() {
+ ListeningExecutorService getProcessingExecutor() {
return processingExecutor;
}
return this;
}
- private ActorSystem getActorSystem() {
+ ActorSystem getActorSystem() {
return actorSystem;
}
return this;
}
- private EventExecutor getEventExecutor() {
+ EventExecutor getEventExecutor() {
return eventExecutor;
}
return this;
}
- private String getTopologyId() {
+ String getTopologyId() {
return topologyId;
}
return this;
}
- private NetconfClientDispatcher getNetconfClientDispatcher() {
+ NetconfClientDispatcher getNetconfClientDispatcher() {
return netconfClientDispatcher;
}
return this;
}
- private NetconfDevice.SchemaResourcesDTO getSchemaResourceDTO() {
+ NetconfDevice.SchemaResourcesDTO getSchemaResourceDTO() {
return schemaResourceDTO;
}
return this;
}
- private Duration getIdleTimeout() {
+ Duration getIdleTimeout() {
return idleTimeout;
}
return this.privateKeyPassphrase;
}
- private AAAEncryptionService getEncryptionService() {
+ AAAEncryptionService getEncryptionService() {
return this.encryptionService;
}
this(id, netOps, rollbackSupport, true);
}
- public WriteRunningTx(RemoteDeviceId id, NetconfBaseOps netconfOps, boolean rollbackSupport,
- boolean isLockAllowed) {
+ public WriteRunningTx(final RemoteDeviceId id, final NetconfBaseOps netconfOps, final boolean rollbackSupport,
+ final boolean isLockAllowed) {
super(id, netconfOps, rollbackSupport, isLockAllowed);
}
this.defaultOperation = defaultOperation;
}
- private ListenableFuture<DOMRpcResult> execute(final RemoteDeviceId id, final NetconfBaseOps netOps,
- final boolean rollbackSupport) {
+ ListenableFuture<DOMRpcResult> execute(final RemoteDeviceId id, final NetconfBaseOps netOps,
+ final boolean rollbackSupport) {
final NetconfRpcFutureCallback editConfigCallback = new NetconfRpcFutureCallback("Edit running", id);
if (defaultOperation.isPresent()) {
return netOps.editConfigRunning(editConfigCallback, editStructure, defaultOperation.get(),