diff --git a/screening/dist/etc/service.properties b/screening/dist/etc/service.properties index 6a7d1852b564d0952529d16b0fa9dea702aea430..4b6e6d29623c0107491a0d201d66ce6e39fc8560 100644 --- a/screening/dist/etc/service.properties +++ b/screening/dist/etc/service.properties @@ -240,6 +240,11 @@ merged-channels-images.storage-processor.channel-labels = Gfp, Dapi # It should be set to 'false' for overlay image datasets. #merged-channels-images.storage-processor.define-channels-per-experiment = false +# Optional boolean property. +# If true an email is sent if some images for the uploaded plate are missing. +# True by default. +#merged-channels-images.storage-processor.notify-if-incomplete = false + # This is an optional boolean property which defines if all image datasets in one experiment have the same # channels or if each imported dataset can have different channels. By default true if not specified. #merged-channels-images.storage-processor.define-channels-per-experiment = false diff --git a/screening/source/java/ch/systemsx/cisd/openbis/dss/etl/PlateStorageProcessor.java b/screening/source/java/ch/systemsx/cisd/openbis/dss/etl/PlateStorageProcessor.java index 7476b9e8a2ce9dea190ed28e593431cb96f8c658..9ade5ba581bef18a08a564c8561143c7364308ba 100644 --- a/screening/source/java/ch/systemsx/cisd/openbis/dss/etl/PlateStorageProcessor.java +++ b/screening/source/java/ch/systemsx/cisd/openbis/dss/etl/PlateStorageProcessor.java @@ -63,6 +63,12 @@ public final class PlateStorageProcessor extends AbstractImageStorageProcessor */ static final String CHANNELS_PER_EXPERIMENT_PROPERTY = "define-channels-per-experiment"; + /** + * Optional boolean property. If true an email is sent if some images for the uploaded plate are + * missing. True by default. + */ + protected static final String NOTIFY_IF_INCOMPLETE_PROPERTY = "notify-if-incomplete"; + // --- private final ch.systemsx.cisd.etlserver.IHCSImageFileExtractor deprecatedImageFileExtractorOrNull; @@ -70,12 +76,16 @@ public final class PlateStorageProcessor extends AbstractImageStorageProcessor // can be overwritten for each dataset private final boolean globalStoreChannelsOnExperimentLevel; + private final boolean notifyIfPlateIncomplete; + public PlateStorageProcessor(Properties properties) { super(properties); this.deprecatedImageFileExtractorOrNull = tryCreateDeprecatedFileExtractor(); this.globalStoreChannelsOnExperimentLevel = PropertyUtils.getBoolean(properties, CHANNELS_PER_EXPERIMENT_PROPERTY, true); + this.notifyIfPlateIncomplete = + PropertyUtils.getBoolean(properties, NOTIFY_IF_INCOMPLETE_PROPERTY, true); } private IHCSImageFileExtractor tryCreateDeprecatedFileExtractor() @@ -245,7 +255,7 @@ public final class PlateStorageProcessor extends AbstractImageStorageProcessor + "are missing (locations: %s)", dataSetFileName, fullLocations.size(), CollectionUtils.abbreviate(fullLocations, 10)); operationLog.warn(message); - if (mailClientOrNull != null) + if (mailClientOrNull != null && notifyIfPlateIncomplete) { Experiment experiment = dataSetInformation.tryToGetExperiment(); assert experiment != null : "dataset not connected to an experiment: "