From 85547f845caad8715a4c3418af11c96c352c643a Mon Sep 17 00:00:00 2001 From: Björn Hagemeister Date: Thu, 16 Oct 2014 15:36:11 +0200 Subject: Implemented --submitkey command line option. --- .../satellitedaemon/filetransfer/ThriftConnection.java | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'src/main/java/org/openslx/satellitedaemon/filetransfer/ThriftConnection.java') 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; + } + } } -- cgit v1.2.3-55-g7522