summaryrefslogtreecommitdiffstats
path: root/src/main/java
diff options
context:
space:
mode:
authorSimon Rettberg2023-09-22 15:21:19 +0200
committerSimon Rettberg2023-09-22 15:21:19 +0200
commitf1d3dac5a363a71512c7a84943eb26f30e0b96de (patch)
treeb0df5cdaa7a35a55be561bf0e55eff4013931fc9 /src/main/java
parentmaven: Don't uses brainfucked open intervals for version ranges (diff)
downloadmaster-sync-shared-f1d3dac5a363a71512c7a84943eb26f30e0b96de.tar.gz
master-sync-shared-f1d3dac5a363a71512c7a84943eb26f30e0b96de.tar.xz
master-sync-shared-f1d3dac5a363a71512c7a84943eb26f30e0b96de.zip
[thrift] Add getter for sat ssl context
Diffstat (limited to 'src/main/java')
-rw-r--r--src/main/java/org/openslx/thrifthelper/ThriftManager.java10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/main/java/org/openslx/thrifthelper/ThriftManager.java b/src/main/java/org/openslx/thrifthelper/ThriftManager.java
index 4971b97..07256b2 100644
--- a/src/main/java/org/openslx/thrifthelper/ThriftManager.java
+++ b/src/main/java/org/openslx/thrifthelper/ThriftManager.java
@@ -55,6 +55,7 @@ public class ThriftManager<T>
private static ErrorCallback satErrorCallback = null;
private static ErrorCallback masterErrorCallback = null;
+ private static SSLContext satSslContext = null;
/**
* Sets the address of the master server
@@ -106,6 +107,7 @@ public class ThriftManager<T>
LOGGER.error( "Given address is empty." );
return false;
}
+ satSslContext = ctx;
// finally set it
satelliteManager = new ThriftManager<SatelliteServer.Iface>( SatelliteServer.Iface.class, SatelliteServer.Client.class,
new WantClientCallback<SatelliteServer.Client>() {
@@ -123,6 +125,14 @@ public class ThriftManager<T>
} );
return true;
}
+
+ /**
+ * Get the SSL context used for talking to the satellite server (if any)
+ */
+ public static SSLContext getSatelliteSslContext()
+ {
+ return satSslContext;
+ }
/**
* Returns the singleton client of the thrift connection to the satellite