RED-7784 - Include unprocessed redactions and update persistence version

This commit is contained in:
Andrei Isvoran 2023-11-07 16:50:26 +02:00
parent ffbe388278
commit caa1aa03d1
3 changed files with 5 additions and 4 deletions

View File

@ -14,5 +14,6 @@ public class ReportResultMessage {
private String userId;
private String downloadId;
private String reportFileInformationStorageId;
private boolean includeUnprocessed;
}

View File

@ -16,7 +16,7 @@ val springCommonsVersion = "2.1.0"
val storageCommonsVersion = "2.27.0"
val poiVersion = "5.2.3"
val metricCommonsVersion = "2.1.0"
val persistenceServiceVersion = "2.236.0"
val persistenceServiceVersion = "2.239.0"
configurations {
all {

View File

@ -44,16 +44,16 @@ public class ReportMessageReceiver {
log.info("Start generating reports for downloadId {}", reportMessage.getDownloadId());
var reportFileInformationStorageId = reportGenerationService.generateReports(reportMessage);
addToReportResultQueue(reportMessage.getUserId(), reportMessage.getDownloadId(), reportFileInformationStorageId, 1);
addToReportResultQueue(reportMessage.getUserId(), reportMessage.getDownloadId(), reportFileInformationStorageId, 1, reportMessage.isIncludeUnprocessed());
long end = System.currentTimeMillis();
log.info("Successfully generated reports for downloadId {}, took {}", reportMessage.getDownloadId(), end - start);
}
private void addToReportResultQueue(String userId, String downloadId, String reportFileInformationStorageId, int priority) {
private void addToReportResultQueue(String userId, String downloadId, String reportFileInformationStorageId, int priority, boolean includeUnprocessed) {
rabbitTemplate.convertAndSend(REPORT_RESULT_QUEUE, new ReportResultMessage(userId, downloadId, reportFileInformationStorageId), message -> {
rabbitTemplate.convertAndSend(REPORT_RESULT_QUEUE, new ReportResultMessage(userId, downloadId, reportFileInformationStorageId, includeUnprocessed), message -> {
message.getMessageProperties().setPriority(priority);
return message;
});