noms-digital-studio/delius-api-pollpushpoke

Name: delius-api-pollpushpoke

Owner: NOMS Digital Studio

Description: A tactical solution to provide simulated external access to delius APIs. The other half of delius-api-job-schedular

Created: 2017-12-21 09:37:04.0

Updated: 2017-12-21 10:28:01.0

Pushed: 2018-01-09 15:15:34.0

Homepage: null

Size: 23

Language: Scala

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

delius-api-pollpushpoke

Self-contained fat-jar micro-service to poll a source API for delius API jobs, push to a target API, and POST back to the job scheduler It is a pretty horrid tactical solution to problems of network access. It is also a POC.

Building and running

Prerequisites:

Build commands:

Running deployable fat jar:

Configuration parameters can be supplied via environment variables, e.g.:

Development notes

Developed in Scala 2.12, using Akka HTTP for HTTP client functionality, and Akka Actors to provide a highly scalable multi-threaded state machine.

The pull/push.poke functionality is unit tested via dependency-injected mock APIs. The source and target REST APIs are also directly tested via WireMock HTTP Servers that mock the HTTP endpoints.

The implementation will be updated as reference source and target API environments become available.

Deployment notes

Configurable via environment parameters:

See Configuration.scala for a full list of configuration parameters.

Running against a mocked Delius instance

Run wiremock standalone and configure for Delius mock endpoint


This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.