Coder Social home page Coder Social logo

hmcts / sscs-hearings-api Goto Github PK

View Code? Open in Web Editor NEW
2.0 12.0 1.0 3.01 MB

This is an API to interface the hearing management component (HMC) with SSCS.

License: MIT License

Shell 0.34% Dockerfile 0.03% Groovy 0.39% HCL 0.35% Java 98.90%
jenkins-cft jenkins-cft-j-z

sscs-hearings-api's Introduction

sscs-hearings-api

Build Status Coverage Status Coverage Code Smells Duplicated Lines (%) Maintainability Rating Reliability Rating Technical Debt

Building and deploying the application

Building the application

The project uses Gradle as a build tool. It already contains ./gradlew wrapper script, so there's no need to install gradle.

To build the project execute the following command:

  ./gradlew build

Running the application

Create the image of the application by executing the following command:

  ./gradlew assemble

Create docker image:

  docker-compose build

Run the distribution (created in build/install/sscs-hearings-api directory) by executing the following command:

  docker-compose up

This will start the API container exposing the application's port (set to 8083 in this template app).

In order to test if the application is up, you can call its health endpoint:

  curl http://localhost:8083/health

You should get a response similar to this:

  {"status":"UP","diskSpace":{"status":"UP","total":249644974080,"free":137188298752,"threshold":10485760}}

Alternative script to run application

To skip all the setting up and building, just execute the following command:

./bin/run-in-docker.sh

For more information:

./bin/run-in-docker.sh -h

Script includes bare minimum environment variables necessary to start api instance. Whenever any variable is changed or any other script regarding docker image/container build, the suggested way to ensure all is cleaned up properly is by this command:

docker-compose rm

It clears stopped containers correctly. Might consider removing clutter of images too, especially the ones fiddled with:

docker images

docker image rm <image-id>

There is no need to remove postgres and java or similar core images.

AppInsights Events

You will need to set the environment variable for the HMC failure messages to be sent as events to Azure AppInsights.

The env var should look similar to below and will need to be grabbed from Azure or another developer.

APPLICATIONINSIGHTS_CONNECTION_STRING=InstrumentationKey\=xxx-xxx-xxx\;IngestionEndpoint\=xxx-xxx-xxx/

Other

Hystrix offers much more than Circuit Breaker pattern implementation or command monitoring. Here are some other functionalities it provides:

License

This project is licensed under the MIT License - see the LICENSE file for details

sscs-hearings-api's People

Contributors

amoslv1 avatar andreitrushkov avatar baskernadarv1 avatar benouaer avatar bensonlievoco avatar chris-pateman avatar dattipoehmcts avatar dependabot[bot] avatar dgordonv1 avatar dholaramgurjar avatar filippo-possenti-version1 avatar gemmatalbot avatar gorkem-turan avatar hajam09 avatar hashimalisolirius avatar ikirsanov avatar jonathan-weston1 avatar justmehmet avatar katkovacs1 avatar lturkingtonhmcts avatar mcareyma avatar mohammedcodess avatar nickhill111 avatar omer-hmcts avatar renovate[bot] avatar sanjayparekh-hmcts avatar ss-evoco avatar suetlaihmcts avatar teawithlucas avatar zikrurr avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Forkers

jarekpierchala

sscs-hearings-api's Issues

Dependency Dashboard

This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.

Rate-Limited

These updates are currently rate-limited. Click on a checkbox below to force their creation now.

  • Update dependency com.github.hmcts:sscs-common to v5.11.6
  • Update plugin org.sonarqube to v5
  • Update dependency com.github.tomakehurst:wiremock to v3
  • Update Tools - Data Processing (com.networknt:json-schema-validator, com.fasterxml.jackson.core:jackson-databind, com.fasterxml.jackson.datatype:jackson-datatype-jsr310, com.fasterxml.jackson.core:jackson-annotations, com.fasterxml.jackson.core:jackson-core)
  • Update Tools - General (org.yaml:snakeyaml, commons-io:commons-io, org.projectlombok:lombok)
  • Update Helm release java to v5.2.1
  • Update dependency org.elasticsearch:elasticsearch to v7.17.24
  • Update Terraform azurerm to ~> 3.116.0
  • Update dependency hashicorp/terraform to v1.9.5
  • Update Github to v4 (major) (actions/checkout, actions/setup-java)
  • Update Terraform azurerm to v4
  • Update plugin com.gorylenko.gradle-git-properties to v2.4.2
  • Update dependency gradle to v8.10.1
  • Update dependency pmd to v7
  • ๐Ÿ” Create all rate-limited PRs at once ๐Ÿ”

