dev #61

Merged
Thibaut merged 4 commits from dev into master 2025-11-14 12:45:54 +00:00
2 changed files with 4 additions and 0 deletions
Showing only changes of commit cc5534ef00 - Show all commits

View File

@ -23,6 +23,8 @@ public class AssoEndpoints {
return stateIdService.get_status(stateId).onFailure().transform(throwable -> {
if (throwable instanceof WebApplicationException exception) {
if (exception.getResponse().getStatus() == 404)
return new DNotFoundException("Service momentanément indisponible");
if (exception.getResponse().getStatus() == 400)
return new DNotFoundException("Asso introuvable");
}
return throwable;

View File

@ -1,6 +1,7 @@
package fr.titionfire.ffsaf.rest.client;
import fr.titionfire.ffsaf.rest.data.AssoData;
import io.quarkus.cache.CacheResult;
import io.smallrye.mutiny.Uni;
import jakarta.ws.rs.GET;
import jakarta.ws.rs.Path;
@ -13,5 +14,6 @@ public interface StateIdService {
@GET
@Path("/structure/{id}")
@CacheResult(cacheName = "AssoData_status")
Uni<AssoData> get_status(@PathParam("id") String id);
}