diff --git a/trove/common/cfg.py b/trove/common/cfg.py index 27e6a0100d..a3a08caa28 100644 --- a/trove/common/cfg.py +++ b/trove/common/cfg.py @@ -279,7 +279,9 @@ common_opts = [ cfg.StrOpt('network_driver', default='trove.network.nova.NovaNetwork', help="Describes the actual network manager used for " "the management of network attributes " - "(security groups, floating IPs, etc.)") + "(security groups, floating IPs, etc.)"), + cfg.IntOpt('usage_timeout', default=600, + help='Timeout to wait for a guest to become active.'), ] # Datastore specific option groups @@ -392,8 +394,6 @@ redis_opts = [ cfg.StrOpt('mount_point', default='/var/lib/redis', help="Filesystem path for mounting " "volumes if volume support is enabled."), - cfg.IntOpt('usage_timeout', default=450, - help='Timeout to wait for a guest to become active.'), cfg.BoolOpt('volume_support', default=False, help='Whether to provision a cinder volume for datadir.'), @@ -420,8 +420,6 @@ cassandra_opts = [ cfg.StrOpt('mount_point', default='/var/lib/cassandra', help="Filesystem path for mounting " "volumes if volume support is enabled."), - cfg.IntOpt('usage_timeout', default=600, - help='Timeout to wait for a guest to become active.'), cfg.BoolOpt('volume_support', default=True, help='Whether to provision a cinder volume for datadir.'), @@ -450,8 +448,6 @@ couchbase_opts = [ cfg.StrOpt('mount_point', default='/var/lib/couchbase', help="Filesystem path for mounting " "volumes if volume support is enabled."), - cfg.IntOpt('usage_timeout', default=450, - help='Timeout to wait for a guest to become active.'), cfg.BoolOpt('root_on_create', default=True, help='Enable the automatic creation of the root user for the ' 'service during instance-create. The generated password for ' @@ -487,8 +483,6 @@ mongodb_opts = [ cfg.StrOpt('mount_point', default='/var/lib/mongodb', help="Filesystem path for mounting " "volumes if volume support is enabled."), - cfg.IntOpt('usage_timeout', default=450, - help='Timeout to wait for a guest to become active.'), cfg.BoolOpt('volume_support', default=True, help='Whether to provision a cinder volume for datadir.'), diff --git a/trove/taskmanager/models.py b/trove/taskmanager/models.py index 61990f8567..727a25bdeb 100755 --- a/trove/taskmanager/models.py +++ b/trove/taskmanager/models.py @@ -255,7 +255,7 @@ class FreshInstanceTasks(FreshInstance, NotifyMixin, ConfigurationMixin): # record to avoid over billing a customer for an instance that # fails to build properly. try: - usage_timeout = CONF.get(datastore_manager).usage_timeout + usage_timeout = CONF.usage_timeout utils.poll_until(self._service_is_active, sleep_time=USAGE_SLEEP_TIME, time_out=usage_timeout)