Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 7 additions & 6 deletions .github/workflows/cd-compute.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ jobs:

env:
AWS_REGION: eu-west-3


steps:
- uses: actions/checkout@v4.1.6
Expand All @@ -46,7 +47,7 @@ jobs:
fi

response=$(curl --fail -X POST "https://api.prod.poja.io/gh-repos/${{ github.repository }}/github-workflow-state" \
-H "Authorization: AppBearer ${{ secrets.GITHUB_TOKEN }}" \
-H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \
-H "Content-Type: application/json" \
-d "$(jq -n \
--arg app_env_deployment_id "$app_env_deployment_id_value" \
Expand Down Expand Up @@ -79,10 +80,10 @@ jobs:
run: |
chmod +x ./gradlew
chmod +x .shell/publish_gen_to_maven_local.sh
response=$(curl --fail -X GET "https://api.prod.poja.io/gh-repos/${{ github.repository }}/upload-build-uri?environment_type=$(echo "${{ github.ref_name }}" | tr '[:lower:]' '[:upper:]')" -H "Authorization: AppBearer ${{ secrets.GITHUB_TOKEN }}" -H "Accept: application/json")
response=$(curl -X GET "https://api.prod.poja.io/gh-repos/${{ github.repository }}/upload-build-uri?environment_type=$(echo "${{ github.ref_name }}" | tr '[:lower:]' '[:upper:]')" -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" -H "Accept: application/json")
echo "upload_build_file_uri=$(echo $response | jq -r '.uri')" >> $GITHUB_ENV
echo "to_upload_filename=$(echo $response | jq -r '.filename')" >> $GITHUB_ENV
curl --fail -X GET -o template.yml "$(echo $response | jq -r '.build_template_file_uri')"
curl -X GET -o template.yml "$(echo $response | jq -r '.build_template_file_uri')"

- name: Build project
run: sam build
Expand All @@ -92,7 +93,7 @@ jobs:
shopt -s globstar
zip -r9 ${{ env.to_upload_filename }} .aws-sam
shopt -u globstar
curl --fail -X PUT -H "Content-Type: application/zip" -H "x-amz-tagging: temporary=true" -T ${{ env.to_upload_filename }} "${{ env.upload_build_file_uri }}"
curl -X PUT -H "Content-Type: application/zip" -H "x-amz-tagging: temporary=true" -T ${{ env.to_upload_filename }} "${{ env.upload_build_file_uri }}"

- name: Get current time
uses: gerred/actions/current-time@master
Expand Down Expand Up @@ -124,7 +125,7 @@ jobs:
input_conf_id="null"
fi
response=$(curl --fail -X PUT "https://api.prod.poja.io/gh-repos/${{ github.repository }}/env-deploys?environment_type=$(echo "${{ github.ref_name }}" | tr '[:lower:]' '[:upper:]')" \
-H "Authorization: AppBearer ${{ secrets.GITHUB_TOKEN }}" \
-H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \
-H "Content-Type: application/json" \
-d "$(jq -n \
--arg env_depl_conf_id "$input_conf_id" \
Expand Down Expand Up @@ -174,7 +175,7 @@ jobs:
fi

response=$(curl --fail -X POST "https://api.prod.poja.io/gh-repos/${{ github.repository }}/github-workflow-state" \
-H "Authorization: AppBearer ${{ secrets.GITHUB_TOKEN }}" \
-H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \
-H "Content-Type: application/json" \
-d "$(jq -n \
--arg app_env_deployment_id "$app_env_deployment_id_value" \
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ jobs:

env:
AWS_REGION: eu-west-3


steps:
- uses: actions/checkout@v4.1.6
Expand All @@ -30,7 +31,8 @@ jobs:
distribution: 'corretto'
- run: chmod +x gradlew
- run: chmod +x .shell/publish_gen_to_maven_local.sh
- run: ./gradlew test
- run: |
./gradlew test



Expand Down
17 changes: 9 additions & 8 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -108,9 +108,10 @@ jacocoTestReport {
}

dependencies {
implementation 'org.springframework.boot:spring-boot-starter-web'
implementation 'org.springframework.boot:spring-boot-starter-web:3.2.2'
testImplementation 'org.testcontainers:testcontainers:2.0.2'

implementation 'com.fasterxml.jackson.datatype:jackson-datatype-jsr310'
implementation 'com.fasterxml.jackson.datatype:jackson-datatype-jsr310:2.15.3'

implementation 'com.amazonaws.serverless:aws-serverless-java-container-springboot3:2.1.0'
implementation 'software.amazon.awssdk:aws-query-protocol:2.20.26'
Expand All @@ -132,16 +133,16 @@ dependencies {

implementation 'org.reflections:reflections:0.10.2'

compileOnly 'org.projectlombok:lombok'
annotationProcessor 'org.projectlombok:lombok'
testCompileOnly 'org.projectlombok:lombok'
testAnnotationProcessor 'org.projectlombok:lombok'
compileOnly 'org.projectlombok:lombok:1.18.30'
annotationProcessor 'org.projectlombok:lombok:1.18.30'
testCompileOnly 'org.projectlombok:lombok:1.18.30'
testAnnotationProcessor 'org.projectlombok:lombok:1.18.30'

implementation 'org.openapitools:jackson-databind-nullable:0.2.6'
implementation 'io.swagger:swagger-annotations:1.6.12'

testImplementation 'org.springframework.boot:spring-boot-starter-test'
testImplementation 'org.testcontainers:junit-jupiter:1.19.1'
testImplementation 'org.springframework.boot:spring-boot-starter-test:3.2.2'
testImplementation 'org.testcontainers:testcontainers-junit-jupiter:2.0.2'
testImplementation 'org.junit-pioneer:junit-pioneer:2.2.0'

implementation 'dev.langchain4j:langchain4j-open-ai:1.1.0'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,10 @@ public String hazavao(
@RequestParam(required = false) Boolean fissureCassure,
@RequestParam(required = false) Boolean risqueFeu,
@RequestParam(required = false) Double noteDegradationGlobale,
@RequestParam(required = false) String categorie) {
@RequestParam(required = false) String categorie,
@RequestParam(required = false) String revetement2,
@RequestParam(required = false) Double hauteurBatiment,
@RequestParam(required = false) String commentaireCouvreur) {

return analyseurToiture.apply(
new Toit(
Expand All @@ -55,6 +58,9 @@ public String hazavao(
fissureCassure,
risqueFeu,
noteDegradationGlobale,
categorie));
categorie,
revetement2,
hauteurBatiment,
commentaireCouvreur));
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ public String handleRequest(SQSEvent event, Context context) {
log.info("SQS messages: {}", messages);

var applicationContext = applicationContext();

var eventConsumer = applicationContext.getBean(EventConsumer.class);
var messageConverter = applicationContext.getBean(ConsumableEventTyper.class);

Expand Down
Loading
Loading