Skip to content

Commit

Permalink
review comment updates
Browse files Browse the repository at this point in the history
  • Loading branch information
farrell-m committed Jun 7, 2024
1 parent ba7860b commit 941e6d5
Show file tree
Hide file tree
Showing 6 changed files with 41 additions and 28 deletions.
9 changes: 8 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,11 @@ In order to generate the interface and models a build can be run on the overall
## caab-service

the caab-service implements the api interface generated in the caab-api subproject.
This service directly interacts with the Transient Data Store in EBS.
This service directly interacts with the Transient Data Store in EBS.

## Common Components

This API uses components from the [LAA CCMS Common Library](https://github.com/ministryofjustice/laa-ccms-spring-boot-common):

- [laa-ccms-spring-boot-plugin](https://github.com/ministryofjustice/laa-ccms-spring-boot-common?tab=readme-ov-file#laa-ccms-spring-boot-gradle-plugin-for-java--spring-boot-projects)
- [laa-ccms-spring-boot-starter-auth](https://github.com/ministryofjustice/laa-ccms-spring-boot-common/tree/main/laa-ccms-spring-boot-starters/laa-ccms-spring-boot-starter-auth)
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
plugins {
id 'net.researchgate.release' version '3.0.2'
id 'uk.gov.laa.ccms.springboot.laa-ccms-spring-boot-gradle-plugin' version '0.0.2' apply false
id 'uk.gov.laa.ccms.springboot.laa-ccms-spring-boot-gradle-plugin' version '0.0.3' apply false
}

subprojects {
Expand Down
2 changes: 1 addition & 1 deletion caab-service/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ dependencies {
implementation files('lib/ojdbc8.jar')

//Enable access token authentication
implementation 'uk.gov.laa.ccms.springboot:laa-ccms-spring-boot-starter-auth:0.0.3-b2f8726-SNAPSHOT'
implementation 'uk.gov.laa.ccms.springboot:laa-ccms-spring-boot-starter-auth'

//Enable Swagger UI
implementation 'org.springdoc:springdoc-openapi-starter-webmvc-ui:2.5.0'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,6 @@ static void properties(DynamicPropertyRegistry registry) {
registry.add("spring.datasource.url", oracleContainerSingleton.getOracleContainer()::getJdbcUrl);
registry.add("spring.datasource.username", oracleContainerSingleton.getOracleContainer()::getUsername);
registry.add("spring.datasource.password", oracleContainerSingleton.getOracleContainer()::getPassword);

registry.add("laa.ccms.springboot.starter.auth.authorized-clients", () -> "[{\"name\":\"caab-ui\",\"roles\":[\"ALL\"],\"token\":\"c196393a-f279-45ba-b5d5-f93e6d30465a\"}]");
registry.add("laa.ccms.springboot.starter.auth.authorized-roles", () -> "[{\"name\":\"ALL\",\"URIs\":[\"/**\"]}]");
registry.add("laa.ccms.springboot.starter.auth.unprotected-uris", () -> "[\"\"]");
}
}

21 changes: 0 additions & 21 deletions caab-service/src/integrationTest/resources/application-local.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,24 +9,3 @@ spring:
database-platform: org.hibernate.dialect.OracleDialect
hibernate:
ddl-auto: none

laa.ccms.springboot.starter.auth:
authentication-header: "Authorization"
authorized-clients: '[
{
"name": "integration-test-runner",
"roles": [
"ALL"
],
"token": "c196393a-f279-45ba-b5d5-f93e6d30465a"
}
]'
authorized-roles: '[
{
"name": "ALL",
"URIs": [
"/**"
]
}
]'
unprotected-uris: [ "/swagger-ui.html", "/swagger-ui/**", "/v3/api-docs/**", "/favicon.ico", "/open-api-specification.yml"]
31 changes: 31 additions & 0 deletions caab-service/src/integrationTest/resources/application.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
laa:
ccms:
caab:
converters:
boolean:
true_values:
Y,Yes
false_values:
N,No
springboot:
starter:
auth:
authentication-header: "Authorization"
authorized-clients: '[
{
"name": "integration-test-runner",
"roles": [
"ALL"
],
"token": "c196393a-f279-45ba-b5d5-f93e6d30465a"
}
]'
authorized-roles: '[
{
"name": "ALL",
"URIs": [
"/**"
]
}
]'
unprotected-uris: [ "/swagger-ui.html", "/swagger-ui/**", "/v3/api-docs/**", "/favicon.ico", "/open-api-specification.yml"]

0 comments on commit 941e6d5

Please sign in to comment.