diff --git a/src/main/java/uk/ac/ebi/ega/accession/analysis/rest/AnalysisDTO.java b/src/main/java/uk/ac/ebi/ega/accession/analysis/rest/AnalysisDTO.java index f81d057..3daebcd 100644 --- a/src/main/java/uk/ac/ebi/ega/accession/analysis/rest/AnalysisDTO.java +++ b/src/main/java/uk/ac/ebi/ega/accession/analysis/rest/AnalysisDTO.java @@ -29,6 +29,9 @@ public class AnalysisDTO implements Analysis { @Column(nullable = false) private String alias; + AnalysisDTO(){ + } + public AnalysisDTO(Analysis analysis) { this(analysis.getSubmissionAccount(), analysis.getAlias()); } diff --git a/src/main/java/uk/ac/ebi/ega/accession/array/rest/ArrayDTO.java b/src/main/java/uk/ac/ebi/ega/accession/array/rest/ArrayDTO.java index 2febd09..8f64760 100644 --- a/src/main/java/uk/ac/ebi/ega/accession/array/rest/ArrayDTO.java +++ b/src/main/java/uk/ac/ebi/ega/accession/array/rest/ArrayDTO.java @@ -29,6 +29,9 @@ public class ArrayDTO implements Array { @Column(nullable = false) private String alias; + ArrayDTO(){ + } + public ArrayDTO(Array array) { this(array.getSubmissionAccount(), array.getAlias()); } diff --git a/src/main/java/uk/ac/ebi/ega/accession/dac/rest/DacDTO.java b/src/main/java/uk/ac/ebi/ega/accession/dac/rest/DacDTO.java index 1715cd9..3e07b53 100644 --- a/src/main/java/uk/ac/ebi/ega/accession/dac/rest/DacDTO.java +++ b/src/main/java/uk/ac/ebi/ega/accession/dac/rest/DacDTO.java @@ -29,6 +29,9 @@ public class DacDTO implements Dac { @Column(nullable = false) private String alias; + DacDTO(){ + } + public DacDTO(Dac dac) { this(dac.getSubmissionAccount(), dac.getAlias()); } diff --git a/src/main/java/uk/ac/ebi/ega/accession/dataset/rest/DatasetDTO.java b/src/main/java/uk/ac/ebi/ega/accession/dataset/rest/DatasetDTO.java index b1d6927..aab7702 100644 --- a/src/main/java/uk/ac/ebi/ega/accession/dataset/rest/DatasetDTO.java +++ b/src/main/java/uk/ac/ebi/ega/accession/dataset/rest/DatasetDTO.java @@ -29,6 +29,9 @@ public class DatasetDTO implements Dataset { @Column(nullable = false) private String alias; + DatasetDTO(){ + } + public DatasetDTO(Dataset dataset) { this(dataset.getSubmissionAccount(), dataset.getAlias()); } diff --git a/src/main/java/uk/ac/ebi/ega/accession/experiment/rest/ExperimentDTO.java b/src/main/java/uk/ac/ebi/ega/accession/experiment/rest/ExperimentDTO.java index 1dee00c..cb7a176 100644 --- a/src/main/java/uk/ac/ebi/ega/accession/experiment/rest/ExperimentDTO.java +++ b/src/main/java/uk/ac/ebi/ega/accession/experiment/rest/ExperimentDTO.java @@ -29,6 +29,9 @@ public class ExperimentDTO implements Experiment { @Column(nullable = false) private String alias; + ExperimentDTO(){ + } + public ExperimentDTO(Experiment experiment) { this(experiment.getSubmissionAccount(), experiment.getAlias()); } diff --git a/src/main/java/uk/ac/ebi/ega/accession/policy/rest/PolicyDTO.java b/src/main/java/uk/ac/ebi/ega/accession/policy/rest/PolicyDTO.java index a34d153..c629b1f 100644 --- a/src/main/java/uk/ac/ebi/ega/accession/policy/rest/PolicyDTO.java +++ b/src/main/java/uk/ac/ebi/ega/accession/policy/rest/PolicyDTO.java @@ -29,6 +29,9 @@ public class PolicyDTO implements Policy { @Column(nullable = false) private String alias; + PolicyDTO(){ + } + public PolicyDTO(Policy policy) { this(policy.getSubmissionAccount(), policy.getAlias()); } diff --git a/src/main/java/uk/ac/ebi/ega/accession/run/rest/RunDTO.java b/src/main/java/uk/ac/ebi/ega/accession/run/rest/RunDTO.java index 6c089de..cc55ccb 100644 --- a/src/main/java/uk/ac/ebi/ega/accession/run/rest/RunDTO.java +++ b/src/main/java/uk/ac/ebi/ega/accession/run/rest/RunDTO.java @@ -29,6 +29,9 @@ public class RunDTO implements Run { @Column(nullable = false) private String alias; + RunDTO(){ + } + public RunDTO(Run run) { this(run.getSubmissionAccount(), run.getAlias()); } diff --git a/src/main/java/uk/ac/ebi/ega/accession/sample/controlled/rest/SampleControlledDTO.java b/src/main/java/uk/ac/ebi/ega/accession/sample/controlled/rest/SampleControlledDTO.java index d5969cf..b30bb8e 100644 --- a/src/main/java/uk/ac/ebi/ega/accession/sample/controlled/rest/SampleControlledDTO.java +++ b/src/main/java/uk/ac/ebi/ega/accession/sample/controlled/rest/SampleControlledDTO.java @@ -29,6 +29,9 @@ public class SampleControlledDTO implements SampleControlled { @Column(nullable = false) private String alias; + SampleControlledDTO(){ + } + public SampleControlledDTO(SampleControlled sampleControlled) { this(sampleControlled.getSubmissionAccount(), sampleControlled.getAlias()); } diff --git a/src/main/java/uk/ac/ebi/ega/accession/sample/open/rest/SampleOpenDTO.java b/src/main/java/uk/ac/ebi/ega/accession/sample/open/rest/SampleOpenDTO.java index d241e98..e9dadb4 100644 --- a/src/main/java/uk/ac/ebi/ega/accession/sample/open/rest/SampleOpenDTO.java +++ b/src/main/java/uk/ac/ebi/ega/accession/sample/open/rest/SampleOpenDTO.java @@ -26,6 +26,9 @@ public class SampleOpenDTO implements SampleOpen { @Column(nullable = false) private String biosampleAccession; + SampleOpenDTO(){ + } + public SampleOpenDTO(SampleOpen sampleOpen) { this(sampleOpen.getBiosampleAccession()); } diff --git a/src/main/java/uk/ac/ebi/ega/accession/study/rest/StudyDTO.java b/src/main/java/uk/ac/ebi/ega/accession/study/rest/StudyDTO.java index 7e070b2..1b2a5ff 100644 --- a/src/main/java/uk/ac/ebi/ega/accession/study/rest/StudyDTO.java +++ b/src/main/java/uk/ac/ebi/ega/accession/study/rest/StudyDTO.java @@ -29,6 +29,9 @@ public class StudyDTO implements Study { @Column(nullable = false) private String alias; + StudyDTO(){ + } + public StudyDTO(Study study) { this(study.getSubmissionAccount(), study.getAlias()); } diff --git a/src/main/resources/application.properties b/src/main/resources/application.properties index 763f722..3cd214d 100644 --- a/src/main/resources/application.properties +++ b/src/main/resources/application.properties @@ -15,27 +15,73 @@ # limitations under the License. # # -accessioning.namespace=EGA -# org.springframework.transaction -> trans -accessioning.variant.instanceId=instance-01; -accessioning.variant.blockSize=1000 -accessioning.variant.id=variant -accessioning.run.instanceId=instance-01; -accessioning.run.blockSize=1000 -accessioning.run.categoryId=run - +##################################################################################### +# SPRING-CORE +##################################################################################### +spring.application.name=EGA accession service +# Bean jmx domain when using multiple applications with tomcat. +spring.jmx.default-domain=ega-accession +endpoints.jmx.domain=ega-accession +##################################################################################### +# DATABASES +##################################################################################### +spring.jpa.hibernate.use-new-id-generator-mappings=true spring.datasource.url=@egaAcccession-db.url@ spring.datasource.username=@egaAccession-db.username@ spring.datasource.password=@egaAcccession-db.password@ spring.jpa.hibernate.ddl-auto=validate spring.jpa.database-platform=org.hibernate.dialect.PostgreSQLDialect spring.jpa.generate-ddl=true - -# Bean jmx domain for actuator when using multiple applications with tomcat. -spring.jmx.default-domain=ega-accession -endpoints.jmx.domain=ega-accession - +##################################################################################### +# ACTUATOR +##################################################################################### management.security.enabled=false management.context-path=/actuator management.endpoint.health.show-details=always -endpoints.health.sensitive=false \ No newline at end of file +endpoints.health.sensitive=false +##################################################################################### +# APPLICATION +##################################################################################### + +accessioning.namespace=EGA +accessioning.variant.instanceId=instance-01; + +accessioning.monotonic.file.blockSize=1000 +accessioning.monotonic.file.blockStartValue=0 +accessioning.monotonic.file.nextBlockInterval=0 + +accessioning.monotonic.study.blockSize=1000 +accessioning.monotonic.study.blockStartValue=0 +accessioning.monotonic.study.nextBlockInterval=0 + +accessioning.monotonic.run.blockSize=1000 +accessioning.monotonic.run.blockStartValue=0 +accessioning.monotonic.run.nextBlockInterval=0 + +accessioning.monotonic.analysis.blockSize=1000 +accessioning.monotonic.analysis.blockStartValue=0 +accessioning.monotonic.analysis.nextBlockInterval=0 + +accessioning.monotonic.experiment.blockSize=1000 +accessioning.monotonic.experiment.blockStartValue=0 +accessioning.monotonic.experiment.nextBlockInterval=0 + +accessioning.monotonic.dac.blockSize=1000 +accessioning.monotonic.dac.blockStartValue=0 +accessioning.monotonic.dac.nextBlockInterval=0 + +accessioning.monotonic.policy.blockSize=1000 +accessioning.monotonic.policy.blockStartValue=0 +accessioning.monotonic.policy.nextBlockInterval=0 + +accessioning.monotonic.dataset.blockSize=1000 +accessioning.monotonic.dataset.blockStartValue=0 +accessioning.monotonic.dataset.nextBlockInterval=0 + +accessioning.monotonic.array.blockSize=1000 +accessioning.monotonic.array.blockStartValue=0 +accessioning.monotonic.array.nextBlockInterval=0 + +accessioning.monotonic.sample.blockSize=1000 +accessioning.monotonic.sample.blockStartValue=0 +accessioning.monotonic.sample.nextBlockInterval=0 \ No newline at end of file diff --git a/src/main/resources/banner.txt b/src/main/resources/banner.txt new file mode 100644 index 0000000..7ea2907 --- /dev/null +++ b/src/main/resources/banner.txt @@ -0,0 +1,5 @@ + ___ ___ _ _ ___ ___ ___ ___ ___ ___ ___ _ _ + | __/ __| /_\ ___ /_\ / __/ __| __/ __/ __|_ _/ _ \| \| | + | _| (_ |/ _ \___/ _ \ (_| (__| _|\__ \__ \| | (_) | .` | + |___\___/_/ \_\ /_/ \_\___\___|___|___/___/___\___/|_|\_| +${application.title} ${application.formatted-version} - Spring Boot ${spring-boot.formatted-version} \ No newline at end of file