See the Homepage for a better formatted version.
## PLATER
PLATER is a service to stand up REST endpoint over a neo4j or redis graph database.
There are some restrictions on the data structure of the Neo4j backend to be fully utilized through PLATER.
> **Data structure restrictions:**
> * All nodes should have an `id` to be searchable (Used in querying single Nodes)
> * All edges should have an `id` to be searchable (Used in generating ReasonerAPI)
> * Data is recommended to comply to the [Translator Reasoner API](https://github.com/NCATSTranslator/ReasonerAPI).
### Installation
To run the web server directly:
#### Create a virtual Environment and activate.
cd <PLATER-ROOT>
python<version> -m venv venv
source venv/bin/activate
#### Install dependencies
pip install -r PLATER/requirements.txt
#### Configure PLATER settings
Populate `.env-template` file with settings and save as `.env` in repo root dir.
```bash
WEB_HOST=0.0.0.0
WEB_PORT=8080
DB_HOST=<neo4j_or_redis_address>
DB_USERNAME=<user name required for neo4j, empty for redis>
DB_PASSWORD=''
DB_PORT=<redis port or neo4j http port>
DB_NAME=<db name for redis, uses default db for neo4j>
DB_TYPE=<use values 'redis' or 'neo4j'>
PLATER_TITLE='Plater'
PLATER_VERSION='1.0.0'
```
#### Run Script
./main.sh
### DOCKER
Or build an image and run it.
```bash
cd PLATER
docker build --tag <image_tag> .
cd ../
```
```bash
docker run --env-file .env\
--name plater\
-p 8080:8080\
--network <network_where_neo4j_is_running>\
plater-tst
```
### Clustering with [Automat Server](https://github.com/RENCI-AUTOMAT/Automat-server/) \[Optional\]
You can also serve several instances of plater through a common gateway(Automat). On specific instructions
please refer to [AUTOMAT's readme](https://github.com/RENCI-AUTOMAT/Automat-server/blob/master/README.md)
### Miscellaneous
###### `/about` Endpoint
The `/about` endpoint can be used to present meta-data about the current PLATER instance.
This meta-data is served from `<repo-root>/PLATER/about.json` file. One can edit the contents of
this file to suite needs. In containerized environment we recommend mounting this file as a volume.
Eg:
```bash
docker run -p 0.0.0.0:8999:8080 \
--env DB_HOST=<your_db_host> \
--env DB_PORT=<your_db_port> \
--env DB_USERNAME=<db_user_name required for neo4j, ignored for redis> \
--env DB_PASSWORD=<db_password> \
--env DB_NAME=<required for redis> \
--env DB_TYPE=<redis or neo4j> \
--env WEB_HOST=0.0.0.0 \
-v <your-custom-about>:/<path-to-plater-repo-home>/plater/about.json \
--network=<docker_network_neo4j_is_running_at> \
<image_tag>
```
Raw data
{
"_id": null,
"home_page": "http://github.com/YaphetKG/plater.git",
"name": "PLATER-GRAPH",
"maintainer": "",
"docs_url": null,
"requires_python": "",
"maintainer_email": "",
"keywords": "knowledge,network,graph,biomedical",
"author": "",
"author_email": "yaphetkg@renci.org",
"download_url": "https://files.pythonhosted.org/packages/d2/d7/dddd57d93eff0a32946b47812ea4986d7454d49045bdd074da13280dcd25/PLATER-GRAPH-1.6.tar.gz",
"platform": "",
"description": "See the Homepage for a better formatted version.\n ## PLATER\n\nPLATER is a service to stand up REST endpoint over a neo4j or redis graph database.\nThere are some restrictions on the data structure of the Neo4j backend to be fully utilized through PLATER.\n\n> **Data structure restrictions:**\n> * All nodes should have an `id` to be searchable (Used in querying single Nodes)\n> * All edges should have an `id` to be searchable (Used in generating ReasonerAPI)\n> * Data is recommended to comply to the [Translator Reasoner API](https://github.com/NCATSTranslator/ReasonerAPI).\n\n### Installation\n\nTo run the web server directly:\n\n#### Create a virtual Environment and activate.\n\n cd <PLATER-ROOT>\n python<version> -m venv venv\n source venv/bin/activate\n \n#### Install dependencies\n \n pip install -r PLATER/requirements.txt\n \n \n#### Configure PLATER settings\n \n Populate `.env-template` file with settings and save as `.env` in repo root dir.\n \n ```bash \n WEB_HOST=0.0.0.0\n WEB_PORT=8080\n DB_HOST=<neo4j_or_redis_address>\n DB_USERNAME=<user name required for neo4j, empty for redis>\n DB_PASSWORD=''\n DB_PORT=<redis port or neo4j http port>\n DB_NAME=<db name for redis, uses default db for neo4j>\n DB_TYPE=<use values 'redis' or 'neo4j'>\n PLATER_TITLE='Plater'\n PLATER_VERSION='1.0.0'\n \n\n ```\n \n \n#### Run Script\n \n ./main.sh\n \n \n ### DOCKER \n Or build an image and run it. \n \n ```bash\n cd PLATER\n docker build --tag <image_tag> .\n cd ../\n ```\n \n ```bash\n docker run --env-file .env\\\n --name plater\\\n -p 8080:8080\\\n --network <network_where_neo4j_is_running>\\\n plater-tst\n\n ```\n \n ### Clustering with [Automat Server](https://github.com/RENCI-AUTOMAT/Automat-server/) \\[Optional\\]\n You can also serve several instances of plater through a common gateway(Automat). On specific instructions \n please refer to [AUTOMAT's readme](https://github.com/RENCI-AUTOMAT/Automat-server/blob/master/README.md)\n \n \n\n ### Miscellaneous\n ###### `/about` Endpoint \n The `/about` endpoint can be used to present meta-data about the current PLATER instance. \n This meta-data is served from `<repo-root>/PLATER/about.json` file. One can edit the contents of\n this file to suite needs. In containerized environment we recommend mounting this file as a volume.\n \n Eg:\n ```bash\ndocker run -p 0.0.0.0:8999:8080 \\\n --env DB_HOST=<your_db_host> \\\n --env DB_PORT=<your_db_port> \\\n --env DB_USERNAME=<db_user_name required for neo4j, ignored for redis> \\\n --env DB_PASSWORD=<db_password> \\\n --env DB_NAME=<required for redis> \\ \n --env DB_TYPE=<redis or neo4j> \\ \n --env WEB_HOST=0.0.0.0 \\\n -v <your-custom-about>:/<path-to-plater-repo-home>/plater/about.json \\\n --network=<docker_network_neo4j_is_running_at> \\ \n <image_tag> \n```",
"bugtrack_url": null,
"license": "",
"summary": "TranslatorAPI Interface for graph databases.",
"version": "1.6",
"split_keywords": [
"knowledge",
"network",
"graph",
"biomedical"
],
"urls": [
{
"comment_text": "",
"digests": {
"md5": "d54eac9bc24fc5b57b1189cd7a8334e6",
"sha256": "b2ee243facd261631b1e55225f85260de83436198bc0673c49113a6e0a17be71"
},
"downloads": -1,
"filename": "PLATER-GRAPH-1.6.tar.gz",
"has_sig": false,
"md5_digest": "d54eac9bc24fc5b57b1189cd7a8334e6",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 25465,
"upload_time": "2021-03-24T03:00:23",
"upload_time_iso_8601": "2021-03-24T03:00:23.783014Z",
"url": "https://files.pythonhosted.org/packages/d2/d7/dddd57d93eff0a32946b47812ea4986d7454d49045bdd074da13280dcd25/PLATER-GRAPH-1.6.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2021-03-24 03:00:23",
"github": true,
"gitlab": false,
"bitbucket": false,
"github_user": null,
"github_project": "YaphetKG",
"error": "Could not fetch GitHub repository",
"lcname": "plater-graph"
}