Browse Source
The statless design was developed in the experiment branch, the experiment shows advantage in removing the status synchronization, uuid mapping compared to the stateful design, and also fully reduce the coupling with OpenStack services like Nova, Cinder. The overhead query latency for resources also acceptable. It's time to move the statless design to the master branch BP: https://blueprints.launchpad.net/tricircle/+spec/implement-stateless Change-Id: I51bbb60dc07da5b2e79f25e02209aa2eb72711ac Signed-off-by: Chaoyi Huang <joehuang@huawei.com>changes/93/267293/2
119 changed files with 10088 additions and 4643 deletions
@ -1,11 +1,111 @@
|
||||
# Tricircle |
||||
|
||||
(Attention Please, Stateless Design Proposal is being worked on the ["experiment"](https://github.com/openstack/tricircle/tree/experiment) branch). |
||||
(The original PoC source code, please switch to |
||||
["poc"](https://github.com/openstack/tricircle/tree/poc) tag, or |
||||
["stable/fortest"](https://github.com/openstack/tricircle/tree/stable/fortest) |
||||
branch) |
||||
|
||||
(The origningal PoC source code, please switch to ["poc"](https://github.com/openstack/tricircle/tree/poc) tag, or ["stable/fortest"](https://github.com/openstack/tricircle/tree/stable/fortest) branch) |
||||
Tricircle is an OpenStack project that aims to deal with multiple OpenStack |
||||
deployment across multiple data centers. It provides users a single management |
||||
view by having only one Tricircle instance on behalf of all the involved |
||||
OpenStack instances. |
||||
|
||||
Tricircle is a openstack project that aims to deal with OpenStack deployment across multiple sites. It provides users a single management view by having only one OpenStack instance on behalf of all the involved ones. It essentially serves as a communication bus between the central OpenStack instance and the other OpenStack instances that are called upon. |
||||
Tricircle presents one big region to the end user in KeyStone. And each |
||||
OpenStack instance, which is called a pod, is a sub-region of Tricircle in |
||||
KeyStone, and not visible to end user directly. |
||||
|
||||
Tricircle acts as OpenStack API gateway, can accept all OpenStack API calls |
||||
and forward the API calls to regarding OpenStack instance(pod), and deal with |
||||
cross pod networking automaticly. |
||||
|
||||
The end user can see avaialbility zone (AZ in short) and use AZ to provision |
||||
VM, Volume, even Network through Tricircle. |
||||
|
||||
Similar as AWS, one AZ can includes many pods, and a tenant's resources will |
||||
be bound to specific pods automaticly. |
||||
|
||||
## Project Resources |
||||
- Project status, bugs, and blueprints are tracked on [Launchpad](https://launchpad.net/tricircle) |
||||
- Additional resources are linked from the project [Wiki](https://wiki.openstack.org/wiki/Tricircle) page |
||||
License: Apache 2.0 |
||||
|
||||
- Design documentation: [Tricircle Design Blueprint](https://docs.google.com/document/d/18kZZ1snMOCD9IQvUKI5NVDzSASpw-QKj7l2zNqMEd3g/) |
||||
- Wiki: https://wiki.openstack.org/wiki/tricircle |
||||
- Documentation: http://docs.openstack.org/developer/tricircle |
||||
- Source: https://github.com/openstack/tricircle |
||||
- Bugs: http://bugs.launchpad.net/tricircle |
||||
- Blueprints: https://launchpad.net/tricircle |
||||
|
||||
## Play with DevStack |
||||
Now stateless design can be played with DevStack. |
||||
|
||||
- 1 Git clone DevStack. |
||||
- 2 Git clone Tricircle, or just download devstack/local.conf.sample |
||||
- 3 Copy devstack/local.conf.sample to DevStack folder and rename it to |
||||
local.conf, change password in the file if needed. |
||||
- 4 Run DevStack. |
||||
- 5 After DevStack successfully starts, check if services have been correctly |
||||
registered. Run "openstack endpoint list" and you should get similar output |
||||
as following: |
||||
``` |
||||
+----------------------------------+-----------+--------------+----------------+ |
||||
| ID | Region | Service Name | Service Type | |
||||
+----------------------------------+-----------+--------------+----------------+ |
||||
| 230059e8533e4d389e034fd68257034b | RegionOne | glance | image | |
||||
| 25180a0a08cb41f69de52a7773452b28 | RegionOne | nova | compute | |
||||
| bd1ed1d6f0cc42398688a77bcc3bda91 | Pod1 | neutron | network | |
||||
| 673736f54ec147b79e97c395afe832f9 | RegionOne | ec2 | ec2 | |
||||
| fd7f188e2ba04ebd856d582828cdc50c | RegionOne | neutron | network | |
||||
| ffb56fd8b24a4a27bf6a707a7f78157f | RegionOne | keystone | identity | |
||||
| 88da40693bfa43b9b02e1478b1fa0bc6 | Pod1 | nova | compute | |
||||
| f35d64c2ddc44c16a4f9dfcd76e23d9f | RegionOne | nova_legacy | compute_legacy | |
||||
| 8759b2941fe7469e9651de3f6a123998 | RegionOne | tricircle | Cascading | |
||||
+----------------------------------+-----------+--------------+----------------+ |
||||
``` |
||||
"RegionOne" is the region you set in local.conf via REGION_NAME, whose default |
||||
value is "RegionOne", we use it as the region for top OpenStack(Tricircle); |
||||
"Pod1" is the region set via "POD_REGION_NAME", new configuration option |
||||
introduced by Tricircle, we use it as the bottom OpenStack. |
||||
|
||||
- 6 Create pod instances for Tricircle and bottom OpenStack |
||||
``` |
||||
curl -X POST http://127.0.0.1:19999/v1.0/pods -H "Content-Type: application/json" \ |
||||
-H "X-Auth-Token: $token" -d '{"pod": {"pod_name": "RegionOne"}}' |
||||
|
||||
curl -X POST http://127.0.0.1:19999/v1.0/pods -H "Content-Type: application/json" \ |
||||
-H "X-Auth-Token: $token" -d '{"pod": {"pod_name": "Pod1", "az_name": "az1"}}' |
||||
|
||||
``` |
||||
Pay attention to "pod_name" parameter we specify when creating pod. Pod name |
||||
should exactly match the region name registered in Keystone since it is used |
||||
by Tricircle to route API request. In the above commands, we create pods named |
||||
"RegionOne" and "Pod1" for top OpenStack(Tricircle) and bottom OpenStack. |
||||
Tricircle API service will automatically create a aggregate when user creates |
||||
a bottom pod, so command "nova aggregate-list" will show the following result: |
||||
``` |
||||
+----+----------+-------------------+ |
||||
| Id | Name | Availability Zone | |
||||
+----+----------+-------------------+ |
||||
| 1 | ag_Pod1 | az1 | |
||||
+----+----------+-------------------+ |
||||
``` |
||||
- 7 Create necessary resources to boot a virtual machine. |
||||
``` |
||||
nova flavor-create test 1 1024 10 1 |
||||
neutron net-create net1 |
||||
neutron subnet-create net1 10.0.0.0/24 |
||||
glance image-list |
||||
``` |
||||
Note that flavor mapping has not been implemented yet so the created flavor is |
||||
just a database record and actually flavor in bottom OpenStack with the same id |
||||
will be used. |
||||
- 8 Boot a virtual machine. |
||||
``` |
||||
nova boot --flavor 1 --image $image_id --nic net-id=$net_id --availability-zone az1 vm1 |
||||
``` |
||||
- 9 Create, list, show and delete volume. |
||||
``` |
||||
cinder --debug create --availability-zone=az1 1 |
||||
cinder --debug list |
||||
cinder --debug show $volume_id |
||||
cinder --debug delete $volume_id |
||||
cinder --debug list |
||||
``` |
||||
|
@ -0,0 +1,63 @@
|
||||
# Copyright 2015 Huawei Technologies Co., Ltd. |
||||
# All Rights Reserved. |
||||
# |
||||
# Licensed under the Apache License, Version 2.0 (the "License"); you may |
||||
# not use this file except in compliance with the License. You may obtain |
||||
# a copy of the License at |
||||
# |
||||
# http://www.apache.org/licenses/LICENSE-2.0 |
||||
# |
||||
# Unless required by applicable law or agreed to in writing, software |
||||
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT |
||||
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the |
||||
# License for the specific language governing permissions and limitations |
||||
# under the License. |
||||
|
||||
# Much of this module is based on the work of the Ironic team |
||||
# see http://git.openstack.org/cgit/openstack/ironic/tree/ironic/cmd/api.py |
||||
|
||||
import logging as std_logging |
||||
import sys |
||||
|
||||
from oslo_config import cfg |
||||
from oslo_log import log as logging |
||||
from oslo_service import wsgi |
||||
|
||||
from tricircle.common import config |
||||
from tricircle.common.i18n import _LI |
||||
from tricircle.common.i18n import _LW |
||||
from tricircle.common import restapp |
||||
|
||||
from tricircle.cinder_apigw import app |
||||
|
||||
CONF = cfg.CONF |
||||
LOG = logging.getLogger(__name__) |
||||
|
||||
|
||||
def main(): |
||||
config.init(app.common_opts, sys.argv[1:]) |
||||
application = app.setup_app() |
||||
|
||||
host = CONF.bind_host |
||||
port = CONF.bind_port |
||||
workers = CONF.api_workers |
||||
|
||||
if workers < 1: |
||||
LOG.warning(_LW("Wrong worker number, worker = %(workers)s"), workers) |
||||
workers = 1 |
||||
|
||||
LOG.info(_LI("Cinder_APIGW on http://%(host)s:%(port)s with %(workers)s"), |
||||
{'host': host, 'port': port, 'workers': workers}) |
||||
|
||||
service = wsgi.Server(CONF, 'Tricircle Cinder_APIGW', |
||||
application, host, port) |
||||
restapp.serve(service, CONF, workers) |
||||
|
||||
LOG.info(_LI("Configuration:")) |
||||
CONF.log_opt_values(LOG, std_logging.INFO) |
||||
|
||||
restapp.wait() |
||||
|
||||
|
||||
if __name__ == '__main__': |
||||
main() |
@ -1,85 +0,0 @@
|
||||
# Copyright 2015 Huawei Technologies Co., Ltd. |
||||
# |
||||
# Licensed under the Apache License, Version 2.0 (the "License"); |
||||
# you may not use this file except in compliance with the License. |
||||
# You may obtain a copy of the License at |
||||
# |
||||
# http://www.apache.org/licenses/LICENSE-2.0 |
||||
# |
||||
# Unless required by applicable law or agreed to in writing, software |
||||
# distributed under the License is distributed on an "AS IS" BASIS, |
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or |
||||
# implied. |
||||
# See the License for the specific language governing permissions and |
||||
# limitations under the License. |
||||
|
||||
|
||||
import eventlet |
||||
|
||||
if __name__ == "__main__": |
||||
eventlet.monkey_patch() |
||||
|
||||
import sys |
||||
import traceback |
||||
|
||||
from oslo_config import cfg |
||||
from oslo_log import log as logging |
||||
|
||||
from tricircle.common.i18n import _LE |
||||
from tricircle.common.nova_lib import conductor_rpcapi |
||||
from tricircle.common.nova_lib import db_api as nova_db_api |
||||
from tricircle.common.nova_lib import exception as nova_exception |
||||
from tricircle.common.nova_lib import objects as nova_objects |
||||
from tricircle.common.nova_lib import objects_base |
||||
from tricircle.common.nova_lib import quota |
||||
from tricircle.common.nova_lib import rpc as nova_rpc |
||||
from tricircle.dispatcher import service |
||||
|
||||
|
||||
def block_db_access(): |
||||
class NoDB(object): |
||||
def __getattr__(self, attr): |
||||
return self |
||||
|
||||
def __call__(self, *args, **kwargs): |
||||
stacktrace = "".join(traceback.format_stack()) |
||||
LOG = logging.getLogger('nova.compute') |
||||
LOG.error(_LE('No db access allowed in nova-compute: %s'), |
||||
stacktrace) |
||||
raise nova_exception.DBNotAllowed('nova-compute') |
||||
|
||||
nova_db_api.IMPL = NoDB() |
||||
|
||||
|
||||
def set_up_nova_object_indirection(): |
||||
conductor = conductor_rpcapi.ConductorAPI() |
||||
conductor.client.target.exchange = "nova" |
||||
objects_base.NovaObject.indirection_api = conductor |
||||
|
||||
|
||||
def process_command_line_arguments(): |
||||
logging.register_options(cfg.CONF) |
||||
logging.set_defaults() |
||||
cfg.CONF(sys.argv[1:]) |
||||
logging.setup(cfg.CONF, "dispatcher", version='0.1') |
||||
|
||||
|
||||
def _set_up_nova_objects(): |
||||
nova_rpc.init(cfg.CONF) |
||||
block_db_access() |
||||
set_up_nova_object_indirection() |
||||
nova_objects.register_all() |
||||
|
||||
|
||||
def _disable_quotas(): |
||||
QUOTAS = quota.QUOTAS |
||||
QUOTAS._driver_cls = quota.NoopQuotaDriver() |
||||
|
||||
|
||||
if __name__ == "__main__": |
||||
_set_up_nova_objects() |
||||
_disable_quotas() |
||||
process_command_line_arguments() |
||||
server = service.setup_server() |
||||
server.start() |
||||
server.wait() |
@ -0,0 +1,68 @@
|
||||
# Copyright 2015 Huawei Technologies Co., Ltd. |
||||
# All Rights Reserved. |
||||
# |
||||
# Licensed under the Apache License, Version 2.0 (the "License"); you may |
||||
# not use this file except in compliance with the License. You may obtain |
||||
# a copy of the License at |
||||
# |
||||
# http://www.apache.org/licenses/LICENSE-2.0 |
||||
# |
||||
# Unless required by applicable law or agreed to in writing, software |
||||
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT |
||||
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the |
||||
# License for the specific language governing permissions and limitations |
||||
# under the License. |
||||
|
||||
# Much of this module is based on the work of the Ironic team |
||||
# see http://git.openstack.org/cgit/openstack/ironic/tree/ironic/cmd/api.py |
||||
|
||||
import eventlet |
||||
|
||||
if __name__ == "__main__": |
||||
eventlet.monkey_patch() |
||||
|
||||
import logging as std_logging |
||||
import sys |
||||
|
||||
from oslo_config import cfg |
||||
from oslo_log import log as logging |
||||
from oslo_service import wsgi |
||||
|
||||
from tricircle.common import config |
||||
from tricircle.common.i18n import _LI |
||||
from tricircle.common.i18n import _LW |
||||
from tricircle.common import restapp |
||||
|
||||
from tricircle.nova_apigw import app |
||||
|
||||
CONF = cfg.CONF |
||||
LOG = logging.getLogger(__name__) |
||||
|
||||
|
||||
def main(): |
||||
config.init(app.common_opts, sys.argv[1:]) |
||||
application = app.setup_app() |
||||
|
||||
host = CONF.bind_host |
||||
port = CONF.bind_port |
||||
workers = CONF.api_workers |
||||
|
||||
if workers < 1: |
||||
LOG.warning(_LW("Wrong worker number, worker = %(workers)s"), workers) |
||||
workers = 1 |
||||
|
||||
LOG.info(_LI("Nova_APIGW on http://%(host)s:%(port)s with %(workers)s"), |
||||
{'host': host, 'port': port, 'workers': workers}) |
||||
|
||||
service = wsgi.Server(CONF, 'Tricircle Nova_APIGW', |
||||
application, host, port) |
||||
restapp.serve(service, CONF, workers) |
||||
|
||||
LOG.info(_LI("Configuration:")) |
||||
CONF.log_opt_values(LOG, std_logging.INFO) |
||||
|
||||
restapp.wait() |
||||
|
||||
|
||||
if __name__ == '__main__': |
||||
main() |
@ -1,85 +0,0 @@
|
||||
# Copyright 2015 Huawei Technologies Co., Ltd. |
||||
# |
||||
# Licensed under the Apache License, Version 2.0 (the "License"); |
||||
# you may not use this file except in compliance with the License. |
||||
# You may obtain a copy of the License at |
||||
# |
||||
# http://www.apache.org/licenses/LICENSE-2.0 |
||||
# |
||||
# Unless required by applicable law or agreed to in writing, software |
||||
# distributed under the License is distributed on an "AS IS" BASIS, |
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or |
||||
# implied. |
||||
# See the License for the specific language governing permissions and |
||||
# limitations under the License. |
||||
|
||||
|
||||
import eventlet |
||||
|
||||
if __name__ == "__main__": |
||||
eventlet.monkey_patch() |
||||
|
||||
import sys |
||||
import traceback |
||||
|
||||
from oslo_config import cfg |
||||
from oslo_log import log as logging |
||||
|
||||
from tricircle.common.i18n import _LE |
||||
from tricircle.common.nova_lib import conductor_rpcapi |
||||
from tricircle.common.nova_lib import db_api as nova_db_api |
||||
from tricircle.common.nova_lib import exception as nova_exception |
||||
from tricircle.common.nova_lib import objects as nova_objects |
||||
from tricircle.common.nova_lib import objects_base |
||||
from tricircle.common.nova_lib import quota |
||||
from tricircle.common.nova_lib import rpc as nova_rpc |
||||
from tricircle.proxy import service |
||||
|
||||
|
||||
def block_db_access(): |
||||
class NoDB(object): |
||||
def __getattr__(self, attr): |
||||
return self |
||||
|
||||
def __call__(self, *args, **kwargs): |
||||
stacktrace = "".join(traceback.format_stack()) |
||||
LOG = logging.getLogger('nova.compute') |
||||
LOG.error(_LE('No db access allowed in nova-compute: %s'), |
||||
stacktrace) |
||||
raise nova_exception.DBNotAllowed('nova-compute') |
||||
|
||||
nova_db_api.IMPL = NoDB() |
||||
|
||||
|
||||
def set_up_nova_object_indirection(): |
||||
conductor = conductor_rpcapi.ConductorAPI() |
||||
conductor.client.target.exchange = "nova" |
||||
objects_base.NovaObject.indirection_api = conductor |
||||
|
||||
|
||||
def process_command_line_arguments(): |
||||
logging.register_options(cfg.CONF) |
||||
logging.set_defaults() |
||||
cfg.CONF(sys.argv[1:]) |
||||
logging.setup(cfg.CONF, "proxy", version='0.1') |
||||
|
||||
|
||||
def _set_up_nova_objects(): |
||||
nova_rpc.init(cfg.CONF) |
||||
block_db_access() |
||||
set_up_nova_object_indirection() |
||||
nova_objects.register_all() |
||||
|
||||
|
||||
def _disable_quotas(): |
||||
QUOTAS = quota.QUOTAS |
||||
QUOTAS._driver_cls = quota.NoopQuotaDriver() |
||||
|
||||
|
||||
if __name__ == "__main__": |
||||
_set_up_nova_objects() |
||||
_disable_quotas() |
||||
process_command_line_arguments() |
||||
server = service.setup_server() |
||||
server.start() |
||||
server.wait() |
@ -0,0 +1,61 @@
|
||||
# Copyright 2015 Huawei Technologies Co., Ltd. |
||||
# All Rights Reserved. |
||||
# |
||||
# Licensed under the Apache License, Version 2.0 (the "License"); you may |
||||
# not use this file except in compliance with the License. You may obtain |
||||
# a copy of the License at |
||||
# |
||||
# http://www.apache.org/licenses/LICENSE-2.0 |
||||
# |
||||
# Unless required by applicable law or agreed to in writing, software |
||||
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT |
||||
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the |
||||
# License for the specific language governing permissions and limitations |
||||
# under the License. |
||||
|
||||
# Much of this module is based on the work of the Ironic team |
||||
# see http://git.openstack.org/cgit/openstack/ironic/tree/ironic/cmd/api.py |
||||
|
||||
import eventlet |
||||
|
||||
if __name__ == "__main__": |
||||
eventlet.monkey_patch() |
||||
|
||||
import logging as std_logging |
||||
import sys |
||||
|
||||
from oslo_config import cfg |
||||
from oslo_log import log as logging |
||||
|
||||
from tricircle.common import config |
||||
from tricircle.common.i18n import _LI |
||||
from tricircle.common.i18n import _LW |
||||
|
||||
from tricircle.xjob import xservice |
||||
|
||||
CONF = cfg.CONF |
||||
LOG = logging.getLogger(__name__) |
||||
|
||||
|
||||
def main(): |
||||
config.init(xservice.common_opts, sys.argv[1:]) |
||||
|
||||
host = CONF.host |
||||
workers = CONF.workers |
||||
|
||||
if workers < 1: |
||||
LOG.warning(_LW("Wrong worker number, worker = %(workers)s"), workers) |
||||
workers = 1 |
||||
|
||||
LOG.info(_LI("XJob Server on http://%(host)s with %(workers)s"), |
||||
{'host': host, 'workers': workers}) |
||||
|
||||
xservice.serve(xservice.create_service(), workers) |
||||
|
||||
LOG.info(_LI("Configuration:")) |
||||
CONF.log_opt_values(LOG, std_logging.INFO) |
||||
|
||||
xservice.wait() |
||||
|
||||
if __name__ == '__main__': |
||||
main() |
@ -0,0 +1,16 @@
|
||||
[DEFAULT] |
||||
output_file = etc/api.conf.sample |
||||
wrap_width = 79 |
||||
namespace = tricircle.api |
||||
namespace = tricircle.common |
||||
namespace = tricircle.db |
||||
namespace = oslo.log |
||||
namespace = oslo.messaging |
||||
namespace = oslo.policy |
||||
namespace = oslo.service.periodic_task |
||||
namespace = oslo.service.service |
||||
namespace = oslo.service.sslutils |
||||
namespace = oslo.db |
||||
namespace = oslo.middleware |
||||
namespace = oslo.concurrency |
||||
namespace = keystonemiddleware.auth_token |
@ -1,412 +0,0 @@
|
||||
[DEFAULT] |
||||
# Print more verbose output (set logging level to INFO instead of default WARNING level). |
||||
# verbose = True |
||||
|
||||
# Print debugging output (set logging level to DEBUG instead of default WARNING level). |
||||
# debug = False |
||||
|
||||
# Where to store Tricircle state files. This directory must be writable by the |
||||
# user executing the agent. |
||||
# state_path = /var/lib/tricircle |
||||
|
||||
# log_format = %(asctime)s %(levelname)8s [%(name)s] %(message)s |
||||
# log_date_format = %Y-%m-%d %H:%M:%S |
||||
|
||||
# use_syslog -> syslog |
||||
# log_file and log_dir -> log_dir/log_file |
||||
# (not log_file) and log_dir -> log_dir/{binary_name}.log |
||||
# use_stderr -> stderr |
||||
# (not user_stderr) and (not log_file) -> stdout |
||||
# publish_errors -> notification system |
||||
|
||||
# use_syslog = False |
||||
# syslog_log_facility = LOG_USER |
||||
|
||||
# use_stderr = True |
||||
# log_file = |
||||
# log_dir = |
||||
|
||||
# publish_errors = False |
||||
|
||||
# Address to bind the API server to |
||||
# bind_host = 127.0.0.1 |
||||
|
||||
# Port the bind the API server to |
||||
# bind_port = 19999 |
||||
|
||||
# Paste configuration file |
||||
# api_paste_config = api-paste.ini |
||||
|
||||
# (StrOpt) Hostname to be used by the tricircle server, agents and services |
||||
# running on this machine. All the agents and services running on this machine |
||||
# must use the same host value. |
||||
# The default value is hostname of the machine. |
||||
# |
||||
# host = |
||||
|
||||
# admin_tenant_name = %SERVICE_TENANT_NAME% |
||||
# admin_user = %SERVICE_USER% |
||||
# admin_password = %SERVICE_PASSWORD% |
||||
|
||||
# Enable or disable bulk create/update/delete operations |
||||
# allow_bulk = True |
||||
# Enable or disable pagination |
||||
# allow_pagination = False |
||||
# Enable or disable sorting |
||||
# allow_sorting = False |
||||
|
||||
# Default maximum number of items returned in a single response, |
||||
# value == infinite and value < 0 means no max limit, and value must |
||||
# be greater than 0. If the number of items requested is greater than |
||||
# pagination_max_limit, server will just return pagination_max_limit |
||||
# of number of items. |
||||
# pagination_max_limit = -1 |
||||
|
||||
# =========== WSGI parameters related to the API server ============== |
||||
# Number of separate worker processes to spawn. The default, 0, runs the |
||||
# worker thread in the current process. Greater than 0 launches that number of |
||||
# child processes as workers. The parent process manages them. |
||||
# api_workers = 3 |
||||
|
||||
# Number of separate RPC worker processes to spawn. The default, 0, runs the |
||||
# worker thread in the current process. Greater than 0 launches that number of |
||||
# child processes as RPC workers. The parent process manages them. |
||||
# This feature is experimental until issues are addressed and testing has been |
||||
# enabled for various plugins for compatibility. |
||||
# rpc_workers = 0 |
||||
|
||||
# Timeout for client connections socket operations. If an |
||||
# incoming connection is idle for this number of seconds it |
||||
# will be closed. A value of '0' means wait forever. (integer |
||||
# value) |
||||
# client_socket_timeout = 900 |
||||
|
||||
# wsgi keepalive option. Determines if connections are allowed to be held open |
||||
# by clients after a request is fulfilled. A value of False will ensure that |
||||
# the socket connection will be explicitly closed once a response has been |
||||
# sent to the client. |
||||
# wsgi_keep_alive = True |
||||
|
||||
# Sets the value of TCP_KEEPIDLE in seconds to use for each server socket when |
||||
# starting API server. Not supported on OS X. |
||||
# tcp_keepidle = 600 |
||||
|
||||
# Number of seconds to keep retrying to listen |
||||
# retry_until_window = 30 |
||||
|
||||
# Number of backlog requests to configure the socket with. |
||||
# backlog = 4096 |
||||
|
||||
# Max header line to accommodate large tokens |
||||
# max_header_line = 16384 |
||||
|
||||
# Enable SSL on the API server |
||||
# use_ssl = False |
||||
|
||||
# Certificate file to use when starting API server securely |
||||
# ssl_cert_file = /path/to/certfile |
||||
|
||||
# Private key file to use when starting API server securely |
||||
# ssl_key_file = /path/to/keyfile |
||||
|
||||
# CA certificate file to use when starting API server securely to |
||||
# verify connecting clients. This is an optional parameter only required if |
||||
# API clients need to authenticate to the API server using SSL certificates |
||||
# signed by a trusted CA |
||||
# ssl_ca_file = /path/to/cafile |
||||
# ======== end of WSGI parameters related to the API server ========== |
||||
|
||||
# The strategy to be used for auth. |
||||
# Supported values are 'keystone'(default), 'noauth'. |
||||
# auth_strategy = keystone |
||||
|
||||
[filter:authtoken] |
||||
# paste.filter_factory = keystonemiddleware.auth_token:filter_factory |
||||
|
||||
[keystone_authtoken] |
||||
# auth_uri = http://162.3.111.227:35357/v3 |
||||
# identity_uri = http://162.3.111.227:35357 |
||||
# admin_tenant_name = service |
||||
# admin_user = tricircle |
||||
# admin_password = 1234 |
||||
# auth_version = 3 |
||||
|
||||
[database] |
||||
# This line MUST be changed to actually run the plugin. |
||||
# Example: |
||||
# connection = mysql://root:pass@127.0.0.1:3306/neutron |
||||
# Replace 127.0.0.1 above with the IP address of the database used by the |
||||
# main neutron server. (Leave it as is if the database runs on this host.) |
||||
# connection = sqlite:// |
||||
# NOTE: In deployment the [database] section and its connection attribute may |
||||
# be set in the corresponding core plugin '.ini' file. However, it is suggested |
||||
# to put the [database] section and its connection attribute in this |
||||
# configuration file. |
||||
|
||||
# Database engine for which script will be generated when using offline |
||||
# migration |
||||
# engine = |
||||
|
||||
# The SQLAlchemy connection string used to connect to the slave database |
||||
# slave_connection = |
||||
|
||||
# Database reconnection retry times - in event connectivity is lost |
||||
# set to -1 implies an infinite retry count |
||||
# max_retries = 10 |
||||
|
||||
# Database reconnection interval in seconds - if the initial connection to the |
||||
# database fails |
||||
# retry_interval = 10 |
||||
|
||||
# Minimum number of SQL connections to keep open in a pool |
||||
# min_pool_size = 1 |
||||
|
||||
# Maximum number of SQL connections to keep open in a pool |
||||
# max_pool_size = 10 |
||||
|
||||
# Timeout in seconds before idle sql connections are reaped |
||||
# idle_timeout = 3600 |
||||
|
||||
# If set, use this value for max_overflow with sqlalchemy |
||||
# max_overflow = 20 |
||||
|
||||
# Verbosity of SQL debugging information. 0=None, 100=Everything |
||||
# connection_debug = 0 |
||||
|
||||