RED-3523: Added flag to disable override IMAGE_INFO file
This commit is contained in:
parent
50a7d52997
commit
363edbe875
@ -10,6 +10,7 @@ import org.springframework.stereotype.Service;
|
|||||||
import com.fasterxml.jackson.core.type.TypeReference;
|
import com.fasterxml.jackson.core.type.TypeReference;
|
||||||
import com.fasterxml.jackson.databind.ObjectMapper;
|
import com.fasterxml.jackson.databind.ObjectMapper;
|
||||||
import com.iqser.red.service.peristence.v1.server.configuration.MessagingConfiguration;
|
import com.iqser.red.service.peristence.v1.server.configuration.MessagingConfiguration;
|
||||||
|
import com.iqser.red.service.peristence.v1.server.settings.FileManagementServiceSettings;
|
||||||
import com.iqser.red.service.persistence.service.v1.api.model.dossiertemplate.dossier.file.FileType;
|
import com.iqser.red.service.persistence.service.v1.api.model.dossiertemplate.dossier.file.FileType;
|
||||||
|
|
||||||
import lombok.RequiredArgsConstructor;
|
import lombok.RequiredArgsConstructor;
|
||||||
@ -25,6 +26,7 @@ public class ImageMessageReceiver {
|
|||||||
private final FileStatusService fileStatusService;
|
private final FileStatusService fileStatusService;
|
||||||
private final ObjectMapper objectMapper;
|
private final ObjectMapper objectMapper;
|
||||||
private final FileStatusProcessingUpdateService fileStatusProcessingUpdateService;
|
private final FileStatusProcessingUpdateService fileStatusProcessingUpdateService;
|
||||||
|
private final FileManagementServiceSettings settings;
|
||||||
|
|
||||||
|
|
||||||
@SneakyThrows
|
@SneakyThrows
|
||||||
@ -37,7 +39,9 @@ public class ImageMessageReceiver {
|
|||||||
String dossierId = (String) imageResponse.get("dossierId");
|
String dossierId = (String) imageResponse.get("dossierId");
|
||||||
String fileId = (String) imageResponse.get("fileId");
|
String fileId = (String) imageResponse.get("fileId");
|
||||||
|
|
||||||
fileManagementStorageService.storeObject(dossierId, fileId, FileType.IMAGE_INFO, in);
|
if(settings.isStoreImageFile()) {
|
||||||
|
fileManagementStorageService.storeObject(dossierId, fileId, FileType.IMAGE_INFO, in);
|
||||||
|
}
|
||||||
fileStatusService.setStatusAnalyse(dossierId, fileId, 1);
|
fileStatusService.setStatusAnalyse(dossierId, fileId, 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -25,4 +25,6 @@ public class FileManagementServiceSettings {
|
|||||||
|
|
||||||
private boolean imageServiceEnabled = true;
|
private boolean imageServiceEnabled = true;
|
||||||
private boolean nerServiceEnabled = true;
|
private boolean nerServiceEnabled = true;
|
||||||
|
|
||||||
|
private boolean storeImageFile = true;
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user