Open

These updates have all been created already. Click a checkbox below to force a retry/rebase of any.

  • Update Spring All (org.springframework.security:spring-security-rsa, org.springframework.cloud:spring-cloud-dependencies, org.springframework.retry:spring-retry, org.springframework.security:spring-security-oauth2-core, org.springframework.security:spring-security-core, org.springframework.security:spring-security-config, org.springframework.security:spring-security-web, org.springframework.security:spring-security-crypto, org.springframework.security:spring-security-oauth2-resource-server, io.spring.dependency-management)
  • Update Spring All (major) (org.springframework.cloud:spring-cloud-dependencies, org.springframework.security:spring-security-oauth2-core, org.springframework.security:spring-security-core, org.springframework.security:spring-security-config, org.springframework.security:spring-security-web, org.springframework.security:spring-security-crypto, org.springframework.security:spring-security-oauth2-resource-server, org.springframework.boot)
  • Update HMCTS Core (com.github.hmcts:ccd-client, com.github.hmcts:service-auth-provider-java-client, uk.gov.hmcts.java)
  • Update Logging (ch.qos.logback:logback-classic, ch.qos.logback:logback-core, com.github.hmcts:java-logging, org.apache.logging.log4j:log4j-to-slf4j)
  • Update Logging (major) (org.slf4j:slf4j-api, net.logstash.logback:logstash-logback-encoder)
  • Update hmctspublic.azurecr.io/base/java Docker tag to v21
  • Update Automated Checks (org.pitest:pitest, checkstyle, info.solidsoft.pitest, org.sonarqube, org.owasp.dependencycheck)
  • Update Testing (au.com.dius.pact.consumer:java8, au.com.dius.pact.consumer:junit5, org.mockito:mockito-inline, com.github.tomakehurst:wiremock, org.assertj:assertj-core, org.junit.jupiter:junit-jupiter-engine, org.junit.jupiter:junit-jupiter-api, au.com.dius.pact, com.github.ben-manes.versions)
  • Update Networking (com.azure:azure-messaging-servicebus, com.azure:azure-core, org.springdoc:springdoc-openapi-ui, org.apache.qpid:qpid-jms-client, org.apache.tomcat.embed:tomcat-embed-websocket, org.apache.tomcat.embed:tomcat-embed-el, org.apache.tomcat.embed:tomcat-embed-core)
  • Update Networking (major) (io.rest-assured:json-path, io.rest-assured:xml-path, io.rest-assured:rest-assured, com.microsoft.azure:applicationinsights-web, com.microsoft.azure:applicationinsights-core, io.github.openfeign:feign-httpclient, org.apache.qpid:qpid-jms-client, org.apache.tomcat.embed:tomcat-embed-websocket, org.apache.tomcat.embed:tomcat-embed-el, org.apache.tomcat.embed:tomcat-embed-core)
  • Click on this checkbox to rebase all open PRs at once

Ignored or Blocked

These are blocked by an existing closed PR and will not be recreated unless you click a checkbox below.

Detected dependencies

docker-compose
docker-compose.yml
dockerfile
Dockerfile
  • hmctspublic.azurecr.io/base/java 17-distroless
github-actions
.github/workflows/ci.yml
  • actions/checkout v3
  • actions/setup-java v3
