Skip to content

Commit

Permalink
Merge pull request #278 from NASA-AMMOS/feat/aerie-1935-expose-plan-t…
Browse files Browse the repository at this point in the history
…imeline-to-mm

[AERIE-1935] Expose plan start time to mission model
  • Loading branch information
pcrosemurgy authored Aug 25, 2022
2 parents 5d2d8ac + 6c98d18 commit 6ead5b6
Show file tree
Hide file tree
Showing 27 changed files with 283 additions and 137 deletions.
80 changes: 41 additions & 39 deletions deployment/Environment.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@ This document provides detailed information about environment variables for each
| `MERLIN_GRAPHQL_URL` | URI of the Aerie GraphQL API | `string` | http://hasura:8080/v1/graphql |
| `COMMANDING_SERVER_PORT` | Port the server listens on | `number` | 27184 |
| `COMMANDING_DB` | Name of Commanding Postgres database | `string` | aerie_commanding |
| `COMMANDING_DB_SERVER` | Hostname of Postgres instance | `string` | |
| `COMMANDING_DB_PASSWORD` | Password of Postgres instance | `string` | |
| `COMMANDING_DB_SERVER` | Hostname of Postgres instance | `string` | |
| `COMMANDING_DB_PASSWORD` | Password of Postgres instance | `string` | |
| `COMMANDING_DB_PORT` | Port of Postgres instance | `number` | 5432 |
| `COMMANDING_DB_USER` | User of Postgres instance | `string` | |
| `COMMANDING_DB_USER` | User of Postgres instance | `string` | |
| `COMMANDING_LOCAL_STORE` | Local storage file storage in the container | `string` | /usr/src/app/commanding_file_store |

## Aerie Gateway
Expand All @@ -36,54 +36,56 @@ This document provides detailed information about environment variables for each
| `POSTGRES_AERIE_MERLIN_DB` | Name of Merlin Postgres database. | `string` | aerie_merlin |
| `POSTGRES_AERIE_SCHEDULER_DB` | Name of scheduler Postgres database. | `string` | aerie_scheduler |
| `POSTGRES_HOST` | Hostname of Postgres instance. | `string` | localhost |
| `POSTGRES_PASSWORD` | Password of Postgres instance. | `string` | |
| `POSTGRES_PASSWORD` | Password of Postgres instance. | `string` | |
| `POSTGRES_PORT` | Port of Postgres instance. | `number` | 5432 |
| `POSTGRES_USER` | User of Postgres instance. | `string` | |
| `POSTGRES_USER` | User of Postgres instance. | `string` | |
| `RATE_LIMITER_FILES_MAX` | Max requests allowed every 15 minutes to file endpoints | `number` | 1000 |
| `RATE_LIMITER_LOGIN_MAX` | Max requests allowed every 15 minutes to login endpoints | `number` | 1000 |

## Aerie Merlin

| Name | Description | Type | Default |
| -------------------- | --------------------------------------------------------- | -------- | ------------------------------- |
| `JAVA_OPTS` | Configuration for Merlin's logging level and output file | `string` | log level: warn. output: stderr |
| `MERLIN_PORT` | Port number for the Merlin server | `number` | 27183 |
| `MERLIN_LOCAL_STORE` | Local storage for Merlin in the container | `string` | /usr/src/app/merlin_file_store |
| `MERLIN_DB_SERVER` | The DB instance that Merlin will connect with | `string` | |
| `MERLIN_DB_PORT` | The DB instance port number that Merlin will connect with | `number` | 5432 |
| `MERLIN_DB_USER` | Username of the DB instance | `string` | |
| `MERLIN_DB_PASSWORD` | Password of the DB instance | `string` | |
| `MERLIN_DB` | The DB for Merlin. | `string` | aerie_merlin |
| Name | Description | Type | Default |
| -------------------- | --------------------------------------------------------------------------------------------------------------------------- | -------- | ------------------------------- |
| `JAVA_OPTS` | Configuration for Merlin's logging level and output file | `string` | log level: warn. output: stderr |
| `MERLIN_PORT` | Port number for the Merlin server | `number` | 27183 |
| `MERLIN_LOCAL_STORE` | Local storage for Merlin in the container | `string` | /usr/src/app/merlin_file_store |
| `MERLIN_DB_SERVER` | The DB instance that Merlin will connect with | `string` | |
| `MERLIN_DB_PORT` | The DB instance port number that Merlin will connect with | `number` | 5432 |
| `MERLIN_DB_USER` | Username of the DB instance | `string` | |
| `MERLIN_DB_PASSWORD` | Password of the DB instance | `string` | |
| `MERLIN_DB` | The DB for Merlin. | `string` | aerie_merlin |
| `UNTRUE_PLAN_START` | Temporary solution to provide plan start time to models, should be set to a time that models will not fail to initialize on | `string` | |

