Skip to content

Latest commit

 

History

History
35 lines (24 loc) · 959 Bytes

README.md

File metadata and controls

35 lines (24 loc) · 959 Bytes

Observing Database API

papahana.yaml

OpenAPI specification file

controller_helper.py

Used to query database. These functions are to be added to the server controller section. Providing the RestFull API server read/write access to the database.

run

in odb_api directory: python3 -m papahana

to leave running without hang-ups: nohup python3 -m papahana & >> /dev/null &

Testing

in the test directory (odb_api/papahana/test) the tests can be run individually python3 -m unittest -v test_containers_controller

Or run all tests together: nosetest

Generate models from the OpenAPI specification files:

swagger-codegen generate -i papahana.yaml -l python-flask -c config.json

where the config.json: { "packageName" : "papahana", "packageVersion" : "0.0.1" }

Generate_db_scripts

Generate scripts, recipes, test OBs, instrument packages, and templates with the command python generate_database.py --mode dev.