Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
lorenzo-catalano committed Jan 11, 2024
1 parent c877a7a commit 0467c21
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,12 @@ public boolean verifyPaymentNotice(Station station) {
cosmosEventsRepository.newEvent(
station.getStationCode(),
Constants.EVENT_FORWARDER_CALL,
String.format("call forwarder for station [%s]", station.getStationCode()));
String.format("call forwarder for station [%s]\n[%s:%s%s]",
station.getStationCode(),
station.getServicePof().getTargetHost(),
station.getServicePof().getTargetPort(),
station.getServicePof().getTargetPath()
));
final RequestEntity.BodyBuilder requestBuilder =
RequestEntity.method(
HttpMethod.POST, UriComponentsBuilder.fromHttpUrl(url).build().toUri());
Expand All @@ -55,7 +60,7 @@ public boolean verifyPaymentNotice(Station station) {
requestBuilder.header("X-Host-Url", station.getServicePof().getTargetHost());
requestBuilder.header("X-Host-Port", station.getServicePof().getTargetPort() + "");
requestBuilder.header("X-Host-Path", station.getServicePof().getTargetPath());
requestBuilder.header("SOAPAction", "paVerifyPaymentNotice");
requestBuilder.header("SOAPAction", "\"paVerifyPaymentNotice\"");

String replacedBody =
paVerifyRequestBody
Expand All @@ -66,13 +71,13 @@ public boolean verifyPaymentNotice(Station station) {
ResponseEntity<String> responseEntity = null;
try {
responseEntity = restTemplate.exchange(body, String.class);
} catch (HttpStatusCodeException e) {
} catch (Exception e) {
cosmosEventsRepository.newEvent(
station.getStationCode(),
Constants.EVENT_FORWARDER_CALL_RESP_ERROR,
String.format(
"call forwarder for station [%s] returned",
station.getStationCode(), e.getStatusCode()));
"call forwarder for station [%s] returned [%s]",
station.getStationCode(), e.getMessage()));
return false;
}

Expand Down
12 changes: 6 additions & 6 deletions src/main/resources/application-local.properties
Original file line number Diff line number Diff line change
Expand Up @@ -34,14 +34,14 @@ remover.range.fault.limit=6

aws.region=weu
aws.ses.user=[email protected]
aws.mailto=[email protected]

excludedStations=""

excludedStations=${EXCLUDED_STATIONS}

#config.refresh.cron= */10 * * * * *
nodo.monitor.cron= */10 * * * * *
config.refresh.cron= -
nodo.monitor.cron= -
nodo.calc.cron= */10 * * * * *
station.monitor.cron= */10 * * * * *
station.calc.cron= */10 * * * * *
station.monitor.cron= -
station.calc.cron= -

logging.level.it.gov.pagopa.standinmanager.service=DEBUG

0 comments on commit 0467c21

Please sign in to comment.