diff --git a/services/tunnelbroker/docker-server/contents/server/src/Constants.h b/services/tunnelbroker/docker-server/contents/server/src/Constants.h --- a/services/tunnelbroker/docker-server/contents/server/src/Constants.h +++ b/services/tunnelbroker/docker-server/contents/server/src/Constants.h @@ -12,6 +12,7 @@ const std::string DEVICE_SESSIONS_VERIFICATION_MESSAGES_TABLE_NAME = "tunnelbroker-verification-message"; const std::string DEVICE_PUBLIC_KEY_TABLE_NAME = "tunnelbroker-public-key"; +const std::string MESSAGES_TABLE_NAME = "tunnelbroker-message"; // Sessions const size_t SIGNATURE_REQUEST_LENGTH = 64; diff --git a/services/tunnelbroker/docker-server/contents/server/src/Tools/ConfigManager.h b/services/tunnelbroker/docker-server/contents/server/src/Tools/ConfigManager.h --- a/services/tunnelbroker/docker-server/contents/server/src/Tools/ConfigManager.h +++ b/services/tunnelbroker/docker-server/contents/server/src/Tools/ConfigManager.h @@ -21,6 +21,7 @@ static const std::string OPTION_DYNAMODB_SESSIONS_TABLE; static const std::string OPTION_DYNAMODB_SESSIONS_VERIFICATION_TABLE; static const std::string OPTION_DYNAMODB_SESSIONS_PUBLIC_KEY_TABLE; + static const std::string OPTION_DYNAMODB_MESSAGES_TABLE; static ConfigManager &getInstance(); void load(); diff --git a/services/tunnelbroker/docker-server/contents/server/src/Tools/ConfigManager.cpp b/services/tunnelbroker/docker-server/contents/server/src/Tools/ConfigManager.cpp --- a/services/tunnelbroker/docker-server/contents/server/src/Tools/ConfigManager.cpp +++ b/services/tunnelbroker/docker-server/contents/server/src/Tools/ConfigManager.cpp @@ -20,6 +20,8 @@ "dynamodb.sessions_verification_table_name"; const std::string ConfigManager::OPTION_DYNAMODB_SESSIONS_PUBLIC_KEY_TABLE = "dynamodb.sessions_public_key_table_name"; +const std::string ConfigManager::OPTION_DYNAMODB_MESSAGES_TABLE = + "dynamodb.messages_table_name"; ConfigManager &ConfigManager::getInstance() { static ConfigManager instance; @@ -68,6 +70,11 @@ boost::program_options::value()->default_value( DEVICE_PUBLIC_KEY_TABLE_NAME), "DynamoDB table name for public keys"); + description.add_options()( + this->OPTION_DYNAMODB_MESSAGES_TABLE.c_str(), + boost::program_options::value()->default_value( + MESSAGES_TABLE_NAME), + "DynamoDB table name for messages"); boost::program_options::parsed_options parsedDescription = boost::program_options::parse_config_file(