No description, website, or topics provided.
Clone or download
knollfear Knollfear/api v1 fix (#109)
* fixing bad merge issue

* restoring operation ID to ensure swagger passes in the right headers
Latest commit e255d99 Dec 13, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github BCDA-38: Create pull request template (#6) Jul 31, 2018
Dockerfiles Knollfear/bcda 520 clean up unit test results (#94) Dec 10, 2018
bcda Knollfear/api v1 fix (#109) Dec 13, 2018
bcdaworker bcda-602 add new relic monitoring to worker job processing (#99) Dec 11, 2018
db BCDA-313: Develop unit tests for bcda/api.go, part 2 (#47) Oct 15, 2018
ops BCDA-350: Sign RPMs with GPG Keys (#97) Dec 6, 2018
shared_files BCDA-509: Tests for servicemux.go (#77) Nov 21, 2018
test BCDA-598: Develop a collection of Postman integration tests (#105) Dec 12, 2018
vendor BCDA-446: Download data issue - truncated file when requesting from A… Nov 6, 2018
.gitignore BCDA 442: Cleanup files for expired jobs (#78) Nov 20, 2018
.travis.yml BCDA-502: Endpoint Sanity Check Tests (#82) Nov 29, 2018
API.md BCDA-543: Update our Getting Started documentation (#79) Nov 27, 2018
Gopkg.lock BCDA-446: Download data issue - truncated file when requesting from A… Nov 6, 2018
Gopkg.toml BCDA-302: Modify workflow established in BCDA-310 to actually query t… Oct 3, 2018
LICENSE.md BCDA-96: add a license doc (#10) Aug 30, 2018
Makefile BCDA-350: Sign RPMs with GPG Keys (#97) Dec 6, 2018
README.md add cli command and auth backend implementation for creating alpha pa… Oct 26, 2018
docker-compose.debug.yml Add delve debugger commands (#20) Sep 14, 2018
docker-compose.test.yml BCDA-502: Endpoint Sanity Check Tests (#82) Nov 29, 2018
docker-compose.yml BCDA-395: Add /Patient endpoint for bulk export of patient data (#95) Dec 6, 2018
unit_test.sh Knollfear/bcda 520 clean up unit test results (#94) Dec 10, 2018

README.md

Beneficiary Claims Data API

Build Status

Dependencies

To get started, install some dependencies:

  1. Install Go
  2. Install Docker
  3. Install Docker Compose
  4. Ensure all dependencies installed above are on PATH and can be executed directly from command line.

Build / Start

Build the images and start the containers:

  1. Build the images and load with fixture data
make docker-bootstrap
  1. Start the containers
docker-compose up

Test

Run tests and produce test metrics:

  1. Run tests (this places results and a coverage report in test_results/):
make test

Use the application

See: API documentation

Environment variables

Configure the bcda and bcdaworker apps by setting the following environment variables.

bcda
BCDA_ERROR_LOG <file_path>
BCDA_REQUEST_LOG <file_path>
BCDA_BB_LOG <file_path>
BB_CLIENT_CERT_FILE <file_path>
BB_CLIENT_KEY_FILE <file_path>
BB_SERVER_LOCATION <url>
FHIR_PAYLOAD_DIR <directory_path>
JWT_EXPIRATION_DELTA <integer> (time in hours that JWT access tokens are valid for)
bcdaworker
BCDA_WORKER_ERROR_LOG <file_path>
BCDA_BB_LOG <file_path>
BB_CLIENT_CERT_FILE <file_path>
BB_CLIENT_KEY_FILE <file_path>
BB_SERVER_LOCATION <url>
FHIR_PAYLOAD_DIR <directory_path>
BB_TIMEOUT_MS <integer>

Other things you can do

Use docker to look at the api database with psql:

docker run --rm --network bcda-app_default -it postgres psql -h bcda-app_db_1 -U postgres bcda

See docker-compose.yml for the password.

Use docker to run the CLI against an API instance

docker exec -it bcda-app_api_1 bash -c 'tmp/bcda -h'

If you have no data in your database, you can load the fixture data with

make load-fixtures