monitor-server-api
Features
For short, monitor-server-api helps you to collect, historicize and exploit the data from your tests written with pytest and monitored with pytest-monitor.
- Centralize your tests results
- bring support for pytest-xdist and pytest-parallel
- Easy data querying through specific queries
- Integrated library for in-script queries
Usage
The server can be launched easily with any WSGI Framework. The following lines can be used for a start:
bash $> # Use it with sqlite (not recomended for production)
bash $> export DATABASE_PATH=/path/to/sqlite/db
bash $> uwsgi --http 0.0.0.0:8050 --workers 8 --process 8 --master
--harakiri 60 --harakiri-verbose --need-app -w monitor_server_api.uwsgi
--callable WSGI_SERVER --env DATABASE_PATH=${DATABASE_PATH} --env ENV=prod
If you prefer using conda
bash $> conda activate <your monitor-server-api env>
bash $> # Setup the server to listen on port 8080, 8 workers, 60s max per request and using sqlite
bash $> launch-monitor-server.sh -p 8080 -t 60 -w 8 -u sqlite:////path/to/db
You can validate that the server runs correctly by going to the root page of the server.
Documentation
A full documentation with use cases and example is available.
Installation
Review the following installation instructions along with basic setup instructions.
You can install monitor-server-api via conda (through the conda-forge channel):
$ conda install monitor-server-api -c https://conda.anaconda.org/conda-forge
Another possibility is to install monitor-server-api via pip_ from PyPI:
$ pip install monitor-server-api
Requirements
Monitor-Server-Api
To run, the monitor-server-api requires a valid Python 3.6+ interpreter. The following requirements are needed:
- flask-restx (officially supported) OR flask-restplus (tested)
- flask-sqlalchemy
Testing requires pytest-flask and pytest-cov (along with pytest obviously).
Monitorlib
The monitorlib also requires a valid Python 3.6+ along with :
- requests
- pandas
Contributing
Contributions are very welcome. Tests are run with pytest. Before submitting a pull request, please ensure that:
- both internal tests and examples are passing.
- internal tests have been written if necessary.
- if your contribution provides a new feature, make sure to provide an example and update the documentation accordingly.
Issues
If you encounter any problem, please file an issue along with a detailed description.
See contributing file for more information.
License
monitor-server-api is free, open-source software
This code is distributed under the license.
Author
The main author of monitor-server-api is Jean-Sébastien Dieu, ]]who can be reached at dieu.jsebastien@yahoo.com.
See AUTHORS file for more contributors.
Metadata
Release files for monitor-server-api 1.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| monitor-server-api-1.1.0.tar.gz | 41.4 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| monitor_server_api-1.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 92.1 kB
Release files / monitor-server-api-1.1.0.tar.gz
| Download URL | monitor-server-api-1.1.0.tar.gz |
|---|---|
| Size | 41.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b457f9865aedfa43473dbbe5152e68eda9be7f24dfba63ccab739ad399c32947
|
|
BLAKE2b-256 checksum How to use checksums |
d852f51e9d912858b71a93278ac105f51be3dce8b45a66ac3c70429b68d0e643
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.1 CPython/3.8.13
|
Release files / monitor_server_api-1.1.0-py3-none-any.whl
| Download URL | monitor_server_api-1.1.0-py3-none-any.whl |
|---|---|
| Size | 50.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
5b594836eaa9d1c7afa5bbbb8b5364fe99139f653fc3a4725d37cbd46258379d
|
|
BLAKE2b-256 checksum How to use checksums |
2f9acf6fafe08cf80d0fb646f0fb80f8e4a1d69e4d0afbe2c31753d6fa29beac
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.1 CPython/3.8.13
|