diff options
author | Björn Hagemeister | 2014-10-16 15:36:11 +0200 |
---|---|---|
committer | Björn Hagemeister | 2014-10-16 15:36:11 +0200 |
commit | 85547f845caad8715a4c3418af11c96c352c643a (patch) | |
tree | 5d29ecbd8384bf97dec306a9d26708b2f7b33245 /src/main/java/org/openslx/satellitedaemon/filetransfer/ThriftConnection.java | |
parent | Added failure information. (diff) | |
download | satellite-daemon-85547f845caad8715a4c3418af11c96c352c643a.tar.gz satellite-daemon-85547f845caad8715a4c3418af11c96c352c643a.tar.xz satellite-daemon-85547f845caad8715a4c3418af11c96c352c643a.zip |
Implemented --submitkey command line option.
Diffstat (limited to 'src/main/java/org/openslx/satellitedaemon/filetransfer/ThriftConnection.java')
-rw-r--r-- | src/main/java/org/openslx/satellitedaemon/filetransfer/ThriftConnection.java | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/main/java/org/openslx/satellitedaemon/filetransfer/ThriftConnection.java b/src/main/java/org/openslx/satellitedaemon/filetransfer/ThriftConnection.java index f716077..723da9b 100644 --- a/src/main/java/org/openslx/satellitedaemon/filetransfer/ThriftConnection.java +++ b/src/main/java/org/openslx/satellitedaemon/filetransfer/ThriftConnection.java @@ -272,4 +272,17 @@ public class ThriftConnection } return false; } + + public static boolean registerSatellite( String organizationId, String ipAddress, String modulus, String exponent ) + { + ImageServer.Client theClient = null; + theClient = getConnection(); + // No check for valid connection. --> not needed, because this satellite is not known yet by master. + try { + return theClient.registerSatellite( organizationId, ipAddress, modulus, exponent ); + } catch ( TException e ) { + log.error( "TException", e ); + return false; + } + } } |