From 7c9acda315642a4df201a5389e74dfc2e78ea1c4 Mon Sep 17 00:00:00 2001 From: Sebastian Henschel Date: Mon, 6 Mar 2017 15:34:56 +0100 Subject: [PATCH] Added README for Akka setup --- README.Akka.md | 60 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 README.Akka.md diff --git a/README.Akka.md b/README.Akka.md new file mode 100644 index 000000000..1b46b3541 --- /dev/null +++ b/README.Akka.md @@ -0,0 +1,60 @@ +# Intro + +Akka is a toolkit and runtime for building highly concurrent, distributed, and resilient message-driven applications on the JVM. +See http://akka.io + + +To use Akka, you want to have two different machines: +- One considered `remote` which stores the data +- One considered `local` which is the public facing side of the API, where your users will connect + +Both run current versions of the Open Bank Project API, but configured and run differently. + + +# Remote side + +- Configure `src/main/resources/default.props`: + +```ini +# Remote end gets data 'locally' +remotedata.enable=false +# Your remote's external IP address +remotedata.hostname=10.0.0.19 +# Arbitrary port of your choosing +remotedata.port=5448 + +# Optionally configure postgres, otherwise file-based H2 will be used +remotedata.db.driver=org.postgresql.Driver +remotedata.db.url=jdbc:postgresql://localhost:5432/dbname?user=user&password=password +``` + +## Run + +```bash +#!/bin/sh + +cd ${HOME}/OBP-API/ && /usr/bin/nohup /usr/bin/mvn compile exec:java -Dexec.mainClass="code.remotedata.RemotedataActors" -Dexec.args="standalone" > ${HOME}/akka_remote_api.log & +``` + + + +# Local OBP API side + +- Configure `src/main/resources/default.props`: + +```ini +# Local end gets data remotely +remotedata.enable=true +# Your remote's public IP address +remotedata.hostname=10.0.0.19 +# Arbitrary port of your choosing, has to match remote above +remotedata.port=5448 +``` + +# Run + +```bash +#!/bin/sh + +cd ${HOME}/OBP-API/ && /usr/bin/nohup /usr/bin/mvn jetty:run -Djetty.port=8080 -DskipTests > ${HOME}/akka_local_api.log & +```