Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/pn 10050 bis #504

Merged
merged 11 commits into from
Jun 17, 2024
Merged
6 changes: 3 additions & 3 deletions scripts/aws/cfn/microservice-dev-cfg.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"PnEcPECMaxMessageSizeMB": "30",
"PnEcPECAttachmentRule": "FIRST",
"PnEcPECTipoRicevutaBreve": "false;2024-03-14T23:00:00Z;true",
"PnEcProviderSwitchRead": "1970-01-01T00:00:00Z;aruba|namirial",
"PnEcProviderSwitchRead": "1970-01-01T00:00:00Z;namirial",
"PnEcProviderSwitchWrite": "1970-01-01T00:00:00Z;namirial",
"PnEcNamirialServerImapAddress": "send.sicurezzapostale.it",
"PnEcNamirialServerSmtpAddress": "send.sicurezzapostale.it",
Expand All @@ -38,9 +38,9 @@
"PnEcNamirialPoolSmtpMaxidle": "40",
"PnEcNamirialPoolSmtpMinidle": "1",
"PnEcNamirialServerCache": "false",
"PnEcNamirialServerCacheEndpoint": "18.102.130.190:6379",
"PnEcNamirialServerCacheEndpoint": "",
"SpringCodecMaxInMemorySize": "256KB",
"PnEcConsRefinementDuration": "PT1M",
"PnEcConsAllowedFutureOffsetDuration": "1m",
"CpuValue": "1024",
"MemoryAmount": "4GB"
}
Expand Down
6 changes: 3 additions & 3 deletions scripts/aws/cfn/microservice.yml
Original file line number Diff line number Diff line change
Expand Up @@ -695,10 +695,10 @@ Parameters:
Description: "[Cartaceo- Ricezione Esiti] Stato della funzionalità che considera BOOKED gli eventi senza uno stato SENT"
Default: 'false'

PnEcConsRefinementDuration:
PnEcConsAllowedFutureOffsetDuration:
Type: String
Description: "[Cartaceo - Ricezione Esiti] Offset usato per traslare il controllo nel futuro su statusDateTime e clientRequestTimestamp"
Default: 'PT1M'
Default: '1m'

### S3 BUCKET FOR OVERSIZE SQS MESSAGES ###

Expand Down Expand Up @@ -920,7 +920,7 @@ Resources:
ContainerEnvEntry67: !Sub 'PnEcNamirialServerCache=${PnEcNamirialServerCache}'
ContainerEnvEntry68: !Sub 'PnEcNamirialServerCacheEndpoint=${PnEcNamirialServerCacheEndpoint}'
ContainerEnvEntry69: !Sub 'SpringCodecMaxInMemorySize=${SpringCodecMaxInMemorySize}'
ContainerEnvEntry70: !Sub 'PnEcConsRefinementDuration=${PnEcConsRefinementDuration}'
ContainerEnvEntry70: !Sub 'PnEcConsAllowedFutureOffsetDuration=${PnEcConsAllowedFutureOffsetDuration}'
ContainerSecret1: !Sub 'ConsolidatoreClientApiKey=arn:aws:secretsmanager:${AWS::Region}:${AWS::AccountId}:secret:pn-EC-Secrets:ConsolidatoreClientApiKey:AWSCURRENT:'
MicroServiceSecretPrefix: pn-EC-Secrets
MappedPaths: '/external-channels/*,/external-channel/*,/consolidatore-ingress/*'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ public RicezioneEsitiCartaceoServiceImpl(GestoreRepositoryCall gestoreRepository
FileCall fileCall, ObjectMapper objectMapper, NotificationTrackerSqsName notificationTrackerSqsName,
SqsService sqsService, StatusCodesToDeliveryFailureCauses statusCodesToDeliveryFailureCauses, StatusPullService statusPullService,
@Value("${ricezione-esiti-cartaceo.consider-event-without-sent-status-as-booked}") boolean considerEventsWithoutStatusAsBooked,
@Value("${ricezione-esiti-cartaceo.refinement-duration}") String offsetDuration) {
@Value("${ricezione-esiti-cartaceo.allowed-future-offset-duration}") Duration offsetDuration) {
super();
this.gestoreRepositoryCall = gestoreRepositoryCall;
this.fileCall = fileCall;
Expand All @@ -71,10 +71,10 @@ public RicezioneEsitiCartaceoServiceImpl(GestoreRepositoryCall gestoreRepository
this.statusCodesToDeliveryFailureCauses = statusCodesToDeliveryFailureCauses;
this.statusPullService = statusPullService;
this.considerEventsWithoutSentStatusAsBooked = considerEventsWithoutStatusAsBooked;
if(offsetDuration != null && !offsetDuration.isBlank()) {
this.offsetDuration = Duration.parse(offsetDuration);
} else {
if (offsetDuration== null){
this.offsetDuration = Duration.ofSeconds(-1);
} else {
this.offsetDuration = offsetDuration;
}
}

Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/application.properties
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,4 @@ pn.log.pn-uid-header=x-pagopa-pn-uid
pn.log.pn-cx-type-header=x-pagopa-pn-cx-type
pn.log.pn-cx-groups-header=x-pagopa-pn-cx-groups
pn.log.pn-cx-role-header=x-pagopa-pn-cx-role
pn.log.cx-id-header=x-pagopa-pn-cx-id
pn.log.cx-id-header=x-pagopa-pn-cx-id
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
lavorazione-cartaceo.max-thread-pool-size=${LavorazioneCartaceoMaxThreadPoolSize:50}
pn.ec.esiti-cartaceo.parameter.name=pn-EC-esitiCartaceo
ricezione-esiti-cartaceo.consider-event-without-sent-status-as-booked=${PnEcRicezioneEsitiCartaceoConsiderEventWithoutSentStatusAsBooked}
ricezione-esiti-cartaceo.refinement-duration=${PnEcConsRefinementDuration}
ricezione-esiti-cartaceo.allowed-future-offset-duration=${PnEcConsAllowedFutureOffsetDuration}
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ lavorazione-cartaceo.max-thread-pool-size=${LavorazioneCartaceoMaxThreadPoolSize
pn.ec.esiti-cartaceo.parameter.name=pn-EC-esitiCartaceo
ricezione-esiti-pec.consider-event-without-status-as-booked=true
ricezione-esiti-cartaceo.consider-event-without-sent-status-as-booked=${PnEcRicezioneEsitiCartaceoConsiderEventWithoutSentStatusAsBooked:true}
ricezione-esiti-cartaceo.refinement-duration=PT1M
ricezione-esiti-cartaceo.allowed-future-offset-duration=1m
Loading