gradle
build.gradle
  • io.spring.dependency-management 1.0.12.RELEASE
  • org.springframework.boot 2.7.18
  • uk.gov.hmcts.java 0.12.27
  • org.owasp.dependencycheck 10.0.3
  • com.github.ben-manes.versions 0.42.0
  • org.sonarqube 4.3.0.3225
  • info.solidsoft.pitest 1.9.11
  • com.gorylenko.gradle-git-properties 2.4.1
  • au.com.dius.pact 4.3.10
  • checkstyle 10.12.1
  • pmd 6.55.0
  • org.springframework.security:spring-security-oauth2-resource-server 5.7.12
  • org.springframework.security:spring-security-crypto 5.7.12
  • org.springframework.security:spring-security-web 5.7.12
  • org.springframework.security:spring-security-config 5.7.12
  • org.springframework.security:spring-security-core 5.7.12
  • org.springframework.security:spring-security-oauth2-core 5.7.12
  • org.springframework.retry:spring-retry 2.0.3
  • org.apache.tomcat.embed:tomcat-embed-core 9.0.86
  • org.apache.tomcat.embed:tomcat-embed-el 9.0.86
  • org.apache.tomcat.embed:tomcat-embed-websocket 9.0.86
  • org.apache.qpid:qpid-jms-client 1.8.0
  • org.apache.logging.log4j:log4j-to-slf4j 2.17.1
  • commons-io:commons-io 2.13.0
  • io.github.openfeign:feign-httpclient 11.10
  • com.squareup.okhttp3:okhttp 4.12.0
  • org.springdoc:springdoc-openapi-ui 1.6.15
  • net.logstash.logback:logstash-logback-encoder 7.4
  • com.github.hmcts:java-logging 6.0.1
  • com.github.hmcts:service-auth-provider-java-client 4.0.3
  • com.github.hmcts:ccd-client 4.9.2
  • org.projectlombok:lombok 1.18.28
  • ch.qos.logback:logback-core 1.2.13
  • ch.qos.logback:logback-classic 1.2.13
  • com.github.hmcts:sscs-common 5.11.4
  • org.slf4j:slf4j-api 1.7.36
  • com.fasterxml.jackson.core:jackson-core 2.15.2
  • com.fasterxml.jackson.core:jackson-annotations 2.15.2
  • com.fasterxml.jackson.datatype:jackson-datatype-jsr310 2.15.2
  • com.fasterxml.jackson.core:jackson-databind 2.15.2
  • com.networknt:json-schema-validator 1.0.86
  • com.azure:azure-core 1.37.0
  • com.azure:azure-messaging-servicebus 7.14.0-beta.1
  • org.elasticsearch:elasticsearch 7.17.12
  • com.microsoft.azure:applicationinsights-core 2.6.4
  • com.microsoft.azure:applicationinsights-web 2.6.4
  • io.rest-assured:rest-assured 4.5.1
  • io.rest-assured:xml-path 4.5.1
  • io.rest-assured:json-path 4.5.1
  • org.junit.jupiter:junit-jupiter-api 5.8.2
  • org.junit.jupiter:junit-jupiter-engine 5.8.2
  • org.pitest:pitest 1.14.2
  • org.codehaus.sonar-plugins:sonar-pitest-plugin 0.5
  • org.assertj:assertj-core 3.22.0
  • commons-io:commons-io 2.13.0
  • com.github.tomakehurst:wiremock 2.27.2
  • org.mockito:mockito-inline 5.1.1
  • au.com.dius.pact.consumer:junit5 4.1.7
  • au.com.dius.pact.consumer:java8 4.1.7
  • au.com.dius.pact.consumer:junit5 4.1.7
  • au.com.dius.pact.consumer:java8 4.1.7
  • org.springframework.cloud:spring-cloud-dependencies 2021.0.1
  • org.yaml:snakeyaml 2.0
  • org.springframework.security:spring-security-rsa 1.1.1
gradle-wrapper
gradle/wrapper/gradle-wrapper.properties
  • gradle 8.9
helm-requirements
charts/sscs-hearings-api/Chart.yaml
  • java 5.2.0
helm-values
charts/sscs-hearings-api/values.yaml
helmv3
charts/sscs-hearings-api/Chart.yaml
  • java 5.2.0
terraform
infrastructure/main.tf
infrastructure/service-bus.tf
infrastructure/state.tf
  • azurerm ~> 3.95.0
terraform-version
infrastructure/.terraform-version
  • hashicorp/terraform 1.7.5

  • Check this box to trigger a request for Renovate to run again on this repository

Action Required: Fix Renovate Configuration

There is an error with this repository's Renovate configuration that needs to be fixed. As a precaution, Renovate will stop PRs until it is resolved.

Error type: Preset is invalid JSON (github>hmcts/sscs-common//.github/sscs-renovate.json)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.