diff --git a/processing/src/main/java/edu/harvard/hms/dbmi/avillach/hpds/processing/GenomicProcessorConfig.java b/processing/src/main/java/edu/harvard/hms/dbmi/avillach/hpds/processing/GenomicProcessorConfig.java index 74482616..9653fef8 100644 --- a/processing/src/main/java/edu/harvard/hms/dbmi/avillach/hpds/processing/GenomicProcessorConfig.java +++ b/processing/src/main/java/edu/harvard/hms/dbmi/avillach/hpds/processing/GenomicProcessorConfig.java @@ -70,4 +70,10 @@ public GenomicProcessor remoteGenomicProcessor(@Value("${hpds.genomicProcessor.r // todo: validate remote processors are valid return new GenomicProcessorParentImpl(genomicProcessors); } + + @Bean + @ConditionalOnProperty(prefix = "hpds.genomicProcessor", name = "impl", matchIfMissing = true) + public GenomicProcessor noOpGenomicProcessor() { + return new GenomicProcessorNoOp(); + } } diff --git a/processing/src/main/java/edu/harvard/hms/dbmi/avillach/hpds/processing/GenomicProcessorNoOp.java b/processing/src/main/java/edu/harvard/hms/dbmi/avillach/hpds/processing/GenomicProcessorNoOp.java new file mode 100644 index 00000000..4dce5b37 --- /dev/null +++ b/processing/src/main/java/edu/harvard/hms/dbmi/avillach/hpds/processing/GenomicProcessorNoOp.java @@ -0,0 +1,59 @@ +package edu.harvard.hms.dbmi.avillach.hpds.processing; + +import edu.harvard.hms.dbmi.avillach.hpds.data.genotype.InfoColumnMeta; +import edu.harvard.hms.dbmi.avillach.hpds.data.genotype.VariantMasks; +import edu.harvard.hms.dbmi.avillach.hpds.data.genotype.caching.VariantBucketHolder; +import reactor.core.publisher.Mono; + +import java.math.BigInteger; +import java.util.Collection; +import java.util.List; +import java.util.Optional; +import java.util.Set; + +public class GenomicProcessorNoOp implements GenomicProcessor { + @Override + public Mono getPatientMask(DistributableQuery distributableQuery) { + return null; + } + + @Override + public Set patientMaskToPatientIdSet(BigInteger patientMask) { + return null; + } + + @Override + public BigInteger createMaskForPatientSet(Set patientSubset) { + return null; + } + + @Override + public Mono> getVariantList(DistributableQuery distributableQuery) { + return null; + } + + @Override + public List getPatientIds() { + return null; + } + + @Override + public Optional getMasks(String path, VariantBucketHolder variantMasksVariantBucketHolder) { + return Optional.empty(); + } + + @Override + public Set getInfoStoreColumns() { + return null; + } + + @Override + public Set getInfoStoreValues(String conceptPath) { + return null; + } + + @Override + public List getInfoColumnMeta() { + return null; + } +} diff --git a/service/src/main/resources/application-open.properties b/service/src/main/resources/application-open.properties new file mode 100644 index 00000000..d2dc8be4 --- /dev/null +++ b/service/src/main/resources/application-open.properties @@ -0,0 +1,3 @@ +SMALL_JOB_LIMIT = 100 +SMALL_TASK_THREADS = 1 +LARGE_TASK_THREADS = 1 \ No newline at end of file diff --git a/service/src/main/resources/application.properties b/service/src/main/resources/application.properties index 6dc668d1..d2dc8be4 100644 --- a/service/src/main/resources/application.properties +++ b/service/src/main/resources/application.properties @@ -1,12 +1,3 @@ SMALL_JOB_LIMIT = 100 SMALL_TASK_THREADS = 1 -LARGE_TASK_THREADS = 1 - -#hpds.genomicProcessor.impl=local -#HPDS_GENOMIC_DATA_DIRECTORY=/opt/local/hpds/all/ - -#hpds.genomicProcessor.impl=localDistributed -#HPDS_GENOMIC_DATA_DIRECTORY=/opt/local/hpds/phs0000946/ - -hpds.genomicProcessor.impl=remote -hpds.genomicProcessor.remoteHosts=http://localhost:8090/,http://localhost:8091/ \ No newline at end of file +LARGE_TASK_THREADS = 1 \ No newline at end of file