2 * Copyright (c) 2023 PANTHEON.tech s.r.o. and others. All rights reserved.
4 * This program and the accompanying materials are made available under the
5 * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6 * and is available at http://www.eclipse.org/legal/epl-v10.html
8 package org.opendaylight.netconf.topology.callhome;
10 import java.net.SocketAddress;
11 import java.security.PublicKey;
14 * Records the status of incoming connections from configured call-home devices.
16 public interface CallHomeStatusRecorder {
19 * Records netconf connection established successfully.
21 * @param id unique client identifier
23 void reportSuccess(String id);
26 * Records client disconnected .
28 * @param id unique client identifier
30 void reportDisconnected(String id);
33 * Records authentication failure for configured client (device).
35 * @param id unique client identifier
37 void reportFailedAuth(String id);
40 * Records NETCONF layer initialization failure for configured client (device).
42 * @param id unique client identifier
44 void reportNetconfFailure(String id);
47 * Records unknown {@link PublicKey} resulting client (device) identification failure.
49 * @param address the remote address the connection was accepted from
50 * @param publicKey {@link PublicKey} used by client for own identification
52 void reportUnknown(SocketAddress address, PublicKey publicKey);
55 * Records any exception causing closure of incoming connection. Mainly for debugging purposes.
57 * @param throwable exception thrown
59 default void onTransportChannelFailure(Throwable throwable) {