## Aerie Merlin Worker

| Name | Description | Type | Default |
| --------------------------- | --------------------------------------------------------- | -------- | -------------------------------------------- |
| `JAVA_OPTS` | Configuration for Merlin's logging level and output file | `string` | log level: warn. output: stderr |
| `MERLIN_WORKER_LOCAL_STORE` | The local storage as for the Merlin container | `string` | /usr/src/app/merlin_file_store |
| `MERLIN_WORKER_DB_SERVER` | The DB instance that Merlin will connect with | `string` | (this must the same as the Merlin container) |
| `MERLIN_WORKER_DB_PORT` | The DB instance port number that Merlin will connect with | `number` | (this must the same as the Merlin container) |
| `MERLIN_WORKER_DB_USER` | Username of the DB instance | `string` | (this must the same as the Merlin container) |
| `MERLIN_WORKER_DB_PASSWORD` | Password of the DB instance | `string` | (this must the same as the Merlin container) |
| `MERLIN_WORKER_DB` | The DB for Merlin. | `string` | (this must the same as the Merlin container) |
| Name | Description | Type | Default |
| --------------------------- | --------------------------------------------------------------------------------------------------------------------------- | -------- | -------------------------------------------- |
| `JAVA_OPTS` | Configuration for Merlin's logging level and output file | `string` | log level: warn. output: stderr |
| `MERLIN_WORKER_LOCAL_STORE` | The local storage as for the Merlin container | `string` | /usr/src/app/merlin_file_store |
| `MERLIN_WORKER_DB_SERVER` | The DB instance that Merlin will connect with | `string` | (this must the same as the Merlin container) |
| `MERLIN_WORKER_DB_PORT` | The DB instance port number that Merlin will connect with | `number` | (this must the same as the Merlin container) |
| `MERLIN_WORKER_DB_USER` | Username of the DB instance | `string` | (this must the same as the Merlin container) |
| `MERLIN_WORKER_DB_PASSWORD` | Password of the DB instance | `string` | (this must the same as the Merlin container) |
| `MERLIN_WORKER_DB` | The DB for Merlin. | `string` | (this must the same as the Merlin container) |
| `UNTRUE_PLAN_START` | Temporary solution to provide plan start time to models, should be set to a time that models will not fail to initialize on | `string` | |

## Aerie Scheduler

| Name | Description | Type | Default |
| ----------------------- | --------------------------------------------------------------------- | -------- |---------------------------------------------------|
| `JAVA_OPTS` | Configuration for the scheduler's logging level and output file | `string` | log level: warn. output: stderr |
| `MERLIN_GRAPHQL_URL` | URI of the Merlin graphql interface to call | `string` | http://hasura:8080/v1/graphql |
| `MERLIN_LOCAL_STORE` | Local storage for Merlin in the container (for backdoor jar access) | `string` | /usr/src/app/merlin_file_store |
| `SCHEDULER_DB` | The DB for scheduler | `string` | aerie_scheduler |
| `SCHEDULER_DB_PASSWORD` | Password of the DB instance | `string` | |
| `SCHEDULER_DB_PORT` | The DB instance port number that scheduler will connect with | `number` | 5432 |
| `SCHEDULER_DB_SERVER` | The DB instance that scheduler will connect with | `string` | |
| `SCHEDULER_DB_USER` | Username of the DB instance | `string` | |
| `SCHEDULER_LOCAL_STORE` | Local storage for scheduler in the container | `string` | /usr/src/app/scheduler_file_store |
| `SCHEDULER_LOGGING` | Whether or not you want Javalin to log server information | `string` | true |
| `SCHEDULER_OUTPUT_MODE` | how scheduler output is sent back to aerie | `string` | UpdateInputPlanWithNewActivities |
| `SCHEDULER_PORT` | Port number for the scheduler server | `number` | 27185 |
| `SCHEDULER_RULES_JAR` | Jar file to load scheduling rules from (until user input to database) | `string` | /usr/src/app/merlin_file_store/scheduler_rules.jar |
| Name | Description | Type | Default |
| ----------------------- | --------------------------------------------------------------------- | -------- | --------------------------------------------------- |
| `JAVA_OPTS` | Configuration for the scheduler's logging level and output file | `string` | log level: warn. output: stderr |
| `MERLIN_GRAPHQL_URL` | URI of the Merlin graphql interface to call | `string` | http://hasura:8080/v1/graphql |
| `MERLIN_LOCAL_STORE` | Local storage for Merlin in the container (for backdoor jar access) | `string` | /usr/src/app/merlin_file_store |
| `SCHEDULER_DB` | The DB for scheduler | `string` | aerie_scheduler |
| `SCHEDULER_DB_PASSWORD` | Password of the DB instance | `string` | |
| `SCHEDULER_DB_PORT` | The DB instance port number that scheduler will connect with | `number` | 5432 |
| `SCHEDULER_DB_SERVER` | The DB instance that scheduler will connect with | `string` | |
| `SCHEDULER_DB_USER` | Username of the DB instance | `string` | |
| `SCHEDULER_LOCAL_STORE` | Local storage for scheduler in the container | `string` | /usr/src/app/scheduler_file_store |
| `SCHEDULER_LOGGING` | Whether or not you want Javalin to log server information | `string` | true |
| `SCHEDULER_OUTPUT_MODE` | how scheduler output is sent back to aerie | `string` | UpdateInputPlanWithNewActivities |
| `SCHEDULER_PORT` | Port number for the scheduler server | `number` | 27185 |
| `SCHEDULER_RULES_JAR` | Jar file to load scheduling rules from (until user input to database) | `string` | /usr/src/app/merlin_file_store/scheduler_rules.jar |

