bcgov / jag-crdp

Apache License 2.0
0 stars 1 forks source link

jag-crdp

Lifecycle:Experimental Maintainability Test Coverage

Recommended Tools

Application Endpoints

Local Host: http://127.0.0.1:8080

Actuator Endpoint Local: http://localhost:8080/actuator/health

Code Climate: https://codeclimate.com/github/bcgov/jag-crdp

WSDL Endpoint Local: N/A

Required Environmental Variables

BASIC_AUTH_PASS: The password for the basic authentication. This can be any value for local

BASIC_AUTH_USER: The username for the basic authentication. This can be any value for local

Additional Env Variables

Optional Environmental Variables

SPLUNK_HTTP_URL: The url for the splunk hec.

SPLUNK_TOKEN: The bearer token to authenticate the application.

SPLUNK_INDEX: The index that the application will push logs to. The index must be created in splunk before they can be pushed to.

Building the Application

1) Make sure using java 11 for the project modals and sdk 2) Run mvn compile 3) Make sure jag-crdp-common-models, jag-crdp-transmit-models and jag-crdp-process-models are marked as generated sources roots (xjc)

Pre-running the application

Run docker run -p 5672:5672 -p 15672:15672 rabbitmq:management

Running the application

Option A) Intellij 1) Set env variables. 2) Run the application

Option B) Jar, e.g., to run 'jag-crdp-transmit-receiver' application 1) Run mvn package 2) Run cd jag-crdp-transmit-receiver 3) Run java -jar ./target/jag-crdp-transmit-receiver.jar $ENV_VAR$ (Note that $ENV_VAR$ are environment variables)

Option C) Docker, e.g., to run 'jag-crdp-transmit-receiver' application 1) Run mvn package 2) Run cd jag-crdp-transmit-receiver 3) Run docker build -t jag-crdp-transmit-receiver . from root folder 4) Run docker run -p 8080:8080 jag-crdp-transmit-receiver $ENV_VAR$ (Note that $ENV_VAR$ are environment variables)

Running RabbitMQ

Pre Commit

1) Do not commit \CRLF use unix line enders 2) Run the linter mvn spotless:apply

JaCoCo Coverage Report

1) Run mvn clean verify 2) Open crdp-code-coverage/target/site/jacoco/index.html in a browser