diff options
Diffstat (limited to 'cpp/src/IceGrid/IceGridRegistry.cpp')
-rw-r--r-- | cpp/src/IceGrid/IceGridRegistry.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/cpp/src/IceGrid/IceGridRegistry.cpp b/cpp/src/IceGrid/IceGridRegistry.cpp index af8320582cf..c3a681e99bd 100644 --- a/cpp/src/IceGrid/IceGridRegistry.cpp +++ b/cpp/src/IceGrid/IceGridRegistry.cpp @@ -66,11 +66,13 @@ bool RegistryService::start(int argc, char* argv[]) { bool nowarn; + bool readonly; IceUtilInternal::Options opts; opts.addOpt("h", "help"); opts.addOpt("v", "version"); opts.addOpt("", "nowarn"); + opts.addOpt("", "readonly"); vector<string> args; try @@ -95,6 +97,7 @@ RegistryService::start(int argc, char* argv[]) return false; } nowarn = opts.isSet("nowarn"); + readonly = opts.isSet("readonly"); if(!args.empty()) { @@ -117,7 +120,7 @@ RegistryService::start(int argc, char* argv[]) TraceLevelsPtr traceLevels = new TraceLevels(communicator(), "IceGrid.Registry"); - _registry = new RegistryI(communicator(), traceLevels, nowarn); + _registry = new RegistryI(communicator(), traceLevels, nowarn, readonly); if(!_registry->start()) { return false; @@ -167,7 +170,8 @@ RegistryService::usage(const string& appName) "Options:\n" "-h, --help Show this message.\n" "-v, --version Display the Ice version.\n" - "--nowarn Don't print any security warnings."; + "--nowarn Don't print any security warnings." + "--readonly Start the master registry in read-only mode."; #ifndef _WIN32 options.append( "\n" |