The API contains two main endpoints. One is for generation of new data called origin/api/v1/* and another endpoint is the primary access point to data queries api/v1/*.
For a full documentation, please refer to the API documentation: https://maayanlab.cloud/sigcom/data-api/swagger.html
Signature Commons can load libraries from a cloud repository on startup if the environmental variable S3_AUTOLOAD is set to 'true'.
| Name | Type | Description |
api_key |
string | Your own API public key |
timestamp |
integer | Current unix timestamp (GMT+0) in seconds |
dev_hash |
string |
Calculate with timestamp and api_secret
Formula: md5(concatenate(<timestamp>, <api_secret>))
|
When launching SigCom it requires several environmental variabls.
| Environmental Variable | Description |
|---|---|
TOKEN | 'pass code needed for several API endpoints' |
PREFIX | '/sigcom/data-api' |
JAVA_OPTS | '-Xmx30G -XX:PermSize=13G -XX:MaxPermSize=13G -XX:+UseCompressedOops' |
deployment | 'marathon_deployed' |
AWS_ACCESS_KEY_ID | 'access key id' |
AWS_SECRET_ACCESS_KEY | 'aws key with S3 credentials to upload new data to AWS bucket' |
AWS_ENDPOINT_URL | 'http://s3.amazonaws.com' |
AWS_BUCKET_PREFIX | 'sigcom/' |
AWS_BUCKET | 'name of bucket' |
S3_AUTOLOAD | 'true/false' |
| Task Name | Description |
|---|---|
| war | Assembles the application WAR file and saves it in the /docker directory |
| tomcatRunWar | Starts a Tomcat instance and deploys the WAR to it |
| clean | Deletes the project build directory and files generated by tasks |
| test | Runs the unit tests using JUnit or TestNG |
| check | Aggregate task that performs verification tasks, such as running the tests |
| compileJava | Compiles production Java source files using the JDK compiler |
To run gradle task, enter
./gradlew {task_name}
The Java Plugin documentation
The War Plugin documentation
The Tomcat Plugin documentation
This will launch the enrichment API on the local machine and should be accessible through the localhost.
./gradlew tomcatRunWar
Processes need to be stopped manually if timcatRunWar has previously been executed.
./gradlew stop
Getting started with docker-compose
gradle war
docker-compose build
docker-compose up