Monasca REST API
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
zhangchun 344c62671a bump py37 to py38 in tox.ini 2 months ago
api-ref Switch to newer openstackdocstheme and reno versions 6 months ago
common Restore user condition but with zuul 3 years ago
config-generator Add keystonemiddleware to oslo-config-generator conf 1 year ago
contrib Remove bundled intree monasca-api tempest plugin 2 years ago
devstack Migrate DevStack plugin to Ubuntu Focal 1 month ago
doc Merge "Move DB migrations documentation to its own file" 6 months ago
docker Merge "Add option to choose Kafka client in Docker" 1 month ago
docs Allow users to set periodic notifications on all notification types 10 months ago
etc Update devstack plugin to support new api 11 months ago
java [Trivial Fix] change the unicode of some higher numbered characters 2 years ago
monasca_api [goal] Migrate testing to ubuntu focal 1 month ago
perf Add read performance testing to monasca-api 2 years ago
playbooks Fix docker hub login variable 1 year ago
releasenotes Update master for stable/victoria 1 month ago
tools Avoid for constraints support 3 years ago
.coveragerc Migrate test run to ostestr 3 years ago
.gitignore Merge log-api and api 1 year ago
.gitreview OpenDev Migration Patch 1 year ago
.stestr.conf Add .stestr.conf . 3 years ago
.zuul.yaml Add Python3 wallaby unit tests 1 month ago
CONTRIBUTING.rst Update Monasca contribution documentation 6 months ago
LICENSE Added license file 6 years ago
README.rst [ussuri][goal] Drop python 2.7 support and testing 11 months ago
babel.cfg initial python implementation 6 years ago
bindep.txt Add libssl to fix pep8 3 years ago
lower-constraints.txt [goal] Migrate testing to ubuntu focal 1 month ago
pom.xml Update links in pom.xml 2 years ago
requirements.txt [goal] Migrate testing to ubuntu focal 1 month ago Ensure the same branch is used for common build 4 years ago
setup.cfg Add py38 package metadata 6 months ago Cleanup py27 support 7 months ago
test-requirements.txt Switch to newer openstackdocstheme and reno versions 6 months ago
tox.ini bump py37 to py38 in tox.ini 3 weeks ago


Team and repository tags



monasca-api is a RESTful API server that is designed with a layered architecture.


The full API Specification can be found in docs/

Python Monasca API Implementation

To install the python api implementation, git clone the source and run the following command:

$ sudo python install

If it installs successfully, you will need to make changes to the following two files to reflect your system settings, especially where kafka server is located:


Once the configuration files are modified to match your environment, you can start up the server by following the following instructions.

To start the server, run the following command:

Running the server in foreground mode
$ gunicorn -k eventlet --worker-connections=2000 --backlog=1000 --paste /etc/monasca/api-config.ini

Running the server as daemons
$ gunicorn -k eventlet --worker-connections=2000 --backlog=1000 --paste /etc/monasca/api-config.ini -D

To check if the code follows python coding style, run the following command from the root directory of this project

$ tox -e pep8

To run all the unit test cases, run the following command from the root directory of this project

$ tox -e py36

Start the Server - for Apache

To start the server using Apache: create a modwsgi file, create a modwsgi configuration file, and enable the wsgi module in Apache.

The modwsgi configuration file may look something like this, and the site will need to be enabled:

The wsgi file may look something like this:

Java Implementation

Details on usage can be found here

WARNING: The Java implementation of Monasca API is DEPRECATED and will be removed in future release.


Copyright (c) 2014 Hewlett-Packard Development Company, L.P.

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

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.