Improve future result access 39/110339/2
authorRobert Varga <robert.varga@pantheon.tech>
Sun, 25 Feb 2024 10:47:46 +0000 (11:47 +0100)
committerRobert Varga <robert.varga@pantheon.tech>
Sun, 25 Feb 2024 11:43:10 +0000 (12:43 +0100)
commite91ff2c6178d04b213fc2d7f26ec976d8f91f58d
treecf745b45adb8fb5650058035c1f2cf69bf432328
parente77f823bc23d00243eb68504d4b9e30254447dfe
Improve future result access

When the future completes, just look at it cause(), as that will be null
for success. This slightly improve the performance in the case of a
failure.

Change-Id: Ieb1aa02e4aa7b86f35a6b6de8c7129f8cc048385
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
protocol/netconf-client/src/main/java/org/opendaylight/netconf/client/NetconfClientSessionNegotiator.java
protocol/netconf-server/src/main/java/org/opendaylight/netconf/server/SendErrorExceptionUtil.java
transport/transport-tcp/src/main/java/org/opendaylight/netconf/transport/tcp/TCPClient.java
transport/transport-tcp/src/main/java/org/opendaylight/netconf/transport/tcp/TCPServer.java