This Spring Boot service implements basic read/write from Open Bank Project Bank Account Service interface.
See GitHub project
Install and deploy a VMware GemFire cluster
In Gfsh
create region --name=BankAccount --type=PARTITION
start server --name=redisServer1 --locators=localhost[10334] --server-port=40404 --classpath=/Users/devtools/repositories/IMDG/gemfire/vmware-gemfire-for-redis-apps-1.1.0/lib/* --J=-Dgemfire-for-redis-enabled=true
gfsh> start server --name=redisServer2 --locators=localhost[10334] --server-port=40405 --classpath=/Users/devtools/repositories/IMDG/gemfire/vmware-gemfire-for-redis-apps-1.1.0/lib/* --J=-Dgemfire-for-redis-port=6380 --J=-Dgemfire-for-redis-enabled=true
See Docker Hub Image
mvn install
cd applications/bank-account-rest-service
mvn spring-boot:build-image
docker tag bank-account-rest-service:0.0.4-SNAPSHOT cloudnativedata/bank-account-rest-service:0.0.4-SNAPSHOT
docker push cloudnativedata/bank-account-rest-service:0.0.4-SNAPSHOT
Install and Deploy a GemFire cluster
kubectl exec gemfire1-locator-0 -- gfsh -e "connect" -e "create region --name=BankAccount --type=PARTITION"
k apply -f cloud/k8/apps/account-rest-service
k delete -f cloud/k8/apps/account-rest-service
k port-forward deployments/account-rest-service 4001:4001
POST
curl -X 'POST' \
'http://localhost:4001/obp/v4.0.0/banks/gh.29.uk/accounts' \
-H 'accept: */*' \
-H 'Content-Type: application/json' \
-d '{
"user_id":"9ca9a7e4-6d02-40e3-a129-0b2bf89de9b1",
"label":"My Account",
"product_code":"AC",
"balance":{ "currency":"EUR", "amount":"0" },
"branch_id":"DERBY6",
"account_routings":[{ "scheme":"AccountNumber", "address":"4930396" }]}'
GET
/obp/v4.0.0/my/banks/at02-0182--01/accounts/ACCOUNT_ID/account
curl -X 'GET' \
'http://localhost:4001/obp/v4.0.0/banks/gh.29.uk/accounts/20211130162851787-571565789/account' \
-H 'accept: */*';echo