The Probate Orchestrator is an API Gateway that mediates API calls between Probate frontend and APIs such as the back office, submit service and business service.
It is written Java and uses the Sprint Boot framework.
probate-frontend • probate-caveats-frontend • probate-back-office • probate-orchestrator-service • probate-business-service • probate-submit-service • probate-persistence-service
- Java 21
- Gradle
Run the service by executing the following command:
$ ./gradlew bootRun
API documentation is provided with Swagger:
http://localhost:4400/swagger-ui.html
- UI to interact with the API resources
# rebuild every time you make changes
./gradlew assemble
# first time only
npx @hmcts/probate-dev-env --create
# start the dev env
npx @hmcts/probate-dev-env
You may run a local instance of orchestrator that points towards AAT BE services to use in conjunction with a local FE instance (probate-frontend or probate-caveats). This allows one to debug the orchestrator by triggering events through local FE.
Steps:
- Ensure VPN is on.
- Run
./gradlew generateAatEnvFile
- Run
POINT_TO_AAT=true ./gradlew run
- After ~10 seconds, orchestrator will be running.
To run all unit tests please execute the following command:
$ ./gradlew test
To run all checks (including unit tests) please execute the following command:
$ ./gradlew check
You can manually run a cron task from the cli:
TASK_NAME=[task] java -jar probate-orchestrator-service.jar run
# E.g.
TASK_NAME=SmeeAndFordExtractTask java -jar probate-orchestrator-service.jar
# or
TASK_NAME=SmeeAndFordExtractTask ./gradlew bootRun
To configure a new cron in AAT please checkout the cnp-flux-config repository and run:
./bin/add-cron.sh SmeeAndFordExtractTask ~/cnp-flux-config "0/10 * * * *"
Then create a PR in the cnp-flux-config repository.
Note that the cron will only run in the aat-00 cluster as we don't have a way to run the job once over multiple clusters. Let's hope that cluster doesn't go down.
When building the project in your IDE (eclipse or IntelliJ), Lombok plugin will be required to compile.
For IntelliJ IDEA, please add the Lombok IntelliJ plugin:
- Go to
File > Settings > Plugins
- Click on
Browse repositories...
- Search for
Lombok Plugin
- Click on
Install plugin
- Restart IntelliJ IDEA
Plugin setup for other IDE's are available on [https://projectlombok.org/setup/overview]
This project is licensed under the MIT License - see the LICENSE file for details.