From d2fb77cf298e97eeb998bf1a5e00f06431afd3fc Mon Sep 17 00:00:00 2001 From: Kiran Kamineni Date: Tue, 17 Apr 2018 11:49:21 -0700 Subject: Added lock for quorum registration Added lock for quorum registration Removed debug statement Issue-ID: AAF-92 Change-Id: Ib2de5ae7ed31b93b6853c78a70305a401ba3c014 Signed-off-by: Kiran Kamineni --- sms-service/src/quorumclient/quorumclient.go | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'sms-service/src/quorumclient/quorumclient.go') diff --git a/sms-service/src/quorumclient/quorumclient.go b/sms-service/src/quorumclient/quorumclient.go index 7244720..05fc967 100644 --- a/sms-service/src/quorumclient/quorumclient.go +++ b/sms-service/src/quorumclient/quorumclient.go @@ -25,6 +25,7 @@ import ( "log" "net/http" "os" + "path/filepath" smsauth "sms/auth" smslogger "sms/log" "strings" @@ -63,10 +64,11 @@ func loadPGPKeys(prKeyPath string, pbKeyPath string) (string, string, error) { //calls necessary initialization endpoints on the //SMS webservice func main() { - idFilePath := "auth/myid" - pbKeyPath := "auth/pbkey" - prKeyPath := "auth/prkey" - shardPath := "auth/shard" + podName := os.Getenv("HOSTNAME") + idFilePath := filepath.Join("auth", podName, "id") + pbKeyPath := filepath.Join("auth", podName, "pbkey") + prKeyPath := filepath.Join("auth", podName, "prkey") + shardPath := filepath.Join("auth", podName, "shard") smslogger.Init("") smslogger.WriteInfo("Starting Log for Quorum Client") -- cgit 1.2.3-korg