## Aerie UI

Expand Down
30 changes: 17 additions & 13 deletions deployment/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,19 +17,23 @@ Before you can deploy Aerie, you must install and configure the following produc

## Setting the Environment Variables

Each container has environment variables that can be used to fine-tune your deployment. See the [environment variable documentation](./Environment.md) for the complete set of variables. See the example [docker-compose.yml](./docker-compose.yml) file for examples on how to set the environment variables.

Inside the [.env](./.env) there is a collection of variables that **must** be set in order to deploy Aerie using the default [init-aerie.sh](./postgres-init-db/init-aerie.sh) and [docker-compose.yml](./docker-compose.yml). They are, as follows:

| Name | Description |
|-----------------------|------------------------------------------------------------------------------|
| REPOSITORY_DOCKER_URL | The URL used to fetch images of Aerie packages. |
| DOCKER_TAG | The version of the Aerie images to fetch. |
| AERIE_USERNAME | The username used for Aerie services when they access the Postgres database. |
| AERIE_PASSWORD | The password used for Aerie services when they access the Postgres database. |
| POSTGRES_DB | The name of the Postgres database. |
| POSTGRES_USER | The username of the superuser for the Postgres database. |
| POSTGRES_PASSWORD | The password of the superuser for the Postgres database. |
Each container has environment variables that can be used to fine-tune your deployment.
See the [environment variable documentation](./Environment.md) for the complete set of variables.
See the example [docker-compose.yml](./docker-compose.yml) file for examples on how to set the environment variables.

Inside the [.env](./.env) there is a collection of variables that **must** be set in order to deploy Aerie using the default [init-aerie.sh](./postgres-init-db/init-aerie.sh) and [docker-compose.yml](./docker-compose.yml).
They are, as follows:

| Name | Description |
| ----------------------- | ---------------------------------------------------------------------------------------------------------------------------- |
| `REPOSITORY_DOCKER_URL` | The URL used to fetch images of Aerie packages. |
| `DOCKER_TAG` | The version of the Aerie images to fetch. |
| `AERIE_USERNAME` | The username used for Aerie services when they access the Postgres database. |
| `AERIE_PASSWORD` | The password used for Aerie services when they access the Postgres database. |
| `POSTGRES_DB` | The name of the Postgres database. |
| `POSTGRES_USER` | The username of the superuser for the Postgres database. |
| `POSTGRES_PASSWORD` | The password of the superuser for the Postgres database. |
| `UNTRUE_PLAN_START` | Temporary solution to provide plan start time to models, should be set to a time that models will not fail to initialize on. |

### **At minimum, you _must_ assign values to the environment variables already present in [.env](./.env) in order to deploy Aerie**.

Expand Down
2 changes: 2 additions & 0 deletions deployment/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ services:
JAVA_OPTS: >
-Dorg.slf4j.simpleLogger.defaultLogLevel=WARN
-Dorg.slf4j.simpleLogger.logFile=System.err
UNTRUE_PLAN_START: "2000-01-01T11:58:55.816Z"
image: "${REPOSITORY_DOCKER_URL}/aerie-merlin:${DOCKER_TAG}"
ports: ["27183:27183"]
restart: always
Expand All @@ -72,6 +73,7 @@ services:
-Dorg.slf4j.simpleLogger.defaultLogLevel=INFO
-Dorg.slf4j.simpleLogger.log.com.zaxxer.hikari=WARN
-Dorg.slf4j.simpleLogger.logFile=System.err
UNTRUE_PLAN_START: "2000-01-01T11:58:55.816Z"
image: "${REPOSITORY_DOCKER_URL}/aerie-merlin-worker:${DOCKER_TAG}"
restart: always
volumes:
Expand Down
Loading

0 comments on commit 6ead5b6

Please sign in to comment.