From 06a02d460287e7834461adac61fc6c5c4c9e8981 Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Fri, 12 May 2023 16:56:58 +0100 Subject: [PATCH 01/85] SCRUM-2394: add attributes to disease annations popup a --- .../AnnotatedEntitiesPopupCuration.js | 35 ++++++++++++------- .../src/components/dataTable/AssertedGenes.js | 24 +++++++++++++ .../src/components/dataTable/NoteCell.js | 6 ++++ .../src/components/dataTable/RelatedNotes.js | 16 +++++++++ .../components/dataTable/StrainBackground.js | 12 +++++++ 5 files changed, 81 insertions(+), 12 deletions(-) create mode 100644 apps/main-app/src/components/dataTable/AssertedGenes.js create mode 100644 apps/main-app/src/components/dataTable/NoteCell.js create mode 100644 apps/main-app/src/components/dataTable/RelatedNotes.js create mode 100644 apps/main-app/src/components/dataTable/StrainBackground.js diff --git a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js index e99ac6284..d752fa34b 100644 --- a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js +++ b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js @@ -13,8 +13,13 @@ import ExternalLink from '../ExternalLink'; import { Link } from 'react-router-dom'; import { getResourceUrl } from "./getResourceUrl"; import TypeCellCuration from './TypeCellCuration'; +import StrainBackground from './StrainBackground'; +import AssertedGenes from './AssertedGenes'; +import RelatedNotes from './RelatedNotes'; +import EvidenceCodesCellCuration from './evidenceCodesCellCuration'; function renderLink(entity) { + // Console.log(entity); const url = getResourceUrl(entity.subject.curie, entity.subject.type, entity.subject.subtype) if (entity.type === 'AlleleDiseaseAnnotation') { @@ -56,8 +61,15 @@ function AnnotatedEntitiesPopupCuration(props) { Name Type + Additional implicated genes Experimental condition Modifier + Strain Background + Genetic Sex + Notes + Annotation type + Evidence Code + Source References @@ -66,18 +78,17 @@ function AnnotatedEntitiesPopupCuration(props) { entities.map(entity => ( {renderLink(entity)} - - - - - - - - - - {entity.singleReference && - SingleReferenceCellCuration(entity.singleReference) - } + + {entity.assertedGenes && AssertedGenes(entity.assertedGenes)} + + + {entity.sgdStrainBackground && StrainBackground(entity.sgdStrainBackground)} + {entity.geneticSex && (entity.geneticSex.name ? entity.geneticSex.name: '')} + {entity.relatedNotes && RelatedNotes(entity.relatedNotes)} + {entity.annotationType && (entity.annotationType.name ? entity.annotationType.name: '')} + {entity.evidenceCodes && } + {entity.dataProvider && (entity.dataProvider.abbreviation ?? '')} + {entity.singleReference && SingleReferenceCellCuration(entity.singleReference) } )) } diff --git a/apps/main-app/src/components/dataTable/AssertedGenes.js b/apps/main-app/src/components/dataTable/AssertedGenes.js new file mode 100644 index 000000000..c4b9ea8ac --- /dev/null +++ b/apps/main-app/src/components/dataTable/AssertedGenes.js @@ -0,0 +1,24 @@ +import CollapsibleList from '../collapsibleList/collapsibleList'; +import ExternalLink from '../ExternalLink'; + + +function makeAssertedGeneLink(curie) { + if(curie) { + const name = ; + return {name}; + } + return null; +} + +function AssertedGenes(assertedGenes) { + if(assertedGenes.length > 1) { + return ( + + {assertedGenes.map(gene => makeAssertedGeneLink(gene.curie))} + + ); + } + return null; +} + +export default AssertedGenes; \ No newline at end of file diff --git a/apps/main-app/src/components/dataTable/NoteCell.js b/apps/main-app/src/components/dataTable/NoteCell.js new file mode 100644 index 000000000..703b4a1cc --- /dev/null +++ b/apps/main-app/src/components/dataTable/NoteCell.js @@ -0,0 +1,6 @@ + +function NoteCell(note) { + return
Note: {note.freeText}
+} + +export default NoteCell; diff --git a/apps/main-app/src/components/dataTable/RelatedNotes.js b/apps/main-app/src/components/dataTable/RelatedNotes.js new file mode 100644 index 000000000..9912cf9bf --- /dev/null +++ b/apps/main-app/src/components/dataTable/RelatedNotes.js @@ -0,0 +1,16 @@ +import CollapsibleList from '../collapsibleList/collapsibleList'; +import NoteCell from './NoteCell' + + +function RelatedNotes(relatedNotes) { + if(relatedNotes.length > 0) { + return ( + + {relatedNotes.map(NoteCell)} + + ); + } + return null; +} + +export default RelatedNotes; \ No newline at end of file diff --git a/apps/main-app/src/components/dataTable/StrainBackground.js b/apps/main-app/src/components/dataTable/StrainBackground.js new file mode 100644 index 000000000..cb045d56d --- /dev/null +++ b/apps/main-app/src/components/dataTable/StrainBackground.js @@ -0,0 +1,12 @@ +import ExternalLink from '../ExternalLink'; + + +function StrainBackground(strainBackground) { + if(strainBackground.curie && strainBackground.name) { + const strainName = ; + return {strainName}; + } + return null; +} + +export default StrainBackground; From cacae5b7d2387015927dd8c4a68ee14401aa9148 Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Tue, 16 May 2023 09:50:41 +0100 Subject: [PATCH 02/85] SCRUM-2394: move code to components --- .../dataTable/AnnotatedEntitiesPopupCuration.js | 17 +++++++++-------- .../components/dataTable/AnnotationSource.js | 8 ++++++++ .../src/components/dataTable/AnnotationType.js | 9 +++++++++ .../src/components/dataTable/AssertedGenes.js | 2 +- .../src/components/dataTable/GeneticSex.js | 8 ++++++++ .../src/components/dataTable/NoteCell.js | 2 +- .../src/components/dataTable/RelatedNotes.js | 2 +- .../dataTable/singleReferenceCellCuration.js | 7 +++++-- 8 files changed, 42 insertions(+), 13 deletions(-) create mode 100644 apps/main-app/src/components/dataTable/AnnotationSource.js create mode 100644 apps/main-app/src/components/dataTable/AnnotationType.js create mode 100644 apps/main-app/src/components/dataTable/GeneticSex.js diff --git a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js index d752fa34b..1eb68ad60 100644 --- a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js +++ b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js @@ -17,6 +17,7 @@ import StrainBackground from './StrainBackground'; import AssertedGenes from './AssertedGenes'; import RelatedNotes from './RelatedNotes'; import EvidenceCodesCellCuration from './evidenceCodesCellCuration'; +import AnnotationSource from './AnnotationSource'; function renderLink(entity) { // Console.log(entity); @@ -79,16 +80,16 @@ function AnnotatedEntitiesPopupCuration(props) { {renderLink(entity)} - {entity.assertedGenes && AssertedGenes(entity.assertedGenes)} + - {entity.sgdStrainBackground && StrainBackground(entity.sgdStrainBackground)} - {entity.geneticSex && (entity.geneticSex.name ? entity.geneticSex.name: '')} - {entity.relatedNotes && RelatedNotes(entity.relatedNotes)} - {entity.annotationType && (entity.annotationType.name ? entity.annotationType.name: '')} - {entity.evidenceCodes && } - {entity.dataProvider && (entity.dataProvider.abbreviation ?? '')} - {entity.singleReference && SingleReferenceCellCuration(entity.singleReference) } + + + + + + + )) } diff --git a/apps/main-app/src/components/dataTable/AnnotationSource.js b/apps/main-app/src/components/dataTable/AnnotationSource.js new file mode 100644 index 000000000..cabbf96d9 --- /dev/null +++ b/apps/main-app/src/components/dataTable/AnnotationSource.js @@ -0,0 +1,8 @@ +function AnnotationSource(dataProvider) { + if(dataProvider) { + return dataProvider.abbreviation && ''; + } + return null; +} + +export default AnnotationSource; diff --git a/apps/main-app/src/components/dataTable/AnnotationType.js b/apps/main-app/src/components/dataTable/AnnotationType.js new file mode 100644 index 000000000..b4f288e19 --- /dev/null +++ b/apps/main-app/src/components/dataTable/AnnotationType.js @@ -0,0 +1,9 @@ + +function AnnotationType(annotationType) { + if (annotationType) { + return annotationType.name && ''; + } + return null; +} + +export default AnnotationType; \ No newline at end of file diff --git a/apps/main-app/src/components/dataTable/AssertedGenes.js b/apps/main-app/src/components/dataTable/AssertedGenes.js index c4b9ea8ac..e882d622d 100644 --- a/apps/main-app/src/components/dataTable/AssertedGenes.js +++ b/apps/main-app/src/components/dataTable/AssertedGenes.js @@ -11,7 +11,7 @@ function makeAssertedGeneLink(curie) { } function AssertedGenes(assertedGenes) { - if(assertedGenes.length > 1) { + if(assertedGenes && assertedGenes.length > 1) { return ( {assertedGenes.map(gene => makeAssertedGeneLink(gene.curie))} diff --git a/apps/main-app/src/components/dataTable/GeneticSex.js b/apps/main-app/src/components/dataTable/GeneticSex.js new file mode 100644 index 000000000..5c127e08c --- /dev/null +++ b/apps/main-app/src/components/dataTable/GeneticSex.js @@ -0,0 +1,8 @@ + +function GeneticSex(geneticSex) { + if(geneticSex) + return geneticSex.name && ''; + return null; +} + +export default GeneticSex; \ No newline at end of file diff --git a/apps/main-app/src/components/dataTable/NoteCell.js b/apps/main-app/src/components/dataTable/NoteCell.js index 703b4a1cc..6865d1251 100644 --- a/apps/main-app/src/components/dataTable/NoteCell.js +++ b/apps/main-app/src/components/dataTable/NoteCell.js @@ -1,6 +1,6 @@ function NoteCell(note) { - return
Note: {note.freeText}
+ return note && (
Note: {note.freeText}
); } export default NoteCell; diff --git a/apps/main-app/src/components/dataTable/RelatedNotes.js b/apps/main-app/src/components/dataTable/RelatedNotes.js index 9912cf9bf..e5ebd3024 100644 --- a/apps/main-app/src/components/dataTable/RelatedNotes.js +++ b/apps/main-app/src/components/dataTable/RelatedNotes.js @@ -3,7 +3,7 @@ import NoteCell from './NoteCell' function RelatedNotes(relatedNotes) { - if(relatedNotes.length > 0) { + if(relatedNotes && relatedNotes.length > 0) { return ( {relatedNotes.map(NoteCell)} diff --git a/apps/main-app/src/components/dataTable/singleReferenceCellCuration.js b/apps/main-app/src/components/dataTable/singleReferenceCellCuration.js index 4249c6ad1..6df816995 100644 --- a/apps/main-app/src/components/dataTable/singleReferenceCellCuration.js +++ b/apps/main-app/src/components/dataTable/singleReferenceCellCuration.js @@ -4,8 +4,11 @@ import ExternalLink from '../ExternalLink'; import { getSingleReferenceCurieAndUrl } from "./utils"; const SingleReferenceCellCuration = (ref) => { - const { curie, url } = getSingleReferenceCurieAndUrl(ref); - return ref && {curie}; + if (ref) { + const { curie, url } = getSingleReferenceCurieAndUrl(ref); + return {curie}; + } + return null; }; From 5b1f7d814cea96de11974ddb8cb9aef5ab3b93aa Mon Sep 17 00:00:00 2001 From: Christian Pich Date: Wed, 24 May 2023 06:05:33 +0200 Subject: [PATCH 03/85] SCRUM-2727 enable filtering on reference column for disease association table on gene page --- apps/main-app/src/components/disease/diseaseAnnotationTable.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/main-app/src/components/disease/diseaseAnnotationTable.js b/apps/main-app/src/components/disease/diseaseAnnotationTable.js index eee3c1245..7475bdcc8 100644 --- a/apps/main-app/src/components/disease/diseaseAnnotationTable.js +++ b/apps/main-app/src/components/disease/diseaseAnnotationTable.js @@ -126,7 +126,7 @@ const DiseaseAnnotationTable = ({ { dataField: 'references', text: 'References', - filterable: false, + filterable: true, filterName: 'reference', headerStyle: {width: '150px'}, formatter: ReferencesCellCuration, From faeb6152bfbda13ecfb7b5b0185b36b986f6ca50 Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Thu, 25 May 2023 17:02:16 +0100 Subject: [PATCH 04/85] SCRUM-2925: fixes for popup --- .../dataTable/AnnotatedEntitiesPopupCuration.js | 6 ++++-- .../src/components/dataTable/AnnotationSource.js | 4 ++-- apps/main-app/src/components/dataTable/AnnotationType.js | 4 ++-- apps/main-app/src/components/dataTable/GeneticSex.js | 4 ++-- .../components/dataTable/singleReferenceCellCuration.js | 8 ++++---- apps/main-app/src/components/dataTable/utils.js | 9 ++++----- 6 files changed, 18 insertions(+), 17 deletions(-) diff --git a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js index 1eb68ad60..c326712f5 100644 --- a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js +++ b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js @@ -18,6 +18,8 @@ import AssertedGenes from './AssertedGenes'; import RelatedNotes from './RelatedNotes'; import EvidenceCodesCellCuration from './evidenceCodesCellCuration'; import AnnotationSource from './AnnotationSource'; +import GeneticSex from './GeneticSex'; +import AnnotationType from './AnnotationType'; function renderLink(entity) { // Console.log(entity); @@ -88,8 +90,8 @@ function AnnotatedEntitiesPopupCuration(props) { - - + + )) } diff --git a/apps/main-app/src/components/dataTable/AnnotationSource.js b/apps/main-app/src/components/dataTable/AnnotationSource.js index cabbf96d9..49c98459d 100644 --- a/apps/main-app/src/components/dataTable/AnnotationSource.js +++ b/apps/main-app/src/components/dataTable/AnnotationSource.js @@ -1,8 +1,8 @@ function AnnotationSource(dataProvider) { if(dataProvider) { - return dataProvider.abbreviation && ''; + return <>{dataProvider.abbreviation}; } - return null; + return <>; } export default AnnotationSource; diff --git a/apps/main-app/src/components/dataTable/AnnotationType.js b/apps/main-app/src/components/dataTable/AnnotationType.js index b4f288e19..0d6694fb9 100644 --- a/apps/main-app/src/components/dataTable/AnnotationType.js +++ b/apps/main-app/src/components/dataTable/AnnotationType.js @@ -1,9 +1,9 @@ function AnnotationType(annotationType) { if (annotationType) { - return annotationType.name && ''; + return <>{annotationType.name}; } - return null; + return <>; } export default AnnotationType; \ No newline at end of file diff --git a/apps/main-app/src/components/dataTable/GeneticSex.js b/apps/main-app/src/components/dataTable/GeneticSex.js index 5c127e08c..469b07a26 100644 --- a/apps/main-app/src/components/dataTable/GeneticSex.js +++ b/apps/main-app/src/components/dataTable/GeneticSex.js @@ -1,8 +1,8 @@ function GeneticSex(geneticSex) { if(geneticSex) - return geneticSex.name && ''; - return null; + return <>{geneticSex.name}; + return <>; } export default GeneticSex; \ No newline at end of file diff --git a/apps/main-app/src/components/dataTable/singleReferenceCellCuration.js b/apps/main-app/src/components/dataTable/singleReferenceCellCuration.js index 6df816995..4dd47e21c 100644 --- a/apps/main-app/src/components/dataTable/singleReferenceCellCuration.js +++ b/apps/main-app/src/components/dataTable/singleReferenceCellCuration.js @@ -3,12 +3,12 @@ import React from 'react'; import ExternalLink from '../ExternalLink'; import { getSingleReferenceCurieAndUrl } from "./utils"; -const SingleReferenceCellCuration = (ref) => { - if (ref) { - const { curie, url } = getSingleReferenceCurieAndUrl(ref); +const SingleReferenceCellCuration = ({singleReference}) => { + if (singleReference) { + const { curie, url } = getSingleReferenceCurieAndUrl(singleReference); return {curie}; } - return null; + return <>; }; diff --git a/apps/main-app/src/components/dataTable/utils.js b/apps/main-app/src/components/dataTable/utils.js index 61be3a5c3..d5c6031b3 100644 --- a/apps/main-app/src/components/dataTable/utils.js +++ b/apps/main-app/src/components/dataTable/utils.js @@ -31,11 +31,10 @@ export function getRefString(referenceItem) { if (!referenceItem) return; - if (!referenceItem.cross_references && !referenceItem.crossReferences) - return referenceItem.curie; - - let xrefCuries = referenceItem.crossReferences.map((crossReference) => crossReference.curie); - + if (!referenceItem.cross_references && !referenceItem.crossReferences){ + return referenceItem.curie + } + let xrefCuries = referenceItem.crossReferences.map((crossReference) => crossReference.referencedCurie); let primaryXrefCurie = ''; if (indexWithPrefix(xrefCuries, 'PMID:') > -1) { From 16b6f80412e0a2ce3aced3a306e2c60ac8fb69d4 Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Thu, 25 May 2023 17:04:44 +0100 Subject: [PATCH 05/85] SCRUM-2925: remove foo prop --- .../src/components/dataTable/AnnotatedEntitiesPopupCuration.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js index c326712f5..6ef16be28 100644 --- a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js +++ b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js @@ -91,7 +91,7 @@ function AnnotatedEntitiesPopupCuration(props) { - + )) } From 50636ca1366840e96376250d6cac63fcc59438a0 Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Thu, 25 May 2023 19:21:17 +0100 Subject: [PATCH 06/85] SCRUM-2925: fixes spacing issues --- .../components/dataTable/AnnotatedEntitiesPopupCuration.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js index 6ef16be28..70387ddd5 100644 --- a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js +++ b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js @@ -22,7 +22,6 @@ import GeneticSex from './GeneticSex'; import AnnotationType from './AnnotationType'; function renderLink(entity) { - // Console.log(entity); const url = getResourceUrl(entity.subject.curie, entity.subject.type, entity.subject.subtype) if (entity.type === 'AlleleDiseaseAnnotation') { @@ -90,8 +89,8 @@ function AnnotatedEntitiesPopupCuration(props) { - - + + )) } From d51be8285ef8cca84034e0e7e5bf8f364efba1fe Mon Sep 17 00:00:00 2001 From: Scott Cain Date: Mon, 29 May 2023 11:45:37 -0700 Subject: [PATCH 07/85] adding constants that will be used by the seq panel (excluding SARS-CoV-2 for now) --- apps/main-app/src/constants.js | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/apps/main-app/src/constants.js b/apps/main-app/src/constants.js index 78ade8672..b209e9db1 100644 --- a/apps/main-app/src/constants.js +++ b/apps/main-app/src/constants.js @@ -248,6 +248,9 @@ export const SPECIES = [ apolloName: 'human', apolloTrack: '/All%20Genes/', jBrowseName: 'Homo sapiens', + jBrowsenclistbaseurl="https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/human/", + jBrowseurltemplate="tracks/All_Genes/{refseq}/trackData.jsonz", + jBrowsefastaurl="https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000001405.40_GRCh38.p14_genomic.fna.gz", vertebrate: true, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -259,6 +262,9 @@ export const SPECIES = [ apolloName: 'mouse', apolloTrack: '/All%20Genes/', jBrowseName: 'Mus musculus', + jBrowsenclistbaseurl="https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/MGI/mouse/", + jBrowseurltemplate="tracks/All_Genes/{refseq}/trackData.jsonz", + jBrowsefastaurl="https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000001635.27_GRCm39_genomic.fna.gz", vertebrate: true, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -270,6 +276,9 @@ export const SPECIES = [ apolloName: 'rat', apolloTrack: '/All%20Genes/', jBrowseName: 'Rattus norvegicus', + jBrowsenclistbaseurl="https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/RGD/rat/", + jBrowseurltemplate="tracks/All_Genes/{refseq}/trackData.jsonz", + jBrowsefastaurl="https://s3.amazonaws.com/agrjbrowse/fasta/GCF_015227675.2_mRatBN7.2_genomic.fna.gz", vertebrate: true, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -281,6 +290,9 @@ export const SPECIES = [ apolloName: 'x_laevis', apolloTrack: '/All%20Genes/', jBrowseName: 'Xenopus laevis', + jBrowsenclistbaseurl="https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/XenBase/x_laevis/", + jBrowseurltemplate="tracks/All_Genes/{refseq}/trackData.jsonz", + jBrowsefastaurl="https://s3.amazonaws.com/agrjbrowse/fasta/XENLA_9.2_genome.fa.gz", vertebrate: true, enableSingleCellExpressionAtlasLink: false, enableOrthologComparison: true, @@ -292,6 +304,9 @@ export const SPECIES = [ apolloName: 'x_tropicalis', apolloTrack: '/All%20Genes/', jBrowseName: 'Xenopus tropicalis', + jBrowsenclistbaseurl="https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/XenBase/x_tropicalis/", + jBrowseurltemplate="tracks/All_Genes/{refseq}/trackData.jsonz", + jBrowsefastaurl="https://s3.amazonaws.com/agrjbrowse/fasta/XENTR_9.1_genome.fa.gz", vertebrate: true, enableSingleCellExpressionAtlasLink: false, enableOrthologComparison: true, @@ -303,6 +318,9 @@ export const SPECIES = [ apolloName: 'zebrafish', apolloTrack: '/All%20Genes/', jBrowseName: 'Danio rerio', + jBrowsenclistbaseurl="https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/zfin/zebrafish-11/", + jBrowseurltemplate="tracks/All_Genes/{refseq}/trackData.jsonz", + jBrowsefastaurl="https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000002035.6_GRCz11_genomic.fna.gz", vertebrate: true, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -314,6 +332,9 @@ export const SPECIES = [ apolloName: 'fly', apolloTrack: '/All%20Genes/', jBrowseName: 'Drosophila melanogaster', + jBrowsenclistbaseurl="https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/FlyBase/fruitfly/", + jBrowseurltemplate="tracks/All_Genes/{refseq}/trackData.jsonz", + jBrowsefastaurl="https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000001215.4_Release_6_plus_ISO1_MT_genomic.fna.gz", vertebrate: false, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -325,6 +346,9 @@ export const SPECIES = [ apolloName: 'worm', apolloTrack: '/All%20Genes/', jBrowseName: 'Caenorhabditis elegans', + jBrowsenclistbaseurl="https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/WormBase/c_elegans_PRJNA13758/", + jBrowseurltemplate="tracks/All_Genes/{refseq}/trackData.jsonz", + jBrowsefastaurl="https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000002985.6_WBcel235_genomic.fna.gz", vertebrate: false, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -336,6 +360,9 @@ export const SPECIES = [ apolloName: 'yeast', apolloTrack: '/All%20Genes/', jBrowseName: 'Saccharomyces cerevisiae', + jBrowsenclistbaseurl="https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/SGD/yeast/", + urltemplate="tracks/All_Genes/{refseq}/trackData.jsonz", + fastaurl="https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000146045.2_R64_genomic.fna.gz", vertebrate: false, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, From 0d08eb64c408622f4475ff1be618febdd33fd2f3 Mon Sep 17 00:00:00 2001 From: Scott Cain Date: Mon, 29 May 2023 12:10:17 -0700 Subject: [PATCH 08/85] this might be all that's needed to add a sequence panel? my big question at the moment is whether `{data.species.jBrowsefastaurl}` works the way I'm guessing it does --- apps/main-app/src/containers/genePage/index.js | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/apps/main-app/src/containers/genePage/index.js b/apps/main-app/src/containers/genePage/index.js index c3dd7ecc5..5e02a40c5 100644 --- a/apps/main-app/src/containers/genePage/index.js +++ b/apps/main-app/src/containers/genePage/index.js @@ -18,6 +18,7 @@ import { InteractionUserGuide } from '../../components/interaction'; import GenomeFeatureWrapper from './genomeFeatureWrapper'; +import GenericGeneSequencePanel from 'generic-sequence-panel'; import ExpressionLinks from './expressionLinks'; import SpeciesIcon from '../../components/speciesIcon'; @@ -41,6 +42,7 @@ import SpeciesName from '../../components/SpeciesName'; const SUMMARY = 'Summary'; const SEQUENCE_FEATURE_VIEWER = 'Sequence Feature Viewer'; +const SEQUENCE_PANEL = 'Sequence Panel'; const FUNCTION = 'Function - GO Annotations'; const PATHWAY = 'Pathways'; const ORTHOLOGY = 'Orthology'; @@ -64,6 +66,7 @@ const SECTIONS = [ {name: TG_ALLELES}, {name: MODELS}, {name: SEQUENCE_FEATURE_VIEWER}, + {name: SEQUENCE_PANEL}, {name: EXPRESSION}, {name: INTERACTIONS}, {name: GENETIC_INTERACTIONS}, @@ -194,6 +197,18 @@ const GenePage = ({geneId}) => { /> + + + + } title={EXPRESSION}> Date: Mon, 29 May 2023 12:15:07 -0700 Subject: [PATCH 09/85] adding the npm package for the sequence panel --- package.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index cf62114b2..20ebc9bad 100644 --- a/package.json +++ b/package.json @@ -86,7 +86,8 @@ "sitemap": "^1.13.0", "tslib": "^2.0.0", "twin.macro": "2.2.3", - "whatwg-fetch": "^3.4.0" + "whatwg-fetch": "^3.4.0", + "generic-sequence-panel": "^1.1.0" }, "devDependencies": { "@babel/core": "7.9.6", From 7ac5cb500a2e2631ff7bdf263bffcbb16f8ec40e Mon Sep 17 00:00:00 2001 From: Scott Cain Date: Mon, 29 May 2023 12:26:50 -0700 Subject: [PATCH 10/85] equals or colon, they're all the same, right? --- apps/main-app/src/constants.js | 54 +++++++++++++++++----------------- 1 file changed, 27 insertions(+), 27 deletions(-) diff --git a/apps/main-app/src/constants.js b/apps/main-app/src/constants.js index b209e9db1..0b55c584b 100644 --- a/apps/main-app/src/constants.js +++ b/apps/main-app/src/constants.js @@ -248,9 +248,9 @@ export const SPECIES = [ apolloName: 'human', apolloTrack: '/All%20Genes/', jBrowseName: 'Homo sapiens', - jBrowsenclistbaseurl="https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/human/", - jBrowseurltemplate="tracks/All_Genes/{refseq}/trackData.jsonz", - jBrowsefastaurl="https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000001405.40_GRCh38.p14_genomic.fna.gz", + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/human/', + jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', + jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000001405.40_GRCh38.p14_genomic.fna.gz', vertebrate: true, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -262,9 +262,9 @@ export const SPECIES = [ apolloName: 'mouse', apolloTrack: '/All%20Genes/', jBrowseName: 'Mus musculus', - jBrowsenclistbaseurl="https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/MGI/mouse/", - jBrowseurltemplate="tracks/All_Genes/{refseq}/trackData.jsonz", - jBrowsefastaurl="https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000001635.27_GRCm39_genomic.fna.gz", + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/MGI/mouse/', + jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', + jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000001635.27_GRCm39_genomic.fna.gz', vertebrate: true, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -276,9 +276,9 @@ export const SPECIES = [ apolloName: 'rat', apolloTrack: '/All%20Genes/', jBrowseName: 'Rattus norvegicus', - jBrowsenclistbaseurl="https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/RGD/rat/", - jBrowseurltemplate="tracks/All_Genes/{refseq}/trackData.jsonz", - jBrowsefastaurl="https://s3.amazonaws.com/agrjbrowse/fasta/GCF_015227675.2_mRatBN7.2_genomic.fna.gz", + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/RGD/rat/', + jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', + jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_015227675.2_mRatBN7.2_genomic.fna.gz', vertebrate: true, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -290,9 +290,9 @@ export const SPECIES = [ apolloName: 'x_laevis', apolloTrack: '/All%20Genes/', jBrowseName: 'Xenopus laevis', - jBrowsenclistbaseurl="https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/XenBase/x_laevis/", - jBrowseurltemplate="tracks/All_Genes/{refseq}/trackData.jsonz", - jBrowsefastaurl="https://s3.amazonaws.com/agrjbrowse/fasta/XENLA_9.2_genome.fa.gz", + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/XenBase/x_laevis/', + jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', + jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/XENLA_9.2_genome.fa.gz', vertebrate: true, enableSingleCellExpressionAtlasLink: false, enableOrthologComparison: true, @@ -304,9 +304,9 @@ export const SPECIES = [ apolloName: 'x_tropicalis', apolloTrack: '/All%20Genes/', jBrowseName: 'Xenopus tropicalis', - jBrowsenclistbaseurl="https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/XenBase/x_tropicalis/", - jBrowseurltemplate="tracks/All_Genes/{refseq}/trackData.jsonz", - jBrowsefastaurl="https://s3.amazonaws.com/agrjbrowse/fasta/XENTR_9.1_genome.fa.gz", + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/XenBase/x_tropicalis/', + jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', + jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/XENTR_9.1_genome.fa.gz', vertebrate: true, enableSingleCellExpressionAtlasLink: false, enableOrthologComparison: true, @@ -318,9 +318,9 @@ export const SPECIES = [ apolloName: 'zebrafish', apolloTrack: '/All%20Genes/', jBrowseName: 'Danio rerio', - jBrowsenclistbaseurl="https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/zfin/zebrafish-11/", - jBrowseurltemplate="tracks/All_Genes/{refseq}/trackData.jsonz", - jBrowsefastaurl="https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000002035.6_GRCz11_genomic.fna.gz", + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/zfin/zebrafish-11/;, + jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', + jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000002035.6_GRCz11_genomic.fna.gz', vertebrate: true, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -332,9 +332,9 @@ export const SPECIES = [ apolloName: 'fly', apolloTrack: '/All%20Genes/', jBrowseName: 'Drosophila melanogaster', - jBrowsenclistbaseurl="https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/FlyBase/fruitfly/", - jBrowseurltemplate="tracks/All_Genes/{refseq}/trackData.jsonz", - jBrowsefastaurl="https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000001215.4_Release_6_plus_ISO1_MT_genomic.fna.gz", + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/FlyBase/fruitfly/', + jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', + jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000001215.4_Release_6_plus_ISO1_MT_genomic.fna.gz', vertebrate: false, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -346,9 +346,9 @@ export const SPECIES = [ apolloName: 'worm', apolloTrack: '/All%20Genes/', jBrowseName: 'Caenorhabditis elegans', - jBrowsenclistbaseurl="https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/WormBase/c_elegans_PRJNA13758/", - jBrowseurltemplate="tracks/All_Genes/{refseq}/trackData.jsonz", - jBrowsefastaurl="https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000002985.6_WBcel235_genomic.fna.gz", + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/WormBase/c_elegans_PRJNA13758/', + jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', + jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000002985.6_WBcel235_genomic.fna.gz', vertebrate: false, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -360,9 +360,9 @@ export const SPECIES = [ apolloName: 'yeast', apolloTrack: '/All%20Genes/', jBrowseName: 'Saccharomyces cerevisiae', - jBrowsenclistbaseurl="https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/SGD/yeast/", - urltemplate="tracks/All_Genes/{refseq}/trackData.jsonz", - fastaurl="https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000146045.2_R64_genomic.fna.gz", + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/SGD/yeast/', + jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', + jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000146045.2_R64_genomic.fna.gz', vertebrate: false, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, From a722fbb02df91d3a6f8422bd0e03012c28c701cd Mon Sep 17 00:00:00 2001 From: Scott Cain Date: Mon, 29 May 2023 12:33:03 -0700 Subject: [PATCH 11/85] fixing a typo --- apps/main-app/src/constants.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/main-app/src/constants.js b/apps/main-app/src/constants.js index 0b55c584b..4c307ec68 100644 --- a/apps/main-app/src/constants.js +++ b/apps/main-app/src/constants.js @@ -318,7 +318,7 @@ export const SPECIES = [ apolloName: 'zebrafish', apolloTrack: '/All%20Genes/', jBrowseName: 'Danio rerio', - jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/zfin/zebrafish-11/;, + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/zfin/zebrafish-11/', jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000002035.6_GRCz11_genomic.fna.gz', vertebrate: true, From e3486973dafdc43cc5dfa452b5314b2383479c64 Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Tue, 30 May 2023 16:23:50 +0100 Subject: [PATCH 12/85] SCRUM-2394: fix passing props by de-structuring --- apps/main-app/src/components/dataTable/AnnotationSource.js | 2 +- apps/main-app/src/components/dataTable/AnnotationType.js | 2 +- apps/main-app/src/components/dataTable/AssertedGenes.js | 2 +- apps/main-app/src/components/dataTable/GeneticSex.js | 2 +- apps/main-app/src/components/dataTable/RelatedNotes.js | 2 +- apps/main-app/src/components/dataTable/StrainBackground.js | 4 ++-- 6 files changed, 7 insertions(+), 7 deletions(-) diff --git a/apps/main-app/src/components/dataTable/AnnotationSource.js b/apps/main-app/src/components/dataTable/AnnotationSource.js index 49c98459d..5d95d9e7a 100644 --- a/apps/main-app/src/components/dataTable/AnnotationSource.js +++ b/apps/main-app/src/components/dataTable/AnnotationSource.js @@ -1,4 +1,4 @@ -function AnnotationSource(dataProvider) { +function AnnotationSource({dataProvider}) { if(dataProvider) { return <>{dataProvider.abbreviation}; } diff --git a/apps/main-app/src/components/dataTable/AnnotationType.js b/apps/main-app/src/components/dataTable/AnnotationType.js index 0d6694fb9..24b7ded4e 100644 --- a/apps/main-app/src/components/dataTable/AnnotationType.js +++ b/apps/main-app/src/components/dataTable/AnnotationType.js @@ -1,5 +1,5 @@ -function AnnotationType(annotationType) { +function AnnotationType({annotationType}) { if (annotationType) { return <>{annotationType.name}; } diff --git a/apps/main-app/src/components/dataTable/AssertedGenes.js b/apps/main-app/src/components/dataTable/AssertedGenes.js index e882d622d..d236fc9af 100644 --- a/apps/main-app/src/components/dataTable/AssertedGenes.js +++ b/apps/main-app/src/components/dataTable/AssertedGenes.js @@ -10,7 +10,7 @@ function makeAssertedGeneLink(curie) { return null; } -function AssertedGenes(assertedGenes) { +function AssertedGenes({assertedGenes}) { if(assertedGenes && assertedGenes.length > 1) { return ( diff --git a/apps/main-app/src/components/dataTable/GeneticSex.js b/apps/main-app/src/components/dataTable/GeneticSex.js index 469b07a26..384f90055 100644 --- a/apps/main-app/src/components/dataTable/GeneticSex.js +++ b/apps/main-app/src/components/dataTable/GeneticSex.js @@ -1,5 +1,5 @@ -function GeneticSex(geneticSex) { +function GeneticSex({geneticSex}) { if(geneticSex) return <>{geneticSex.name}; return <>; diff --git a/apps/main-app/src/components/dataTable/RelatedNotes.js b/apps/main-app/src/components/dataTable/RelatedNotes.js index e5ebd3024..8cb2db8e9 100644 --- a/apps/main-app/src/components/dataTable/RelatedNotes.js +++ b/apps/main-app/src/components/dataTable/RelatedNotes.js @@ -2,7 +2,7 @@ import CollapsibleList from '../collapsibleList/collapsibleList'; import NoteCell from './NoteCell' -function RelatedNotes(relatedNotes) { +function RelatedNotes({relatedNotes}) { if(relatedNotes && relatedNotes.length > 0) { return ( diff --git a/apps/main-app/src/components/dataTable/StrainBackground.js b/apps/main-app/src/components/dataTable/StrainBackground.js index cb045d56d..39a011db2 100644 --- a/apps/main-app/src/components/dataTable/StrainBackground.js +++ b/apps/main-app/src/components/dataTable/StrainBackground.js @@ -1,8 +1,8 @@ import ExternalLink from '../ExternalLink'; -function StrainBackground(strainBackground) { - if(strainBackground.curie && strainBackground.name) { +function StrainBackground({strainBackground}) { + if(strainBackground?.curie && strainBackground?.name) { const strainName = ; return {strainName}; } From 92bb3f3f60f4d4baa84cf7148cb39e177cb0efce Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Tue, 30 May 2023 16:29:15 +0100 Subject: [PATCH 13/85] SCRUM-2394: fix passing props by de-structuring --- apps/main-app/src/components/dataTable/AssertedGenes.js | 2 +- apps/main-app/src/components/dataTable/RelatedNotes.js | 2 +- apps/main-app/src/components/dataTable/StrainBackground.js | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/apps/main-app/src/components/dataTable/AssertedGenes.js b/apps/main-app/src/components/dataTable/AssertedGenes.js index d236fc9af..19b88d88d 100644 --- a/apps/main-app/src/components/dataTable/AssertedGenes.js +++ b/apps/main-app/src/components/dataTable/AssertedGenes.js @@ -18,7 +18,7 @@ function AssertedGenes({assertedGenes}) { ); } - return null; + return <>; } export default AssertedGenes; \ No newline at end of file diff --git a/apps/main-app/src/components/dataTable/RelatedNotes.js b/apps/main-app/src/components/dataTable/RelatedNotes.js index 8cb2db8e9..c5f8eee0b 100644 --- a/apps/main-app/src/components/dataTable/RelatedNotes.js +++ b/apps/main-app/src/components/dataTable/RelatedNotes.js @@ -10,7 +10,7 @@ function RelatedNotes({relatedNotes}) { ); } - return null; + return <>; } export default RelatedNotes; \ No newline at end of file diff --git a/apps/main-app/src/components/dataTable/StrainBackground.js b/apps/main-app/src/components/dataTable/StrainBackground.js index 39a011db2..611537aa4 100644 --- a/apps/main-app/src/components/dataTable/StrainBackground.js +++ b/apps/main-app/src/components/dataTable/StrainBackground.js @@ -6,7 +6,7 @@ function StrainBackground({strainBackground}) { const strainName = ; return {strainName}; } - return null; + return <>; } export default StrainBackground; From 9c539c963e0ec136465dd2c60f1b06a0b3dd7308 Mon Sep 17 00:00:00 2001 From: Scott Cain Date: Tue, 30 May 2023 11:02:02 -0700 Subject: [PATCH 14/85] Revert "Add sequence panel" --- apps/main-app/src/constants.js | 27 ------------------- .../main-app/src/containers/genePage/index.js | 15 ----------- package.json | 3 +-- 3 files changed, 1 insertion(+), 44 deletions(-) diff --git a/apps/main-app/src/constants.js b/apps/main-app/src/constants.js index 4c307ec68..78ade8672 100644 --- a/apps/main-app/src/constants.js +++ b/apps/main-app/src/constants.js @@ -248,9 +248,6 @@ export const SPECIES = [ apolloName: 'human', apolloTrack: '/All%20Genes/', jBrowseName: 'Homo sapiens', - jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/human/', - jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', - jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000001405.40_GRCh38.p14_genomic.fna.gz', vertebrate: true, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -262,9 +259,6 @@ export const SPECIES = [ apolloName: 'mouse', apolloTrack: '/All%20Genes/', jBrowseName: 'Mus musculus', - jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/MGI/mouse/', - jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', - jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000001635.27_GRCm39_genomic.fna.gz', vertebrate: true, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -276,9 +270,6 @@ export const SPECIES = [ apolloName: 'rat', apolloTrack: '/All%20Genes/', jBrowseName: 'Rattus norvegicus', - jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/RGD/rat/', - jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', - jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_015227675.2_mRatBN7.2_genomic.fna.gz', vertebrate: true, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -290,9 +281,6 @@ export const SPECIES = [ apolloName: 'x_laevis', apolloTrack: '/All%20Genes/', jBrowseName: 'Xenopus laevis', - jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/XenBase/x_laevis/', - jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', - jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/XENLA_9.2_genome.fa.gz', vertebrate: true, enableSingleCellExpressionAtlasLink: false, enableOrthologComparison: true, @@ -304,9 +292,6 @@ export const SPECIES = [ apolloName: 'x_tropicalis', apolloTrack: '/All%20Genes/', jBrowseName: 'Xenopus tropicalis', - jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/XenBase/x_tropicalis/', - jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', - jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/XENTR_9.1_genome.fa.gz', vertebrate: true, enableSingleCellExpressionAtlasLink: false, enableOrthologComparison: true, @@ -318,9 +303,6 @@ export const SPECIES = [ apolloName: 'zebrafish', apolloTrack: '/All%20Genes/', jBrowseName: 'Danio rerio', - jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/zfin/zebrafish-11/', - jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', - jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000002035.6_GRCz11_genomic.fna.gz', vertebrate: true, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -332,9 +314,6 @@ export const SPECIES = [ apolloName: 'fly', apolloTrack: '/All%20Genes/', jBrowseName: 'Drosophila melanogaster', - jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/FlyBase/fruitfly/', - jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', - jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000001215.4_Release_6_plus_ISO1_MT_genomic.fna.gz', vertebrate: false, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -346,9 +325,6 @@ export const SPECIES = [ apolloName: 'worm', apolloTrack: '/All%20Genes/', jBrowseName: 'Caenorhabditis elegans', - jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/WormBase/c_elegans_PRJNA13758/', - jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', - jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000002985.6_WBcel235_genomic.fna.gz', vertebrate: false, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -360,9 +336,6 @@ export const SPECIES = [ apolloName: 'yeast', apolloTrack: '/All%20Genes/', jBrowseName: 'Saccharomyces cerevisiae', - jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/SGD/yeast/', - jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', - jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000146045.2_R64_genomic.fna.gz', vertebrate: false, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, diff --git a/apps/main-app/src/containers/genePage/index.js b/apps/main-app/src/containers/genePage/index.js index 5e02a40c5..c3dd7ecc5 100644 --- a/apps/main-app/src/containers/genePage/index.js +++ b/apps/main-app/src/containers/genePage/index.js @@ -18,7 +18,6 @@ import { InteractionUserGuide } from '../../components/interaction'; import GenomeFeatureWrapper from './genomeFeatureWrapper'; -import GenericGeneSequencePanel from 'generic-sequence-panel'; import ExpressionLinks from './expressionLinks'; import SpeciesIcon from '../../components/speciesIcon'; @@ -42,7 +41,6 @@ import SpeciesName from '../../components/SpeciesName'; const SUMMARY = 'Summary'; const SEQUENCE_FEATURE_VIEWER = 'Sequence Feature Viewer'; -const SEQUENCE_PANEL = 'Sequence Panel'; const FUNCTION = 'Function - GO Annotations'; const PATHWAY = 'Pathways'; const ORTHOLOGY = 'Orthology'; @@ -66,7 +64,6 @@ const SECTIONS = [ {name: TG_ALLELES}, {name: MODELS}, {name: SEQUENCE_FEATURE_VIEWER}, - {name: SEQUENCE_PANEL}, {name: EXPRESSION}, {name: INTERACTIONS}, {name: GENETIC_INTERACTIONS}, @@ -197,18 +194,6 @@ const GenePage = ({geneId}) => { /> - - - - } title={EXPRESSION}> Date: Tue, 30 May 2023 16:34:39 -0500 Subject: [PATCH 15/85] SCRUM-2394 asserted genes and notes updates -- asserted genes display symbol instead of curie -- main row gene is filtered out of asserted genes -- notes are prefixed with either note or summary depending on type --- .../dataTable/AnnotatedEntitiesPopupCuration.js | 4 ++-- apps/main-app/src/components/dataTable/AssertedGenes.js | 9 +++++---- apps/main-app/src/components/dataTable/NoteCell.js | 4 +++- .../src/components/disease/diseaseAnnotationTable.js | 2 +- 4 files changed, 11 insertions(+), 8 deletions(-) diff --git a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js index 70387ddd5..1e4f317d3 100644 --- a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js +++ b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js @@ -39,7 +39,7 @@ function renderLink(entity) { } function AnnotatedEntitiesPopupCuration(props) { - const {children, entities} = props; + const {children, entities, mainRowCurie} = props; if (!entities || !entities.length) { return null; @@ -81,7 +81,7 @@ function AnnotatedEntitiesPopupCuration(props) { {renderLink(entity)} - + gene.curie !== mainRowCurie)}/> diff --git a/apps/main-app/src/components/dataTable/AssertedGenes.js b/apps/main-app/src/components/dataTable/AssertedGenes.js index 19b88d88d..a91f9a976 100644 --- a/apps/main-app/src/components/dataTable/AssertedGenes.js +++ b/apps/main-app/src/components/dataTable/AssertedGenes.js @@ -2,19 +2,20 @@ import CollapsibleList from '../collapsibleList/collapsibleList'; import ExternalLink from '../ExternalLink'; -function makeAssertedGeneLink(curie) { +function makeAssertedGeneLink(curie, geneSymbol) { if(curie) { - const name = ; - return {name}; + const symbol = ; + return {symbol}; } return null; } function AssertedGenes({assertedGenes}) { + console.log("asserted genes", assertedGenes) if(assertedGenes && assertedGenes.length > 1) { return ( - {assertedGenes.map(gene => makeAssertedGeneLink(gene.curie))} + {assertedGenes.map(gene => makeAssertedGeneLink(gene.curie, gene.geneSymbol.displayText))} ); } diff --git a/apps/main-app/src/components/dataTable/NoteCell.js b/apps/main-app/src/components/dataTable/NoteCell.js index 6865d1251..f0cd4d892 100644 --- a/apps/main-app/src/components/dataTable/NoteCell.js +++ b/apps/main-app/src/components/dataTable/NoteCell.js @@ -1,6 +1,8 @@ function NoteCell(note) { - return note && (
Note: {note.freeText}
); + console.log(note); + const prefix = note.noteType.name === "disease_note" ? "Note:" : "Summary:"; + return note && (
{prefix} {note.freeText}
); } export default NoteCell; diff --git a/apps/main-app/src/components/disease/diseaseAnnotationTable.js b/apps/main-app/src/components/disease/diseaseAnnotationTable.js index 7475bdcc8..357d74ec9 100644 --- a/apps/main-app/src/components/disease/diseaseAnnotationTable.js +++ b/apps/main-app/src/components/disease/diseaseAnnotationTable.js @@ -73,7 +73,7 @@ const DiseaseAnnotationTable = ({
{GeneCellCuration(row.subject)}
- + Annotation details From 1713c4a1ee7108122a31ed6639032e70b694bcd9 Mon Sep 17 00:00:00 2001 From: Adam Gibson Date: Tue, 30 May 2023 16:46:30 -0500 Subject: [PATCH 16/85] SCRUM-2394 moved filter logic into AssertedGenes component --- .../components/dataTable/AnnotatedEntitiesPopupCuration.js | 2 +- apps/main-app/src/components/dataTable/AssertedGenes.js | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js index 1e4f317d3..b3152c065 100644 --- a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js +++ b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js @@ -81,7 +81,7 @@ function AnnotatedEntitiesPopupCuration(props) { {renderLink(entity)} - gene.curie !== mainRowCurie)}/> + diff --git a/apps/main-app/src/components/dataTable/AssertedGenes.js b/apps/main-app/src/components/dataTable/AssertedGenes.js index a91f9a976..f287f1524 100644 --- a/apps/main-app/src/components/dataTable/AssertedGenes.js +++ b/apps/main-app/src/components/dataTable/AssertedGenes.js @@ -10,12 +10,12 @@ function makeAssertedGeneLink(curie, geneSymbol) { return null; } -function AssertedGenes({assertedGenes}) { - console.log("asserted genes", assertedGenes) +function AssertedGenes({assertedGenes, mainRowCurie}) { + const filteredAssertedGenes = assertedGenes?.filter(gene => gene.curie !== mainRowCurie); if(assertedGenes && assertedGenes.length > 1) { return ( - {assertedGenes.map(gene => makeAssertedGeneLink(gene.curie, gene.geneSymbol.displayText))} + {filteredAssertedGenes.map(gene => makeAssertedGeneLink(gene.curie, gene.geneSymbol.displayText))} ); } From b8ca2f027d54ce0c06369346e0c12ab317e7d9cd Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Wed, 31 May 2023 10:56:40 +0100 Subject: [PATCH 17/85] SCRUM-2394: increase popup width and add no-wrap to notes cell --- .../src/components/dataTable/AnnotatedEntitiesPopupCuration.js | 2 +- apps/main-app/src/components/dataTable/style.scss | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js index b3152c065..a9e9291c1 100644 --- a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js +++ b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js @@ -86,7 +86,7 @@ function AnnotatedEntitiesPopupCuration(props) { - + diff --git a/apps/main-app/src/components/dataTable/style.scss b/apps/main-app/src/components/dataTable/style.scss index 3b23f7ba3..706e8373d 100644 --- a/apps/main-app/src/components/dataTable/style.scss +++ b/apps/main-app/src/components/dataTable/style.scss @@ -46,7 +46,7 @@ overflow-y: scroll; .tablePopupInner { - width: 600px; + width: 900px; } } From f4395d517a66d8ed7a26c6e710ddc715256a8098 Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Wed, 31 May 2023 10:58:28 +0100 Subject: [PATCH 18/85] SCRUM-2394: increase popup width and add no-wrap to notes cell --- .../src/components/dataTable/AnnotatedEntitiesPopupCuration.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js index a9e9291c1..0ee9d6294 100644 --- a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js +++ b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js @@ -86,7 +86,7 @@ function AnnotatedEntitiesPopupCuration(props) { - + From d5b4e5f3623945ebfe6180e980aa8b168e889835 Mon Sep 17 00:00:00 2001 From: Adam Gibson Date: Wed, 7 Jun 2023 14:24:05 -0500 Subject: [PATCH 19/85] SCRUM-2723 removed subtype hack code --- .../components/dataTable/TypeCellCuration.js | 15 ++-------- .../components/dataTable/getResourceUrl.js | 30 +++++++------------ 2 files changed, 14 insertions(+), 31 deletions(-) diff --git a/apps/main-app/src/components/dataTable/TypeCellCuration.js b/apps/main-app/src/components/dataTable/TypeCellCuration.js index d996fbaf8..fd82d7ffc 100644 --- a/apps/main-app/src/components/dataTable/TypeCellCuration.js +++ b/apps/main-app/src/components/dataTable/TypeCellCuration.js @@ -1,19 +1,10 @@ const TypeCellCuration = ({ subject }) => { - if (subject.type === "AffectedGenomicModel") { - const [prefix] = subject.curie.split(':'); + const subtype = subject?.subtype?.name || ""; + const capitalizedSubtype = `${subtype.charAt(0).toUpperCase()}${subtype.slice(1)}`; - subject.subtype = {}; - if(prefix === "MGI") subject.subtype.name = "Genotype"; - if(prefix === "ZFIN") subject.subtype.name = "Fish"; - if(prefix === "WB") { - if(subject.curie.toLowerCase().includes("genotype")) subject.subtype.name = "Genotype"; - if(subject.curie.toLowerCase().includes("strain")) subject.subtype.name = "Strain"; - } - if(prefix === "RGD") subject.subtype.name = "Strain"; - - return subject.subtype?.name || ""; + return capitalizedSubtype || ""; } else { return subject.type || ""; } diff --git a/apps/main-app/src/components/dataTable/getResourceUrl.js b/apps/main-app/src/components/dataTable/getResourceUrl.js index e6fb0d76c..e9d6aa792 100644 --- a/apps/main-app/src/components/dataTable/getResourceUrl.js +++ b/apps/main-app/src/components/dataTable/getResourceUrl.js @@ -3,32 +3,24 @@ import { resourceDescriptors } from "../../../../../dist/resourceDescriptors"; export const getResourceUrl = (curie, type, subtype ) => { const [prefix, id] = curie.split(':'); - if(type === "AffectedGenomicModel" && !subtype){ - subtype = {}; - if(prefix === "MGI") subtype.name = "genotype"; - if(prefix === "ZFIN") subtype.name = "fish"; - if(prefix === "WB") { - if(curie.toLowerCase().includes("genotype")) subtype.name = "genotype"; - if(curie.toLowerCase().includes("strain")) subtype.name = "strain"; - } - if(prefix === "RGD") subtype.name = "strain"; - } - let resource; if(subtype){ [resource] = resourceDescriptors - .filter(resource => resource.db_prefix === prefix)[0].pages - .filter(page => page.name === subtype.name.toLowerCase())[0].url - .split('['); + .find(resource => resource.db_prefix === prefix)?.pages + .find(page => page.name === subtype.name.toLowerCase())?.url + .split('[') + || []; } else if(type){ [resource] = resourceDescriptors - .filter(resource => resource.db_prefix === prefix)[0].pages - .filter(page => page.name === type.toLowerCase())[0].url - .split('['); + .find(resource => resource.db_prefix === prefix)?.pages + .find(page => page.name === type.toLowerCase())?.url + .split('[') + || []; } else { [resource] = resourceDescriptors - .filter(resource => resource.db_prefix === prefix)[0].default_url - .split('['); + .find(resource => resource.db_prefix === prefix)?.default_url + .split('[') + || []; } return resource + id; } From 97bf521147c7dd827f5eae1cd9be267194a26f2a Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Thu, 22 Jun 2023 10:26:55 +0100 Subject: [PATCH 20/85] SCRUM-2833: add genetic modifiers --- .../AnnotatedEntitiesPopupCuration.js | 3 ++ .../dataTable/GeneticModifiersCellCuration.js | 28 +++++++++++++++++++ 2 files changed, 31 insertions(+) create mode 100644 apps/main-app/src/components/dataTable/GeneticModifiersCellCuration.js diff --git a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js index 0ee9d6294..0429e33fa 100644 --- a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js +++ b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js @@ -20,6 +20,7 @@ import EvidenceCodesCellCuration from './evidenceCodesCellCuration'; import AnnotationSource from './AnnotationSource'; import GeneticSex from './GeneticSex'; import AnnotationType from './AnnotationType'; +import GeneticModifiersCellCuration from './GeneticModifiersCellCuration'; function renderLink(entity) { const url = getResourceUrl(entity.subject.curie, entity.subject.type, entity.subject.subtype) @@ -66,6 +67,7 @@ function AnnotatedEntitiesPopupCuration(props) { Additional implicated genes Experimental condition Modifier + Genetic Modifier Strain Background Genetic Sex Notes @@ -84,6 +86,7 @@ function AnnotatedEntitiesPopupCuration(props) { + diff --git a/apps/main-app/src/components/dataTable/GeneticModifiersCellCuration.js b/apps/main-app/src/components/dataTable/GeneticModifiersCellCuration.js new file mode 100644 index 000000000..abd2d7fef --- /dev/null +++ b/apps/main-app/src/components/dataTable/GeneticModifiersCellCuration.js @@ -0,0 +1,28 @@ +import React from 'react'; +import { CollapsibleList } from '../collapsibleList'; +import ExternalLink from '../ExternalLink'; +import { getResourceUrl } from './getResourceUrl'; + + +function GeneticModifier(modifier) { + let url = getResourceUrl(modifier.curie, modifier.type); + return {modifier.curie}; +} + +function GeneticModifiersCellCuration ({relation, modifiers}) { + if(relation && modifiers?.length > 0){ + return (
+ +
{relation.name.replace(/_/, ' ')}:
+
+ + {modifiers.map(GeneticModifier)} + +
+
+
); + } + return <>; +}; + +export default GeneticModifiersCellCuration; \ No newline at end of file From 72769515b8ad0c6b8ef38dcef6bd8581da4e6179 Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Thu, 22 Jun 2023 10:37:33 +0100 Subject: [PATCH 21/85] SCRUM-2833: fix header --- .../src/components/dataTable/AnnotatedEntitiesPopupCuration.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js index 0429e33fa..52326dcfa 100644 --- a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js +++ b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js @@ -67,7 +67,7 @@ function AnnotatedEntitiesPopupCuration(props) { Additional implicated genes Experimental condition Modifier - Genetic Modifier + Genetic Modifiers Strain Background Genetic Sex Notes From 0c2a4b472b64acad4cba693f21724266d099e717 Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Thu, 22 Jun 2023 14:34:24 +0100 Subject: [PATCH 22/85] SCRUM-2833: pass subtype and set width for related notes --- .../components/dataTable/AnnotatedEntitiesPopupCuration.js | 4 ++-- .../components/dataTable/GeneticModifiersCellCuration.js | 4 ++-- apps/main-app/src/components/dataTable/NoteCell.js | 1 - apps/main-app/src/components/dataTable/style.scss | 4 ++++ apps/main-app/src/components/pathway/pathwayWidget.js | 6 +++--- 5 files changed, 11 insertions(+), 8 deletions(-) diff --git a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js index 52326dcfa..c592e8739 100644 --- a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js +++ b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js @@ -70,7 +70,7 @@ function AnnotatedEntitiesPopupCuration(props) { Genetic Modifiers Strain Background Genetic Sex - Notes + Notes Annotation type Evidence Code Source @@ -89,7 +89,7 @@ function AnnotatedEntitiesPopupCuration(props) { - + diff --git a/apps/main-app/src/components/dataTable/GeneticModifiersCellCuration.js b/apps/main-app/src/components/dataTable/GeneticModifiersCellCuration.js index abd2d7fef..0cd92e30c 100644 --- a/apps/main-app/src/components/dataTable/GeneticModifiersCellCuration.js +++ b/apps/main-app/src/components/dataTable/GeneticModifiersCellCuration.js @@ -5,7 +5,7 @@ import { getResourceUrl } from './getResourceUrl'; function GeneticModifier(modifier) { - let url = getResourceUrl(modifier.curie, modifier.type); + let url = getResourceUrl(modifier.curie, modifier.type, modifier.subtype); return {modifier.curie}; } @@ -13,7 +13,7 @@ function GeneticModifiersCellCuration ({relation, modifiers}) { if(relation && modifiers?.length > 0){ return (
-
{relation.name.replace(/_/, ' ')}:
+
{relation.name?.replace(/_/, ' ')}:
{modifiers.map(GeneticModifier)} diff --git a/apps/main-app/src/components/dataTable/NoteCell.js b/apps/main-app/src/components/dataTable/NoteCell.js index f0cd4d892..b0256a9fa 100644 --- a/apps/main-app/src/components/dataTable/NoteCell.js +++ b/apps/main-app/src/components/dataTable/NoteCell.js @@ -1,6 +1,5 @@ function NoteCell(note) { - console.log(note); const prefix = note.noteType.name === "disease_note" ? "Note:" : "Summary:"; return note && (
{prefix} {note.freeText}
); } diff --git a/apps/main-app/src/components/dataTable/style.scss b/apps/main-app/src/components/dataTable/style.scss index 706e8373d..efc5a72d0 100644 --- a/apps/main-app/src/components/dataTable/style.scss +++ b/apps/main-app/src/components/dataTable/style.scss @@ -53,3 +53,7 @@ .helpIconWrapper { margin-left: 5px; } + +.relatedNotes { + min-width: 300px; +} \ No newline at end of file diff --git a/apps/main-app/src/components/pathway/pathwayWidget.js b/apps/main-app/src/components/pathway/pathwayWidget.js index 6bccfbcab..500aea3ff 100644 --- a/apps/main-app/src/components/pathway/pathwayWidget.js +++ b/apps/main-app/src/components/pathway/pathwayWidget.js @@ -416,7 +416,7 @@ class PathwayWidget extends Component { : } -
+
{(this.state.reactomePathways.loaded && !this.state.reactomePathways.error && this.state.reactomePathways.pathways.length > 0) ?
@@ -446,7 +446,7 @@ class PathwayWidget extends Component {
: } - + {(this.state.reactomeReactions.loaded && this.state.reactomeReactions.reactions && this.state.reactomeReactions.reactions.length > 0) ?
@@ -490,7 +490,7 @@ class PathwayWidget extends Component { show-activity="false" show-isolated-activity="true" show-legend="false" - style={{ "max-width": "1280px" }} + style={{ "maxWidth": "1280px" }} >
From 5b1d13b7ef098bdaaa16cabec64bdae8e2aae24a Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Fri, 23 Jun 2023 13:50:02 +0100 Subject: [PATCH 23/85] SCRUM-2833: make gene and allele links internal --- .../dataTable/GeneticModifiersCellCuration.js | 23 +++++++++++++++---- 1 file changed, 19 insertions(+), 4 deletions(-) diff --git a/apps/main-app/src/components/dataTable/GeneticModifiersCellCuration.js b/apps/main-app/src/components/dataTable/GeneticModifiersCellCuration.js index 0cd92e30c..80795333d 100644 --- a/apps/main-app/src/components/dataTable/GeneticModifiersCellCuration.js +++ b/apps/main-app/src/components/dataTable/GeneticModifiersCellCuration.js @@ -2,11 +2,26 @@ import React from 'react'; import { CollapsibleList } from '../collapsibleList'; import ExternalLink from '../ExternalLink'; import { getResourceUrl } from './getResourceUrl'; +import { Link } from 'react-router-dom'; -function GeneticModifier(modifier) { - let url = getResourceUrl(modifier.curie, modifier.type, modifier.subtype); - return {modifier.curie}; +function GeneticModifierLink(modifier) { + switch(modifier?.type) { + case 'Gene': + return {modifier.geneSymbol.displayText}; + break; + case 'Allele': + return {modifier.alleleSymbol.displayText}; + break; + case 'AffectedGenomicModel': + let url = getResourceUrl(modifier.curie, modifier.type, modifier.subtype); + return {modifier.curie}; + break; + default: + return <>; + break; + } + return <>; } function GeneticModifiersCellCuration ({relation, modifiers}) { @@ -16,7 +31,7 @@ function GeneticModifiersCellCuration ({relation, modifiers}) {
{relation.name?.replace(/_/, ' ')}:
- {modifiers.map(GeneticModifier)} + {modifiers.map(GeneticModifierLink)}
From 5eef7d54f5c53c2cb9bb94edfd041e382d59658f Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Fri, 23 Jun 2023 14:45:57 +0100 Subject: [PATCH 24/85] SCRUM-2833: use dangerousSetInnerHTML --- .../dataTable/GeneticModifiersCellCuration.js | 21 ++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) diff --git a/apps/main-app/src/components/dataTable/GeneticModifiersCellCuration.js b/apps/main-app/src/components/dataTable/GeneticModifiersCellCuration.js index 80795333d..1805e9392 100644 --- a/apps/main-app/src/components/dataTable/GeneticModifiersCellCuration.js +++ b/apps/main-app/src/components/dataTable/GeneticModifiersCellCuration.js @@ -8,14 +8,29 @@ import { Link } from 'react-router-dom'; function GeneticModifierLink(modifier) { switch(modifier?.type) { case 'Gene': - return {modifier.geneSymbol.displayText}; + if (modifier.geneSymbol) { + return ( + + + ); + } break; case 'Allele': - return {modifier.alleleSymbol.displayText}; + if (modifier.alleleSymbol) { + return ( + + + ); + } break; case 'AffectedGenomicModel': let url = getResourceUrl(modifier.curie, modifier.type, modifier.subtype); - return {modifier.curie}; + if (url) { + return ( + + + ); + } break; default: return <>; From ac5c2d947a4f99ec7dfe6e0c5a633927dd9d7762 Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Fri, 23 Jun 2023 14:53:17 +0100 Subject: [PATCH 25/85] SCRUM-2833: Remove Header 'Modifier' that was a placeholder --- .../src/components/dataTable/AnnotatedEntitiesPopupCuration.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js index c592e8739..8cb5d17cf 100644 --- a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js +++ b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js @@ -66,7 +66,7 @@ function AnnotatedEntitiesPopupCuration(props) { Type Additional implicated genes Experimental condition - Modifier + Genetic Modifiers Strain Background Genetic Sex From d4fde996296b5b113a7a3a28cfd216c77907b320 Mon Sep 17 00:00:00 2001 From: Christian Pich Date: Mon, 26 Jun 2023 12:23:35 +0200 Subject: [PATCH 26/85] SCRUM-2704 rename endpoint /homologs to /orthologs --- apps/main-app/src/hooks/useGeneOrthology.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/main-app/src/hooks/useGeneOrthology.js b/apps/main-app/src/hooks/useGeneOrthology.js index 5538ba427..ef185a649 100644 --- a/apps/main-app/src/hooks/useGeneOrthology.js +++ b/apps/main-app/src/hooks/useGeneOrthology.js @@ -3,6 +3,6 @@ import fetchData from '../lib/fetchData'; export default function useGeneOrthology(geneId) { return useQuery(['gene-orthology', geneId], () => { - return fetchData(`/api/gene/${geneId}/homologs?filter.stringency=all&limit=10000`); + return fetchData(`/api/gene/${geneId}/orthologs?filter.stringency=all&limit=10000`); }); } From 6f2a8f00a36ab9e88ca4e70a3e51055e8e32c231 Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Tue, 4 Jul 2023 12:16:46 +0100 Subject: [PATCH 27/85] SCRUM-2703: add paralogy section --- .../dataTable/EvidenceCodeCuration.js | 2 +- .../paralogy/paralogyFilteredTable.js | 215 ++++++++++++++++++ .../src/components/paralogy/paralogyTable.js | 122 ++++++++++ .../components/paralogy/paralogyUserGuide.js | 35 +++ .../main-app/src/containers/genePage/index.js | 8 + apps/main-app/src/hooks/useGeneParalogy.js | 8 + 6 files changed, 389 insertions(+), 1 deletion(-) create mode 100644 apps/main-app/src/components/paralogy/paralogyFilteredTable.js create mode 100644 apps/main-app/src/components/paralogy/paralogyTable.js create mode 100644 apps/main-app/src/components/paralogy/paralogyUserGuide.js create mode 100644 apps/main-app/src/hooks/useGeneParalogy.js diff --git a/apps/main-app/src/components/dataTable/EvidenceCodeCuration.js b/apps/main-app/src/components/dataTable/EvidenceCodeCuration.js index 6f0c04e16..db3f8d1ac 100644 --- a/apps/main-app/src/components/dataTable/EvidenceCodeCuration.js +++ b/apps/main-app/src/components/dataTable/EvidenceCodeCuration.js @@ -28,7 +28,7 @@ const EvidenceCodeCuration = ({code}) => { } }; -EvidenceCodeCuration.PropTypes = { +EvidenceCodeCuration.propTypes = { code: PropTypes.shape({ curie: PropTypes.string, name: PropTypes.string, diff --git a/apps/main-app/src/components/paralogy/paralogyFilteredTable.js b/apps/main-app/src/components/paralogy/paralogyFilteredTable.js new file mode 100644 index 000000000..59fe5a150 --- /dev/null +++ b/apps/main-app/src/components/paralogy/paralogyFilteredTable.js @@ -0,0 +1,215 @@ +import { useState } from 'react'; +import PropTypes from 'prop-types'; +import { Collapse } from 'reactstrap'; +import StringencySelection from '../orthology/stringencySelection'; +import { isBest } from '../orthology/orthologyTable'; +import { getOrthologSpeciesName } from '../orthology/utils'; +import HorizontalScroll from '../horizontalScroll'; +import LoadingSpinner from '../loadingSpinner'; +import NoData from '../noData'; +import ControlsContainer from '../controlsContainer'; +import { STRINGENCY_HIGH } from '../orthology/constants'; +import { + compareAlphabeticalCaseInsensitive, + orthologyMeetsStringency +} from '../../lib/utils'; +import HelpPopup from '../helpPopup'; +import OrthologyFilterHelp from '../orthology/orthologyFilterHelp'; +import useResettableState from '../../hooks/useResettableState'; +import useGeneParalogy from '../../hooks/useGeneParalogy'; +import ParalogyTable from './paralogyTable'; + +const ParalogyFilteredTable = ({geneId}) => { + const [ + filterScoreGreaterThan, + setFilterScoreGreaterThan, + resetFilterScoreGreaterThan + ] = useResettableState(0); + const [ + filterMethod, + setFilterMethod, + resetFilterMethod + ] = useResettableState(null); + const [ + filterBest, + setFilterBest, + resetFilterBest + ] = useResettableState(false); + const [ + filterReverseBest, + setFilterReverseBest, + resetFilterReverseBest + ] = useResettableState(false); + const [ + filterSpecies, + setFilterSpecies, + resetFilterSpecies + ] = useResettableState(null); + const [ + stringencyLevel, + setStringencyLevel, + resetStringencyLevel + ] = useResettableState(STRINGENCY_HIGH); + const [showFilterPanel, setShowFilterPanel] = useState(false); + + const { data, isLoading } = useGeneParalogy(geneId); + + const filterCallback = (dat) => { + const meetMethodFilter = filterMethod ? + dat.predictionMethodsMatched.indexOf(filterMethod) > -1 : + true; + return ( + meetMethodFilter && + dat.predictionMethodsMatched.length > filterScoreGreaterThan && + (filterBest ? isBest(dat.best) : true) && + (filterReverseBest ? isBest(dat.bestReverse) : true) && + (filterSpecies ? getOrthologSpeciesName(dat) === filterSpecies : true) && + orthologyMeetsStringency(dat, stringencyLevel) + ); + }; + + const resetFilters = () => { + resetFilterScoreGreaterThan(); + resetFilterMethod(); + resetFilterBest(); + resetFilterReverseBest(); + resetFilterSpecies(); + resetStringencyLevel(); + }; + + if (isLoading) { + return ; + } + + if (data.total === 0) { + return ; + } + + const filteredData = data.results.filter(filterCallback); + const all_methods = data.results[0].predictionMethodsMatched.concat( + data.results[0].predictionMethodsNotCalled, + data.results[0].predictionMethodsNotMatched + ).sort(compareAlphabeticalCaseInsensitive); + + const labelStyle = { + margin: '0em 1em 0em 0', + lineHeight: '2em', + }; + const inputStyle = { + margin: '0 0.5em' + }; + + const buttonStyle = { + marginTop: '0.5em', + marginRight: '0.5em', + minWidth: '8em', + }; + + const docTextStyle = { + fontStyle: 'italic', + opacity: 0.7, + fontSize: '0.9em', + }; + + return ( +
+ + + + + + + + +
+ Additional filters to further constrain the results: +
+ + +
+ + +
+
+
+ + +
+
+ +
+ { + filteredData.length > 0 ? + + + : + No paralog matching your filter. Please try a less stringent filter. + } +
+
+ ); +}; + +ParalogyFilteredTable.propTypes = { + geneId: PropTypes.string.isRequired, +}; + +export default ParalogyFilteredTable; diff --git a/apps/main-app/src/components/paralogy/paralogyTable.js b/apps/main-app/src/components/paralogy/paralogyTable.js new file mode 100644 index 000000000..d5a164891 --- /dev/null +++ b/apps/main-app/src/components/paralogy/paralogyTable.js @@ -0,0 +1,122 @@ +import { Component } from 'react'; +import PropTypes from 'prop-types'; +import { Link } from 'react-router-dom'; +import MethodHeader from '../orthology/methodHeader'; +import MethodCell from '../orthology/methodCell'; +import BooleanCell from '../orthology/booleanCell'; +import { + getOrthologSpeciesName, + getOrthologId, + getOrthologSymbol, +} from '../orthology/utils'; +import HelpPopup from '../helpPopup'; + +import style from '../orthology/style.scss'; + +const columns = [ + {name: 'Gene symbol'}, + {name: 'Count'}, + {name: 'Best', help: This gene is called a paralog of the input gene by the highest number of algorithms.
In specific cases, ZFIN curators have asserted reliable paralogy to the gene called by the second highest number of algorithms. These are denoted Yes *.
}, + {name: 'Best reverse', help: 'The input gene is called a paralog of this gene by the highest number of algorithms.'}, + {name: 'Method'} +]; + +export function isBest(value = '') { + return typeof value === 'boolean' ? value : value.match(/yes/i); +} + +class ParalogyTable extends Component { + + render() { + let rowGroup = 0; + return( + + + + { + columns.map((column) => { + if (column.name === 'Method') { + return (); + } else { + return (); + } + }) + } + + + + { + this.props.data.map((orthData, idx, orthList) => { + const scoreNumerator = orthData.predictionMethodsMatched.length; + const scoreDemominator = scoreNumerator + + orthData.predictionMethodsNotMatched.length; + const orthId = getOrthologId(orthData); + + if (idx > 0 && getOrthologSpeciesName(orthList[idx - 1]) !== getOrthologSpeciesName(orthData)) { + rowGroup += 1; + } + + return ( + + + + 'Yes *' : + null + } + value={orthData.best} + /> + + + + ); + }) + } + +
+ {column.name} {column.help && {column.help}} +
+ + + + {`${scoreNumerator} of ${scoreDemominator}`}
+ ); + } +} + +ParalogyTable.propTypes = { + data: PropTypes.arrayOf( + PropTypes.shape({ + gene: PropTypes.shape({ + id: PropTypes.string, + symbol: PropTypes.string, + species: PropTypes.shape({ + name: PropTypes.string, + }), + }), + predictionMethodsMatched: PropTypes.arrayOf(PropTypes.string), + predictionMethodsNotCalled: PropTypes.arrayOf(PropTypes.string), + predictionMethodsNotMatched: PropTypes.arrayOf(PropTypes.string), + best: PropTypes.oneOfType([ + PropTypes.bool, + PropTypes.string + ]), + bestReverse: PropTypes.oneOfType([ + PropTypes.bool, + PropTypes.string + ]), + }) + ) +}; + +export default ParalogyTable; diff --git a/apps/main-app/src/components/paralogy/paralogyUserGuide.js b/apps/main-app/src/components/paralogy/paralogyUserGuide.js new file mode 100644 index 000000000..089c7aaa6 --- /dev/null +++ b/apps/main-app/src/components/paralogy/paralogyUserGuide.js @@ -0,0 +1,35 @@ +import ExternalLink from '../ExternalLink'; + +const ParalogyUserGuide = () => ( +
+

+ Many aspects of data integration presented at the Alliance require a + common set of paralogy relationships among genes for the organisms + represented, including human. The Alliance provides the results of + all methods that have been benchmarked by the + Quest for Orthologs Consortium (QfO), as well as curated + ortholog inferences from HGNC (for human and mouse genes), Xenbase (for frog genes), and + ZFIN (relating zebrafish genes to orthologs in human, mouse, and fly). +

+

+ The paralog inferences from the different methods have been + integrated using the DRSC Integrative Ortholog Prediction Tool + (DIOPT). DIOPT integrates a number of existing methods including + those used by the Alliance: Ensembl Compara, HGNC, Hieranoid, + InParanoid, OMA, OrthoFinder, OrthoInspector, PANTHER, PhylomeDB, + SonicParanoid, Xenbase, and ZFIN. See the + DIOPT documentation for additional information and + references related to the included methods. DIOPT assigns a + score/count based on the number of methods that call a specific + paralog. For noncoding RNA genes, currently only HGNC and ZFIN + curated paralogs are included. +

+

+ The DIOPT approach allows flexibility in the choice of algorithms and + in the level of stringency applied. For the Paralogy table, these + parameters can be specified. +

+
+); + +export default ParalogyUserGuide; diff --git a/apps/main-app/src/containers/genePage/index.js b/apps/main-app/src/containers/genePage/index.js index c3dd7ecc5..2fb549e59 100644 --- a/apps/main-app/src/containers/genePage/index.js +++ b/apps/main-app/src/containers/genePage/index.js @@ -3,6 +3,8 @@ import PropTypes from 'prop-types'; import { DataPage, PageNav, PageData, PageHeader } from '../../components/dataPage'; import BasicGeneInfo from './basicGeneInfo'; import { OrthologyFilteredTable, OrthologyUserGuide, OrthologyBasicInfo } from '../../components/orthology'; +import ParalogyFilteredTable from '../../components/paralogy/paralogyFilteredTable' +import ParalogyUserGuide from '../../components/paralogy/paralogyUserGuide' import GoUserGuide from '../../components/geneOntologyRibbon/goUserGuide'; import PathwayUserGuide from '../../components/pathway/pathwayUserGuide'; @@ -44,6 +46,7 @@ const SEQUENCE_FEATURE_VIEWER = 'Sequence Feature Viewer'; const FUNCTION = 'Function - GO Annotations'; const PATHWAY = 'Pathways'; const ORTHOLOGY = 'Orthology'; +const PARALOGY = 'Paralogy' const DISEASE = 'Disease Associations'; const EXPRESSION = 'Expression'; const ALLELES = 'Alleles and Variants'; @@ -56,6 +59,7 @@ const MODELS = 'Models'; const SECTIONS = [ {name: SUMMARY}, {name: ORTHOLOGY}, + {name: PARALOGY}, {name: FUNCTION}, {name: PATHWAY}, {name: PHENOTYPES}, @@ -123,6 +127,10 @@ const GenePage = ({geneId}) => { + } title={PARALOGY}> + + + } title={FUNCTION}> { + return fetchData(`/api/gene/${geneId}/paralogs?filter.stringency=all&limit=10000`); + }); +} From 052d46e8a0f2f3dea0dbb46761432b59a24c19c2 Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Mon, 10 Jul 2023 16:07:01 +0100 Subject: [PATCH 28/85] SCRUM-2703: remove comparison and import --- apps/main-app/src/components/paralogy/paralogyTable.js | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/apps/main-app/src/components/paralogy/paralogyTable.js b/apps/main-app/src/components/paralogy/paralogyTable.js index d5a164891..d3729a80f 100644 --- a/apps/main-app/src/components/paralogy/paralogyTable.js +++ b/apps/main-app/src/components/paralogy/paralogyTable.js @@ -5,9 +5,8 @@ import MethodHeader from '../orthology/methodHeader'; import MethodCell from '../orthology/methodCell'; import BooleanCell from '../orthology/booleanCell'; import { - getOrthologSpeciesName, getOrthologId, - getOrthologSymbol, + getOrthologSymbol as getHomologSymbol, } from '../orthology/utils'; import HelpPopup from '../helpPopup'; @@ -54,15 +53,11 @@ class ParalogyTable extends Component { orthData.predictionMethodsNotMatched.length; const orthId = getOrthologId(orthData); - if (idx > 0 && getOrthologSpeciesName(orthList[idx - 1]) !== getOrthologSpeciesName(orthData)) { - rowGroup += 1; - } - return ( - + {`${scoreNumerator} of ${scoreDemominator}`} From 39129504d8708751035e7148309ed838d0b405cd Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Wed, 12 Jul 2023 10:15:21 +0100 Subject: [PATCH 29/85] SCRUM-2703: sort by number of predictions methods matched --- apps/main-app/src/components/paralogy/paralogyTable.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/apps/main-app/src/components/paralogy/paralogyTable.js b/apps/main-app/src/components/paralogy/paralogyTable.js index d3729a80f..edc80abfc 100644 --- a/apps/main-app/src/components/paralogy/paralogyTable.js +++ b/apps/main-app/src/components/paralogy/paralogyTable.js @@ -8,6 +8,7 @@ import { getOrthologId, getOrthologSymbol as getHomologSymbol, } from '../orthology/utils'; +import { sortBy } from '../../lib/utils'; import HelpPopup from '../helpPopup'; import style from '../orthology/style.scss'; @@ -47,7 +48,9 @@ class ParalogyTable extends Component { { - this.props.data.map((orthData, idx, orthList) => { + sortBy(this.props.data, [ + (orthDataA, orthDataB) => orthDataB.predictionMethodsMatched.length - orthDataA.predictionMethodsMatched.length + ]).map((orthData, idx, orthList) => { const scoreNumerator = orthData.predictionMethodsMatched.length; const scoreDemominator = scoreNumerator + orthData.predictionMethodsNotMatched.length; From 2e5c0a53848b3fe800c3efdd3a2c390e9bbc9fbb Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Wed, 12 Jul 2023 10:41:47 +0100 Subject: [PATCH 30/85] SCRUM-2703: sort by best and bestReverse --- .../src/components/paralogy/paralogyTable.js | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/apps/main-app/src/components/paralogy/paralogyTable.js b/apps/main-app/src/components/paralogy/paralogyTable.js index edc80abfc..bb0918bb2 100644 --- a/apps/main-app/src/components/paralogy/paralogyTable.js +++ b/apps/main-app/src/components/paralogy/paralogyTable.js @@ -25,6 +25,15 @@ export function isBest(value = '') { return typeof value === 'boolean' ? value : value.match(/yes/i); } +function scoreBest(best, bestReverse, OtherBest, OtherBestReverse) { + let AB = (best === 'Yes') ? -1 : 0; + let AR = (bestReverse === 'Yes') ? -1 : 0; + let OB = (OtherBest === 'Yes') ? -1 : 0; + let OR = (OtherBestReverse === 'Yes') ? -1 : 0; + return (AB+AR) - (OB+OR) +} + + class ParalogyTable extends Component { render() { @@ -49,7 +58,8 @@ class ParalogyTable extends Component { { sortBy(this.props.data, [ - (orthDataA, orthDataB) => orthDataB.predictionMethodsMatched.length - orthDataA.predictionMethodsMatched.length + (orthDataA, orthDataB) => orthDataB.predictionMethodsMatched.length - orthDataA.predictionMethodsMatched.length, + (orthDataA, orthDataB) => scoreBest(orthDataA.best, orthDataA.bestReverse, orthDataB.best, orthDataB.bestReverse) ]).map((orthData, idx, orthList) => { const scoreNumerator = orthData.predictionMethodsMatched.length; const scoreDemominator = scoreNumerator + From c730c474abda06414f002ab1deb1330cc61fc934 Mon Sep 17 00:00:00 2001 From: Christian Pich Date: Wed, 12 Jul 2023 15:03:55 +0200 Subject: [PATCH 31/85] SCRUM-2823 add disease qualifier column to disease annoation table on gene page --- .../dataTable/DiseaseQualifiersColumn.js | 23 +++++++++++++++++++ .../disease/diseaseAnnotationTable.js | 9 ++++++++ package.json | 1 + 3 files changed, 33 insertions(+) create mode 100644 apps/main-app/src/components/dataTable/DiseaseQualifiersColumn.js diff --git a/apps/main-app/src/components/dataTable/DiseaseQualifiersColumn.js b/apps/main-app/src/components/dataTable/DiseaseQualifiersColumn.js new file mode 100644 index 000000000..0560a2227 --- /dev/null +++ b/apps/main-app/src/components/dataTable/DiseaseQualifiersColumn.js @@ -0,0 +1,23 @@ +import React from 'react'; +import PropTypes from 'prop-types'; +import CommaSeparatedList from '../commaSeparatedList'; +import EvidenceCodeCuration from './EvidenceCodeCuration'; + +const DiseaseQualifiersColumn = ({qualifiers}) => { + + if (!qualifiers || !qualifiers.length) { + return null; + } + + return ( + + {qualifiers.map(qualifier => qualifier)} + + ); +}; + +DiseaseQualifiersColumn.propTypes = { + qualifiers: PropTypes.arrayOf(PropTypes.string), +}; + +export default DiseaseQualifiersColumn; diff --git a/apps/main-app/src/components/disease/diseaseAnnotationTable.js b/apps/main-app/src/components/disease/diseaseAnnotationTable.js index 357d74ec9..5ea3fbb4d 100644 --- a/apps/main-app/src/components/disease/diseaseAnnotationTable.js +++ b/apps/main-app/src/components/disease/diseaseAnnotationTable.js @@ -17,6 +17,7 @@ import useComparisonRibbonTableQuery from '../../hooks/useComparisonRibbonTableQ import SpeciesName from '../SpeciesName'; import AssociationType from '../AssociationType'; import DiseaseLinkCuration from './DiseaseLinkCuration'; +import DiseaseQualifiersColumn from "../dataTable/DiseaseQualifiersColumn"; /* @@ -92,6 +93,14 @@ const DiseaseAnnotationTable = ({ filterFormatter: type => , headerStyle: {width: '120px'}, }, + { + dataField: 'diseaseQualifier', + text: 'Disease Qualifier', + filterable: true, + headerStyle: {width: '100px'}, + formatter: diseaseQualifiers => , + filterName: 'diseaseQualifier', + }, { dataField: 'object.curie', text: 'Disease', diff --git a/package.json b/package.json index cf62114b2..d97a636da 100644 --- a/package.json +++ b/package.json @@ -90,6 +90,7 @@ }, "devDependencies": { "@babel/core": "7.9.6", + "@babel/plugin-proposal-private-property-in-object": "^7.21.11", "@babel/preset-env": "7.9.6", "@babel/preset-react": "7.9.4", "@babel/preset-typescript": "7.9.0", From 8da210595d54dd7922df173e9c2c50976e069c1a Mon Sep 17 00:00:00 2001 From: Adam Gibson Date: Thu, 13 Jul 2023 10:32:33 -0500 Subject: [PATCH 32/85] KANBAN-357 Update build_resource_descriptors.js to create dist folder --- bin/build_resource_descriptors.js | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/bin/build_resource_descriptors.js b/bin/build_resource_descriptors.js index 74e5f958a..3a0872d82 100644 --- a/bin/build_resource_descriptors.js +++ b/bin/build_resource_descriptors.js @@ -1,12 +1,17 @@ const yaml = require('js-yaml'); const https = require('https'); -const fs = require('fs'); +const fs = require('fs'); console.log("Build resource desriptors is running..."); // Get document, or throw exception on error const url = 'https://raw.githubusercontent.com/alliance-genome/agr_schemas/master/resourceDescriptors.yaml'; +const dir = './dist'; -const file = fs.createWriteStream("./dist/resourceDescriptors.yaml"); +if(!fs.existsSync(dir)){ + fs.mkdirSync(dir); +} + +const file = fs.createWriteStream(`${dir}/resourceDescriptors.yaml`); console.log("Output file: " + file.path); From 3550754f2f7c85951b90fdb690c2cbc4d641e051 Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Wed, 19 Jul 2023 12:52:53 +0100 Subject: [PATCH 33/85] SCRUM-3082: refactor {ortho,para} logy sections --- .../main-app/src/components/OrthologPicker.js | 2 +- .../disease/diseaseComparisonRibbon.js | 2 +- .../expression/expressionComparisonRibbon.js | 2 +- .../components/geneOntologyRibbon/index.js | 2 +- .../{orthology => homology}/booleanCell.js | 2 -- .../{orthology => homology}/constants.js | 0 .../homologyFilterHelp.js} | 25 ++++++++++--------- .../homologyUserGuide.js} | 5 ++-- .../{orthology => homology}/methodCell.js | 1 - .../{orthology => homology}/methodHeader.js | 1 - .../{orthology => homology}/methodLogo.js | 1 - .../stringencySelection.js | 0 .../{orthology => homology}/style.scss | 0 .../{orthology => homology}/utils.js | 0 .../src/components/orthology/index.js | 8 +++--- .../orthology/orthologyBasicInfo.js | 2 +- .../orthology/orthologyFilteredTable.js | 14 +++++------ .../components/orthology/orthologyTable.js | 12 ++++----- .../paralogy/paralogyFilteredTable.js | 10 ++++---- .../src/components/paralogy/paralogyTable.js | 11 ++++---- .../src/components/pathway/pathwayWidget.js | 2 +- .../main-app/src/containers/genePage/index.js | 4 +-- apps/main-app/src/lib/utils.js | 2 +- 23 files changed, 52 insertions(+), 56 deletions(-) rename apps/main-app/src/components/{orthology => homology}/booleanCell.js (94%) rename apps/main-app/src/components/{orthology => homology}/constants.js (100%) rename apps/main-app/src/components/{orthology/orthologyFilterHelp.js => homology/homologyFilterHelp.js} (61%) rename apps/main-app/src/components/{orthology/orthologyUserGuide.js => homology/homologyUserGuide.js} (94%) rename apps/main-app/src/components/{orthology => homology}/methodCell.js (98%) rename apps/main-app/src/components/{orthology => homology}/methodHeader.js (94%) rename apps/main-app/src/components/{orthology => homology}/methodLogo.js (96%) rename apps/main-app/src/components/{orthology => homology}/stringencySelection.js (100%) rename apps/main-app/src/components/{orthology => homology}/style.scss (100%) rename apps/main-app/src/components/{orthology => homology}/utils.js (100%) diff --git a/apps/main-app/src/components/OrthologPicker.js b/apps/main-app/src/components/OrthologPicker.js index e753843ed..83e7cacf3 100644 --- a/apps/main-app/src/components/OrthologPicker.js +++ b/apps/main-app/src/components/OrthologPicker.js @@ -4,7 +4,7 @@ import { STRINGENCY_HIGH, STRINGENCY_MED, STRINGNECY_LOW -} from './orthology/constants'; +} from './homology/constants'; import { DropdownMenu, DropdownToggle, diff --git a/apps/main-app/src/components/disease/diseaseComparisonRibbon.js b/apps/main-app/src/components/disease/diseaseComparisonRibbon.js index 142115e99..af8488413 100644 --- a/apps/main-app/src/components/disease/diseaseComparisonRibbon.js +++ b/apps/main-app/src/components/disease/diseaseComparisonRibbon.js @@ -7,7 +7,7 @@ import React, { useRef, useState } from 'react'; import PropTypes from 'prop-types'; import DiseaseAnnotationTable from './diseaseAnnotationTable'; import HorizontalScroll from '../horizontalScroll'; -import { STRINGENCY_HIGH } from '../orthology/constants'; +import { STRINGENCY_HIGH } from '../homology/constants'; import HelpPopup from '../helpPopup'; import DiseaseControlsHelp from './diseaseControlsHelp'; import ControlsContainer from '../controlsContainer'; diff --git a/apps/main-app/src/components/expression/expressionComparisonRibbon.js b/apps/main-app/src/components/expression/expressionComparisonRibbon.js index ba372121e..fd44da75e 100644 --- a/apps/main-app/src/components/expression/expressionComparisonRibbon.js +++ b/apps/main-app/src/components/expression/expressionComparisonRibbon.js @@ -2,7 +2,7 @@ import React, { useRef, useState } from 'react'; import PropTypes from 'prop-types'; import { withRouter } from 'react-router-dom'; import ControlsContainer from '../controlsContainer'; -import { STRINGENCY_HIGH } from '../orthology/constants'; +import { STRINGENCY_HIGH } from '../homology/constants'; import ExpressionAnnotationTable from './expressionAnnotationTable'; import HorizontalScroll from '../horizontalScroll'; import HelpPopup from '../helpPopup'; diff --git a/apps/main-app/src/components/geneOntologyRibbon/index.js b/apps/main-app/src/components/geneOntologyRibbon/index.js index b6c7871fb..2367e6118 100644 --- a/apps/main-app/src/components/geneOntologyRibbon/index.js +++ b/apps/main-app/src/components/geneOntologyRibbon/index.js @@ -2,7 +2,7 @@ import React, { Component } from 'react'; import PropTypes from 'prop-types'; import HorizontalScroll from '../horizontalScroll'; -import { STRINGENCY_HIGH } from '../orthology/constants'; +import { STRINGENCY_HIGH } from '../homology/constants'; import HelpPopup from '../helpPopup'; import GoControlsHelp from './goControlsHelp'; import ControlsContainer from '../controlsContainer'; diff --git a/apps/main-app/src/components/orthology/booleanCell.js b/apps/main-app/src/components/homology/booleanCell.js similarity index 94% rename from apps/main-app/src/components/orthology/booleanCell.js rename to apps/main-app/src/components/homology/booleanCell.js index cd54faa9e..7fdb83cb8 100644 --- a/apps/main-app/src/components/orthology/booleanCell.js +++ b/apps/main-app/src/components/homology/booleanCell.js @@ -1,6 +1,4 @@ -import React from 'react'; import PropTypes from 'prop-types'; - import style from './style.scss'; const BooleanCell = ({value, isTrueFunc, render}) => { diff --git a/apps/main-app/src/components/orthology/constants.js b/apps/main-app/src/components/homology/constants.js similarity index 100% rename from apps/main-app/src/components/orthology/constants.js rename to apps/main-app/src/components/homology/constants.js diff --git a/apps/main-app/src/components/orthology/orthologyFilterHelp.js b/apps/main-app/src/components/homology/homologyFilterHelp.js similarity index 61% rename from apps/main-app/src/components/orthology/orthologyFilterHelp.js rename to apps/main-app/src/components/homology/homologyFilterHelp.js index 5f5a70ced..2fb056b3f 100644 --- a/apps/main-app/src/components/orthology/orthologyFilterHelp.js +++ b/apps/main-app/src/components/homology/homologyFilterHelp.js @@ -1,7 +1,8 @@ -import React from 'react'; -const OrthologyFilterHelp = () => ( -
+function HomologyFilterHelp({ortholog}) { + let HOMOLOG = ortholog ? 'ortholog' : 'paralog'; + let DETERMINER = ortholog ? 'An' : 'A'; + return

There are three precomputed stringency options, described below. Note that not all the included methods have been applied to all the species @@ -11,25 +12,25 @@ const OrthologyFilterHelp = () => (

1) Stringent (default)
- Primary criterion: An ortholog called by 3 or more methods is included + Primary criterion: {DETERMINER} {HOMOLOG} called by 3 or more methods is included if it is a best count OR a best reverse count.
- Secondary criteria: An ortholog predicted by ZFIN, HGNC, or Xenbase is always - included, regardless of count. An ortholog called by 2 methods is + Secondary criteria: {DETERMINER} {HOMOLOG} predicted by ZFIN, HGNC, or Xenbase is always + included, regardless of count. {DETERMINER} {HOMOLOG} called by 2 methods is included if it is both a best count AND a best reverse count.

2) Moderate
- Primary criterion: An ortholog called by 3 or more methods is included + Primary criterion: {DETERMINER} {HOMOLOG} called by 3 or more methods is included (regardless of best or best reverse status).
- Secondary criteria (no change): An ortholog predicted by ZFIN or HGNC is - always included, regardless of count. An ortholog called by 2 methods is + Secondary criteria (no change): {DETERMINER} {HOMOLOG} predicted by ZFIN or HGNC is + always included, regardless of count. {DETERMINER} {HOMOLOG} called by 2 methods is included it is both a best count AND a best reverse count.

3) No filter
- All orthologs are included. + All {HOMOLOG}s are included.

@@ -45,6 +46,6 @@ const OrthologyFilterHelp = () => ( the "Reset filters" button must be used.

-); +} -export default OrthologyFilterHelp; +export default HomologyFilterHelp; diff --git a/apps/main-app/src/components/orthology/orthologyUserGuide.js b/apps/main-app/src/components/homology/homologyUserGuide.js similarity index 94% rename from apps/main-app/src/components/orthology/orthologyUserGuide.js rename to apps/main-app/src/components/homology/homologyUserGuide.js index 49c410612..4fa509d75 100644 --- a/apps/main-app/src/components/orthology/orthologyUserGuide.js +++ b/apps/main-app/src/components/homology/homologyUserGuide.js @@ -1,7 +1,6 @@ -import React from 'react'; import ExternalLink from '../ExternalLink'; -const OrthologyUserGuide = () => ( +const HomologyUserGuide = () => (

Many aspects of data integration presented at the Alliance require a @@ -33,4 +32,4 @@ const OrthologyUserGuide = () => (

); -export default OrthologyUserGuide; +export default HomologyUserGuide; diff --git a/apps/main-app/src/components/orthology/methodCell.js b/apps/main-app/src/components/homology/methodCell.js similarity index 98% rename from apps/main-app/src/components/orthology/methodCell.js rename to apps/main-app/src/components/homology/methodCell.js index a46e7e471..fb979287a 100644 --- a/apps/main-app/src/components/orthology/methodCell.js +++ b/apps/main-app/src/components/homology/methodCell.js @@ -1,4 +1,3 @@ -import React from 'react'; import PropTypes from 'prop-types'; import { UncontrolledTooltip } from 'reactstrap'; import { ALL_METHODS, methodCellStyle } from './constants'; diff --git a/apps/main-app/src/components/orthology/methodHeader.js b/apps/main-app/src/components/homology/methodHeader.js similarity index 94% rename from apps/main-app/src/components/orthology/methodHeader.js rename to apps/main-app/src/components/homology/methodHeader.js index 8ef8ed301..4981fdfb2 100644 --- a/apps/main-app/src/components/orthology/methodHeader.js +++ b/apps/main-app/src/components/homology/methodHeader.js @@ -1,4 +1,3 @@ -import React from 'react'; import PropTypes from 'prop-types'; import MethodLogo from './methodLogo'; import { ALL_METHODS, methodHeaderStyle } from './constants'; diff --git a/apps/main-app/src/components/orthology/methodLogo.js b/apps/main-app/src/components/homology/methodLogo.js similarity index 96% rename from apps/main-app/src/components/orthology/methodLogo.js rename to apps/main-app/src/components/homology/methodLogo.js index 48a414bbf..32cd5e4cb 100644 --- a/apps/main-app/src/components/orthology/methodLogo.js +++ b/apps/main-app/src/components/homology/methodLogo.js @@ -1,4 +1,3 @@ -import React from 'react'; import PropTypes from 'prop-types'; import { UncontrolledTooltip } from 'reactstrap'; import { ALL_METHODS, methodHeaderCellStyle } from './constants'; diff --git a/apps/main-app/src/components/orthology/stringencySelection.js b/apps/main-app/src/components/homology/stringencySelection.js similarity index 100% rename from apps/main-app/src/components/orthology/stringencySelection.js rename to apps/main-app/src/components/homology/stringencySelection.js diff --git a/apps/main-app/src/components/orthology/style.scss b/apps/main-app/src/components/homology/style.scss similarity index 100% rename from apps/main-app/src/components/orthology/style.scss rename to apps/main-app/src/components/homology/style.scss diff --git a/apps/main-app/src/components/orthology/utils.js b/apps/main-app/src/components/homology/utils.js similarity index 100% rename from apps/main-app/src/components/orthology/utils.js rename to apps/main-app/src/components/homology/utils.js diff --git a/apps/main-app/src/components/orthology/index.js b/apps/main-app/src/components/orthology/index.js index 5712012bb..52e834d71 100644 --- a/apps/main-app/src/components/orthology/index.js +++ b/apps/main-app/src/components/orthology/index.js @@ -1,15 +1,15 @@ import OrthologyTable from './orthologyTable'; import OrthologyFilteredTable from './orthologyFilteredTable'; -import OrthologyUserGuide from './orthologyUserGuide'; +import HomologyUserGuide from '../homology/homologyUserGuide'; import OrthologyBasicInfo from './orthologyBasicInfo'; -import StringencySelection from './stringencySelection'; +import StringencySelection from '../homology/stringencySelection'; export { OrthologyBasicInfo, OrthologyTable, OrthologyFilteredTable, - OrthologyUserGuide, + HomologyUserGuide, StringencySelection, }; -export * from './utils'; +export * from '../homology/utils'; diff --git a/apps/main-app/src/components/orthology/orthologyBasicInfo.js b/apps/main-app/src/components/orthology/orthologyBasicInfo.js index 3f91762ab..9f4601959 100644 --- a/apps/main-app/src/components/orthology/orthologyBasicInfo.js +++ b/apps/main-app/src/components/orthology/orthologyBasicInfo.js @@ -1,4 +1,4 @@ -import React, { Component } from 'react'; +import { Component } from 'react'; import PropTypes from 'prop-types'; import { AttributeList, diff --git a/apps/main-app/src/components/orthology/orthologyFilteredTable.js b/apps/main-app/src/components/orthology/orthologyFilteredTable.js index 111df8586..54d5bd692 100644 --- a/apps/main-app/src/components/orthology/orthologyFilteredTable.js +++ b/apps/main-app/src/components/orthology/orthologyFilteredTable.js @@ -1,20 +1,20 @@ -import React, { useState } from 'react'; +import { useState } from 'react'; import PropTypes from 'prop-types'; import { Collapse } from 'reactstrap'; -import StringencySelection from './stringencySelection'; +import StringencySelection from '../homology/stringencySelection'; import OrthologyTable, { isBest } from './orthologyTable'; -import { getOrthologSpeciesName } from './utils'; +import { getOrthologSpeciesName } from '../homology/utils'; import HorizontalScroll from '../horizontalScroll'; import LoadingSpinner from '../loadingSpinner'; import NoData from '../noData'; import ControlsContainer from '../controlsContainer'; -import { STRINGENCY_HIGH } from './constants'; +import { STRINGENCY_HIGH } from '../homology/constants'; import { compareAlphabeticalCaseInsensitive, orthologyMeetsStringency } from '../../lib/utils'; import HelpPopup from '../helpPopup'; -import OrthologyFilterHelp from './orthologyFilterHelp'; +import HomologyFilterHelp from '../homology/homologyFilterHelp'; import useResettableState from '../../hooks/useResettableState'; import useGeneOrthology from '../../hooks/useGeneOrthology'; @@ -115,7 +115,7 @@ const OrthologyFilteredTable = ({geneId}) => { - + { { filteredData.length > 0 ? - + : No ortholog matching your filter. Please try a less stringent filter. } diff --git a/apps/main-app/src/components/orthology/orthologyTable.js b/apps/main-app/src/components/orthology/orthologyTable.js index 8022f4637..c0cf6a9b8 100644 --- a/apps/main-app/src/components/orthology/orthologyTable.js +++ b/apps/main-app/src/components/orthology/orthologyTable.js @@ -1,20 +1,20 @@ -import React, { Component } from 'react'; +import { Component } from 'react'; import PropTypes from 'prop-types'; import { Link } from 'react-router-dom'; -import MethodHeader from './methodHeader'; -import MethodCell from './methodCell'; -import BooleanCell from './booleanCell'; +import MethodHeader from '../homology/methodHeader'; +import MethodCell from '../homology/methodCell'; +import BooleanCell from '../homology/booleanCell'; import { getOrthologSpeciesId, getOrthologSpeciesName, getOrthologId, getOrthologSymbol, -} from './utils'; +} from '../homology/utils'; import { sortBy, compareByFixedOrder } from '../../lib/utils'; import { TAXON_ORDER } from '../../constants'; import HelpPopup from '../helpPopup'; -import style from './style.scss'; +import style from '../homology/style.scss'; import SpeciesName from '../SpeciesName'; const columns = [ diff --git a/apps/main-app/src/components/paralogy/paralogyFilteredTable.js b/apps/main-app/src/components/paralogy/paralogyFilteredTable.js index 59fe5a150..8b9122d93 100644 --- a/apps/main-app/src/components/paralogy/paralogyFilteredTable.js +++ b/apps/main-app/src/components/paralogy/paralogyFilteredTable.js @@ -1,20 +1,20 @@ import { useState } from 'react'; import PropTypes from 'prop-types'; import { Collapse } from 'reactstrap'; -import StringencySelection from '../orthology/stringencySelection'; +import StringencySelection from '../homology/stringencySelection'; import { isBest } from '../orthology/orthologyTable'; -import { getOrthologSpeciesName } from '../orthology/utils'; +import { getOrthologSpeciesName } from '../homology/utils'; import HorizontalScroll from '../horizontalScroll'; import LoadingSpinner from '../loadingSpinner'; import NoData from '../noData'; import ControlsContainer from '../controlsContainer'; -import { STRINGENCY_HIGH } from '../orthology/constants'; +import { STRINGENCY_HIGH } from '../homology/constants'; import { compareAlphabeticalCaseInsensitive, orthologyMeetsStringency } from '../../lib/utils'; import HelpPopup from '../helpPopup'; -import OrthologyFilterHelp from '../orthology/orthologyFilterHelp'; +import HomologyFilterHelp from '../homology/homologyFilterHelp'; import useResettableState from '../../hooks/useResettableState'; import useGeneParalogy from '../../hooks/useGeneParalogy'; import ParalogyTable from './paralogyTable'; @@ -116,7 +116,7 @@ const ParalogyFilteredTable = ({geneId}) => { - + { - } title={ORTHOLOGY}> + } title={ORTHOLOGY}> diff --git a/apps/main-app/src/lib/utils.js b/apps/main-app/src/lib/utils.js index 4b6fa1592..874c7bcad 100644 --- a/apps/main-app/src/lib/utils.js +++ b/apps/main-app/src/lib/utils.js @@ -1,4 +1,4 @@ -import { STRINGENCY_HIGH, STRINGENCY_MED } from '../components/orthology/constants'; +import { STRINGENCY_HIGH, STRINGENCY_MED } from '../components/homology/constants'; import { DEFAULT_TABLE_STATE, SPECIES } from '../constants'; import { stringify } from 'qs'; From 099cba388ee99208f84d7d0cfd873c0754db30b0 Mon Sep 17 00:00:00 2001 From: Christian Pich Date: Thu, 20 Jul 2023 13:09:20 +0200 Subject: [PATCH 34/85] SCRUM-2824 make disease qualifier column a list of options --- .../main-app/src/components/disease/diseaseAnnotationTable.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/main-app/src/components/disease/diseaseAnnotationTable.js b/apps/main-app/src/components/disease/diseaseAnnotationTable.js index 5ea3fbb4d..667d8992b 100644 --- a/apps/main-app/src/components/disease/diseaseAnnotationTable.js +++ b/apps/main-app/src/components/disease/diseaseAnnotationTable.js @@ -94,9 +94,9 @@ const DiseaseAnnotationTable = ({ headerStyle: {width: '120px'}, }, { - dataField: 'diseaseQualifier', + dataField: 'diseaseQualifiers', text: 'Disease Qualifier', - filterable: true, + filterable: getDistinctFieldValue(resolvedData, 'diseaseQualifiers'), headerStyle: {width: '100px'}, formatter: diseaseQualifiers => , filterName: 'diseaseQualifier', From c0ff6aaf1e7069f7c4f438d3fa28bdd6d00d24df Mon Sep 17 00:00:00 2001 From: Adam Gibson Date: Thu, 20 Jul 2023 16:00:13 -0500 Subject: [PATCH 35/85] SCRUM-2806 added update-on-subject-change=false to wc-ribbon-strips --- apps/main-app/src/components/geneOntologyRibbon/index.js | 1 + 1 file changed, 1 insertion(+) diff --git a/apps/main-app/src/components/geneOntologyRibbon/index.js b/apps/main-app/src/components/geneOntologyRibbon/index.js index 2367e6118..354daf692 100644 --- a/apps/main-app/src/components/geneOntologyRibbon/index.js +++ b/apps/main-app/src/components/geneOntologyRibbon/index.js @@ -459,6 +459,7 @@ class GeneOntologyRibbon extends Component { subject-base-url='/gene/' subject-open-new-tab={false} subject-position={compareOrthologs ? '1' : '0'} + update-on-subject-change={false} />
{applyingFilters && }
From 01d47baec3bd31cf419097a5310fecb36dc704ee Mon Sep 17 00:00:00 2001 From: Scott Cain Date: Thu, 3 Aug 2023 09:35:34 -0700 Subject: [PATCH 36/85] adding url info for the sequence panel --- apps/main-app/src/constants.js | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/apps/main-app/src/constants.js b/apps/main-app/src/constants.js index 78ade8672..4c307ec68 100644 --- a/apps/main-app/src/constants.js +++ b/apps/main-app/src/constants.js @@ -248,6 +248,9 @@ export const SPECIES = [ apolloName: 'human', apolloTrack: '/All%20Genes/', jBrowseName: 'Homo sapiens', + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/human/', + jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', + jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000001405.40_GRCh38.p14_genomic.fna.gz', vertebrate: true, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -259,6 +262,9 @@ export const SPECIES = [ apolloName: 'mouse', apolloTrack: '/All%20Genes/', jBrowseName: 'Mus musculus', + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/MGI/mouse/', + jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', + jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000001635.27_GRCm39_genomic.fna.gz', vertebrate: true, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -270,6 +276,9 @@ export const SPECIES = [ apolloName: 'rat', apolloTrack: '/All%20Genes/', jBrowseName: 'Rattus norvegicus', + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/RGD/rat/', + jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', + jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_015227675.2_mRatBN7.2_genomic.fna.gz', vertebrate: true, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -281,6 +290,9 @@ export const SPECIES = [ apolloName: 'x_laevis', apolloTrack: '/All%20Genes/', jBrowseName: 'Xenopus laevis', + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/XenBase/x_laevis/', + jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', + jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/XENLA_9.2_genome.fa.gz', vertebrate: true, enableSingleCellExpressionAtlasLink: false, enableOrthologComparison: true, @@ -292,6 +304,9 @@ export const SPECIES = [ apolloName: 'x_tropicalis', apolloTrack: '/All%20Genes/', jBrowseName: 'Xenopus tropicalis', + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/XenBase/x_tropicalis/', + jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', + jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/XENTR_9.1_genome.fa.gz', vertebrate: true, enableSingleCellExpressionAtlasLink: false, enableOrthologComparison: true, @@ -303,6 +318,9 @@ export const SPECIES = [ apolloName: 'zebrafish', apolloTrack: '/All%20Genes/', jBrowseName: 'Danio rerio', + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/zfin/zebrafish-11/', + jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', + jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000002035.6_GRCz11_genomic.fna.gz', vertebrate: true, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -314,6 +332,9 @@ export const SPECIES = [ apolloName: 'fly', apolloTrack: '/All%20Genes/', jBrowseName: 'Drosophila melanogaster', + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/FlyBase/fruitfly/', + jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', + jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000001215.4_Release_6_plus_ISO1_MT_genomic.fna.gz', vertebrate: false, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -325,6 +346,9 @@ export const SPECIES = [ apolloName: 'worm', apolloTrack: '/All%20Genes/', jBrowseName: 'Caenorhabditis elegans', + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/WormBase/c_elegans_PRJNA13758/', + jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', + jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000002985.6_WBcel235_genomic.fna.gz', vertebrate: false, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, @@ -336,6 +360,9 @@ export const SPECIES = [ apolloName: 'yeast', apolloTrack: '/All%20Genes/', jBrowseName: 'Saccharomyces cerevisiae', + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/SGD/yeast/', + jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', + jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000146045.2_R64_genomic.fna.gz', vertebrate: false, enableSingleCellExpressionAtlasLink: true, enableOrthologComparison: true, From cbb408c756c47c14e7a8167a0a4927834d8f489e Mon Sep 17 00:00:00 2001 From: Scott Cain Date: Thu, 3 Aug 2023 09:51:58 -0700 Subject: [PATCH 37/85] adding the sequence panel --- .../main-app/src/containers/genePage/index.js | 13 +++++ .../genePage/sequencePanelWrapper.js | 48 +++++++++++++++++++ package.json | 2 + 3 files changed, 63 insertions(+) create mode 100644 apps/main-app/src/containers/genePage/sequencePanelWrapper.js diff --git a/apps/main-app/src/containers/genePage/index.js b/apps/main-app/src/containers/genePage/index.js index cf6633e72..afc2b59ad 100644 --- a/apps/main-app/src/containers/genePage/index.js +++ b/apps/main-app/src/containers/genePage/index.js @@ -20,6 +20,7 @@ import { InteractionUserGuide } from '../../components/interaction'; import GenomeFeatureWrapper from './genomeFeatureWrapper'; +import SequencePanel from './sequencePanelWrapper'; import ExpressionLinks from './expressionLinks'; import SpeciesIcon from '../../components/speciesIcon'; @@ -43,6 +44,7 @@ import SpeciesName from '../../components/SpeciesName'; const SUMMARY = 'Summary'; const SEQUENCE_FEATURE_VIEWER = 'Sequence Feature Viewer'; +const SEQUENCE_PANEL = 'Sequence Panel'; const FUNCTION = 'Function - GO Annotations'; const PATHWAY = 'Pathways'; const ORTHOLOGY = 'Orthology'; @@ -68,6 +70,7 @@ const SECTIONS = [ {name: TG_ALLELES}, {name: MODELS}, {name: SEQUENCE_FEATURE_VIEWER}, + {name: SEQUENCE_PANEL}, {name: EXPRESSION}, {name: INTERACTIONS}, {name: GENETIC_INTERACTIONS}, @@ -202,6 +205,16 @@ const GenePage = ({geneId}) => { /> + + + + } title={EXPRESSION}> + ); + } +} + +SequencePanel.propTypes = { + species: PropTypes.string, + refseq: PropTypes.string, + start: PropTypes.number, + end: PropTypes.number, + gene: PropTypes.string, + jBrowsenclistbaseurl: PropTypes.string, + jBrowseurltemplate: PropTypes.string, + jBrowsefastaurl: PropTypes.string +}; + +export default SequencePanel; diff --git a/package.json b/package.json index d97a636da..5fe3415b0 100644 --- a/package.json +++ b/package.json @@ -46,6 +46,7 @@ "custom-event-polyfill": "^1.0.6", "d3-selection": "2.0.0", "document-register-element": "1.13.1", + "generic-sequence-panel": "^1.1.0", "html-react-parser": "^0.10.0", "immutable": "^3.8.1", "js-yaml": "^4.1.0", @@ -126,6 +127,7 @@ "babel-jest": "26.2.2", "babel-loader": "8.1.0", "babel-plugin-macros": "3.0.1", + "buffer": "^6.0.3", "cypress": "^6.0.1", "dotenv": "10.0.0", "eslint": "7.10.0", From d2b03cf269104aa6586446e07916af97b8458699 Mon Sep 17 00:00:00 2001 From: Adam Gibson Date: Thu, 3 Aug 2023 12:41:58 -0500 Subject: [PATCH 38/85] SCRUM-2372 default to mod homepage when no crossReference --- .../AnnotatedEntitiesPopupCuration.js | 8 ++++-- .../components/dataTable/AnnotationSource.js | 1 + .../dataTable/ProvidersCellCuration.js | 10 +++++-- .../src/components/dataTable/utils.js | 26 +++++++++++++++++++ .../disease/diseaseAnnotationTable.js | 12 ++------- 5 files changed, 43 insertions(+), 14 deletions(-) diff --git a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js index 8cb5d17cf..5aa1fd229 100644 --- a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js +++ b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js @@ -1,4 +1,4 @@ -import React from 'react'; +import React, { useState } from 'react'; import PropTypes from 'prop-types'; import { DropdownMenu, @@ -21,6 +21,8 @@ import AnnotationSource from './AnnotationSource'; import GeneticSex from './GeneticSex'; import AnnotationType from './AnnotationType'; import GeneticModifiersCellCuration from './GeneticModifiersCellCuration'; +import ProvidersCellCuration from './ProvidersCellCuration'; +import { buildProviders } from './utils'; function renderLink(entity) { const url = getResourceUrl(entity.subject.curie, entity.subject.type, entity.subject.subtype) @@ -41,6 +43,8 @@ function renderLink(entity) { function AnnotatedEntitiesPopupCuration(props) { const {children, entities, mainRowCurie} = props; + //initialize state only once instead of every render + const [providers] = useState(() => buildProviders(entities)); if (!entities || !entities.length) { return null; @@ -92,7 +96,7 @@ function AnnotatedEntitiesPopupCuration(props) { - + )) diff --git a/apps/main-app/src/components/dataTable/AnnotationSource.js b/apps/main-app/src/components/dataTable/AnnotationSource.js index 5d95d9e7a..19f25beed 100644 --- a/apps/main-app/src/components/dataTable/AnnotationSource.js +++ b/apps/main-app/src/components/dataTable/AnnotationSource.js @@ -1,4 +1,5 @@ function AnnotationSource({dataProvider}) { + console.log(dataProvider); if(dataProvider) { return <>{dataProvider.abbreviation}; } diff --git a/apps/main-app/src/components/dataTable/ProvidersCellCuration.js b/apps/main-app/src/components/dataTable/ProvidersCellCuration.js index 882dbbdc3..deb42b12f 100644 --- a/apps/main-app/src/components/dataTable/ProvidersCellCuration.js +++ b/apps/main-app/src/components/dataTable/ProvidersCellCuration.js @@ -1,4 +1,6 @@ import CommaSeparatedList from '../commaSeparatedList'; +import { buildSourceUrl } from './utils'; +import ExternalLink from '../ExternalLink'; const removeDuplicates = (providers) => { const newArray = providers.map((provider) => [provider.dataProvider.abbreviation, provider]); @@ -10,17 +12,21 @@ const removeDuplicates = (providers) => { } const ProvidersCellCuration = ({ providers }) => { + if(!providers) return null; + const uniqueProviders = removeDuplicates(providers); + const url = buildSourceUrl(providers[0].dataProvider); + return ( { uniqueProviders.map(provider => { const { dataProvider, secondaryDataProvider } = provider; - return ( - {dataProvider.abbreviation} + {/* todo: better key and title */} + {dataProvider?.sourceOrganization?.abbreviation}; { secondaryDataProvider && <> diff --git a/apps/main-app/src/components/dataTable/utils.js b/apps/main-app/src/components/dataTable/utils.js index d5c6031b3..cfa0c1a2c 100644 --- a/apps/main-app/src/components/dataTable/utils.js +++ b/apps/main-app/src/components/dataTable/utils.js @@ -79,6 +79,31 @@ export const getMultipleReferencesCuriesAndUrls = (references) => { return references.map((reference) => getSingleReferenceCurieAndUrl(reference)); } +export const buildProviders = (annotations) => { + if(!annotations) return; + return annotations.map(annotation => { + return { + dataProvider: annotation.dataProvider, + secondaryDataProvider: annotation.secondaryDataProvider + } + }); +} + +export const buildSourceUrl = (dataProvider) => { + if(!dataProvider) return; + let url; + + //default to mod homepage if no crossReferene is provided + if(!dataProvider.crossReference){ + url = dataProvider.sourceOrganization?.homepageResourceDescriptorPage?.urlTemplate; + } else { + const urlTemplate = dataProvider.crossReference?.resourceDescriptorPage.urlTemplate; + const referenceCurie = dataProvider.crossReference?.referencedCurie; + url = urlTemplate?.replace("[%s]", `${referenceCurie}`) + } + return url; +} + // TODO: remove when the data is fixed on the backend // see https://agr-jira.atlassian.net/browse/SCRUM-2649 export function simplifySpeciesNameSC(speciesName) { @@ -87,4 +112,5 @@ export function simplifySpeciesNameSC(speciesName) { return SC; else return speciesName; + } \ No newline at end of file diff --git a/apps/main-app/src/components/disease/diseaseAnnotationTable.js b/apps/main-app/src/components/disease/diseaseAnnotationTable.js index 667d8992b..035f332f8 100644 --- a/apps/main-app/src/components/disease/diseaseAnnotationTable.js +++ b/apps/main-app/src/components/disease/diseaseAnnotationTable.js @@ -9,7 +9,7 @@ import { SpeciesCell, } from '../dataTable'; import AnnotatedEntitiesPopupCuration from '../dataTable/AnnotatedEntitiesPopupCuration'; -import {getDistinctFieldValue,simplifySpeciesNameSC} from '../dataTable/utils'; +import { getDistinctFieldValue, simplifySpeciesNameSC, buildProviders } from '../dataTable/utils'; import {compareByFixedOrder} from '../../lib/utils'; import {SPECIES_NAME_ORDER} from '../../constants'; import ProvidersCellCuration from '../dataTable/ProvidersCellCuration'; @@ -41,14 +41,6 @@ const DiseaseAnnotationTable = ({ ...tableProps } = useComparisonRibbonTableQuery('/api/disease', focusGeneId, orthologGenes, term, params); - const buildProviders = (annotation) => { - return annotation.primaryAnnotations.map(primaryAnnotation => { - return { - dataProvider: primaryAnnotation.dataProvider, - secondaryDataProvider: primaryAnnotation.secondaryDataProvider - } - }); - } const buildWith = (annotation) => { const filteredPrimaryAnnotations = annotation.primaryAnnotations.filter(primaryAnnotation => primaryAnnotation.with); @@ -144,7 +136,7 @@ const DiseaseAnnotationTable = ({ const data = results.map(annotation => ({ species: annotation.subject.taxon, - providers: buildProviders(annotation), + providers: buildProviders(annotation.primaryAnnotations), basedOn: buildWith(annotation), ...annotation, })); From 8035cadbfbd9639451655420f4db13583503ee16 Mon Sep 17 00:00:00 2001 From: Adam Gibson Date: Fri, 4 Aug 2023 12:37:04 -0500 Subject: [PATCH 39/85] SCRUM-2372 added ProviderCellCuration --- .../dataTable/ProviderCellCuration.js | 26 +++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 apps/main-app/src/components/dataTable/ProviderCellCuration.js diff --git a/apps/main-app/src/components/dataTable/ProviderCellCuration.js b/apps/main-app/src/components/dataTable/ProviderCellCuration.js new file mode 100644 index 000000000..dd88c8b05 --- /dev/null +++ b/apps/main-app/src/components/dataTable/ProviderCellCuration.js @@ -0,0 +1,26 @@ +import ExternalLink from "../ExternalLink"; + +function ProviderCellCuration({ provider }) { + if(!provider) return null; + + const { dataProvider, secondaryDataProvider } = provider; + + return ( + + + {dataProvider.abbreviation} + + { + secondaryDataProvider && + <> + via + + {secondaryDataProvider.abbreviation} + + + } + + ) +} + +export default ProviderCellCuration; From d237def179d99372bc2baa90c09b30872bd9ad11 Mon Sep 17 00:00:00 2001 From: Adam Gibson Date: Fri, 4 Aug 2023 12:37:48 -0500 Subject: [PATCH 40/85] SCRUM-2372 refactored ProvidersCellCuration --- .../dataTable/ProvidersCellCuration.js | 23 ++++--------------- 1 file changed, 4 insertions(+), 19 deletions(-) diff --git a/apps/main-app/src/components/dataTable/ProvidersCellCuration.js b/apps/main-app/src/components/dataTable/ProvidersCellCuration.js index deb42b12f..6c84ad8a5 100644 --- a/apps/main-app/src/components/dataTable/ProvidersCellCuration.js +++ b/apps/main-app/src/components/dataTable/ProvidersCellCuration.js @@ -1,6 +1,7 @@ import CommaSeparatedList from '../commaSeparatedList'; -import { buildSourceUrl } from './utils'; +import { buildProvidersWithUrl } from './utils'; import ExternalLink from '../ExternalLink'; +import ProviderCellCuration from './ProviderCellCuration'; const removeDuplicates = (providers) => { const newArray = providers.map((provider) => [provider.dataProvider.abbreviation, provider]); @@ -15,28 +16,12 @@ const ProvidersCellCuration = ({ providers }) => { if(!providers) return null; const uniqueProviders = removeDuplicates(providers); - const url = buildSourceUrl(providers[0].dataProvider); - return ( { - uniqueProviders.map(provider => { - const { dataProvider, secondaryDataProvider } = provider; - return ( - - {/* todo: better key and title */} - {dataProvider?.sourceOrganization?.abbreviation}; - { - secondaryDataProvider && - <> - via - {secondaryDataProvider.abbreviation} - - } - - ) - + uniqueProviders?.map(provider => { + return }) } From 26e487628e9125bd49ba825c20e2e4d880e26339 Mon Sep 17 00:00:00 2001 From: Adam Gibson Date: Fri, 4 Aug 2023 12:38:32 -0500 Subject: [PATCH 41/85] SCRUM-2372 refactored utils methods --- .../AnnotatedEntitiesPopupCuration.js | 44 +++++++-------- .../components/dataTable/AnnotationSource.js | 9 ---- .../src/components/dataTable/utils.js | 54 ++++++++++++++++--- .../disease/diseaseAnnotationTable.js | 4 +- 4 files changed, 72 insertions(+), 39 deletions(-) delete mode 100644 apps/main-app/src/components/dataTable/AnnotationSource.js diff --git a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js index 5aa1fd229..d2692a633 100644 --- a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js +++ b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js @@ -17,12 +17,11 @@ import StrainBackground from './StrainBackground'; import AssertedGenes from './AssertedGenes'; import RelatedNotes from './RelatedNotes'; import EvidenceCodesCellCuration from './evidenceCodesCellCuration'; -import AnnotationSource from './AnnotationSource'; +import ProviderCellCuration from './ProviderCellCuration'; import GeneticSex from './GeneticSex'; import AnnotationType from './AnnotationType'; import GeneticModifiersCellCuration from './GeneticModifiersCellCuration'; -import ProvidersCellCuration from './ProvidersCellCuration'; -import { buildProviders } from './utils'; +import { buildProviderWithUrl } from './utils'; function renderLink(entity) { const url = getResourceUrl(entity.subject.curie, entity.subject.type, entity.subject.subtype) @@ -43,8 +42,6 @@ function renderLink(entity) { function AnnotatedEntitiesPopupCuration(props) { const {children, entities, mainRowCurie} = props; - //initialize state only once instead of every render - const [providers] = useState(() => buildProviders(entities)); if (!entities || !entities.length) { return null; @@ -83,23 +80,26 @@ function AnnotatedEntitiesPopupCuration(props) { { - entities.map(entity => ( - - {renderLink(entity)} - - - - - - - - - - - - - - )) + entities.map(entity => { + const provider = buildProviderWithUrl(entity); + return ( + + {renderLink(entity)} + + + + + + + + + + + + + + ) + }) } diff --git a/apps/main-app/src/components/dataTable/AnnotationSource.js b/apps/main-app/src/components/dataTable/AnnotationSource.js deleted file mode 100644 index 19f25beed..000000000 --- a/apps/main-app/src/components/dataTable/AnnotationSource.js +++ /dev/null @@ -1,9 +0,0 @@ -function AnnotationSource({dataProvider}) { - console.log(dataProvider); - if(dataProvider) { - return <>{dataProvider.abbreviation}; - } - return <>; -} - -export default AnnotationSource; diff --git a/apps/main-app/src/components/dataTable/utils.js b/apps/main-app/src/components/dataTable/utils.js index cfa0c1a2c..0825cb9bd 100644 --- a/apps/main-app/src/components/dataTable/utils.js +++ b/apps/main-app/src/components/dataTable/utils.js @@ -79,23 +79,64 @@ export const getMultipleReferencesCuriesAndUrls = (references) => { return references.map((reference) => getSingleReferenceCurieAndUrl(reference)); } +const buildProvider = (annotation) => { + if(!annotation) return; + return { + dataProvider: annotation.dataProvider, + secondaryDataProvider: annotation.secondaryDataProvider + } +} + export const buildProviders = (annotations) => { if(!annotations) return; return annotations.map(annotation => { + return buildProvider(annotation); + }); +} + +export const buildProviderWithUrl = (annotation) => { + + const { dataProvider, secondaryDataProvider } = buildProvider(annotation); + + if(secondaryDataProvider){ return { - dataProvider: annotation.dataProvider, - secondaryDataProvider: annotation.secondaryDataProvider + dataProvider: { + id: dataProvider.id, + abbreviation: dataProvider.sourceOrganization?.abbreviation, + url: buildSourceUrl(dataProvider) + }, + secondaryDataProvider: { + id: secondaryDataProvider.id, + abbreviation: secondaryDataProvider.sourceOrganization?.abbreviation, + url: buildSourceUrl(secondaryDataProvider) + }, } - }); + } else { + return { + dataProvider: { + id: dataProvider.id, + abbreviation: dataProvider.sourceOrganization?.abbreviation, + url: buildSourceUrl(dataProvider) + }, + } + } +} + +export const buildProvidersWithUrl = (annotations) => { + if(!annotations) return; + + return annotations.map((annotation) => { + return buildProviderWithUrl(annotation) + }) } export const buildSourceUrl = (dataProvider) => { if(!dataProvider) return; let url; - //default to mod homepage if no crossReferene is provided + //default to mod homepage if no crossReference is provided if(!dataProvider.crossReference){ - url = dataProvider.sourceOrganization?.homepageResourceDescriptorPage?.urlTemplate; + url = dataProvider.sourceOrganization?.homepageResourceDescriptorPage?.urlTemplate?.replace("[%s]", ""); } else { const urlTemplate = dataProvider.crossReference?.resourceDescriptorPage.urlTemplate; const referenceCurie = dataProvider.crossReference?.referencedCurie; @@ -113,4 +154,5 @@ export function simplifySpeciesNameSC(speciesName) { else return speciesName; -} \ No newline at end of file +} + diff --git a/apps/main-app/src/components/disease/diseaseAnnotationTable.js b/apps/main-app/src/components/disease/diseaseAnnotationTable.js index 035f332f8..43f6e63aa 100644 --- a/apps/main-app/src/components/disease/diseaseAnnotationTable.js +++ b/apps/main-app/src/components/disease/diseaseAnnotationTable.js @@ -9,7 +9,7 @@ import { SpeciesCell, } from '../dataTable'; import AnnotatedEntitiesPopupCuration from '../dataTable/AnnotatedEntitiesPopupCuration'; -import { getDistinctFieldValue, simplifySpeciesNameSC, buildProviders } from '../dataTable/utils'; +import { getDistinctFieldValue, buildProvidersWithUrl } from '../dataTable/utils'; import {compareByFixedOrder} from '../../lib/utils'; import {SPECIES_NAME_ORDER} from '../../constants'; import ProvidersCellCuration from '../dataTable/ProvidersCellCuration'; @@ -136,7 +136,7 @@ const DiseaseAnnotationTable = ({ const data = results.map(annotation => ({ species: annotation.subject.taxon, - providers: buildProviders(annotation.primaryAnnotations), + providers: buildProvidersWithUrl(annotation.primaryAnnotations), basedOn: buildWith(annotation), ...annotation, })); From 9e175292bbb21109bac35044272dd5f185636e24 Mon Sep 17 00:00:00 2001 From: Olin Blodgett Date: Thu, 10 Aug 2023 14:31:44 -0400 Subject: [PATCH 42/85] Added focus gene id to query --- apps/main-app/src/hooks/useComparisonRibbonTableQuery.js | 1 + 1 file changed, 1 insertion(+) diff --git a/apps/main-app/src/hooks/useComparisonRibbonTableQuery.js b/apps/main-app/src/hooks/useComparisonRibbonTableQuery.js index e6b7048bf..ef88435e6 100644 --- a/apps/main-app/src/hooks/useComparisonRibbonTableQuery.js +++ b/apps/main-app/src/hooks/useComparisonRibbonTableQuery.js @@ -15,6 +15,7 @@ export default function useComparisonRibbonTableQuery( } const params = { ...additionalQueryParams, + focusGeneId: focusGeneId, geneID: geneIds, }; if (termId && termId !== 'all') { From 14e918c0efa3428689d540deff8ca32374b658d9 Mon Sep 17 00:00:00 2001 From: Olin Blodgett Date: Thu, 10 Aug 2023 14:52:50 -0400 Subject: [PATCH 43/85] Changed to focus taxon id --- apps/main-app/src/components/disease/diseaseAnnotationTable.js | 3 ++- .../main-app/src/components/disease/diseaseComparisonRibbon.js | 1 + .../src/components/expression/expressionAnnotationTable.js | 3 ++- .../src/components/expression/expressionComparisonRibbon.js | 2 +- apps/main-app/src/hooks/useComparisonRibbonTableQuery.js | 3 ++- 5 files changed, 8 insertions(+), 4 deletions(-) diff --git a/apps/main-app/src/components/disease/diseaseAnnotationTable.js b/apps/main-app/src/components/disease/diseaseAnnotationTable.js index 43f6e63aa..a1e0d9929 100644 --- a/apps/main-app/src/components/disease/diseaseAnnotationTable.js +++ b/apps/main-app/src/components/disease/diseaseAnnotationTable.js @@ -26,6 +26,7 @@ import DiseaseQualifiersColumn from "../dataTable/DiseaseQualifiersColumn"; */ const DiseaseAnnotationTable = ({ focusGeneId, + focusTaxonId, includeNotAnnotations, orthologGenes, term, @@ -39,7 +40,7 @@ const DiseaseAnnotationTable = ({ data: results, resolvedData, ...tableProps - } = useComparisonRibbonTableQuery('/api/disease', focusGeneId, orthologGenes, term, params); + } = useComparisonRibbonTableQuery('/api/disease', focusGeneId, focusTaxonId, orthologGenes, term, params); const buildWith = (annotation) => { diff --git a/apps/main-app/src/components/disease/diseaseComparisonRibbon.js b/apps/main-app/src/components/disease/diseaseComparisonRibbon.js index af8488413..f27be8890 100644 --- a/apps/main-app/src/components/disease/diseaseComparisonRibbon.js +++ b/apps/main-app/src/components/disease/diseaseComparisonRibbon.js @@ -127,6 +127,7 @@ const DiseaseComparisonRibbon = ({geneId, geneTaxon, history}) => { {selectedBlock.group &&
{ @@ -28,7 +29,7 @@ const ExpressionAnnotationTable = ({ resolvedData, data: results, ...tableProps - } = useComparisonRibbonTableQuery('/api/expression', focusGeneId, orthologGenes, term); + } = useComparisonRibbonTableQuery('/api/expression', focusGeneId, focusTaxonId, orthologGenes, term); const columns = [ { diff --git a/apps/main-app/src/components/expression/expressionComparisonRibbon.js b/apps/main-app/src/components/expression/expressionComparisonRibbon.js index fd44da75e..85aa48f2a 100644 --- a/apps/main-app/src/components/expression/expressionComparisonRibbon.js +++ b/apps/main-app/src/components/expression/expressionComparisonRibbon.js @@ -116,7 +116,7 @@ const ExpressionComparisonRibbon = ({ {selectedBlock.group &&
- +
} diff --git a/apps/main-app/src/hooks/useComparisonRibbonTableQuery.js b/apps/main-app/src/hooks/useComparisonRibbonTableQuery.js index ef88435e6..0cab1c413 100644 --- a/apps/main-app/src/hooks/useComparisonRibbonTableQuery.js +++ b/apps/main-app/src/hooks/useComparisonRibbonTableQuery.js @@ -5,6 +5,7 @@ import qs from 'qs'; export default function useComparisonRibbonTableQuery( baseUrl, focusGeneId, + focusTaxonId, orthologGenes, termId, additionalQueryParams @@ -15,7 +16,7 @@ export default function useComparisonRibbonTableQuery( } const params = { ...additionalQueryParams, - focusGeneId: focusGeneId, + focusTaxonId: focusTaxonId, geneID: geneIds, }; if (termId && termId !== 'all') { From c32b408e13609eca69bcc5b6e524d7187486f9ee Mon Sep 17 00:00:00 2001 From: Adam Gibson Date: Thu, 10 Aug 2023 15:59:10 -0500 Subject: [PATCH 44/85] SCRUM-2372 add code to split referencedCurie --- .../dataTable/ProvidersCellCuration.js | 2 - .../src/components/dataTable/utils.js | 41 ++++++++++++++----- 2 files changed, 31 insertions(+), 12 deletions(-) diff --git a/apps/main-app/src/components/dataTable/ProvidersCellCuration.js b/apps/main-app/src/components/dataTable/ProvidersCellCuration.js index 6c84ad8a5..01a3f7572 100644 --- a/apps/main-app/src/components/dataTable/ProvidersCellCuration.js +++ b/apps/main-app/src/components/dataTable/ProvidersCellCuration.js @@ -1,6 +1,4 @@ import CommaSeparatedList from '../commaSeparatedList'; -import { buildProvidersWithUrl } from './utils'; -import ExternalLink from '../ExternalLink'; import ProviderCellCuration from './ProviderCellCuration'; const removeDuplicates = (providers) => { diff --git a/apps/main-app/src/components/dataTable/utils.js b/apps/main-app/src/components/dataTable/utils.js index 0825cb9bd..1375a96b7 100644 --- a/apps/main-app/src/components/dataTable/utils.js +++ b/apps/main-app/src/components/dataTable/utils.js @@ -1,6 +1,6 @@ import React from 'react'; -import {compareAlphabeticalCaseInsensitive} from '../../lib/utils'; -import {getResourceUrl, getResourceUrls} from "./getResourceUrl"; +import { compareAlphabeticalCaseInsensitive } from '../../lib/utils'; +import { getResourceUrl } from "./getResourceUrl"; export const renderPaginationShowsTotal = (start, end, total) => { return Showing { start } - { end } of { total.toLocaleString() } rows; @@ -130,18 +130,39 @@ export const buildProvidersWithUrl = (annotations) => { }) } +const getReferencedCurie = (dataProvider) => { + if(!dataProvider) return; + + const abbreviation = dataProvider.sourceOrganization?.abbreviation; + const referencedCurie = dataProvider.crossReference?.referencedCurie; + + const modHasPrefix = { + RGD: true, + FB: true, + WB: true, + ZFIN: true, + OMIM: false, + SGD: false, + MGI: false, + } + + if(modHasPrefix[abbreviation]){ + return referencedCurie; + } else { + return referencedCurie?.split(":")[1]; + } +} + export const buildSourceUrl = (dataProvider) => { if(!dataProvider) return; - let url; //default to mod homepage if no crossReference is provided - if(!dataProvider.crossReference){ - url = dataProvider.sourceOrganization?.homepageResourceDescriptorPage?.urlTemplate?.replace("[%s]", ""); - } else { - const urlTemplate = dataProvider.crossReference?.resourceDescriptorPage.urlTemplate; - const referenceCurie = dataProvider.crossReference?.referencedCurie; - url = urlTemplate?.replace("[%s]", `${referenceCurie}`) - } + if(!dataProvider.crossReference) return dataProvider.sourceOrganization?.homepageResourceDescriptorPage?.urlTemplate?.replace("[%s]", ""); + + const urlTemplate = dataProvider.crossReference?.resourceDescriptorPage?.urlTemplate; + const referencedCurie = getReferencedCurie(dataProvider); + const url = urlTemplate?.replace("[%s]", `${referencedCurie}`) + return url; } From 8ca2e88c7159e0d2743deb3825ca9532c3dd22f0 Mon Sep 17 00:00:00 2001 From: Adam Gibson Date: Fri, 11 Aug 2023 12:11:02 -0500 Subject: [PATCH 45/85] SCRUM-2372 updated curie prefix logic --- .../main-app/src/components/dataTable/utils.js | 18 ++++-------------- 1 file changed, 4 insertions(+), 14 deletions(-) diff --git a/apps/main-app/src/components/dataTable/utils.js b/apps/main-app/src/components/dataTable/utils.js index 1375a96b7..9e8011ef8 100644 --- a/apps/main-app/src/components/dataTable/utils.js +++ b/apps/main-app/src/components/dataTable/utils.js @@ -136,21 +136,11 @@ const getReferencedCurie = (dataProvider) => { const abbreviation = dataProvider.sourceOrganization?.abbreviation; const referencedCurie = dataProvider.crossReference?.referencedCurie; - const modHasPrefix = { - RGD: true, - FB: true, - WB: true, - ZFIN: true, - OMIM: false, - SGD: false, - MGI: false, - } + const modPrefixException = [ "OMIM", "SGD", "MGI", ]; - if(modHasPrefix[abbreviation]){ - return referencedCurie; - } else { - return referencedCurie?.split(":")[1]; - } + if(modPrefixException.includes(abbreviation)) return referencedCurie?.split(":")[1]; + + return referencedCurie; } export const buildSourceUrl = (dataProvider) => { From 170eb08611bafb4b7cbe16568e983274452f3d1a Mon Sep 17 00:00:00 2001 From: Adam Gibson Date: Fri, 11 Aug 2023 10:50:01 -0500 Subject: [PATCH 46/85] SCRUM-3092 added AssociationCellCuration to AnnotatedEntitiesPopupCuration --- .../components/dataTable/AnnotatedEntitiesPopupCuration.js | 3 +++ .../src/components/dataTable/AssociationCellCuration.js | 6 ++++++ apps/main-app/src/components/dataTable/style.scss | 4 ++++ 3 files changed, 13 insertions(+) create mode 100644 apps/main-app/src/components/dataTable/AssociationCellCuration.js diff --git a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js index d2692a633..1557b8c2f 100644 --- a/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js +++ b/apps/main-app/src/components/dataTable/AnnotatedEntitiesPopupCuration.js @@ -20,6 +20,7 @@ import EvidenceCodesCellCuration from './evidenceCodesCellCuration'; import ProviderCellCuration from './ProviderCellCuration'; import GeneticSex from './GeneticSex'; import AnnotationType from './AnnotationType'; +import AssociationCellCuration from './AssociationCellCuration'; import GeneticModifiersCellCuration from './GeneticModifiersCellCuration'; import { buildProviderWithUrl } from './utils'; @@ -65,6 +66,7 @@ function AnnotatedEntitiesPopupCuration(props) { Name Type + Association Additional implicated genes Experimental condition @@ -86,6 +88,7 @@ function AnnotatedEntitiesPopupCuration(props) { {renderLink(entity)} + diff --git a/apps/main-app/src/components/dataTable/AssociationCellCuration.js b/apps/main-app/src/components/dataTable/AssociationCellCuration.js new file mode 100644 index 000000000..3906c3ecc --- /dev/null +++ b/apps/main-app/src/components/dataTable/AssociationCellCuration.js @@ -0,0 +1,6 @@ +function AssociationCellCuration({ association }){ + if(!association) return; + return association.replaceAll('_', ' '); +} + +export default AssociationCellCuration; \ No newline at end of file diff --git a/apps/main-app/src/components/dataTable/style.scss b/apps/main-app/src/components/dataTable/style.scss index efc5a72d0..5f510090b 100644 --- a/apps/main-app/src/components/dataTable/style.scss +++ b/apps/main-app/src/components/dataTable/style.scss @@ -56,4 +56,8 @@ .relatedNotes { min-width: 300px; +} + +.associationCell { + min-width: 150px; } \ No newline at end of file From b7e7bc0f8fa6e9769e7fa074d1b6985a0c5c779e Mon Sep 17 00:00:00 2001 From: Adam Gibson Date: Fri, 18 Aug 2023 09:29:43 -0500 Subject: [PATCH 47/85] SCRUM-3201 remove duplicates from basedOnGeneCellCuration --- .../components/dataTable/ProvidersCellCuration.js | 12 ++---------- .../components/dataTable/basedOnGeneCellCuration.js | 8 +++++--- apps/main-app/src/components/dataTable/utils.js | 10 ++++++++++ 3 files changed, 17 insertions(+), 13 deletions(-) diff --git a/apps/main-app/src/components/dataTable/ProvidersCellCuration.js b/apps/main-app/src/components/dataTable/ProvidersCellCuration.js index 01a3f7572..6aab93143 100644 --- a/apps/main-app/src/components/dataTable/ProvidersCellCuration.js +++ b/apps/main-app/src/components/dataTable/ProvidersCellCuration.js @@ -1,19 +1,11 @@ import CommaSeparatedList from '../commaSeparatedList'; import ProviderCellCuration from './ProviderCellCuration'; - -const removeDuplicates = (providers) => { - const newArray = providers.map((provider) => [provider.dataProvider.abbreviation, provider]); - const newMap = new Map(newArray); - const iterator = newMap.values(); - const uniqueProviders = [...iterator]; - - return uniqueProviders; -} +import { removeDuplicates } from './utils'; const ProvidersCellCuration = ({ providers }) => { if(!providers) return null; - const uniqueProviders = removeDuplicates(providers); + const uniqueProviders = removeDuplicates(providers, (provider) => provider.dataProvider.abbreviation); return ( diff --git a/apps/main-app/src/components/dataTable/basedOnGeneCellCuration.js b/apps/main-app/src/components/dataTable/basedOnGeneCellCuration.js index 8c7b063a1..7b5314997 100644 --- a/apps/main-app/src/components/dataTable/basedOnGeneCellCuration.js +++ b/apps/main-app/src/components/dataTable/basedOnGeneCellCuration.js @@ -1,15 +1,17 @@ import { Link } from 'react-router-dom'; -import { shortSpeciesName} from '../../lib/utils'; +import { shortSpeciesName } from '../../lib/utils'; import { CollapsibleList } from '../../components/collapsibleList'; +import { removeDuplicates } from './utils'; import GeneSymbolCuration from '../GeneSymbolCuration'; const BasedOnGeneCellCuration = (genes) => { if (!genes) { return null; } + const uniqueGenes = removeDuplicates(genes, (gene) => gene.geneSymbol.displayText); return ( - - {genes.map(gene => ( + + {uniqueGenes.map(gene => ( ({shortSpeciesName(gene.taxon.curie)}) diff --git a/apps/main-app/src/components/dataTable/utils.js b/apps/main-app/src/components/dataTable/utils.js index 9e8011ef8..2d88be9ee 100644 --- a/apps/main-app/src/components/dataTable/utils.js +++ b/apps/main-app/src/components/dataTable/utils.js @@ -167,3 +167,13 @@ export function simplifySpeciesNameSC(speciesName) { } +//takes an array of objects and a function that returns the approprate subField and returns a unique set of those objects +export function removeDuplicates(objects, keyFunction){ + const newArray = objects.map((object) => [keyFunction(object), object]); + const newMap = new Map(newArray); + const iterator = newMap.values(); + const uniqueObjects = [...iterator]; + + return uniqueObjects; +} + From c4e4709fd9b9a2215093f7e129b6d7ecd7b827ef Mon Sep 17 00:00:00 2001 From: Scott Cain Date: Mon, 21 Aug 2023 12:52:35 -0700 Subject: [PATCH 48/85] This is part of what's needed for https://agr-jira.atlassian.net/browse/KANBAN-366 still needed is dealing with Name/Symbol confusion for yeast --- .../containers/genePage/sequencePanelWrapper.js | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/apps/main-app/src/containers/genePage/sequencePanelWrapper.js b/apps/main-app/src/containers/genePage/sequencePanelWrapper.js index 7c24f01fc..d1bd8797d 100644 --- a/apps/main-app/src/containers/genePage/sequencePanelWrapper.js +++ b/apps/main-app/src/containers/genePage/sequencePanelWrapper.js @@ -18,11 +18,21 @@ class SequencePanel extends Component { } render() { - console.log(this.props.refseq); + var refseq = this.props.refseq; + if((this.props.species === 'NCBITaxon:559292' || this.props.species === 'NCBITaxon:8355') && !this.props.refseq.startsWith('chr') && !this.props.refseq.toLowerCase().startsWith('scaffold')){ + refseq = 'chr' + refseq; + } + console.log(this.props); + console.log(this.props.gene); console.log(this.jBrowseurltemplate); + console.log(refseq); + console.log(this.props.start); + console.log(this.props.end); + console.log(this.jBrowsenclistbaseurl); + console.log(this.jBrowsefastaurl); return ( Date: Mon, 21 Aug 2023 20:02:11 -0700 Subject: [PATCH 49/85] updating the database path (should try to generalize this) --- apps/main-app/src/constants.js | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/apps/main-app/src/constants.js b/apps/main-app/src/constants.js index 4c307ec68..7c552a539 100644 --- a/apps/main-app/src/constants.js +++ b/apps/main-app/src/constants.js @@ -248,7 +248,7 @@ export const SPECIES = [ apolloName: 'human', apolloTrack: '/All%20Genes/', jBrowseName: 'Homo sapiens', - jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/human/', + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/6.0.0/human/', jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000001405.40_GRCh38.p14_genomic.fna.gz', vertebrate: true, @@ -262,7 +262,7 @@ export const SPECIES = [ apolloName: 'mouse', apolloTrack: '/All%20Genes/', jBrowseName: 'Mus musculus', - jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/MGI/mouse/', + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/6.0.0/MGI/mouse/', jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000001635.27_GRCm39_genomic.fna.gz', vertebrate: true, @@ -276,7 +276,7 @@ export const SPECIES = [ apolloName: 'rat', apolloTrack: '/All%20Genes/', jBrowseName: 'Rattus norvegicus', - jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/RGD/rat/', + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/6.0.0/RGD/rat/', jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_015227675.2_mRatBN7.2_genomic.fna.gz', vertebrate: true, @@ -290,7 +290,7 @@ export const SPECIES = [ apolloName: 'x_laevis', apolloTrack: '/All%20Genes/', jBrowseName: 'Xenopus laevis', - jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/XenBase/x_laevis/', + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/6.0.0/XenBase/x_laevis/', jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/XENLA_9.2_genome.fa.gz', vertebrate: true, @@ -304,7 +304,7 @@ export const SPECIES = [ apolloName: 'x_tropicalis', apolloTrack: '/All%20Genes/', jBrowseName: 'Xenopus tropicalis', - jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/XenBase/x_tropicalis/', + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/6.0.0/XenBase/x_tropicalis/', jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/XENTR_9.1_genome.fa.gz', vertebrate: true, @@ -318,7 +318,7 @@ export const SPECIES = [ apolloName: 'zebrafish', apolloTrack: '/All%20Genes/', jBrowseName: 'Danio rerio', - jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/zfin/zebrafish-11/', + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/6.0.0/zfin/zebrafish-11/', jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000002035.6_GRCz11_genomic.fna.gz', vertebrate: true, @@ -332,7 +332,7 @@ export const SPECIES = [ apolloName: 'fly', apolloTrack: '/All%20Genes/', jBrowseName: 'Drosophila melanogaster', - jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/FlyBase/fruitfly/', + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/6.0.0/FlyBase/fruitfly/', jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000001215.4_Release_6_plus_ISO1_MT_genomic.fna.gz', vertebrate: false, @@ -346,7 +346,7 @@ export const SPECIES = [ apolloName: 'worm', apolloTrack: '/All%20Genes/', jBrowseName: 'Caenorhabditis elegans', - jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/WormBase/c_elegans_PRJNA13758/', + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/6.0.0/WormBase/c_elegans_PRJNA13758/', jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000002985.6_WBcel235_genomic.fna.gz', vertebrate: false, @@ -360,7 +360,7 @@ export const SPECIES = [ apolloName: 'yeast', apolloTrack: '/All%20Genes/', jBrowseName: 'Saccharomyces cerevisiae', - jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/5.4.0/SGD/yeast/', + jBrowsenclistbaseurl: 'https://s3.amazonaws.com/agrjbrowse/docker/6.0.0/SGD/yeast/', jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz', jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000146045.2_R64_genomic.fna.gz', vertebrate: false, From 08ca54532204489fe572d9c0b2b711359f9503dc Mon Sep 17 00:00:00 2001 From: markquintontulloch Date: Wed, 23 Aug 2023 14:13:52 +0100 Subject: [PATCH 50/85] Display AGM name instead of curie --- .../src/components/dataTable/GeneticModifiersCellCuration.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/apps/main-app/src/components/dataTable/GeneticModifiersCellCuration.js b/apps/main-app/src/components/dataTable/GeneticModifiersCellCuration.js index 1805e9392..fc969aa93 100644 --- a/apps/main-app/src/components/dataTable/GeneticModifiersCellCuration.js +++ b/apps/main-app/src/components/dataTable/GeneticModifiersCellCuration.js @@ -25,16 +25,15 @@ function GeneticModifierLink(modifier) { break; case 'AffectedGenomicModel': let url = getResourceUrl(modifier.curie, modifier.type, modifier.subtype); - if (url) { + if (url && modifier.name) { return ( - + ); } break; default: return <>; - break; } return <>; } From a1e3afdcb10a23624956e1df916baa4b08ca8855 Mon Sep 17 00:00:00 2001 From: Scott Cain Date: Fri, 25 Aug 2023 08:25:08 -0700 Subject: [PATCH 51/85] removing logging messages --- .../src/containers/genePage/sequencePanelWrapper.js | 8 -------- 1 file changed, 8 deletions(-) diff --git a/apps/main-app/src/containers/genePage/sequencePanelWrapper.js b/apps/main-app/src/containers/genePage/sequencePanelWrapper.js index d1bd8797d..f444e8e2e 100644 --- a/apps/main-app/src/containers/genePage/sequencePanelWrapper.js +++ b/apps/main-app/src/containers/genePage/sequencePanelWrapper.js @@ -22,14 +22,6 @@ class SequencePanel extends Component { if((this.props.species === 'NCBITaxon:559292' || this.props.species === 'NCBITaxon:8355') && !this.props.refseq.startsWith('chr') && !this.props.refseq.toLowerCase().startsWith('scaffold')){ refseq = 'chr' + refseq; } - console.log(this.props); - console.log(this.props.gene); - console.log(this.jBrowseurltemplate); - console.log(refseq); - console.log(this.props.start); - console.log(this.props.end); - console.log(this.jBrowsenclistbaseurl); - console.log(this.jBrowsefastaurl); return ( Date: Fri, 25 Aug 2023 10:17:19 -0700 Subject: [PATCH 52/85] updating version of seqpanel to get a typo fix --- package.json | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index 5fe3415b0..4c54b6faf 100644 --- a/package.json +++ b/package.json @@ -46,7 +46,7 @@ "custom-event-polyfill": "^1.0.6", "d3-selection": "2.0.0", "document-register-element": "1.13.1", - "generic-sequence-panel": "^1.1.0", + "generic-sequence-panel": "^1.1.1", "html-react-parser": "^0.10.0", "immutable": "^3.8.1", "js-yaml": "^4.1.0", @@ -55,6 +55,7 @@ "lodash.without": "^4.4.0", "next": "12.1.0", "numeral": "^2.0.6", + "nx": "^16.7.1", "object-hash": "2.1.1", "popper.js": "1.16.1", "prop-types": "^15.5.10", @@ -87,6 +88,7 @@ "sitemap": "^1.13.0", "tslib": "^2.0.0", "twin.macro": "2.2.3", + "vx": "^0.0.1", "whatwg-fetch": "^3.4.0" }, "devDependencies": { From 82c0a4e9c7b4ab9b6fb2ee6ac912042ab063959c Mon Sep 17 00:00:00 2001 From: Scott Cain Date: Fri, 25 Aug 2023 10:19:35 -0700 Subject: [PATCH 53/85] whoops, didn't mean to add a few of those things to packages --- package.json | 2 -- 1 file changed, 2 deletions(-) diff --git a/package.json b/package.json index 4c54b6faf..b1a6240bb 100644 --- a/package.json +++ b/package.json @@ -55,7 +55,6 @@ "lodash.without": "^4.4.0", "next": "12.1.0", "numeral": "^2.0.6", - "nx": "^16.7.1", "object-hash": "2.1.1", "popper.js": "1.16.1", "prop-types": "^15.5.10", @@ -88,7 +87,6 @@ "sitemap": "^1.13.0", "tslib": "^2.0.0", "twin.macro": "2.2.3", - "vx": "^0.0.1", "whatwg-fetch": "^3.4.0" }, "devDependencies": { From d21dd8dead0797391eeecc6c0471a627b6105ba6 Mon Sep 17 00:00:00 2001 From: Scott Cain Date: Fri, 1 Sep 2023 13:17:22 -0700 Subject: [PATCH 54/85] adding updated seqpanel and changing the label to "Sequence Details" --- apps/main-app/src/containers/genePage/index.js | 6 +++--- package.json | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/apps/main-app/src/containers/genePage/index.js b/apps/main-app/src/containers/genePage/index.js index afc2b59ad..11616dfa3 100644 --- a/apps/main-app/src/containers/genePage/index.js +++ b/apps/main-app/src/containers/genePage/index.js @@ -44,7 +44,7 @@ import SpeciesName from '../../components/SpeciesName'; const SUMMARY = 'Summary'; const SEQUENCE_FEATURE_VIEWER = 'Sequence Feature Viewer'; -const SEQUENCE_PANEL = 'Sequence Panel'; +const SEQUENCE_DETAILS = 'Sequence Details'; const FUNCTION = 'Function - GO Annotations'; const PATHWAY = 'Pathways'; const ORTHOLOGY = 'Orthology'; @@ -70,7 +70,7 @@ const SECTIONS = [ {name: TG_ALLELES}, {name: MODELS}, {name: SEQUENCE_FEATURE_VIEWER}, - {name: SEQUENCE_PANEL}, + {name: SEQUENCE_DETAILS}, {name: EXPRESSION}, {name: INTERACTIONS}, {name: GENETIC_INTERACTIONS}, @@ -205,7 +205,7 @@ const GenePage = ({geneId}) => { /> - + Date: Mon, 4 Sep 2023 11:23:49 -0700 Subject: [PATCH 55/85] bump to the version of generic-seqquence-panel for ui improvements --- package.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index 694ca7e05..0c3925d5d 100644 --- a/package.json +++ b/package.json @@ -46,7 +46,7 @@ "custom-event-polyfill": "^1.0.6", "d3-selection": "2.0.0", "document-register-element": "1.13.1", - "generic-sequence-panel": "^1.2.0", + "generic-sequence-panel": "^1.2.1", "html-react-parser": "^0.10.0", "immutable": "^3.8.1", "js-yaml": "^4.1.0", @@ -55,6 +55,7 @@ "lodash.without": "^4.4.0", "next": "12.1.0", "numeral": "^2.0.6", + "nx": "^16.7.4", "object-hash": "2.1.1", "popper.js": "1.16.1", "prop-types": "^15.5.10", From fe1d88ce3c1ff8cb56068fa34c7cd759a2624d0e Mon Sep 17 00:00:00 2001 From: Scott Cain Date: Mon, 4 Sep 2023 11:25:22 -0700 Subject: [PATCH 56/85] dang it, I don't think nx is supposed to be in package.json --- package.json | 1 - 1 file changed, 1 deletion(-) diff --git a/package.json b/package.json index 0c3925d5d..dc8bba819 100644 --- a/package.json +++ b/package.json @@ -55,7 +55,6 @@ "lodash.without": "^4.4.0", "next": "12.1.0", "numeral": "^2.0.6", - "nx": "^16.7.4", "object-hash": "2.1.1", "popper.js": "1.16.1", "prop-types": "^15.5.10", From 2122ae68d88e2a3854963180c6dbd16f6145c91a Mon Sep 17 00:00:00 2001 From: Adam Gibson Date: Thu, 7 Sep 2023 15:11:36 -0500 Subject: [PATCH 57/85] SCRUM-3219 add no data filter --- apps/main-app/src/components/dataTable/DataTable.js | 7 ++++++- .../src/components/dataTable/DropdownNoDataFilter.js | 7 +++++++ 2 files changed, 13 insertions(+), 1 deletion(-) create mode 100644 apps/main-app/src/components/dataTable/DropdownNoDataFilter.js diff --git a/apps/main-app/src/components/dataTable/DataTable.js b/apps/main-app/src/components/dataTable/DataTable.js index c10011246..7660c723d 100644 --- a/apps/main-app/src/components/dataTable/DataTable.js +++ b/apps/main-app/src/components/dataTable/DataTable.js @@ -24,6 +24,7 @@ import DropdownCheckboxFilter from './DropdownCheckboxFilter'; import HorizontalScroll from '../horizontalScroll'; import { buildTableQueryString } from '../../lib/utils'; import LoadingSpinner from '../loadingSpinner'; +import DropdownNoDataFilter from './DropdownNoDataFilter'; const DataTable = ({ className, @@ -150,7 +151,11 @@ const DataTable = ({ value={columnFilter} /> ); - } else { + } else if(filterField === "diseaseQualifier") { + column.filterRenderer = () => ( + + ); + } else{ column.filterRenderer = (onFilter, column) => ( { + return No Data to Filter; +}; + +export default DropdownNoDataFilter; From 0ed9bb0e6895575064cef74c98444271135b62c1 Mon Sep 17 00:00:00 2001 From: Adam Gibson Date: Thu, 7 Sep 2023 15:39:46 -0500 Subject: [PATCH 58/85] SCRUM-3219 add filterType --- apps/main-app/src/components/dataTable/DataTable.js | 3 ++- apps/main-app/src/components/disease/diseaseAnnotationTable.js | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/apps/main-app/src/components/dataTable/DataTable.js b/apps/main-app/src/components/dataTable/DataTable.js index 7660c723d..645a66c36 100644 --- a/apps/main-app/src/components/dataTable/DataTable.js +++ b/apps/main-app/src/components/dataTable/DataTable.js @@ -151,7 +151,8 @@ const DataTable = ({ value={columnFilter} /> ); - } else if(filterField === "diseaseQualifier") { + //if filter is a checkbox dropdown, but there is are no distinctFieldValues then show DropdownNoDataFilter instead + } else if(column.filterType === "checkbox") { column.filterRenderer = () => ( ); diff --git a/apps/main-app/src/components/disease/diseaseAnnotationTable.js b/apps/main-app/src/components/disease/diseaseAnnotationTable.js index a1e0d9929..fc72712f8 100644 --- a/apps/main-app/src/components/disease/diseaseAnnotationTable.js +++ b/apps/main-app/src/components/disease/diseaseAnnotationTable.js @@ -90,9 +90,10 @@ const DiseaseAnnotationTable = ({ dataField: 'diseaseQualifiers', text: 'Disease Qualifier', filterable: getDistinctFieldValue(resolvedData, 'diseaseQualifiers'), + filterName: 'diseaseQualifier', + filterType: 'checkbox', headerStyle: {width: '100px'}, formatter: diseaseQualifiers => , - filterName: 'diseaseQualifier', }, { dataField: 'object.curie', From cfaf6b3068cb56de9b5c24fa57afe8686fb59ada Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Tue, 5 Sep 2023 14:00:55 +0100 Subject: [PATCH 59/85] SCRUM-3222: paralogy UI changes for DIOPT with new ranking --- .../paralogy/paralogyFilteredTable.js | 215 ------------------ .../src/components/paralogy/paralogyTable.js | 190 ++++++---------- .../components/paralogy/paralogyUserGuide.js | 27 +-- .../src/components/paralogy/rankHelp.js | 16 ++ .../main-app/src/containers/genePage/index.js | 4 +- 5 files changed, 100 insertions(+), 352 deletions(-) delete mode 100644 apps/main-app/src/components/paralogy/paralogyFilteredTable.js create mode 100644 apps/main-app/src/components/paralogy/rankHelp.js diff --git a/apps/main-app/src/components/paralogy/paralogyFilteredTable.js b/apps/main-app/src/components/paralogy/paralogyFilteredTable.js deleted file mode 100644 index 8b9122d93..000000000 --- a/apps/main-app/src/components/paralogy/paralogyFilteredTable.js +++ /dev/null @@ -1,215 +0,0 @@ -import { useState } from 'react'; -import PropTypes from 'prop-types'; -import { Collapse } from 'reactstrap'; -import StringencySelection from '../homology/stringencySelection'; -import { isBest } from '../orthology/orthologyTable'; -import { getOrthologSpeciesName } from '../homology/utils'; -import HorizontalScroll from '../horizontalScroll'; -import LoadingSpinner from '../loadingSpinner'; -import NoData from '../noData'; -import ControlsContainer from '../controlsContainer'; -import { STRINGENCY_HIGH } from '../homology/constants'; -import { - compareAlphabeticalCaseInsensitive, - orthologyMeetsStringency -} from '../../lib/utils'; -import HelpPopup from '../helpPopup'; -import HomologyFilterHelp from '../homology/homologyFilterHelp'; -import useResettableState from '../../hooks/useResettableState'; -import useGeneParalogy from '../../hooks/useGeneParalogy'; -import ParalogyTable from './paralogyTable'; - -const ParalogyFilteredTable = ({geneId}) => { - const [ - filterScoreGreaterThan, - setFilterScoreGreaterThan, - resetFilterScoreGreaterThan - ] = useResettableState(0); - const [ - filterMethod, - setFilterMethod, - resetFilterMethod - ] = useResettableState(null); - const [ - filterBest, - setFilterBest, - resetFilterBest - ] = useResettableState(false); - const [ - filterReverseBest, - setFilterReverseBest, - resetFilterReverseBest - ] = useResettableState(false); - const [ - filterSpecies, - setFilterSpecies, - resetFilterSpecies - ] = useResettableState(null); - const [ - stringencyLevel, - setStringencyLevel, - resetStringencyLevel - ] = useResettableState(STRINGENCY_HIGH); - const [showFilterPanel, setShowFilterPanel] = useState(false); - - const { data, isLoading } = useGeneParalogy(geneId); - - const filterCallback = (dat) => { - const meetMethodFilter = filterMethod ? - dat.predictionMethodsMatched.indexOf(filterMethod) > -1 : - true; - return ( - meetMethodFilter && - dat.predictionMethodsMatched.length > filterScoreGreaterThan && - (filterBest ? isBest(dat.best) : true) && - (filterReverseBest ? isBest(dat.bestReverse) : true) && - (filterSpecies ? getOrthologSpeciesName(dat) === filterSpecies : true) && - orthologyMeetsStringency(dat, stringencyLevel) - ); - }; - - const resetFilters = () => { - resetFilterScoreGreaterThan(); - resetFilterMethod(); - resetFilterBest(); - resetFilterReverseBest(); - resetFilterSpecies(); - resetStringencyLevel(); - }; - - if (isLoading) { - return ; - } - - if (data.total === 0) { - return ; - } - - const filteredData = data.results.filter(filterCallback); - const all_methods = data.results[0].predictionMethodsMatched.concat( - data.results[0].predictionMethodsNotCalled, - data.results[0].predictionMethodsNotMatched - ).sort(compareAlphabeticalCaseInsensitive); - - const labelStyle = { - margin: '0em 1em 0em 0', - lineHeight: '2em', - }; - const inputStyle = { - margin: '0 0.5em' - }; - - const buttonStyle = { - marginTop: '0.5em', - marginRight: '0.5em', - minWidth: '8em', - }; - - const docTextStyle = { - fontStyle: 'italic', - opacity: 0.7, - fontSize: '0.9em', - }; - - return ( -
- - - - - - - - -
- Additional filters to further constrain the results: -
- - -
- - -
-
-
- - -
-
- -
- { - filteredData.length > 0 ? - - - : - No paralog matching your filter. Please try a less stringent filter. - } -
-
- ); -}; - -ParalogyFilteredTable.propTypes = { - geneId: PropTypes.string.isRequired, -}; - -export default ParalogyFilteredTable; diff --git a/apps/main-app/src/components/paralogy/paralogyTable.js b/apps/main-app/src/components/paralogy/paralogyTable.js index 166270658..4071e58f0 100644 --- a/apps/main-app/src/components/paralogy/paralogyTable.js +++ b/apps/main-app/src/components/paralogy/paralogyTable.js @@ -1,131 +1,85 @@ -import { Component } from 'react'; -import PropTypes from 'prop-types'; import { Link } from 'react-router-dom'; +import PropTypes from 'prop-types'; +import HorizontalScroll from '../horizontalScroll'; +import LoadingSpinner from '../loadingSpinner'; +import NoData from '../noData'; +import { compareAlphabeticalCaseInsensitive } from '../../lib/utils'; +import useGeneParalogy from '../../hooks/useGeneParalogy'; import MethodHeader from '../homology/methodHeader'; import MethodCell from '../homology/methodCell'; -import BooleanCell from '../homology/booleanCell'; -import { - getOrthologId, - getOrthologSymbol as getHomologSymbol, -} from '../homology/utils'; -import { sortBy } from '../../lib/utils'; import HelpPopup from '../helpPopup'; +import RankHelp from './rankHelp'; -import style from '../homology/style.scss'; - -const columns = [ - {name: 'Gene symbol'}, - {name: 'Count'}, - {name: 'Best', help: This gene is called a paralog of the input gene by the highest number of algorithms.
In specific cases, ZFIN curators have asserted reliable paralogy to the gene called by the second highest number of algorithms. These are denoted Yes *.
}, - {name: 'Best reverse', help: 'The input gene is called a paralog of this gene by the highest number of algorithms.'}, - {name: 'Method'} -]; - -export function isBest(value = '') { - return typeof value === 'boolean' ? value : value.match(/yes/i); -} - -function scoreBest(best, bestReverse, OtherBest, OtherBestReverse) { - let AB = (best === 'Yes') ? -1 : 0; - let AR = (bestReverse === 'Yes') ? -1 : 0; - let OB = (OtherBest === 'Yes') ? -1 : 0; - let OR = (OtherBestReverse === 'Yes') ? -1 : 0; - - return (AB+AR) - (OB+OR) -} - +const ParalogyTable = ({geneId}) => { + const { data, isLoading } = useGeneParalogy(geneId); + if (isLoading) { + return ; + } + if (data?.results.length === 0) { + return No paralogs for the gene. + } -class ParalogyTable extends Component { + const results = data.results.sort( (a,b) => { + if (Number(a.rank) < Number(b.rank)) { + return -1; + } + if (Number(a.rank) > Number(b.rank)) { + return 1; + } + return 0; + }); - render() { - let rowGroup = 0; - return( - - - - { - columns.map((column) => { - if (column.name === 'Method') { - return (); - } else { - return (); + const all_methods = data.results[0].predictionMethodsMatched.concat( + data.results[0].predictionMethodsNotCalled, + data.results[0].predictionMethodsNotMatched + ).sort(compareAlphabeticalCaseInsensitive); + + return ( +
+
+ +
- {column.name} {column.help && {column.help}} -
+ + + + + + + + + + + + + { + results.map( result => { + return ( + + + + + + + + )}) } - }) - } - - - - { - sortBy(this.props.data, [ - (orthDataA, orthDataB) => orthDataB.predictionMethodsMatched.length - orthDataA.predictionMethodsMatched.length, - (orthDataA, orthDataB) => scoreBest(orthDataA.best, orthDataA.bestReverse, orthDataB.best, orthDataB.bestReverse) - ]).map((orthData, idx, orthList) => { - const scoreNumerator = orthData.predictionMethodsMatched.length; - const scoreDemominator = scoreNumerator + - orthData.predictionMethodsNotMatched.length; - const orthId = getOrthologId(orthData); - - return ( - - - - 'Yes *' : - null - } - value={orthData.best} - /> - - - - ); - }) - } - -
Gene symbolRank Alignment LengthSimilarity %Identity %Method Count
+ + + + {result.rank}{result.length}{result.similarity}{result.identity}{result.methodCount} of {result.totalMethodCount}
- - - - {`${scoreNumerator} of ${scoreDemominator}`}
- ); - } -} + + + +
+
+ ); +}; ParalogyTable.propTypes = { - data: PropTypes.arrayOf( - PropTypes.shape({ - gene: PropTypes.shape({ - id: PropTypes.string, - symbol: PropTypes.string, - species: PropTypes.shape({ - name: PropTypes.string, - }), - }), - predictionMethodsMatched: PropTypes.arrayOf(PropTypes.string), - predictionMethodsNotCalled: PropTypes.arrayOf(PropTypes.string), - predictionMethodsNotMatched: PropTypes.arrayOf(PropTypes.string), - best: PropTypes.oneOfType([ - PropTypes.bool, - PropTypes.string - ]), - bestReverse: PropTypes.oneOfType([ - PropTypes.bool, - PropTypes.string - ]), - }) - ) + geneId: PropTypes.string.isRequired, }; export default ParalogyTable; diff --git a/apps/main-app/src/components/paralogy/paralogyUserGuide.js b/apps/main-app/src/components/paralogy/paralogyUserGuide.js index 089c7aaa6..4d740fd55 100644 --- a/apps/main-app/src/components/paralogy/paralogyUserGuide.js +++ b/apps/main-app/src/components/paralogy/paralogyUserGuide.js @@ -1,6 +1,7 @@ import ExternalLink from '../ExternalLink'; -const ParalogyUserGuide = () => ( +export default function ParalogyUserGuide() { + return (

Many aspects of data integration presented at the Alliance require a @@ -8,28 +9,20 @@ const ParalogyUserGuide = () => ( represented, including human. The Alliance provides the results of all methods that have been benchmarked by the Quest for Orthologs Consortium (QfO), as well as curated - ortholog inferences from HGNC (for human and mouse genes), Xenbase (for frog genes), and - ZFIN (relating zebrafish genes to orthologs in human, mouse, and fly). + ortholog inferences from HGNC (for human and mouse genes), and SGD (for yeast genes).

The paralog inferences from the different methods have been integrated using the DRSC Integrative Ortholog Prediction Tool (DIOPT). DIOPT integrates a number of existing methods including - those used by the Alliance: Ensembl Compara, HGNC, Hieranoid, - InParanoid, OMA, OrthoFinder, OrthoInspector, PANTHER, PhylomeDB, - SonicParanoid, Xenbase, and ZFIN. See the + those used by the Alliance: Ensembl Compara, HGNC, InParanoid, + OMA, OrthoFinder, OrthoInspector, PANTHER, PhylomeDB, + SonicParanoid and SGD. See the DIOPT documentation for additional information and references related to the included methods. DIOPT assigns a score/count based on the number of methods that call a specific - paralog. For noncoding RNA genes, currently only HGNC and ZFIN - curated paralogs are included. + paralog. For noncoding RNA genes, currently only HGNC curated + paralogs are included.

-

- The DIOPT approach allows flexibility in the choice of algorithms and - in the level of stringency applied. For the Paralogy table, these - parameters can be specified. -

-
-); - -export default ParalogyUserGuide; +
); + } \ No newline at end of file diff --git a/apps/main-app/src/components/paralogy/rankHelp.js b/apps/main-app/src/components/paralogy/rankHelp.js new file mode 100644 index 000000000..374d50a1b --- /dev/null +++ b/apps/main-app/src/components/paralogy/rankHelp.js @@ -0,0 +1,16 @@ + +export default function RankHelp() { + return ( +
+

+ Rank is calculated via the highest percent similarity within + four quartiles of alignment length (determined by using four 25% + quartiles derived from the longest paralog alignment length). + + Paralogs with the longest alignment and greatest similarity + percentage are ranked highest and DIOPT algorithm matches are + used as secondary ranking criteria in cases of equal similarity + within alignment length quartiles. Multiple entries can share the same rank. +

+
); + } diff --git a/apps/main-app/src/containers/genePage/index.js b/apps/main-app/src/containers/genePage/index.js index 11616dfa3..5645f57af 100644 --- a/apps/main-app/src/containers/genePage/index.js +++ b/apps/main-app/src/containers/genePage/index.js @@ -3,7 +3,7 @@ import PropTypes from 'prop-types'; import { DataPage, PageNav, PageData, PageHeader } from '../../components/dataPage'; import BasicGeneInfo from './basicGeneInfo'; import { OrthologyFilteredTable, HomologyUserGuide, OrthologyBasicInfo } from '../../components/orthology'; -import ParalogyFilteredTable from '../../components/paralogy/paralogyFilteredTable' +import ParalogyTable from '../../components/paralogy/paralogyTable' import ParalogyUserGuide from '../../components/paralogy/paralogyUserGuide' import GoUserGuide from '../../components/geneOntologyRibbon/goUserGuide'; import PathwayUserGuide from '../../components/pathway/pathwayUserGuide'; @@ -131,7 +131,7 @@ const GenePage = ({geneId}) => {
} title={PARALOGY}> - + } title={FUNCTION}> From 0484396fbc1d0c4f3a15d042daa5b312d65420c3 Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Mon, 11 Sep 2023 14:00:17 +0100 Subject: [PATCH 60/85] SCRUM-3222: paralogy UI changes for DIOPT with new ranking --- .../src/components/paralogy/paralogyTable.js | 38 ++++++++----------- 1 file changed, 16 insertions(+), 22 deletions(-) diff --git a/apps/main-app/src/components/paralogy/paralogyTable.js b/apps/main-app/src/components/paralogy/paralogyTable.js index 4071e58f0..ef604e684 100644 --- a/apps/main-app/src/components/paralogy/paralogyTable.js +++ b/apps/main-app/src/components/paralogy/paralogyTable.js @@ -3,7 +3,6 @@ import PropTypes from 'prop-types'; import HorizontalScroll from '../horizontalScroll'; import LoadingSpinner from '../loadingSpinner'; import NoData from '../noData'; -import { compareAlphabeticalCaseInsensitive } from '../../lib/utils'; import useGeneParalogy from '../../hooks/useGeneParalogy'; import MethodHeader from '../homology/methodHeader'; import MethodCell from '../homology/methodCell'; @@ -28,12 +27,7 @@ const ParalogyTable = ({geneId}) => { } return 0; }); - - const all_methods = data.results[0].predictionMethodsMatched.concat( - data.results[0].predictionMethodsNotCalled, - data.results[0].predictionMethodsNotMatched - ).sort(compareAlphabeticalCaseInsensitive); - + return (
@@ -55,20 +49,20 @@ const ParalogyTable = ({geneId}) => { results.map( result => { return ( - - - - - {result.rank} - {result.length} - {result.similarity} - {result.identity} - {result.methodCount} of {result.totalMethodCount} - - )}) + + + + + {result.rank} + {result.length} + {result.similarity} + {result.identity} + {result.methodCount} of {result.totalMethodCount} + + )}) } @@ -82,4 +76,4 @@ ParalogyTable.propTypes = { geneId: PropTypes.string.isRequired, }; -export default ParalogyTable; +export default ParalogyTable; \ No newline at end of file From ab7906000b0e6656e392c2c48d0c548a44cb6191 Mon Sep 17 00:00:00 2001 From: Olin Blodgett Date: Mon, 11 Sep 2023 16:58:55 -0400 Subject: [PATCH 61/85] Added code for deploing a ALB with the UI code --- cdk-outputs.json | 5 + cdk.context.json | 98 +++ cdk.json | 4 + cdk.out/cdk-stack.assets.json | 20 + cdk.out/cdk-stack.template.json | 1097 +++++++++++++++++++++++++ cdk.out/cdk.out | 1 + cdk.out/manifest.json | 106 +++ cdk.out/stage-alb-stack.assets.json | 20 + cdk.out/stage-alb-stack.template.json | 186 +++++ cdk.out/tree.json | 398 +++++++++ cdk/cdk-stage.ts | 13 + cdk/stage-alb-stack.ts | 54 ++ package.json | 5 + tsconfig.json | 32 + 14 files changed, 2039 insertions(+) create mode 100644 cdk-outputs.json create mode 100644 cdk.context.json create mode 100644 cdk.json create mode 100644 cdk.out/cdk-stack.assets.json create mode 100644 cdk.out/cdk-stack.template.json create mode 100644 cdk.out/cdk.out create mode 100644 cdk.out/manifest.json create mode 100644 cdk.out/stage-alb-stack.assets.json create mode 100644 cdk.out/stage-alb-stack.template.json create mode 100644 cdk.out/tree.json create mode 100644 cdk/cdk-stage.ts create mode 100644 cdk/stage-alb-stack.ts create mode 100644 tsconfig.json diff --git a/cdk-outputs.json b/cdk-outputs.json new file mode 100644 index 000000000..8278425ae --- /dev/null +++ b/cdk-outputs.json @@ -0,0 +1,5 @@ +{ + "stage-alb-stack": { + "albDNS": "internal-stage-alb8A-D8N9BHZDT6F2-1821793229.us-east-1.elb.amazonaws.com" + } +} diff --git a/cdk.context.json b/cdk.context.json new file mode 100644 index 000000000..6e5c33c0e --- /dev/null +++ b/cdk.context.json @@ -0,0 +1,98 @@ +{ + "availability-zones:account=100225593120:region=us-east-1": [ + "us-east-1a", + "us-east-1b", + "us-east-1c", + "us-east-1d", + "us-east-1e", + "us-east-1f" + ], + "vpc-provider:account=100225593120:filter.tag:Name=Docker:region=us-east-1:returnAsymmetricSubnets=true": { + "vpcId": "vpc-55522232", + "vpcCidrBlock": "172.31.0.0/16", + "ownerAccountId": "100225593120", + "availabilityZones": [], + "subnetGroups": [ + { + "name": "Public", + "type": "Public", + "subnets": [ + { + "subnetId": "subnet-3ebf4477", + "cidr": "172.31.0.0/20", + "availabilityZone": "us-east-1a", + "routeTableId": "rtb-c63af6a0" + }, + { + "subnetId": "subnet-df7c7487", + "cidr": "172.31.16.0/20", + "availabilityZone": "us-east-1b", + "routeTableId": "rtb-c63af6a0" + }, + { + "subnetId": "subnet-81c95ee4", + "cidr": "172.31.64.0/20", + "availabilityZone": "us-east-1c", + "routeTableId": "rtb-c63af6a0" + }, + { + "subnetId": "subnet-ff838bd5", + "cidr": "172.31.48.0/20", + "availabilityZone": "us-east-1d", + "routeTableId": "rtb-c63af6a0" + }, + { + "subnetId": "subnet-af62dca3", + "cidr": "172.31.80.0/20", + "availabilityZone": "us-east-1f", + "routeTableId": "rtb-c63af6a0" + } + ] + }, + { + "name": "Private", + "type": "Private", + "subnets": [ + { + "subnetId": "subnet-0d4703177afb1797d", + "cidr": "172.31.96.0/24", + "availabilityZone": "us-east-1a", + "routeTableId": "rtb-05e12b551f60b37ed" + }, + { + "subnetId": "subnet-04262fc338f638054", + "cidr": "172.31.97.0/24", + "availabilityZone": "us-east-1b", + "routeTableId": "rtb-05e12b551f60b37ed" + }, + { + "subnetId": "subnet-044457c061edf85f2", + "cidr": "172.31.98.0/24", + "availabilityZone": "us-east-1c", + "routeTableId": "rtb-05e12b551f60b37ed" + }, + { + "subnetId": "subnet-04019d42d5c9e6fb9", + "cidr": "172.31.99.0/24", + "availabilityZone": "us-east-1d", + "routeTableId": "rtb-05e12b551f60b37ed" + }, + { + "subnetId": "subnet-049778993fb504a7c", + "cidr": "172.31.101.0/24", + "availabilityZone": "us-east-1f", + "routeTableId": "rtb-05e12b551f60b37ed" + } + ] + } + ] + }, + "security-group:account=100225593120:region=us-east-1:securityGroupName=default:vpcId=vpc-55522232": { + "securityGroupId": "sg-21ac675b", + "allowAllOutbound": false + }, + "security-group:account=100225593120:region=us-east-1:securityGroupId=sg-21ac675b": { + "securityGroupId": "sg-21ac675b", + "allowAllOutbound": false + } +} diff --git a/cdk.json b/cdk.json new file mode 100644 index 000000000..f0c49fded --- /dev/null +++ b/cdk.json @@ -0,0 +1,4 @@ +{ + "app": "npx ts-node --prefer-ts-exts cdk/cdk-stage.ts", + "context": {} +} diff --git a/cdk.out/cdk-stack.assets.json b/cdk.out/cdk-stack.assets.json new file mode 100644 index 000000000..3c6354600 --- /dev/null +++ b/cdk.out/cdk-stack.assets.json @@ -0,0 +1,20 @@ +{ + "version": "34.0.0", + "files": { + "a4518594ba7b9be03de79203ec8a1006b42513fd59d1dc48d55538a9f27e9c4a": { + "source": { + "path": "cdk-stack.template.json", + "packaging": "file" + }, + "destinations": { + "100225593120-us-east-1": { + "bucketName": "cdk-hnb659fds-assets-100225593120-us-east-1", + "objectKey": "a4518594ba7b9be03de79203ec8a1006b42513fd59d1dc48d55538a9f27e9c4a.json", + "region": "us-east-1", + "assumeRoleArn": "arn:${AWS::Partition}:iam::100225593120:role/cdk-hnb659fds-file-publishing-role-100225593120-us-east-1" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/cdk.out/cdk-stack.template.json b/cdk.out/cdk-stack.template.json new file mode 100644 index 000000000..7d2dde57f --- /dev/null +++ b/cdk.out/cdk-stack.template.json @@ -0,0 +1,1097 @@ +{ + "Resources": { + "vpc555222327AFC16C5": { + "Type": "AWS::EC2::VPC", + "Properties": { + "CidrBlock": "10.0.0.0/16", + "EnableDnsHostnames": true, + "EnableDnsSupport": true, + "InstanceTenancy": "default", + "Tags": [ + { + "Key": "Name", + "Value": "cdk-stack/vpc-55522232" + } + ] + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/Resource" + } + }, + "vpc55522232PublicSubnet1Subnet8C1D3F0B": { + "Type": "AWS::EC2::Subnet", + "Properties": { + "AvailabilityZone": "us-east-1a", + "CidrBlock": "10.0.0.0/19", + "MapPublicIpOnLaunch": true, + "Tags": [ + { + "Key": "aws-cdk:subnet-name", + "Value": "Public" + }, + { + "Key": "aws-cdk:subnet-type", + "Value": "Public" + }, + { + "Key": "Name", + "Value": "cdk-stack/vpc-55522232/PublicSubnet1" + } + ], + "VpcId": { + "Ref": "vpc555222327AFC16C5" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet1/Subnet" + } + }, + "vpc55522232PublicSubnet1RouteTable201E0132": { + "Type": "AWS::EC2::RouteTable", + "Properties": { + "Tags": [ + { + "Key": "Name", + "Value": "cdk-stack/vpc-55522232/PublicSubnet1" + } + ], + "VpcId": { + "Ref": "vpc555222327AFC16C5" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet1/RouteTable" + } + }, + "vpc55522232PublicSubnet1RouteTableAssociationFC3053F6": { + "Type": "AWS::EC2::SubnetRouteTableAssociation", + "Properties": { + "RouteTableId": { + "Ref": "vpc55522232PublicSubnet1RouteTable201E0132" + }, + "SubnetId": { + "Ref": "vpc55522232PublicSubnet1Subnet8C1D3F0B" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet1/RouteTableAssociation" + } + }, + "vpc55522232PublicSubnet1DefaultRoute3576EEAF": { + "Type": "AWS::EC2::Route", + "Properties": { + "DestinationCidrBlock": "0.0.0.0/0", + "GatewayId": { + "Ref": "vpc55522232IGW2124CFCD" + }, + "RouteTableId": { + "Ref": "vpc55522232PublicSubnet1RouteTable201E0132" + } + }, + "DependsOn": [ + "vpc55522232VPCGW0E59A086" + ], + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet1/DefaultRoute" + } + }, + "vpc55522232PublicSubnet1EIP2B529517": { + "Type": "AWS::EC2::EIP", + "Properties": { + "Domain": "vpc", + "Tags": [ + { + "Key": "Name", + "Value": "cdk-stack/vpc-55522232/PublicSubnet1" + } + ] + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet1/EIP" + } + }, + "vpc55522232PublicSubnet1NATGateway8F921A30": { + "Type": "AWS::EC2::NatGateway", + "Properties": { + "AllocationId": { + "Fn::GetAtt": [ + "vpc55522232PublicSubnet1EIP2B529517", + "AllocationId" + ] + }, + "SubnetId": { + "Ref": "vpc55522232PublicSubnet1Subnet8C1D3F0B" + }, + "Tags": [ + { + "Key": "Name", + "Value": "cdk-stack/vpc-55522232/PublicSubnet1" + } + ] + }, + "DependsOn": [ + "vpc55522232PublicSubnet1DefaultRoute3576EEAF", + "vpc55522232PublicSubnet1RouteTableAssociationFC3053F6" + ], + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet1/NATGateway" + } + }, + "vpc55522232PublicSubnet2Subnet82DD7CE0": { + "Type": "AWS::EC2::Subnet", + "Properties": { + "AvailabilityZone": "us-east-1b", + "CidrBlock": "10.0.32.0/19", + "MapPublicIpOnLaunch": true, + "Tags": [ + { + "Key": "aws-cdk:subnet-name", + "Value": "Public" + }, + { + "Key": "aws-cdk:subnet-type", + "Value": "Public" + }, + { + "Key": "Name", + "Value": "cdk-stack/vpc-55522232/PublicSubnet2" + } + ], + "VpcId": { + "Ref": "vpc555222327AFC16C5" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet2/Subnet" + } + }, + "vpc55522232PublicSubnet2RouteTableB74BC90B": { + "Type": "AWS::EC2::RouteTable", + "Properties": { + "Tags": [ + { + "Key": "Name", + "Value": "cdk-stack/vpc-55522232/PublicSubnet2" + } + ], + "VpcId": { + "Ref": "vpc555222327AFC16C5" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet2/RouteTable" + } + }, + "vpc55522232PublicSubnet2RouteTableAssociation94475C00": { + "Type": "AWS::EC2::SubnetRouteTableAssociation", + "Properties": { + "RouteTableId": { + "Ref": "vpc55522232PublicSubnet2RouteTableB74BC90B" + }, + "SubnetId": { + "Ref": "vpc55522232PublicSubnet2Subnet82DD7CE0" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet2/RouteTableAssociation" + } + }, + "vpc55522232PublicSubnet2DefaultRoute96F97D0D": { + "Type": "AWS::EC2::Route", + "Properties": { + "DestinationCidrBlock": "0.0.0.0/0", + "GatewayId": { + "Ref": "vpc55522232IGW2124CFCD" + }, + "RouteTableId": { + "Ref": "vpc55522232PublicSubnet2RouteTableB74BC90B" + } + }, + "DependsOn": [ + "vpc55522232VPCGW0E59A086" + ], + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet2/DefaultRoute" + } + }, + "vpc55522232PublicSubnet2EIP9D615FD5": { + "Type": "AWS::EC2::EIP", + "Properties": { + "Domain": "vpc", + "Tags": [ + { + "Key": "Name", + "Value": "cdk-stack/vpc-55522232/PublicSubnet2" + } + ] + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet2/EIP" + } + }, + "vpc55522232PublicSubnet2NATGatewayCE45ECF6": { + "Type": "AWS::EC2::NatGateway", + "Properties": { + "AllocationId": { + "Fn::GetAtt": [ + "vpc55522232PublicSubnet2EIP9D615FD5", + "AllocationId" + ] + }, + "SubnetId": { + "Ref": "vpc55522232PublicSubnet2Subnet82DD7CE0" + }, + "Tags": [ + { + "Key": "Name", + "Value": "cdk-stack/vpc-55522232/PublicSubnet2" + } + ] + }, + "DependsOn": [ + "vpc55522232PublicSubnet2DefaultRoute96F97D0D", + "vpc55522232PublicSubnet2RouteTableAssociation94475C00" + ], + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet2/NATGateway" + } + }, + "vpc55522232PublicSubnet3SubnetB60D3678": { + "Type": "AWS::EC2::Subnet", + "Properties": { + "AvailabilityZone": "us-east-1c", + "CidrBlock": "10.0.64.0/19", + "MapPublicIpOnLaunch": true, + "Tags": [ + { + "Key": "aws-cdk:subnet-name", + "Value": "Public" + }, + { + "Key": "aws-cdk:subnet-type", + "Value": "Public" + }, + { + "Key": "Name", + "Value": "cdk-stack/vpc-55522232/PublicSubnet3" + } + ], + "VpcId": { + "Ref": "vpc555222327AFC16C5" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet3/Subnet" + } + }, + "vpc55522232PublicSubnet3RouteTableE4B6F284": { + "Type": "AWS::EC2::RouteTable", + "Properties": { + "Tags": [ + { + "Key": "Name", + "Value": "cdk-stack/vpc-55522232/PublicSubnet3" + } + ], + "VpcId": { + "Ref": "vpc555222327AFC16C5" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet3/RouteTable" + } + }, + "vpc55522232PublicSubnet3RouteTableAssociationE9DD046D": { + "Type": "AWS::EC2::SubnetRouteTableAssociation", + "Properties": { + "RouteTableId": { + "Ref": "vpc55522232PublicSubnet3RouteTableE4B6F284" + }, + "SubnetId": { + "Ref": "vpc55522232PublicSubnet3SubnetB60D3678" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet3/RouteTableAssociation" + } + }, + "vpc55522232PublicSubnet3DefaultRoute4A067F3E": { + "Type": "AWS::EC2::Route", + "Properties": { + "DestinationCidrBlock": "0.0.0.0/0", + "GatewayId": { + "Ref": "vpc55522232IGW2124CFCD" + }, + "RouteTableId": { + "Ref": "vpc55522232PublicSubnet3RouteTableE4B6F284" + } + }, + "DependsOn": [ + "vpc55522232VPCGW0E59A086" + ], + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet3/DefaultRoute" + } + }, + "vpc55522232PublicSubnet3EIP60F7BABB": { + "Type": "AWS::EC2::EIP", + "Properties": { + "Domain": "vpc", + "Tags": [ + { + "Key": "Name", + "Value": "cdk-stack/vpc-55522232/PublicSubnet3" + } + ] + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet3/EIP" + } + }, + "vpc55522232PublicSubnet3NATGateway285C26A6": { + "Type": "AWS::EC2::NatGateway", + "Properties": { + "AllocationId": { + "Fn::GetAtt": [ + "vpc55522232PublicSubnet3EIP60F7BABB", + "AllocationId" + ] + }, + "SubnetId": { + "Ref": "vpc55522232PublicSubnet3SubnetB60D3678" + }, + "Tags": [ + { + "Key": "Name", + "Value": "cdk-stack/vpc-55522232/PublicSubnet3" + } + ] + }, + "DependsOn": [ + "vpc55522232PublicSubnet3DefaultRoute4A067F3E", + "vpc55522232PublicSubnet3RouteTableAssociationE9DD046D" + ], + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet3/NATGateway" + } + }, + "vpc55522232PrivateSubnet1Subnet2E4DA426": { + "Type": "AWS::EC2::Subnet", + "Properties": { + "AvailabilityZone": "us-east-1a", + "CidrBlock": "10.0.96.0/19", + "MapPublicIpOnLaunch": false, + "Tags": [ + { + "Key": "aws-cdk:subnet-name", + "Value": "Private" + }, + { + "Key": "aws-cdk:subnet-type", + "Value": "Private" + }, + { + "Key": "Name", + "Value": "cdk-stack/vpc-55522232/PrivateSubnet1" + } + ], + "VpcId": { + "Ref": "vpc555222327AFC16C5" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet1/Subnet" + } + }, + "vpc55522232PrivateSubnet1RouteTableC546D020": { + "Type": "AWS::EC2::RouteTable", + "Properties": { + "Tags": [ + { + "Key": "Name", + "Value": "cdk-stack/vpc-55522232/PrivateSubnet1" + } + ], + "VpcId": { + "Ref": "vpc555222327AFC16C5" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet1/RouteTable" + } + }, + "vpc55522232PrivateSubnet1RouteTableAssociation98BDECFD": { + "Type": "AWS::EC2::SubnetRouteTableAssociation", + "Properties": { + "RouteTableId": { + "Ref": "vpc55522232PrivateSubnet1RouteTableC546D020" + }, + "SubnetId": { + "Ref": "vpc55522232PrivateSubnet1Subnet2E4DA426" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet1/RouteTableAssociation" + } + }, + "vpc55522232PrivateSubnet1DefaultRouteD15CA2D8": { + "Type": "AWS::EC2::Route", + "Properties": { + "DestinationCidrBlock": "0.0.0.0/0", + "NatGatewayId": { + "Ref": "vpc55522232PublicSubnet1NATGateway8F921A30" + }, + "RouteTableId": { + "Ref": "vpc55522232PrivateSubnet1RouteTableC546D020" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet1/DefaultRoute" + } + }, + "vpc55522232PrivateSubnet2SubnetBF911E75": { + "Type": "AWS::EC2::Subnet", + "Properties": { + "AvailabilityZone": "us-east-1b", + "CidrBlock": "10.0.128.0/19", + "MapPublicIpOnLaunch": false, + "Tags": [ + { + "Key": "aws-cdk:subnet-name", + "Value": "Private" + }, + { + "Key": "aws-cdk:subnet-type", + "Value": "Private" + }, + { + "Key": "Name", + "Value": "cdk-stack/vpc-55522232/PrivateSubnet2" + } + ], + "VpcId": { + "Ref": "vpc555222327AFC16C5" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet2/Subnet" + } + }, + "vpc55522232PrivateSubnet2RouteTableC23CB4A9": { + "Type": "AWS::EC2::RouteTable", + "Properties": { + "Tags": [ + { + "Key": "Name", + "Value": "cdk-stack/vpc-55522232/PrivateSubnet2" + } + ], + "VpcId": { + "Ref": "vpc555222327AFC16C5" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet2/RouteTable" + } + }, + "vpc55522232PrivateSubnet2RouteTableAssociationE7D278B5": { + "Type": "AWS::EC2::SubnetRouteTableAssociation", + "Properties": { + "RouteTableId": { + "Ref": "vpc55522232PrivateSubnet2RouteTableC23CB4A9" + }, + "SubnetId": { + "Ref": "vpc55522232PrivateSubnet2SubnetBF911E75" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet2/RouteTableAssociation" + } + }, + "vpc55522232PrivateSubnet2DefaultRoute306FAD64": { + "Type": "AWS::EC2::Route", + "Properties": { + "DestinationCidrBlock": "0.0.0.0/0", + "NatGatewayId": { + "Ref": "vpc55522232PublicSubnet2NATGatewayCE45ECF6" + }, + "RouteTableId": { + "Ref": "vpc55522232PrivateSubnet2RouteTableC23CB4A9" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet2/DefaultRoute" + } + }, + "vpc55522232PrivateSubnet3SubnetC9D7ECC5": { + "Type": "AWS::EC2::Subnet", + "Properties": { + "AvailabilityZone": "us-east-1c", + "CidrBlock": "10.0.160.0/19", + "MapPublicIpOnLaunch": false, + "Tags": [ + { + "Key": "aws-cdk:subnet-name", + "Value": "Private" + }, + { + "Key": "aws-cdk:subnet-type", + "Value": "Private" + }, + { + "Key": "Name", + "Value": "cdk-stack/vpc-55522232/PrivateSubnet3" + } + ], + "VpcId": { + "Ref": "vpc555222327AFC16C5" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet3/Subnet" + } + }, + "vpc55522232PrivateSubnet3RouteTable571A2BD8": { + "Type": "AWS::EC2::RouteTable", + "Properties": { + "Tags": [ + { + "Key": "Name", + "Value": "cdk-stack/vpc-55522232/PrivateSubnet3" + } + ], + "VpcId": { + "Ref": "vpc555222327AFC16C5" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet3/RouteTable" + } + }, + "vpc55522232PrivateSubnet3RouteTableAssociationF86DE320": { + "Type": "AWS::EC2::SubnetRouteTableAssociation", + "Properties": { + "RouteTableId": { + "Ref": "vpc55522232PrivateSubnet3RouteTable571A2BD8" + }, + "SubnetId": { + "Ref": "vpc55522232PrivateSubnet3SubnetC9D7ECC5" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet3/RouteTableAssociation" + } + }, + "vpc55522232PrivateSubnet3DefaultRoute23A9E99F": { + "Type": "AWS::EC2::Route", + "Properties": { + "DestinationCidrBlock": "0.0.0.0/0", + "NatGatewayId": { + "Ref": "vpc55522232PublicSubnet3NATGateway285C26A6" + }, + "RouteTableId": { + "Ref": "vpc55522232PrivateSubnet3RouteTable571A2BD8" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet3/DefaultRoute" + } + }, + "vpc55522232IGW2124CFCD": { + "Type": "AWS::EC2::InternetGateway", + "Properties": { + "Tags": [ + { + "Key": "Name", + "Value": "cdk-stack/vpc-55522232" + } + ] + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/IGW" + } + }, + "vpc55522232VPCGW0E59A086": { + "Type": "AWS::EC2::VPCGatewayAttachment", + "Properties": { + "InternetGatewayId": { + "Ref": "vpc55522232IGW2124CFCD" + }, + "VpcId": { + "Ref": "vpc555222327AFC16C5" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/vpc-55522232/VPCGW" + } + }, + "alb8A8B13C2": { + "Type": "AWS::ElasticLoadBalancingV2::LoadBalancer", + "Properties": { + "LoadBalancerAttributes": [ + { + "Key": "deletion_protection.enabled", + "Value": "false" + } + ], + "Scheme": "internal", + "SecurityGroups": [ + { + "Fn::GetAtt": [ + "albSecurityGroup49866104", + "GroupId" + ] + } + ], + "Subnets": [ + { + "Ref": "vpc55522232PrivateSubnet1Subnet2E4DA426" + }, + { + "Ref": "vpc55522232PrivateSubnet2SubnetBF911E75" + }, + { + "Ref": "vpc55522232PrivateSubnet3SubnetC9D7ECC5" + } + ], + "Type": "application" + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/alb/Resource" + } + }, + "albSecurityGroup49866104": { + "Type": "AWS::EC2::SecurityGroup", + "Properties": { + "GroupDescription": "Automatically created Security Group for ELB cdkstackalb6DF91EA2", + "SecurityGroupIngress": [ + { + "CidrIp": "0.0.0.0/0", + "Description": "Allow from anyone on port 80", + "FromPort": 80, + "IpProtocol": "tcp", + "ToPort": 80 + } + ], + "VpcId": { + "Ref": "vpc555222327AFC16C5" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/alb/SecurityGroup/Resource" + } + }, + "albSecurityGrouptocdkstackasgInstanceSecurityGroup3E3F3E71809881611E": { + "Type": "AWS::EC2::SecurityGroupEgress", + "Properties": { + "Description": "Load balancer to target", + "DestinationSecurityGroupId": { + "Fn::GetAtt": [ + "asgInstanceSecurityGroup5CEB2975", + "GroupId" + ] + }, + "FromPort": 80, + "GroupId": { + "Fn::GetAtt": [ + "albSecurityGroup49866104", + "GroupId" + ] + }, + "IpProtocol": "tcp", + "ToPort": 80 + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/alb/SecurityGroup/to cdkstackasgInstanceSecurityGroup3E3F3E71:80" + } + }, + "albListener3EA0B2EF": { + "Type": "AWS::ElasticLoadBalancingV2::Listener", + "Properties": { + "DefaultActions": [ + { + "TargetGroupArn": { + "Ref": "albListenerdefaulttargetGroup79BAE92B" + }, + "Type": "forward" + } + ], + "LoadBalancerArn": { + "Ref": "alb8A8B13C2" + }, + "Port": 80, + "Protocol": "HTTP" + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/alb/Listener/Resource" + } + }, + "albListenerdefaulttargetGroup79BAE92B": { + "Type": "AWS::ElasticLoadBalancingV2::TargetGroup", + "Properties": { + "HealthCheckIntervalSeconds": 30, + "HealthCheckPath": "/", + "HealthyThresholdCount": 5, + "Port": 80, + "Protocol": "HTTP", + "TargetGroupAttributes": [ + { + "Key": "stickiness.enabled", + "Value": "false" + } + ], + "TargetType": "instance", + "UnhealthyThresholdCount": 2, + "VpcId": { + "Ref": "vpc555222327AFC16C5" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/alb/Listener/default-targetGroup/Resource" + } + }, + "albListenerstaticRule4F017351": { + "Type": "AWS::ElasticLoadBalancingV2::ListenerRule", + "Properties": { + "Actions": [ + { + "FixedResponseConfig": { + "ContentType": "text/html", + "MessageBody": "

Static ALB Response

", + "StatusCode": "200" + }, + "Type": "fixed-response" + } + ], + "Conditions": [ + { + "Field": "path-pattern", + "PathPatternConfig": { + "Values": [ + "/static" + ] + } + } + ], + "ListenerArn": { + "Ref": "albListener3EA0B2EF" + }, + "Priority": 5 + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/alb/Listener/--staticRule/Resource" + } + }, + "asgInstanceSecurityGroup5CEB2975": { + "Type": "AWS::EC2::SecurityGroup", + "Properties": { + "GroupDescription": "cdk-stack/asg/InstanceSecurityGroup", + "SecurityGroupEgress": [ + { + "CidrIp": "0.0.0.0/0", + "Description": "Allow all outbound traffic by default", + "IpProtocol": "-1" + } + ], + "Tags": [ + { + "Key": "Name", + "Value": "cdk-stack/asg" + } + ], + "VpcId": { + "Ref": "vpc555222327AFC16C5" + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/asg/InstanceSecurityGroup/Resource" + } + }, + "asgInstanceSecurityGroupfromcdkstackalbSecurityGroup20A8C03080818D6412": { + "Type": "AWS::EC2::SecurityGroupIngress", + "Properties": { + "Description": "Load balancer to target", + "FromPort": 80, + "GroupId": { + "Fn::GetAtt": [ + "asgInstanceSecurityGroup5CEB2975", + "GroupId" + ] + }, + "IpProtocol": "tcp", + "SourceSecurityGroupId": { + "Fn::GetAtt": [ + "albSecurityGroup49866104", + "GroupId" + ] + }, + "ToPort": 80 + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/asg/InstanceSecurityGroup/from cdkstackalbSecurityGroup20A8C030:80" + } + }, + "asgInstanceRole8AC4201C": { + "Type": "AWS::IAM::Role", + "Properties": { + "AssumeRolePolicyDocument": { + "Statement": [ + { + "Action": "sts:AssumeRole", + "Effect": "Allow", + "Principal": { + "Service": "ec2.amazonaws.com" + } + } + ], + "Version": "2012-10-17" + }, + "Tags": [ + { + "Key": "Name", + "Value": "cdk-stack/asg" + } + ] + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/asg/InstanceRole/Resource" + } + }, + "asgInstanceProfile4E44E320": { + "Type": "AWS::IAM::InstanceProfile", + "Properties": { + "Roles": [ + { + "Ref": "asgInstanceRole8AC4201C" + } + ] + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/asg/InstanceProfile" + } + }, + "asgLaunchConfig37FDE42B": { + "Type": "AWS::AutoScaling::LaunchConfiguration", + "Properties": { + "IamInstanceProfile": { + "Ref": "asgInstanceProfile4E44E320" + }, + "ImageId": { + "Ref": "SsmParameterValueawsserviceamiamazonlinuxlatestamzn2amihvmx8664gp2C96584B6F00A464EAD1953AFF4B05118Parameter" + }, + "InstanceType": "t2.micro", + "SecurityGroups": [ + { + "Fn::GetAtt": [ + "asgInstanceSecurityGroup5CEB2975", + "GroupId" + ] + } + ], + "UserData": { + "Fn::Base64": "#!/bin/bash\nsudo su\nyum install -y httpd\nsystemctl start httpd\nsystemctl enable httpd\necho \"

Hello World from $(hostname -f)

\" > /var/www/html/index.html" + } + }, + "DependsOn": [ + "asgInstanceRole8AC4201C" + ], + "Metadata": { + "aws:cdk:path": "cdk-stack/asg/LaunchConfig" + } + }, + "asgASG4D014670": { + "Type": "AWS::AutoScaling::AutoScalingGroup", + "Properties": { + "LaunchConfigurationName": { + "Ref": "asgLaunchConfig37FDE42B" + }, + "MaxSize": "3", + "MinSize": "2", + "Tags": [ + { + "Key": "Name", + "PropagateAtLaunch": true, + "Value": "cdk-stack/asg" + } + ], + "TargetGroupARNs": [ + { + "Ref": "albListenerdefaulttargetGroup79BAE92B" + } + ], + "VPCZoneIdentifier": [ + { + "Ref": "vpc55522232PrivateSubnet1Subnet2E4DA426" + }, + { + "Ref": "vpc55522232PrivateSubnet2SubnetBF911E75" + }, + { + "Ref": "vpc55522232PrivateSubnet3SubnetC9D7ECC5" + } + ] + }, + "UpdatePolicy": { + "AutoScalingScheduledAction": { + "IgnoreUnmodifiedGroupSizeProperties": true + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/asg/ASG" + } + }, + "asgScalingPolicyrequestsperminute5D73703F": { + "Type": "AWS::AutoScaling::ScalingPolicy", + "Properties": { + "AutoScalingGroupName": { + "Ref": "asgASG4D014670" + }, + "PolicyType": "TargetTrackingScaling", + "TargetTrackingConfiguration": { + "PredefinedMetricSpecification": { + "PredefinedMetricType": "ALBRequestCountPerTarget", + "ResourceLabel": { + "Fn::Join": [ + "", + [ + { + "Fn::Select": [ + 1, + { + "Fn::Split": [ + "/", + { + "Ref": "albListener3EA0B2EF" + } + ] + } + ] + }, + "/", + { + "Fn::Select": [ + 2, + { + "Fn::Split": [ + "/", + { + "Ref": "albListener3EA0B2EF" + } + ] + } + ] + }, + "/", + { + "Fn::Select": [ + 3, + { + "Fn::Split": [ + "/", + { + "Ref": "albListener3EA0B2EF" + } + ] + } + ] + }, + "/", + { + "Fn::GetAtt": [ + "albListenerdefaulttargetGroup79BAE92B", + "TargetGroupFullName" + ] + } + ] + ] + } + }, + "TargetValue": 60 + } + }, + "DependsOn": [ + "albListenerstaticRule4F017351", + "albListenerdefaulttargetGroup79BAE92B", + "albListener3EA0B2EF" + ], + "Metadata": { + "aws:cdk:path": "cdk-stack/asg/ScalingPolicyrequests-per-minute/Resource" + } + }, + "asgScalingPolicycpuutilscaling06365506": { + "Type": "AWS::AutoScaling::ScalingPolicy", + "Properties": { + "AutoScalingGroupName": { + "Ref": "asgASG4D014670" + }, + "PolicyType": "TargetTrackingScaling", + "TargetTrackingConfiguration": { + "PredefinedMetricSpecification": { + "PredefinedMetricType": "ASGAverageCPUUtilization" + }, + "TargetValue": 75 + } + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/asg/ScalingPolicycpu-util-scaling/Resource" + } + }, + "CDKMetadata": { + "Type": "AWS::CDK::Metadata", + "Properties": { + "Analytics": "v2:deflate64:H4sIAAAAAAAA/31Sy27CMBD8Fu7GFbQ99EgRQpFQGyWIa7UxSzAkdmSvQSjKv9d5kSCqnnZndrQejz3nH+98NoGrnYr9eZrJhJcxgTgzT/2UKOa83BWCLQ9qFy5Z6JJMitglCqnmhi7SjnALSYYDP3ALa7WQQFKru7huVkFYly+gNRBe4cZCIy++HRYHitD4vhe0Tjq0IO/1mKMiFqNwRtJtbbQrGg//EqvUoLVPdKAavmKYgSUpMg37BDJQQqr04sNYFIVPoLnJxs8+mxmaetEDHuukJVSdpu9H8y2Y1N+vtzmGf2yJXBvxGFcMHGkrIPMuvUcP4hbct27AKXFcanWQqTP3l3iStqdvjf8CnutGofYumugfiIpJyHkZ6dZRXwNlqQ4hNPogvbmKRWi1M6KZhmAgR2rj+HZUuPb/dJKKKb1HfrIvl9kbn8/46+RkpZwap0jmyKO2/gL2/416uAIAAA==" + }, + "Metadata": { + "aws:cdk:path": "cdk-stack/CDKMetadata/Default" + } + } + }, + "Parameters": { + "SsmParameterValueawsserviceamiamazonlinuxlatestamzn2amihvmx8664gp2C96584B6F00A464EAD1953AFF4B05118Parameter": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/aws/service/ami-amazon-linux-latest/amzn2-ami-hvm-x86_64-gp2" + }, + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Outputs": { + "albDNS": { + "Value": { + "Fn::GetAtt": [ + "alb8A8B13C2", + "DNSName" + ] + } + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/cdk.out/cdk.out b/cdk.out/cdk.out new file mode 100644 index 000000000..2313ab543 --- /dev/null +++ b/cdk.out/cdk.out @@ -0,0 +1 @@ +{"version":"34.0.0"} \ No newline at end of file diff --git a/cdk.out/manifest.json b/cdk.out/manifest.json new file mode 100644 index 000000000..7647b8e69 --- /dev/null +++ b/cdk.out/manifest.json @@ -0,0 +1,106 @@ +{ + "version": "34.0.0", + "artifacts": { + "stage-alb-stack.assets": { + "type": "cdk:asset-manifest", + "properties": { + "file": "stage-alb-stack.assets.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "stage-alb-stack": { + "type": "aws:cloudformation:stack", + "environment": "aws://100225593120/us-east-1", + "properties": { + "templateFile": "stage-alb-stack.template.json", + "validateOnSynth": false, + "assumeRoleArn": "arn:${AWS::Partition}:iam::100225593120:role/cdk-hnb659fds-deploy-role-100225593120-us-east-1", + "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::100225593120:role/cdk-hnb659fds-cfn-exec-role-100225593120-us-east-1", + "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-100225593120-us-east-1/3a2577e14946ca0614397f637d69c1a3786b28baa3a527e7bc1dc110e89ce09b.json", + "requiresBootstrapStackVersion": 6, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", + "additionalDependencies": [ + "stage-alb-stack.assets" + ], + "lookupRole": { + "arn": "arn:${AWS::Partition}:iam::100225593120:role/cdk-hnb659fds-lookup-role-100225593120-us-east-1", + "requiresBootstrapStackVersion": 8, + "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" + } + }, + "dependencies": [ + "stage-alb-stack.assets" + ], + "metadata": { + "/stage-alb-stack/default/from 0.0.0.0_0:443": [ + { + "type": "aws:cdk:logicalId", + "data": "defaultfrom00000443FDCE37BB" + } + ], + "/stage-alb-stack/alb/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "alb8A8B13C2" + } + ], + "/stage-alb-stack/alb/HTTPS Listener/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "albHTTPSListener7C8C4C55" + } + ], + "/stage-alb-stack/alb/HTTPS Listener/Backend StageGroup/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "albHTTPSListenerBackendStageGroup18A8DB5E" + } + ], + "/stage-alb-stack/Public DNS/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PublicDNSD41885E8" + } + ], + "/stage-alb-stack/Private DNS/Resource": [ + { + "type": "aws:cdk:logicalId", + "data": "PrivateDNSEACE6CB2" + } + ], + "/stage-alb-stack/albDNS": [ + { + "type": "aws:cdk:logicalId", + "data": "albDNS" + } + ], + "/stage-alb-stack/CDKMetadata/Default": [ + { + "type": "aws:cdk:logicalId", + "data": "CDKMetadata" + } + ], + "/stage-alb-stack/BootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "BootstrapVersion" + } + ], + "/stage-alb-stack/CheckBootstrapVersion": [ + { + "type": "aws:cdk:logicalId", + "data": "CheckBootstrapVersion" + } + ] + }, + "displayName": "stage-alb-stack" + }, + "Tree": { + "type": "cdk:tree", + "properties": { + "file": "tree.json" + } + } + } +} \ No newline at end of file diff --git a/cdk.out/stage-alb-stack.assets.json b/cdk.out/stage-alb-stack.assets.json new file mode 100644 index 000000000..62cd4b0d1 --- /dev/null +++ b/cdk.out/stage-alb-stack.assets.json @@ -0,0 +1,20 @@ +{ + "version": "34.0.0", + "files": { + "3a2577e14946ca0614397f637d69c1a3786b28baa3a527e7bc1dc110e89ce09b": { + "source": { + "path": "stage-alb-stack.template.json", + "packaging": "file" + }, + "destinations": { + "100225593120-us-east-1": { + "bucketName": "cdk-hnb659fds-assets-100225593120-us-east-1", + "objectKey": "3a2577e14946ca0614397f637d69c1a3786b28baa3a527e7bc1dc110e89ce09b.json", + "region": "us-east-1", + "assumeRoleArn": "arn:${AWS::Partition}:iam::100225593120:role/cdk-hnb659fds-file-publishing-role-100225593120-us-east-1" + } + } + } + }, + "dockerImages": {} +} \ No newline at end of file diff --git a/cdk.out/stage-alb-stack.template.json b/cdk.out/stage-alb-stack.template.json new file mode 100644 index 000000000..fb15d30e1 --- /dev/null +++ b/cdk.out/stage-alb-stack.template.json @@ -0,0 +1,186 @@ +{ + "Resources": { + "defaultfrom00000443FDCE37BB": { + "Type": "AWS::EC2::SecurityGroupIngress", + "Properties": { + "CidrIp": "0.0.0.0/0", + "Description": "Allow from anyone on port 443", + "FromPort": 443, + "GroupId": "sg-21ac675b", + "IpProtocol": "tcp", + "ToPort": 443 + }, + "Metadata": { + "aws:cdk:path": "stage-alb-stack/default/from 0.0.0.0_0:443" + } + }, + "alb8A8B13C2": { + "Type": "AWS::ElasticLoadBalancingV2::LoadBalancer", + "Properties": { + "LoadBalancerAttributes": [ + { + "Key": "deletion_protection.enabled", + "Value": "false" + } + ], + "Scheme": "internal", + "SecurityGroups": [ + "sg-21ac675b" + ], + "Subnets": [ + "subnet-0d4703177afb1797d", + "subnet-04262fc338f638054", + "subnet-044457c061edf85f2", + "subnet-04019d42d5c9e6fb9", + "subnet-049778993fb504a7c" + ], + "Type": "application" + }, + "Metadata": { + "aws:cdk:path": "stage-alb-stack/alb/Resource" + } + }, + "albHTTPSListener7C8C4C55": { + "Type": "AWS::ElasticLoadBalancingV2::Listener", + "Properties": { + "Certificates": [ + { + "CertificateArn": "arn:aws:acm:us-east-1:100225593120:certificate/047a56a2-09dd-4857-9f28-32d23650d4da" + } + ], + "DefaultActions": [ + { + "TargetGroupArn": { + "Ref": "albHTTPSListenerBackendStageGroup18A8DB5E" + }, + "Type": "forward" + } + ], + "LoadBalancerArn": { + "Ref": "alb8A8B13C2" + }, + "Port": 443, + "Protocol": "HTTPS" + }, + "Metadata": { + "aws:cdk:path": "stage-alb-stack/alb/HTTPS Listener/Resource" + } + }, + "albHTTPSListenerBackendStageGroup18A8DB5E": { + "Type": "AWS::ElasticLoadBalancingV2::TargetGroup", + "Properties": { + "Port": 443, + "Protocol": "HTTPS", + "TargetGroupAttributes": [ + { + "Key": "stickiness.enabled", + "Value": "false" + } + ], + "TargetType": "instance", + "Targets": [ + { + "Id": "i-0d7ea7b7cc11a2e8f" + } + ], + "VpcId": "vpc-55522232" + }, + "Metadata": { + "aws:cdk:path": "stage-alb-stack/alb/HTTPS Listener/Backend StageGroup/Resource" + } + }, + "PublicDNSD41885E8": { + "Type": "AWS::Route53::RecordSet", + "Properties": { + "HostedZoneId": "Z3IZ3D6V94JEC2", + "Name": "stage-alb.alliancegenome.org.", + "ResourceRecords": [ + { + "Fn::GetAtt": [ + "alb8A8B13C2", + "DNSName" + ] + } + ], + "TTL": "300", + "Type": "CNAME" + }, + "Metadata": { + "aws:cdk:path": "stage-alb-stack/Public DNS/Resource" + } + }, + "PrivateDNSEACE6CB2": { + "Type": "AWS::Route53::RecordSet", + "Properties": { + "HostedZoneId": "Z007692222A6W93AZVSPD", + "Name": "stage-alb.alliancegenome.org.", + "ResourceRecords": [ + { + "Fn::GetAtt": [ + "alb8A8B13C2", + "DNSName" + ] + } + ], + "TTL": "300", + "Type": "CNAME" + }, + "Metadata": { + "aws:cdk:path": "stage-alb-stack/Private DNS/Resource" + } + }, + "CDKMetadata": { + "Type": "AWS::CDK::Metadata", + "Properties": { + "Analytics": "v2:deflate64:H4sIAAAAAAAA/1WPsWrDQAyGnyX7WcVOM3RsM5RCoWBnL4qsGiUXnbnTJRTjd68dt+Aukn6+DwlV8LSDcoO3VFB7LrwcYWgM6exqTiFHYjexz4Gpgv2XNkw5in2/xpD7N+0ip+TYYzIhH7A9okcl0e5awfDc914ITYK+T+zlzji6ac+/vPYkGeuv8zev+AFjx3a/PiurOLqpGu+2MOwVL1wzhdjO0jI1bOM4x49sfbYFLB+OTkPLcEoP1/IRqhK2m1MSKWJWkwtDvfQfzO4j0CsBAAA=" + }, + "Metadata": { + "aws:cdk:path": "stage-alb-stack/CDKMetadata/Default" + } + } + }, + "Outputs": { + "albDNS": { + "Value": { + "Fn::GetAtt": [ + "alb8A8B13C2", + "DNSName" + ] + } + } + }, + "Parameters": { + "BootstrapVersion": { + "Type": "AWS::SSM::Parameter::Value", + "Default": "/cdk-bootstrap/hnb659fds/version", + "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" + } + }, + "Rules": { + "CheckBootstrapVersion": { + "Assertions": [ + { + "Assert": { + "Fn::Not": [ + { + "Fn::Contains": [ + [ + "1", + "2", + "3", + "4", + "5" + ], + { + "Ref": "BootstrapVersion" + } + ] + } + ] + }, + "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." + } + ] + } + } +} \ No newline at end of file diff --git a/cdk.out/tree.json b/cdk.out/tree.json new file mode 100644 index 000000000..d397d1053 --- /dev/null +++ b/cdk.out/tree.json @@ -0,0 +1,398 @@ +{ + "version": "tree-0.1", + "tree": { + "id": "App", + "path": "", + "children": { + "stage-alb-stack": { + "id": "stage-alb-stack", + "path": "stage-alb-stack", + "children": { + "Docker": { + "id": "Docker", + "path": "stage-alb-stack/Docker", + "children": { + "PublicSubnet1": { + "id": "PublicSubnet1", + "path": "stage-alb-stack/Docker/PublicSubnet1", + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "2.95.1" + } + }, + "PublicSubnet2": { + "id": "PublicSubnet2", + "path": "stage-alb-stack/Docker/PublicSubnet2", + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "2.95.1" + } + }, + "PublicSubnet3": { + "id": "PublicSubnet3", + "path": "stage-alb-stack/Docker/PublicSubnet3", + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "2.95.1" + } + }, + "PublicSubnet4": { + "id": "PublicSubnet4", + "path": "stage-alb-stack/Docker/PublicSubnet4", + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "2.95.1" + } + }, + "PublicSubnet5": { + "id": "PublicSubnet5", + "path": "stage-alb-stack/Docker/PublicSubnet5", + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "2.95.1" + } + }, + "PrivateSubnet1": { + "id": "PrivateSubnet1", + "path": "stage-alb-stack/Docker/PrivateSubnet1", + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "2.95.1" + } + }, + "PrivateSubnet2": { + "id": "PrivateSubnet2", + "path": "stage-alb-stack/Docker/PrivateSubnet2", + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "2.95.1" + } + }, + "PrivateSubnet3": { + "id": "PrivateSubnet3", + "path": "stage-alb-stack/Docker/PrivateSubnet3", + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "2.95.1" + } + }, + "PrivateSubnet4": { + "id": "PrivateSubnet4", + "path": "stage-alb-stack/Docker/PrivateSubnet4", + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "2.95.1" + } + }, + "PrivateSubnet5": { + "id": "PrivateSubnet5", + "path": "stage-alb-stack/Docker/PrivateSubnet5", + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "2.95.1" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "2.95.1" + } + }, + "default": { + "id": "default", + "path": "stage-alb-stack/default", + "children": { + "from 0.0.0.0_0:443": { + "id": "from 0.0.0.0_0:443", + "path": "stage-alb-stack/default/from 0.0.0.0_0:443", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::EC2::SecurityGroupIngress", + "aws:cdk:cloudformation:props": { + "cidrIp": "0.0.0.0/0", + "description": "Allow from anyone on port 443", + "fromPort": 443, + "groupId": "sg-21ac675b", + "ipProtocol": "tcp", + "toPort": 443 + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroupIngress", + "version": "2.95.1" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "2.95.1" + } + }, + "Public Zone": { + "id": "Public Zone", + "path": "stage-alb-stack/Public Zone", + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "2.95.1" + } + }, + "Private Zone": { + "id": "Private Zone", + "path": "stage-alb-stack/Private Zone", + "constructInfo": { + "fqn": "aws-cdk-lib.Resource", + "version": "2.95.1" + } + }, + "alb": { + "id": "alb", + "path": "stage-alb-stack/alb", + "children": { + "Resource": { + "id": "Resource", + "path": "stage-alb-stack/alb/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::ElasticLoadBalancingV2::LoadBalancer", + "aws:cdk:cloudformation:props": { + "loadBalancerAttributes": [ + { + "key": "deletion_protection.enabled", + "value": "false" + } + ], + "scheme": "internal", + "securityGroups": [ + "sg-21ac675b" + ], + "subnets": [ + "subnet-0d4703177afb1797d", + "subnet-04262fc338f638054", + "subnet-044457c061edf85f2", + "subnet-04019d42d5c9e6fb9", + "subnet-049778993fb504a7c" + ], + "type": "application" + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.CfnLoadBalancer", + "version": "2.95.1" + } + }, + "HTTPS Listener": { + "id": "HTTPS Listener", + "path": "stage-alb-stack/alb/HTTPS Listener", + "children": { + "Resource": { + "id": "Resource", + "path": "stage-alb-stack/alb/HTTPS Listener/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::ElasticLoadBalancingV2::Listener", + "aws:cdk:cloudformation:props": { + "certificates": [ + { + "certificateArn": "arn:aws:acm:us-east-1:100225593120:certificate/047a56a2-09dd-4857-9f28-32d23650d4da" + } + ], + "defaultActions": [ + { + "type": "forward", + "targetGroupArn": { + "Ref": "albHTTPSListenerBackendStageGroup18A8DB5E" + } + } + ], + "loadBalancerArn": { + "Ref": "alb8A8B13C2" + }, + "port": 443, + "protocol": "HTTPS" + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.CfnListener", + "version": "2.95.1" + } + }, + "Backend StageGroup": { + "id": "Backend StageGroup", + "path": "stage-alb-stack/alb/HTTPS Listener/Backend StageGroup", + "children": { + "Resource": { + "id": "Resource", + "path": "stage-alb-stack/alb/HTTPS Listener/Backend StageGroup/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::ElasticLoadBalancingV2::TargetGroup", + "aws:cdk:cloudformation:props": { + "port": 443, + "protocol": "HTTPS", + "targetGroupAttributes": [ + { + "key": "stickiness.enabled", + "value": "false" + } + ], + "targets": [ + { + "id": "i-0d7ea7b7cc11a2e8f" + } + ], + "targetType": "instance", + "vpcId": "vpc-55522232" + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.CfnTargetGroup", + "version": "2.95.1" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationTargetGroup", + "version": "2.95.1" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationListener", + "version": "2.95.1" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationLoadBalancer", + "version": "2.95.1" + } + }, + "Public DNS": { + "id": "Public DNS", + "path": "stage-alb-stack/Public DNS", + "children": { + "Resource": { + "id": "Resource", + "path": "stage-alb-stack/Public DNS/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::Route53::RecordSet", + "aws:cdk:cloudformation:props": { + "hostedZoneId": "Z3IZ3D6V94JEC2", + "name": "stage-alb.alliancegenome.org.", + "resourceRecords": [ + { + "Fn::GetAtt": [ + "alb8A8B13C2", + "DNSName" + ] + } + ], + "ttl": "300", + "type": "CNAME" + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_route53.CfnRecordSet", + "version": "2.95.1" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_route53.CnameRecord", + "version": "2.95.1" + } + }, + "Private DNS": { + "id": "Private DNS", + "path": "stage-alb-stack/Private DNS", + "children": { + "Resource": { + "id": "Resource", + "path": "stage-alb-stack/Private DNS/Resource", + "attributes": { + "aws:cdk:cloudformation:type": "AWS::Route53::RecordSet", + "aws:cdk:cloudformation:props": { + "hostedZoneId": "Z007692222A6W93AZVSPD", + "name": "stage-alb.alliancegenome.org.", + "resourceRecords": [ + { + "Fn::GetAtt": [ + "alb8A8B13C2", + "DNSName" + ] + } + ], + "ttl": "300", + "type": "CNAME" + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_route53.CfnRecordSet", + "version": "2.95.1" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.aws_route53.CnameRecord", + "version": "2.95.1" + } + }, + "albDNS": { + "id": "albDNS", + "path": "stage-alb-stack/albDNS", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnOutput", + "version": "2.95.1" + } + }, + "CDKMetadata": { + "id": "CDKMetadata", + "path": "stage-alb-stack/CDKMetadata", + "children": { + "Default": { + "id": "Default", + "path": "stage-alb-stack/CDKMetadata/Default", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnResource", + "version": "2.95.1" + } + } + }, + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.2.70" + } + }, + "BootstrapVersion": { + "id": "BootstrapVersion", + "path": "stage-alb-stack/BootstrapVersion", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnParameter", + "version": "2.95.1" + } + }, + "CheckBootstrapVersion": { + "id": "CheckBootstrapVersion", + "path": "stage-alb-stack/CheckBootstrapVersion", + "constructInfo": { + "fqn": "aws-cdk-lib.CfnRule", + "version": "2.95.1" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.Stack", + "version": "2.95.1" + } + }, + "Tree": { + "id": "Tree", + "path": "Tree", + "constructInfo": { + "fqn": "constructs.Construct", + "version": "10.2.70" + } + } + }, + "constructInfo": { + "fqn": "aws-cdk-lib.App", + "version": "2.95.1" + } + } +} \ No newline at end of file diff --git a/cdk/cdk-stage.ts b/cdk/cdk-stage.ts new file mode 100644 index 000000000..1514b7b37 --- /dev/null +++ b/cdk/cdk-stage.ts @@ -0,0 +1,13 @@ +#!/usr/bin/env node +import * as cdk from 'aws-cdk-lib'; +import {StageALBStack} from './stage-alb-stack'; + +const app = new cdk.App(); + +new StageALBStack(app, 'stage-alb-stack', { + stackName: 'stage-alb-stack', + env: { + region: process.env.CDK_DEFAULT_REGION, + account: process.env.CDK_DEFAULT_ACCOUNT, + }, +}); diff --git a/cdk/stage-alb-stack.ts b/cdk/stage-alb-stack.ts new file mode 100644 index 000000000..0f67ef573 --- /dev/null +++ b/cdk/stage-alb-stack.ts @@ -0,0 +1,54 @@ +import * as autoscaling from 'aws-cdk-lib/aws-autoscaling'; +import * as ec2 from 'aws-cdk-lib/aws-ec2'; +import * as route53 from 'aws-cdk-lib/aws-route53'; +import * as route53Targets from 'aws-cdk-lib/aws-route53-targets'; +import * as elbv2 from 'aws-cdk-lib/aws-elasticloadbalancingv2'; +import * as targets from 'aws-cdk-lib/aws-elasticloadbalancingv2-targets'; +import * as cdk from 'aws-cdk-lib'; + +export class StageALBStack extends cdk.Stack { + constructor(scope: cdk.App, id: string, props?: cdk.StackProps) { + super(scope, id, props); + + const vpc = ec2.Vpc.fromLookup(this, 'Docker', { vpcName: 'Docker' }); + const sg = ec2.SecurityGroup.fromLookupById(this, 'default', 'sg-21ac675b'); + const cert = elbv2.ListenerCertificate.fromArn('arn:aws:acm:us-east-1:100225593120:certificate/047a56a2-09dd-4857-9f28-32d23650d4da'); + const stage = new targets.InstanceIdTarget('i-0d7ea7b7cc11a2e8f') + const public_zone = route53.HostedZone.fromHostedZoneAttributes(this, 'Public Zone', { zoneName: 'alliancegenome.org', hostedZoneId: 'Z3IZ3D6V94JEC2' }); + const private_zone = route53.HostedZone.fromHostedZoneAttributes(this, 'Private Zone', { zoneName: 'alliancegenome.org', hostedZoneId: 'Z007692222A6W93AZVSPD' }); + + const alb = new elbv2.ApplicationLoadBalancer(this, 'alb', { + vpc, + internetFacing: false, + securityGroup: sg + }); + + new route53.CnameRecord(this, "Public DNS", { + zone: public_zone, + recordName: "stage-alb", + domainName: alb.loadBalancerDnsName, + ttl: cdk.Duration.minutes(5) + }); + new route53.CnameRecord(this, "Private DNS", { + zone: private_zone, + recordName: "stage-alb", + domainName: alb.loadBalancerDnsName, + ttl: cdk.Duration.minutes(5) + }); + + const listener = alb.addListener('HTTPS Listener', { + port: 443, + open: true, + certificates: [cert] + }); + + listener.addTargets("Backend Stage", { + port: 443, + targets: [stage] + }); + + new cdk.CfnOutput(this, 'albDNS', { + value: alb.loadBalancerDnsName + }); + } +} diff --git a/package.json b/package.json index dc8bba819..35e4ec9f1 100644 --- a/package.json +++ b/package.json @@ -41,7 +41,11 @@ "@testing-library/jest-dom": "^5.16.1", "abortcontroller-polyfill": "^1.5.0", "agr_genomefeaturecomponent": "^0.3.24", + "aws-cdk": "^2.95.1", + "aws-cdk-lib": "^2.95.1", + "aws-lambda": "^1.0.7", "bootstrap": "4.6.1", + "constructs": "^10.2.70", "core-js": "^3.6.5", "custom-event-polyfill": "^1.0.6", "d3-selection": "2.0.0", @@ -85,6 +89,7 @@ "regenerator-runtime": "^0.13.7", "reselect": "^2.5.4", "sitemap": "^1.13.0", + "source-map-support": "^0.5.21", "tslib": "^2.0.0", "twin.macro": "2.2.3", "whatwg-fetch": "^3.4.0" diff --git a/tsconfig.json b/tsconfig.json new file mode 100644 index 000000000..f26d10908 --- /dev/null +++ b/tsconfig.json @@ -0,0 +1,32 @@ +{ + "compilerOptions": { + "target": "ES2018", + "module": "commonjs", + "lib": ["es2018", "ESNext.AsyncIterable"], + "allowJs": true, + "checkJs": true, + "removeComments": true, + "resolveJsonModule": true, + "declaration": true, + "strict": true, + "noImplicitAny": true, + "strictNullChecks": true, + "strictPropertyInitialization": true, + "noImplicitThis": true, + "alwaysStrict": true, + "noUnusedLocals": false, + "noUnusedParameters": false, + "noImplicitReturns": true, + "noFallthroughCasesInSwitch": true, + "esModuleInterop": true, + "allowSyntheticDefaultImports": true, + "inlineSourceMap": true, + "inlineSources": true, + "skipLibCheck": true, + "forceConsistentCasingInFileNames": true, + "experimentalDecorators": true, + "typeRoots": ["./node_modules/@types"], + "isolatedModules": true + }, + "exclude": ["node_modules", "**/node_modules/*", "cdk.out"] +} From 80a2de26e28a9f7081bc87eac3ff911e88b45c20 Mon Sep 17 00:00:00 2001 From: Olin Blodgett Date: Mon, 11 Sep 2023 17:05:04 -0400 Subject: [PATCH 62/85] Removed specific impl files --- .gitignore | 3 + cdk-outputs.json | 5 - cdk.context.json | 98 --- cdk.out/cdk-stack.assets.json | 20 - cdk.out/cdk-stack.template.json | 1097 ------------------------- cdk.out/cdk.out | 1 - cdk.out/manifest.json | 106 --- cdk.out/stage-alb-stack.assets.json | 20 - cdk.out/stage-alb-stack.template.json | 186 ----- cdk.out/tree.json | 398 --------- 10 files changed, 3 insertions(+), 1931 deletions(-) delete mode 100644 cdk-outputs.json delete mode 100644 cdk.context.json delete mode 100644 cdk.out/cdk-stack.assets.json delete mode 100644 cdk.out/cdk-stack.template.json delete mode 100644 cdk.out/cdk.out delete mode 100644 cdk.out/manifest.json delete mode 100644 cdk.out/stage-alb-stack.assets.json delete mode 100644 cdk.out/stage-alb-stack.template.json delete mode 100644 cdk.out/tree.json diff --git a/.gitignore b/.gitignore index 25cdc69bd..90d75eaa9 100644 --- a/.gitignore +++ b/.gitignore @@ -46,3 +46,6 @@ Thumbs.db *.swp +cdk-outputs.json +cdk.context.json +cdk.out diff --git a/cdk-outputs.json b/cdk-outputs.json deleted file mode 100644 index 8278425ae..000000000 --- a/cdk-outputs.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stage-alb-stack": { - "albDNS": "internal-stage-alb8A-D8N9BHZDT6F2-1821793229.us-east-1.elb.amazonaws.com" - } -} diff --git a/cdk.context.json b/cdk.context.json deleted file mode 100644 index 6e5c33c0e..000000000 --- a/cdk.context.json +++ /dev/null @@ -1,98 +0,0 @@ -{ - "availability-zones:account=100225593120:region=us-east-1": [ - "us-east-1a", - "us-east-1b", - "us-east-1c", - "us-east-1d", - "us-east-1e", - "us-east-1f" - ], - "vpc-provider:account=100225593120:filter.tag:Name=Docker:region=us-east-1:returnAsymmetricSubnets=true": { - "vpcId": "vpc-55522232", - "vpcCidrBlock": "172.31.0.0/16", - "ownerAccountId": "100225593120", - "availabilityZones": [], - "subnetGroups": [ - { - "name": "Public", - "type": "Public", - "subnets": [ - { - "subnetId": "subnet-3ebf4477", - "cidr": "172.31.0.0/20", - "availabilityZone": "us-east-1a", - "routeTableId": "rtb-c63af6a0" - }, - { - "subnetId": "subnet-df7c7487", - "cidr": "172.31.16.0/20", - "availabilityZone": "us-east-1b", - "routeTableId": "rtb-c63af6a0" - }, - { - "subnetId": "subnet-81c95ee4", - "cidr": "172.31.64.0/20", - "availabilityZone": "us-east-1c", - "routeTableId": "rtb-c63af6a0" - }, - { - "subnetId": "subnet-ff838bd5", - "cidr": "172.31.48.0/20", - "availabilityZone": "us-east-1d", - "routeTableId": "rtb-c63af6a0" - }, - { - "subnetId": "subnet-af62dca3", - "cidr": "172.31.80.0/20", - "availabilityZone": "us-east-1f", - "routeTableId": "rtb-c63af6a0" - } - ] - }, - { - "name": "Private", - "type": "Private", - "subnets": [ - { - "subnetId": "subnet-0d4703177afb1797d", - "cidr": "172.31.96.0/24", - "availabilityZone": "us-east-1a", - "routeTableId": "rtb-05e12b551f60b37ed" - }, - { - "subnetId": "subnet-04262fc338f638054", - "cidr": "172.31.97.0/24", - "availabilityZone": "us-east-1b", - "routeTableId": "rtb-05e12b551f60b37ed" - }, - { - "subnetId": "subnet-044457c061edf85f2", - "cidr": "172.31.98.0/24", - "availabilityZone": "us-east-1c", - "routeTableId": "rtb-05e12b551f60b37ed" - }, - { - "subnetId": "subnet-04019d42d5c9e6fb9", - "cidr": "172.31.99.0/24", - "availabilityZone": "us-east-1d", - "routeTableId": "rtb-05e12b551f60b37ed" - }, - { - "subnetId": "subnet-049778993fb504a7c", - "cidr": "172.31.101.0/24", - "availabilityZone": "us-east-1f", - "routeTableId": "rtb-05e12b551f60b37ed" - } - ] - } - ] - }, - "security-group:account=100225593120:region=us-east-1:securityGroupName=default:vpcId=vpc-55522232": { - "securityGroupId": "sg-21ac675b", - "allowAllOutbound": false - }, - "security-group:account=100225593120:region=us-east-1:securityGroupId=sg-21ac675b": { - "securityGroupId": "sg-21ac675b", - "allowAllOutbound": false - } -} diff --git a/cdk.out/cdk-stack.assets.json b/cdk.out/cdk-stack.assets.json deleted file mode 100644 index 3c6354600..000000000 --- a/cdk.out/cdk-stack.assets.json +++ /dev/null @@ -1,20 +0,0 @@ -{ - "version": "34.0.0", - "files": { - "a4518594ba7b9be03de79203ec8a1006b42513fd59d1dc48d55538a9f27e9c4a": { - "source": { - "path": "cdk-stack.template.json", - "packaging": "file" - }, - "destinations": { - "100225593120-us-east-1": { - "bucketName": "cdk-hnb659fds-assets-100225593120-us-east-1", - "objectKey": "a4518594ba7b9be03de79203ec8a1006b42513fd59d1dc48d55538a9f27e9c4a.json", - "region": "us-east-1", - "assumeRoleArn": "arn:${AWS::Partition}:iam::100225593120:role/cdk-hnb659fds-file-publishing-role-100225593120-us-east-1" - } - } - } - }, - "dockerImages": {} -} \ No newline at end of file diff --git a/cdk.out/cdk-stack.template.json b/cdk.out/cdk-stack.template.json deleted file mode 100644 index 7d2dde57f..000000000 --- a/cdk.out/cdk-stack.template.json +++ /dev/null @@ -1,1097 +0,0 @@ -{ - "Resources": { - "vpc555222327AFC16C5": { - "Type": "AWS::EC2::VPC", - "Properties": { - "CidrBlock": "10.0.0.0/16", - "EnableDnsHostnames": true, - "EnableDnsSupport": true, - "InstanceTenancy": "default", - "Tags": [ - { - "Key": "Name", - "Value": "cdk-stack/vpc-55522232" - } - ] - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/Resource" - } - }, - "vpc55522232PublicSubnet1Subnet8C1D3F0B": { - "Type": "AWS::EC2::Subnet", - "Properties": { - "AvailabilityZone": "us-east-1a", - "CidrBlock": "10.0.0.0/19", - "MapPublicIpOnLaunch": true, - "Tags": [ - { - "Key": "aws-cdk:subnet-name", - "Value": "Public" - }, - { - "Key": "aws-cdk:subnet-type", - "Value": "Public" - }, - { - "Key": "Name", - "Value": "cdk-stack/vpc-55522232/PublicSubnet1" - } - ], - "VpcId": { - "Ref": "vpc555222327AFC16C5" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet1/Subnet" - } - }, - "vpc55522232PublicSubnet1RouteTable201E0132": { - "Type": "AWS::EC2::RouteTable", - "Properties": { - "Tags": [ - { - "Key": "Name", - "Value": "cdk-stack/vpc-55522232/PublicSubnet1" - } - ], - "VpcId": { - "Ref": "vpc555222327AFC16C5" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet1/RouteTable" - } - }, - "vpc55522232PublicSubnet1RouteTableAssociationFC3053F6": { - "Type": "AWS::EC2::SubnetRouteTableAssociation", - "Properties": { - "RouteTableId": { - "Ref": "vpc55522232PublicSubnet1RouteTable201E0132" - }, - "SubnetId": { - "Ref": "vpc55522232PublicSubnet1Subnet8C1D3F0B" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet1/RouteTableAssociation" - } - }, - "vpc55522232PublicSubnet1DefaultRoute3576EEAF": { - "Type": "AWS::EC2::Route", - "Properties": { - "DestinationCidrBlock": "0.0.0.0/0", - "GatewayId": { - "Ref": "vpc55522232IGW2124CFCD" - }, - "RouteTableId": { - "Ref": "vpc55522232PublicSubnet1RouteTable201E0132" - } - }, - "DependsOn": [ - "vpc55522232VPCGW0E59A086" - ], - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet1/DefaultRoute" - } - }, - "vpc55522232PublicSubnet1EIP2B529517": { - "Type": "AWS::EC2::EIP", - "Properties": { - "Domain": "vpc", - "Tags": [ - { - "Key": "Name", - "Value": "cdk-stack/vpc-55522232/PublicSubnet1" - } - ] - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet1/EIP" - } - }, - "vpc55522232PublicSubnet1NATGateway8F921A30": { - "Type": "AWS::EC2::NatGateway", - "Properties": { - "AllocationId": { - "Fn::GetAtt": [ - "vpc55522232PublicSubnet1EIP2B529517", - "AllocationId" - ] - }, - "SubnetId": { - "Ref": "vpc55522232PublicSubnet1Subnet8C1D3F0B" - }, - "Tags": [ - { - "Key": "Name", - "Value": "cdk-stack/vpc-55522232/PublicSubnet1" - } - ] - }, - "DependsOn": [ - "vpc55522232PublicSubnet1DefaultRoute3576EEAF", - "vpc55522232PublicSubnet1RouteTableAssociationFC3053F6" - ], - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet1/NATGateway" - } - }, - "vpc55522232PublicSubnet2Subnet82DD7CE0": { - "Type": "AWS::EC2::Subnet", - "Properties": { - "AvailabilityZone": "us-east-1b", - "CidrBlock": "10.0.32.0/19", - "MapPublicIpOnLaunch": true, - "Tags": [ - { - "Key": "aws-cdk:subnet-name", - "Value": "Public" - }, - { - "Key": "aws-cdk:subnet-type", - "Value": "Public" - }, - { - "Key": "Name", - "Value": "cdk-stack/vpc-55522232/PublicSubnet2" - } - ], - "VpcId": { - "Ref": "vpc555222327AFC16C5" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet2/Subnet" - } - }, - "vpc55522232PublicSubnet2RouteTableB74BC90B": { - "Type": "AWS::EC2::RouteTable", - "Properties": { - "Tags": [ - { - "Key": "Name", - "Value": "cdk-stack/vpc-55522232/PublicSubnet2" - } - ], - "VpcId": { - "Ref": "vpc555222327AFC16C5" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet2/RouteTable" - } - }, - "vpc55522232PublicSubnet2RouteTableAssociation94475C00": { - "Type": "AWS::EC2::SubnetRouteTableAssociation", - "Properties": { - "RouteTableId": { - "Ref": "vpc55522232PublicSubnet2RouteTableB74BC90B" - }, - "SubnetId": { - "Ref": "vpc55522232PublicSubnet2Subnet82DD7CE0" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet2/RouteTableAssociation" - } - }, - "vpc55522232PublicSubnet2DefaultRoute96F97D0D": { - "Type": "AWS::EC2::Route", - "Properties": { - "DestinationCidrBlock": "0.0.0.0/0", - "GatewayId": { - "Ref": "vpc55522232IGW2124CFCD" - }, - "RouteTableId": { - "Ref": "vpc55522232PublicSubnet2RouteTableB74BC90B" - } - }, - "DependsOn": [ - "vpc55522232VPCGW0E59A086" - ], - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet2/DefaultRoute" - } - }, - "vpc55522232PublicSubnet2EIP9D615FD5": { - "Type": "AWS::EC2::EIP", - "Properties": { - "Domain": "vpc", - "Tags": [ - { - "Key": "Name", - "Value": "cdk-stack/vpc-55522232/PublicSubnet2" - } - ] - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet2/EIP" - } - }, - "vpc55522232PublicSubnet2NATGatewayCE45ECF6": { - "Type": "AWS::EC2::NatGateway", - "Properties": { - "AllocationId": { - "Fn::GetAtt": [ - "vpc55522232PublicSubnet2EIP9D615FD5", - "AllocationId" - ] - }, - "SubnetId": { - "Ref": "vpc55522232PublicSubnet2Subnet82DD7CE0" - }, - "Tags": [ - { - "Key": "Name", - "Value": "cdk-stack/vpc-55522232/PublicSubnet2" - } - ] - }, - "DependsOn": [ - "vpc55522232PublicSubnet2DefaultRoute96F97D0D", - "vpc55522232PublicSubnet2RouteTableAssociation94475C00" - ], - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet2/NATGateway" - } - }, - "vpc55522232PublicSubnet3SubnetB60D3678": { - "Type": "AWS::EC2::Subnet", - "Properties": { - "AvailabilityZone": "us-east-1c", - "CidrBlock": "10.0.64.0/19", - "MapPublicIpOnLaunch": true, - "Tags": [ - { - "Key": "aws-cdk:subnet-name", - "Value": "Public" - }, - { - "Key": "aws-cdk:subnet-type", - "Value": "Public" - }, - { - "Key": "Name", - "Value": "cdk-stack/vpc-55522232/PublicSubnet3" - } - ], - "VpcId": { - "Ref": "vpc555222327AFC16C5" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet3/Subnet" - } - }, - "vpc55522232PublicSubnet3RouteTableE4B6F284": { - "Type": "AWS::EC2::RouteTable", - "Properties": { - "Tags": [ - { - "Key": "Name", - "Value": "cdk-stack/vpc-55522232/PublicSubnet3" - } - ], - "VpcId": { - "Ref": "vpc555222327AFC16C5" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet3/RouteTable" - } - }, - "vpc55522232PublicSubnet3RouteTableAssociationE9DD046D": { - "Type": "AWS::EC2::SubnetRouteTableAssociation", - "Properties": { - "RouteTableId": { - "Ref": "vpc55522232PublicSubnet3RouteTableE4B6F284" - }, - "SubnetId": { - "Ref": "vpc55522232PublicSubnet3SubnetB60D3678" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet3/RouteTableAssociation" - } - }, - "vpc55522232PublicSubnet3DefaultRoute4A067F3E": { - "Type": "AWS::EC2::Route", - "Properties": { - "DestinationCidrBlock": "0.0.0.0/0", - "GatewayId": { - "Ref": "vpc55522232IGW2124CFCD" - }, - "RouteTableId": { - "Ref": "vpc55522232PublicSubnet3RouteTableE4B6F284" - } - }, - "DependsOn": [ - "vpc55522232VPCGW0E59A086" - ], - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet3/DefaultRoute" - } - }, - "vpc55522232PublicSubnet3EIP60F7BABB": { - "Type": "AWS::EC2::EIP", - "Properties": { - "Domain": "vpc", - "Tags": [ - { - "Key": "Name", - "Value": "cdk-stack/vpc-55522232/PublicSubnet3" - } - ] - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet3/EIP" - } - }, - "vpc55522232PublicSubnet3NATGateway285C26A6": { - "Type": "AWS::EC2::NatGateway", - "Properties": { - "AllocationId": { - "Fn::GetAtt": [ - "vpc55522232PublicSubnet3EIP60F7BABB", - "AllocationId" - ] - }, - "SubnetId": { - "Ref": "vpc55522232PublicSubnet3SubnetB60D3678" - }, - "Tags": [ - { - "Key": "Name", - "Value": "cdk-stack/vpc-55522232/PublicSubnet3" - } - ] - }, - "DependsOn": [ - "vpc55522232PublicSubnet3DefaultRoute4A067F3E", - "vpc55522232PublicSubnet3RouteTableAssociationE9DD046D" - ], - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PublicSubnet3/NATGateway" - } - }, - "vpc55522232PrivateSubnet1Subnet2E4DA426": { - "Type": "AWS::EC2::Subnet", - "Properties": { - "AvailabilityZone": "us-east-1a", - "CidrBlock": "10.0.96.0/19", - "MapPublicIpOnLaunch": false, - "Tags": [ - { - "Key": "aws-cdk:subnet-name", - "Value": "Private" - }, - { - "Key": "aws-cdk:subnet-type", - "Value": "Private" - }, - { - "Key": "Name", - "Value": "cdk-stack/vpc-55522232/PrivateSubnet1" - } - ], - "VpcId": { - "Ref": "vpc555222327AFC16C5" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet1/Subnet" - } - }, - "vpc55522232PrivateSubnet1RouteTableC546D020": { - "Type": "AWS::EC2::RouteTable", - "Properties": { - "Tags": [ - { - "Key": "Name", - "Value": "cdk-stack/vpc-55522232/PrivateSubnet1" - } - ], - "VpcId": { - "Ref": "vpc555222327AFC16C5" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet1/RouteTable" - } - }, - "vpc55522232PrivateSubnet1RouteTableAssociation98BDECFD": { - "Type": "AWS::EC2::SubnetRouteTableAssociation", - "Properties": { - "RouteTableId": { - "Ref": "vpc55522232PrivateSubnet1RouteTableC546D020" - }, - "SubnetId": { - "Ref": "vpc55522232PrivateSubnet1Subnet2E4DA426" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet1/RouteTableAssociation" - } - }, - "vpc55522232PrivateSubnet1DefaultRouteD15CA2D8": { - "Type": "AWS::EC2::Route", - "Properties": { - "DestinationCidrBlock": "0.0.0.0/0", - "NatGatewayId": { - "Ref": "vpc55522232PublicSubnet1NATGateway8F921A30" - }, - "RouteTableId": { - "Ref": "vpc55522232PrivateSubnet1RouteTableC546D020" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet1/DefaultRoute" - } - }, - "vpc55522232PrivateSubnet2SubnetBF911E75": { - "Type": "AWS::EC2::Subnet", - "Properties": { - "AvailabilityZone": "us-east-1b", - "CidrBlock": "10.0.128.0/19", - "MapPublicIpOnLaunch": false, - "Tags": [ - { - "Key": "aws-cdk:subnet-name", - "Value": "Private" - }, - { - "Key": "aws-cdk:subnet-type", - "Value": "Private" - }, - { - "Key": "Name", - "Value": "cdk-stack/vpc-55522232/PrivateSubnet2" - } - ], - "VpcId": { - "Ref": "vpc555222327AFC16C5" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet2/Subnet" - } - }, - "vpc55522232PrivateSubnet2RouteTableC23CB4A9": { - "Type": "AWS::EC2::RouteTable", - "Properties": { - "Tags": [ - { - "Key": "Name", - "Value": "cdk-stack/vpc-55522232/PrivateSubnet2" - } - ], - "VpcId": { - "Ref": "vpc555222327AFC16C5" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet2/RouteTable" - } - }, - "vpc55522232PrivateSubnet2RouteTableAssociationE7D278B5": { - "Type": "AWS::EC2::SubnetRouteTableAssociation", - "Properties": { - "RouteTableId": { - "Ref": "vpc55522232PrivateSubnet2RouteTableC23CB4A9" - }, - "SubnetId": { - "Ref": "vpc55522232PrivateSubnet2SubnetBF911E75" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet2/RouteTableAssociation" - } - }, - "vpc55522232PrivateSubnet2DefaultRoute306FAD64": { - "Type": "AWS::EC2::Route", - "Properties": { - "DestinationCidrBlock": "0.0.0.0/0", - "NatGatewayId": { - "Ref": "vpc55522232PublicSubnet2NATGatewayCE45ECF6" - }, - "RouteTableId": { - "Ref": "vpc55522232PrivateSubnet2RouteTableC23CB4A9" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet2/DefaultRoute" - } - }, - "vpc55522232PrivateSubnet3SubnetC9D7ECC5": { - "Type": "AWS::EC2::Subnet", - "Properties": { - "AvailabilityZone": "us-east-1c", - "CidrBlock": "10.0.160.0/19", - "MapPublicIpOnLaunch": false, - "Tags": [ - { - "Key": "aws-cdk:subnet-name", - "Value": "Private" - }, - { - "Key": "aws-cdk:subnet-type", - "Value": "Private" - }, - { - "Key": "Name", - "Value": "cdk-stack/vpc-55522232/PrivateSubnet3" - } - ], - "VpcId": { - "Ref": "vpc555222327AFC16C5" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet3/Subnet" - } - }, - "vpc55522232PrivateSubnet3RouteTable571A2BD8": { - "Type": "AWS::EC2::RouteTable", - "Properties": { - "Tags": [ - { - "Key": "Name", - "Value": "cdk-stack/vpc-55522232/PrivateSubnet3" - } - ], - "VpcId": { - "Ref": "vpc555222327AFC16C5" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet3/RouteTable" - } - }, - "vpc55522232PrivateSubnet3RouteTableAssociationF86DE320": { - "Type": "AWS::EC2::SubnetRouteTableAssociation", - "Properties": { - "RouteTableId": { - "Ref": "vpc55522232PrivateSubnet3RouteTable571A2BD8" - }, - "SubnetId": { - "Ref": "vpc55522232PrivateSubnet3SubnetC9D7ECC5" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet3/RouteTableAssociation" - } - }, - "vpc55522232PrivateSubnet3DefaultRoute23A9E99F": { - "Type": "AWS::EC2::Route", - "Properties": { - "DestinationCidrBlock": "0.0.0.0/0", - "NatGatewayId": { - "Ref": "vpc55522232PublicSubnet3NATGateway285C26A6" - }, - "RouteTableId": { - "Ref": "vpc55522232PrivateSubnet3RouteTable571A2BD8" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/PrivateSubnet3/DefaultRoute" - } - }, - "vpc55522232IGW2124CFCD": { - "Type": "AWS::EC2::InternetGateway", - "Properties": { - "Tags": [ - { - "Key": "Name", - "Value": "cdk-stack/vpc-55522232" - } - ] - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/IGW" - } - }, - "vpc55522232VPCGW0E59A086": { - "Type": "AWS::EC2::VPCGatewayAttachment", - "Properties": { - "InternetGatewayId": { - "Ref": "vpc55522232IGW2124CFCD" - }, - "VpcId": { - "Ref": "vpc555222327AFC16C5" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/vpc-55522232/VPCGW" - } - }, - "alb8A8B13C2": { - "Type": "AWS::ElasticLoadBalancingV2::LoadBalancer", - "Properties": { - "LoadBalancerAttributes": [ - { - "Key": "deletion_protection.enabled", - "Value": "false" - } - ], - "Scheme": "internal", - "SecurityGroups": [ - { - "Fn::GetAtt": [ - "albSecurityGroup49866104", - "GroupId" - ] - } - ], - "Subnets": [ - { - "Ref": "vpc55522232PrivateSubnet1Subnet2E4DA426" - }, - { - "Ref": "vpc55522232PrivateSubnet2SubnetBF911E75" - }, - { - "Ref": "vpc55522232PrivateSubnet3SubnetC9D7ECC5" - } - ], - "Type": "application" - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/alb/Resource" - } - }, - "albSecurityGroup49866104": { - "Type": "AWS::EC2::SecurityGroup", - "Properties": { - "GroupDescription": "Automatically created Security Group for ELB cdkstackalb6DF91EA2", - "SecurityGroupIngress": [ - { - "CidrIp": "0.0.0.0/0", - "Description": "Allow from anyone on port 80", - "FromPort": 80, - "IpProtocol": "tcp", - "ToPort": 80 - } - ], - "VpcId": { - "Ref": "vpc555222327AFC16C5" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/alb/SecurityGroup/Resource" - } - }, - "albSecurityGrouptocdkstackasgInstanceSecurityGroup3E3F3E71809881611E": { - "Type": "AWS::EC2::SecurityGroupEgress", - "Properties": { - "Description": "Load balancer to target", - "DestinationSecurityGroupId": { - "Fn::GetAtt": [ - "asgInstanceSecurityGroup5CEB2975", - "GroupId" - ] - }, - "FromPort": 80, - "GroupId": { - "Fn::GetAtt": [ - "albSecurityGroup49866104", - "GroupId" - ] - }, - "IpProtocol": "tcp", - "ToPort": 80 - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/alb/SecurityGroup/to cdkstackasgInstanceSecurityGroup3E3F3E71:80" - } - }, - "albListener3EA0B2EF": { - "Type": "AWS::ElasticLoadBalancingV2::Listener", - "Properties": { - "DefaultActions": [ - { - "TargetGroupArn": { - "Ref": "albListenerdefaulttargetGroup79BAE92B" - }, - "Type": "forward" - } - ], - "LoadBalancerArn": { - "Ref": "alb8A8B13C2" - }, - "Port": 80, - "Protocol": "HTTP" - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/alb/Listener/Resource" - } - }, - "albListenerdefaulttargetGroup79BAE92B": { - "Type": "AWS::ElasticLoadBalancingV2::TargetGroup", - "Properties": { - "HealthCheckIntervalSeconds": 30, - "HealthCheckPath": "/", - "HealthyThresholdCount": 5, - "Port": 80, - "Protocol": "HTTP", - "TargetGroupAttributes": [ - { - "Key": "stickiness.enabled", - "Value": "false" - } - ], - "TargetType": "instance", - "UnhealthyThresholdCount": 2, - "VpcId": { - "Ref": "vpc555222327AFC16C5" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/alb/Listener/default-targetGroup/Resource" - } - }, - "albListenerstaticRule4F017351": { - "Type": "AWS::ElasticLoadBalancingV2::ListenerRule", - "Properties": { - "Actions": [ - { - "FixedResponseConfig": { - "ContentType": "text/html", - "MessageBody": "

Static ALB Response

", - "StatusCode": "200" - }, - "Type": "fixed-response" - } - ], - "Conditions": [ - { - "Field": "path-pattern", - "PathPatternConfig": { - "Values": [ - "/static" - ] - } - } - ], - "ListenerArn": { - "Ref": "albListener3EA0B2EF" - }, - "Priority": 5 - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/alb/Listener/--staticRule/Resource" - } - }, - "asgInstanceSecurityGroup5CEB2975": { - "Type": "AWS::EC2::SecurityGroup", - "Properties": { - "GroupDescription": "cdk-stack/asg/InstanceSecurityGroup", - "SecurityGroupEgress": [ - { - "CidrIp": "0.0.0.0/0", - "Description": "Allow all outbound traffic by default", - "IpProtocol": "-1" - } - ], - "Tags": [ - { - "Key": "Name", - "Value": "cdk-stack/asg" - } - ], - "VpcId": { - "Ref": "vpc555222327AFC16C5" - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/asg/InstanceSecurityGroup/Resource" - } - }, - "asgInstanceSecurityGroupfromcdkstackalbSecurityGroup20A8C03080818D6412": { - "Type": "AWS::EC2::SecurityGroupIngress", - "Properties": { - "Description": "Load balancer to target", - "FromPort": 80, - "GroupId": { - "Fn::GetAtt": [ - "asgInstanceSecurityGroup5CEB2975", - "GroupId" - ] - }, - "IpProtocol": "tcp", - "SourceSecurityGroupId": { - "Fn::GetAtt": [ - "albSecurityGroup49866104", - "GroupId" - ] - }, - "ToPort": 80 - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/asg/InstanceSecurityGroup/from cdkstackalbSecurityGroup20A8C030:80" - } - }, - "asgInstanceRole8AC4201C": { - "Type": "AWS::IAM::Role", - "Properties": { - "AssumeRolePolicyDocument": { - "Statement": [ - { - "Action": "sts:AssumeRole", - "Effect": "Allow", - "Principal": { - "Service": "ec2.amazonaws.com" - } - } - ], - "Version": "2012-10-17" - }, - "Tags": [ - { - "Key": "Name", - "Value": "cdk-stack/asg" - } - ] - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/asg/InstanceRole/Resource" - } - }, - "asgInstanceProfile4E44E320": { - "Type": "AWS::IAM::InstanceProfile", - "Properties": { - "Roles": [ - { - "Ref": "asgInstanceRole8AC4201C" - } - ] - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/asg/InstanceProfile" - } - }, - "asgLaunchConfig37FDE42B": { - "Type": "AWS::AutoScaling::LaunchConfiguration", - "Properties": { - "IamInstanceProfile": { - "Ref": "asgInstanceProfile4E44E320" - }, - "ImageId": { - "Ref": "SsmParameterValueawsserviceamiamazonlinuxlatestamzn2amihvmx8664gp2C96584B6F00A464EAD1953AFF4B05118Parameter" - }, - "InstanceType": "t2.micro", - "SecurityGroups": [ - { - "Fn::GetAtt": [ - "asgInstanceSecurityGroup5CEB2975", - "GroupId" - ] - } - ], - "UserData": { - "Fn::Base64": "#!/bin/bash\nsudo su\nyum install -y httpd\nsystemctl start httpd\nsystemctl enable httpd\necho \"

Hello World from $(hostname -f)

\" > /var/www/html/index.html" - } - }, - "DependsOn": [ - "asgInstanceRole8AC4201C" - ], - "Metadata": { - "aws:cdk:path": "cdk-stack/asg/LaunchConfig" - } - }, - "asgASG4D014670": { - "Type": "AWS::AutoScaling::AutoScalingGroup", - "Properties": { - "LaunchConfigurationName": { - "Ref": "asgLaunchConfig37FDE42B" - }, - "MaxSize": "3", - "MinSize": "2", - "Tags": [ - { - "Key": "Name", - "PropagateAtLaunch": true, - "Value": "cdk-stack/asg" - } - ], - "TargetGroupARNs": [ - { - "Ref": "albListenerdefaulttargetGroup79BAE92B" - } - ], - "VPCZoneIdentifier": [ - { - "Ref": "vpc55522232PrivateSubnet1Subnet2E4DA426" - }, - { - "Ref": "vpc55522232PrivateSubnet2SubnetBF911E75" - }, - { - "Ref": "vpc55522232PrivateSubnet3SubnetC9D7ECC5" - } - ] - }, - "UpdatePolicy": { - "AutoScalingScheduledAction": { - "IgnoreUnmodifiedGroupSizeProperties": true - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/asg/ASG" - } - }, - "asgScalingPolicyrequestsperminute5D73703F": { - "Type": "AWS::AutoScaling::ScalingPolicy", - "Properties": { - "AutoScalingGroupName": { - "Ref": "asgASG4D014670" - }, - "PolicyType": "TargetTrackingScaling", - "TargetTrackingConfiguration": { - "PredefinedMetricSpecification": { - "PredefinedMetricType": "ALBRequestCountPerTarget", - "ResourceLabel": { - "Fn::Join": [ - "", - [ - { - "Fn::Select": [ - 1, - { - "Fn::Split": [ - "/", - { - "Ref": "albListener3EA0B2EF" - } - ] - } - ] - }, - "/", - { - "Fn::Select": [ - 2, - { - "Fn::Split": [ - "/", - { - "Ref": "albListener3EA0B2EF" - } - ] - } - ] - }, - "/", - { - "Fn::Select": [ - 3, - { - "Fn::Split": [ - "/", - { - "Ref": "albListener3EA0B2EF" - } - ] - } - ] - }, - "/", - { - "Fn::GetAtt": [ - "albListenerdefaulttargetGroup79BAE92B", - "TargetGroupFullName" - ] - } - ] - ] - } - }, - "TargetValue": 60 - } - }, - "DependsOn": [ - "albListenerstaticRule4F017351", - "albListenerdefaulttargetGroup79BAE92B", - "albListener3EA0B2EF" - ], - "Metadata": { - "aws:cdk:path": "cdk-stack/asg/ScalingPolicyrequests-per-minute/Resource" - } - }, - "asgScalingPolicycpuutilscaling06365506": { - "Type": "AWS::AutoScaling::ScalingPolicy", - "Properties": { - "AutoScalingGroupName": { - "Ref": "asgASG4D014670" - }, - "PolicyType": "TargetTrackingScaling", - "TargetTrackingConfiguration": { - "PredefinedMetricSpecification": { - "PredefinedMetricType": "ASGAverageCPUUtilization" - }, - "TargetValue": 75 - } - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/asg/ScalingPolicycpu-util-scaling/Resource" - } - }, - "CDKMetadata": { - "Type": "AWS::CDK::Metadata", - "Properties": { - "Analytics": "v2:deflate64:H4sIAAAAAAAA/31Sy27CMBD8Fu7GFbQ99EgRQpFQGyWIa7UxSzAkdmSvQSjKv9d5kSCqnnZndrQejz3nH+98NoGrnYr9eZrJhJcxgTgzT/2UKOa83BWCLQ9qFy5Z6JJMitglCqnmhi7SjnALSYYDP3ALa7WQQFKru7huVkFYly+gNRBe4cZCIy++HRYHitD4vhe0Tjq0IO/1mKMiFqNwRtJtbbQrGg//EqvUoLVPdKAavmKYgSUpMg37BDJQQqr04sNYFIVPoLnJxs8+mxmaetEDHuukJVSdpu9H8y2Y1N+vtzmGf2yJXBvxGFcMHGkrIPMuvUcP4hbct27AKXFcanWQqTP3l3iStqdvjf8CnutGofYumugfiIpJyHkZ6dZRXwNlqQ4hNPogvbmKRWi1M6KZhmAgR2rj+HZUuPb/dJKKKb1HfrIvl9kbn8/46+RkpZwap0jmyKO2/gL2/416uAIAAA==" - }, - "Metadata": { - "aws:cdk:path": "cdk-stack/CDKMetadata/Default" - } - } - }, - "Parameters": { - "SsmParameterValueawsserviceamiamazonlinuxlatestamzn2amihvmx8664gp2C96584B6F00A464EAD1953AFF4B05118Parameter": { - "Type": "AWS::SSM::Parameter::Value", - "Default": "/aws/service/ami-amazon-linux-latest/amzn2-ami-hvm-x86_64-gp2" - }, - "BootstrapVersion": { - "Type": "AWS::SSM::Parameter::Value", - "Default": "/cdk-bootstrap/hnb659fds/version", - "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" - } - }, - "Outputs": { - "albDNS": { - "Value": { - "Fn::GetAtt": [ - "alb8A8B13C2", - "DNSName" - ] - } - } - }, - "Rules": { - "CheckBootstrapVersion": { - "Assertions": [ - { - "Assert": { - "Fn::Not": [ - { - "Fn::Contains": [ - [ - "1", - "2", - "3", - "4", - "5" - ], - { - "Ref": "BootstrapVersion" - } - ] - } - ] - }, - "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." - } - ] - } - } -} \ No newline at end of file diff --git a/cdk.out/cdk.out b/cdk.out/cdk.out deleted file mode 100644 index 2313ab543..000000000 --- a/cdk.out/cdk.out +++ /dev/null @@ -1 +0,0 @@ -{"version":"34.0.0"} \ No newline at end of file diff --git a/cdk.out/manifest.json b/cdk.out/manifest.json deleted file mode 100644 index 7647b8e69..000000000 --- a/cdk.out/manifest.json +++ /dev/null @@ -1,106 +0,0 @@ -{ - "version": "34.0.0", - "artifacts": { - "stage-alb-stack.assets": { - "type": "cdk:asset-manifest", - "properties": { - "file": "stage-alb-stack.assets.json", - "requiresBootstrapStackVersion": 6, - "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" - } - }, - "stage-alb-stack": { - "type": "aws:cloudformation:stack", - "environment": "aws://100225593120/us-east-1", - "properties": { - "templateFile": "stage-alb-stack.template.json", - "validateOnSynth": false, - "assumeRoleArn": "arn:${AWS::Partition}:iam::100225593120:role/cdk-hnb659fds-deploy-role-100225593120-us-east-1", - "cloudFormationExecutionRoleArn": "arn:${AWS::Partition}:iam::100225593120:role/cdk-hnb659fds-cfn-exec-role-100225593120-us-east-1", - "stackTemplateAssetObjectUrl": "s3://cdk-hnb659fds-assets-100225593120-us-east-1/3a2577e14946ca0614397f637d69c1a3786b28baa3a527e7bc1dc110e89ce09b.json", - "requiresBootstrapStackVersion": 6, - "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version", - "additionalDependencies": [ - "stage-alb-stack.assets" - ], - "lookupRole": { - "arn": "arn:${AWS::Partition}:iam::100225593120:role/cdk-hnb659fds-lookup-role-100225593120-us-east-1", - "requiresBootstrapStackVersion": 8, - "bootstrapStackVersionSsmParameter": "/cdk-bootstrap/hnb659fds/version" - } - }, - "dependencies": [ - "stage-alb-stack.assets" - ], - "metadata": { - "/stage-alb-stack/default/from 0.0.0.0_0:443": [ - { - "type": "aws:cdk:logicalId", - "data": "defaultfrom00000443FDCE37BB" - } - ], - "/stage-alb-stack/alb/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "alb8A8B13C2" - } - ], - "/stage-alb-stack/alb/HTTPS Listener/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "albHTTPSListener7C8C4C55" - } - ], - "/stage-alb-stack/alb/HTTPS Listener/Backend StageGroup/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "albHTTPSListenerBackendStageGroup18A8DB5E" - } - ], - "/stage-alb-stack/Public DNS/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "PublicDNSD41885E8" - } - ], - "/stage-alb-stack/Private DNS/Resource": [ - { - "type": "aws:cdk:logicalId", - "data": "PrivateDNSEACE6CB2" - } - ], - "/stage-alb-stack/albDNS": [ - { - "type": "aws:cdk:logicalId", - "data": "albDNS" - } - ], - "/stage-alb-stack/CDKMetadata/Default": [ - { - "type": "aws:cdk:logicalId", - "data": "CDKMetadata" - } - ], - "/stage-alb-stack/BootstrapVersion": [ - { - "type": "aws:cdk:logicalId", - "data": "BootstrapVersion" - } - ], - "/stage-alb-stack/CheckBootstrapVersion": [ - { - "type": "aws:cdk:logicalId", - "data": "CheckBootstrapVersion" - } - ] - }, - "displayName": "stage-alb-stack" - }, - "Tree": { - "type": "cdk:tree", - "properties": { - "file": "tree.json" - } - } - } -} \ No newline at end of file diff --git a/cdk.out/stage-alb-stack.assets.json b/cdk.out/stage-alb-stack.assets.json deleted file mode 100644 index 62cd4b0d1..000000000 --- a/cdk.out/stage-alb-stack.assets.json +++ /dev/null @@ -1,20 +0,0 @@ -{ - "version": "34.0.0", - "files": { - "3a2577e14946ca0614397f637d69c1a3786b28baa3a527e7bc1dc110e89ce09b": { - "source": { - "path": "stage-alb-stack.template.json", - "packaging": "file" - }, - "destinations": { - "100225593120-us-east-1": { - "bucketName": "cdk-hnb659fds-assets-100225593120-us-east-1", - "objectKey": "3a2577e14946ca0614397f637d69c1a3786b28baa3a527e7bc1dc110e89ce09b.json", - "region": "us-east-1", - "assumeRoleArn": "arn:${AWS::Partition}:iam::100225593120:role/cdk-hnb659fds-file-publishing-role-100225593120-us-east-1" - } - } - } - }, - "dockerImages": {} -} \ No newline at end of file diff --git a/cdk.out/stage-alb-stack.template.json b/cdk.out/stage-alb-stack.template.json deleted file mode 100644 index fb15d30e1..000000000 --- a/cdk.out/stage-alb-stack.template.json +++ /dev/null @@ -1,186 +0,0 @@ -{ - "Resources": { - "defaultfrom00000443FDCE37BB": { - "Type": "AWS::EC2::SecurityGroupIngress", - "Properties": { - "CidrIp": "0.0.0.0/0", - "Description": "Allow from anyone on port 443", - "FromPort": 443, - "GroupId": "sg-21ac675b", - "IpProtocol": "tcp", - "ToPort": 443 - }, - "Metadata": { - "aws:cdk:path": "stage-alb-stack/default/from 0.0.0.0_0:443" - } - }, - "alb8A8B13C2": { - "Type": "AWS::ElasticLoadBalancingV2::LoadBalancer", - "Properties": { - "LoadBalancerAttributes": [ - { - "Key": "deletion_protection.enabled", - "Value": "false" - } - ], - "Scheme": "internal", - "SecurityGroups": [ - "sg-21ac675b" - ], - "Subnets": [ - "subnet-0d4703177afb1797d", - "subnet-04262fc338f638054", - "subnet-044457c061edf85f2", - "subnet-04019d42d5c9e6fb9", - "subnet-049778993fb504a7c" - ], - "Type": "application" - }, - "Metadata": { - "aws:cdk:path": "stage-alb-stack/alb/Resource" - } - }, - "albHTTPSListener7C8C4C55": { - "Type": "AWS::ElasticLoadBalancingV2::Listener", - "Properties": { - "Certificates": [ - { - "CertificateArn": "arn:aws:acm:us-east-1:100225593120:certificate/047a56a2-09dd-4857-9f28-32d23650d4da" - } - ], - "DefaultActions": [ - { - "TargetGroupArn": { - "Ref": "albHTTPSListenerBackendStageGroup18A8DB5E" - }, - "Type": "forward" - } - ], - "LoadBalancerArn": { - "Ref": "alb8A8B13C2" - }, - "Port": 443, - "Protocol": "HTTPS" - }, - "Metadata": { - "aws:cdk:path": "stage-alb-stack/alb/HTTPS Listener/Resource" - } - }, - "albHTTPSListenerBackendStageGroup18A8DB5E": { - "Type": "AWS::ElasticLoadBalancingV2::TargetGroup", - "Properties": { - "Port": 443, - "Protocol": "HTTPS", - "TargetGroupAttributes": [ - { - "Key": "stickiness.enabled", - "Value": "false" - } - ], - "TargetType": "instance", - "Targets": [ - { - "Id": "i-0d7ea7b7cc11a2e8f" - } - ], - "VpcId": "vpc-55522232" - }, - "Metadata": { - "aws:cdk:path": "stage-alb-stack/alb/HTTPS Listener/Backend StageGroup/Resource" - } - }, - "PublicDNSD41885E8": { - "Type": "AWS::Route53::RecordSet", - "Properties": { - "HostedZoneId": "Z3IZ3D6V94JEC2", - "Name": "stage-alb.alliancegenome.org.", - "ResourceRecords": [ - { - "Fn::GetAtt": [ - "alb8A8B13C2", - "DNSName" - ] - } - ], - "TTL": "300", - "Type": "CNAME" - }, - "Metadata": { - "aws:cdk:path": "stage-alb-stack/Public DNS/Resource" - } - }, - "PrivateDNSEACE6CB2": { - "Type": "AWS::Route53::RecordSet", - "Properties": { - "HostedZoneId": "Z007692222A6W93AZVSPD", - "Name": "stage-alb.alliancegenome.org.", - "ResourceRecords": [ - { - "Fn::GetAtt": [ - "alb8A8B13C2", - "DNSName" - ] - } - ], - "TTL": "300", - "Type": "CNAME" - }, - "Metadata": { - "aws:cdk:path": "stage-alb-stack/Private DNS/Resource" - } - }, - "CDKMetadata": { - "Type": "AWS::CDK::Metadata", - "Properties": { - "Analytics": "v2:deflate64:H4sIAAAAAAAA/1WPsWrDQAyGnyX7WcVOM3RsM5RCoWBnL4qsGiUXnbnTJRTjd68dt+Aukn6+DwlV8LSDcoO3VFB7LrwcYWgM6exqTiFHYjexz4Gpgv2XNkw5in2/xpD7N+0ip+TYYzIhH7A9okcl0e5awfDc914ITYK+T+zlzji6ac+/vPYkGeuv8zev+AFjx3a/PiurOLqpGu+2MOwVL1wzhdjO0jI1bOM4x49sfbYFLB+OTkPLcEoP1/IRqhK2m1MSKWJWkwtDvfQfzO4j0CsBAAA=" - }, - "Metadata": { - "aws:cdk:path": "stage-alb-stack/CDKMetadata/Default" - } - } - }, - "Outputs": { - "albDNS": { - "Value": { - "Fn::GetAtt": [ - "alb8A8B13C2", - "DNSName" - ] - } - } - }, - "Parameters": { - "BootstrapVersion": { - "Type": "AWS::SSM::Parameter::Value", - "Default": "/cdk-bootstrap/hnb659fds/version", - "Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" - } - }, - "Rules": { - "CheckBootstrapVersion": { - "Assertions": [ - { - "Assert": { - "Fn::Not": [ - { - "Fn::Contains": [ - [ - "1", - "2", - "3", - "4", - "5" - ], - { - "Ref": "BootstrapVersion" - } - ] - } - ] - }, - "AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." - } - ] - } - } -} \ No newline at end of file diff --git a/cdk.out/tree.json b/cdk.out/tree.json deleted file mode 100644 index d397d1053..000000000 --- a/cdk.out/tree.json +++ /dev/null @@ -1,398 +0,0 @@ -{ - "version": "tree-0.1", - "tree": { - "id": "App", - "path": "", - "children": { - "stage-alb-stack": { - "id": "stage-alb-stack", - "path": "stage-alb-stack", - "children": { - "Docker": { - "id": "Docker", - "path": "stage-alb-stack/Docker", - "children": { - "PublicSubnet1": { - "id": "PublicSubnet1", - "path": "stage-alb-stack/Docker/PublicSubnet1", - "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "2.95.1" - } - }, - "PublicSubnet2": { - "id": "PublicSubnet2", - "path": "stage-alb-stack/Docker/PublicSubnet2", - "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "2.95.1" - } - }, - "PublicSubnet3": { - "id": "PublicSubnet3", - "path": "stage-alb-stack/Docker/PublicSubnet3", - "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "2.95.1" - } - }, - "PublicSubnet4": { - "id": "PublicSubnet4", - "path": "stage-alb-stack/Docker/PublicSubnet4", - "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "2.95.1" - } - }, - "PublicSubnet5": { - "id": "PublicSubnet5", - "path": "stage-alb-stack/Docker/PublicSubnet5", - "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "2.95.1" - } - }, - "PrivateSubnet1": { - "id": "PrivateSubnet1", - "path": "stage-alb-stack/Docker/PrivateSubnet1", - "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "2.95.1" - } - }, - "PrivateSubnet2": { - "id": "PrivateSubnet2", - "path": "stage-alb-stack/Docker/PrivateSubnet2", - "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "2.95.1" - } - }, - "PrivateSubnet3": { - "id": "PrivateSubnet3", - "path": "stage-alb-stack/Docker/PrivateSubnet3", - "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "2.95.1" - } - }, - "PrivateSubnet4": { - "id": "PrivateSubnet4", - "path": "stage-alb-stack/Docker/PrivateSubnet4", - "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "2.95.1" - } - }, - "PrivateSubnet5": { - "id": "PrivateSubnet5", - "path": "stage-alb-stack/Docker/PrivateSubnet5", - "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "2.95.1" - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "2.95.1" - } - }, - "default": { - "id": "default", - "path": "stage-alb-stack/default", - "children": { - "from 0.0.0.0_0:443": { - "id": "from 0.0.0.0_0:443", - "path": "stage-alb-stack/default/from 0.0.0.0_0:443", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::EC2::SecurityGroupIngress", - "aws:cdk:cloudformation:props": { - "cidrIp": "0.0.0.0/0", - "description": "Allow from anyone on port 443", - "fromPort": 443, - "groupId": "sg-21ac675b", - "ipProtocol": "tcp", - "toPort": 443 - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_ec2.CfnSecurityGroupIngress", - "version": "2.95.1" - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "2.95.1" - } - }, - "Public Zone": { - "id": "Public Zone", - "path": "stage-alb-stack/Public Zone", - "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "2.95.1" - } - }, - "Private Zone": { - "id": "Private Zone", - "path": "stage-alb-stack/Private Zone", - "constructInfo": { - "fqn": "aws-cdk-lib.Resource", - "version": "2.95.1" - } - }, - "alb": { - "id": "alb", - "path": "stage-alb-stack/alb", - "children": { - "Resource": { - "id": "Resource", - "path": "stage-alb-stack/alb/Resource", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::ElasticLoadBalancingV2::LoadBalancer", - "aws:cdk:cloudformation:props": { - "loadBalancerAttributes": [ - { - "key": "deletion_protection.enabled", - "value": "false" - } - ], - "scheme": "internal", - "securityGroups": [ - "sg-21ac675b" - ], - "subnets": [ - "subnet-0d4703177afb1797d", - "subnet-04262fc338f638054", - "subnet-044457c061edf85f2", - "subnet-04019d42d5c9e6fb9", - "subnet-049778993fb504a7c" - ], - "type": "application" - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.CfnLoadBalancer", - "version": "2.95.1" - } - }, - "HTTPS Listener": { - "id": "HTTPS Listener", - "path": "stage-alb-stack/alb/HTTPS Listener", - "children": { - "Resource": { - "id": "Resource", - "path": "stage-alb-stack/alb/HTTPS Listener/Resource", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::ElasticLoadBalancingV2::Listener", - "aws:cdk:cloudformation:props": { - "certificates": [ - { - "certificateArn": "arn:aws:acm:us-east-1:100225593120:certificate/047a56a2-09dd-4857-9f28-32d23650d4da" - } - ], - "defaultActions": [ - { - "type": "forward", - "targetGroupArn": { - "Ref": "albHTTPSListenerBackendStageGroup18A8DB5E" - } - } - ], - "loadBalancerArn": { - "Ref": "alb8A8B13C2" - }, - "port": 443, - "protocol": "HTTPS" - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.CfnListener", - "version": "2.95.1" - } - }, - "Backend StageGroup": { - "id": "Backend StageGroup", - "path": "stage-alb-stack/alb/HTTPS Listener/Backend StageGroup", - "children": { - "Resource": { - "id": "Resource", - "path": "stage-alb-stack/alb/HTTPS Listener/Backend StageGroup/Resource", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::ElasticLoadBalancingV2::TargetGroup", - "aws:cdk:cloudformation:props": { - "port": 443, - "protocol": "HTTPS", - "targetGroupAttributes": [ - { - "key": "stickiness.enabled", - "value": "false" - } - ], - "targets": [ - { - "id": "i-0d7ea7b7cc11a2e8f" - } - ], - "targetType": "instance", - "vpcId": "vpc-55522232" - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.CfnTargetGroup", - "version": "2.95.1" - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationTargetGroup", - "version": "2.95.1" - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationListener", - "version": "2.95.1" - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_elasticloadbalancingv2.ApplicationLoadBalancer", - "version": "2.95.1" - } - }, - "Public DNS": { - "id": "Public DNS", - "path": "stage-alb-stack/Public DNS", - "children": { - "Resource": { - "id": "Resource", - "path": "stage-alb-stack/Public DNS/Resource", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::Route53::RecordSet", - "aws:cdk:cloudformation:props": { - "hostedZoneId": "Z3IZ3D6V94JEC2", - "name": "stage-alb.alliancegenome.org.", - "resourceRecords": [ - { - "Fn::GetAtt": [ - "alb8A8B13C2", - "DNSName" - ] - } - ], - "ttl": "300", - "type": "CNAME" - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_route53.CfnRecordSet", - "version": "2.95.1" - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_route53.CnameRecord", - "version": "2.95.1" - } - }, - "Private DNS": { - "id": "Private DNS", - "path": "stage-alb-stack/Private DNS", - "children": { - "Resource": { - "id": "Resource", - "path": "stage-alb-stack/Private DNS/Resource", - "attributes": { - "aws:cdk:cloudformation:type": "AWS::Route53::RecordSet", - "aws:cdk:cloudformation:props": { - "hostedZoneId": "Z007692222A6W93AZVSPD", - "name": "stage-alb.alliancegenome.org.", - "resourceRecords": [ - { - "Fn::GetAtt": [ - "alb8A8B13C2", - "DNSName" - ] - } - ], - "ttl": "300", - "type": "CNAME" - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_route53.CfnRecordSet", - "version": "2.95.1" - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.aws_route53.CnameRecord", - "version": "2.95.1" - } - }, - "albDNS": { - "id": "albDNS", - "path": "stage-alb-stack/albDNS", - "constructInfo": { - "fqn": "aws-cdk-lib.CfnOutput", - "version": "2.95.1" - } - }, - "CDKMetadata": { - "id": "CDKMetadata", - "path": "stage-alb-stack/CDKMetadata", - "children": { - "Default": { - "id": "Default", - "path": "stage-alb-stack/CDKMetadata/Default", - "constructInfo": { - "fqn": "aws-cdk-lib.CfnResource", - "version": "2.95.1" - } - } - }, - "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" - } - }, - "BootstrapVersion": { - "id": "BootstrapVersion", - "path": "stage-alb-stack/BootstrapVersion", - "constructInfo": { - "fqn": "aws-cdk-lib.CfnParameter", - "version": "2.95.1" - } - }, - "CheckBootstrapVersion": { - "id": "CheckBootstrapVersion", - "path": "stage-alb-stack/CheckBootstrapVersion", - "constructInfo": { - "fqn": "aws-cdk-lib.CfnRule", - "version": "2.95.1" - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.Stack", - "version": "2.95.1" - } - }, - "Tree": { - "id": "Tree", - "path": "Tree", - "constructInfo": { - "fqn": "constructs.Construct", - "version": "10.2.70" - } - } - }, - "constructInfo": { - "fqn": "aws-cdk-lib.App", - "version": "2.95.1" - } - } -} \ No newline at end of file From 768c74ba0fc5baf97f08328727c203c5605483d7 Mon Sep 17 00:00:00 2001 From: Olin Blodgett Date: Mon, 11 Sep 2023 19:36:48 -0400 Subject: [PATCH 63/85] Added additional listener --- Makefile | 3 +++ cdk/stage-alb-stack.ts | 53 ++++++++++++++++++++++++++++++++++++------ 2 files changed, 49 insertions(+), 7 deletions(-) diff --git a/Makefile b/Makefile index bd26ec60d..7b158aab2 100644 --- a/Makefile +++ b/Makefile @@ -23,6 +23,9 @@ test: run: npm start +alb-deploy: + npx aws-cdk deploy --outputs-file ./cdk-outputs.json + uirun: npm start diff --git a/cdk/stage-alb-stack.ts b/cdk/stage-alb-stack.ts index 0f67ef573..c5ec4cd9e 100644 --- a/cdk/stage-alb-stack.ts +++ b/cdk/stage-alb-stack.ts @@ -11,7 +11,8 @@ export class StageALBStack extends cdk.Stack { super(scope, id, props); const vpc = ec2.Vpc.fromLookup(this, 'Docker', { vpcName: 'Docker' }); - const sg = ec2.SecurityGroup.fromLookupById(this, 'default', 'sg-21ac675b'); + const sg1 = ec2.SecurityGroup.fromLookupById(this, 'default', 'sg-21ac675b'); + const sg2 = ec2.SecurityGroup.fromLookupById(this, 'HTTP/HTTPS', 'sg-0415cab61ab6b45c5'); const cert = elbv2.ListenerCertificate.fromArn('arn:aws:acm:us-east-1:100225593120:certificate/047a56a2-09dd-4857-9f28-32d23650d4da'); const stage = new targets.InstanceIdTarget('i-0d7ea7b7cc11a2e8f') const public_zone = route53.HostedZone.fromHostedZoneAttributes(this, 'Public Zone', { zoneName: 'alliancegenome.org', hostedZoneId: 'Z3IZ3D6V94JEC2' }); @@ -19,10 +20,12 @@ export class StageALBStack extends cdk.Stack { const alb = new elbv2.ApplicationLoadBalancer(this, 'alb', { vpc, - internetFacing: false, - securityGroup: sg + internetFacing: true, + securityGroup: sg1 }); + alb.addSecurityGroup(sg2); + new route53.CnameRecord(this, "Public DNS", { zone: public_zone, recordName: "stage-alb", @@ -36,15 +39,51 @@ export class StageALBStack extends cdk.Stack { ttl: cdk.Duration.minutes(5) }); - const listener = alb.addListener('HTTPS Listener', { + const listener_https = alb.addListener('HTTPS Listener', { port: 443, open: true, certificates: [cert] }); - listener.addTargets("Backend Stage", { - port: 443, - targets: [stage] + listener_https.addTargets("Backend Stage", { + healthCheck: { + path: '/robots.txt', + unhealthyThresholdCount: 3, + healthyThresholdCount: 5, + interval: cdk.Duration.seconds(60), + }, + port: 80, + targets: [stage], + }); + +/* + listener_https.addAction("Redirect to Stage", { + priority: 10, + conditions: [ + elbv2.ListenerCondition.hostHeaders(['stage-alb.alliancegenome.org']), + ], + action: elbv2.ListenerAction.redirect({ + protocol: 'HTTPS', + port: '443', + host: 'stage.alliancegenome.org', + path: '/#{path}', + query: '#{query}', + permanent: true, + }), + }); +*/ + + const listener_http = alb.addListener('HTTP Listener', { + port: 80, + open: true, + defaultAction: elbv2.ListenerAction.redirect({ + protocol: 'HTTPS', + port: '443', + host: 'stage.alliancegenome.org', + path: '/#{path}', + query: '#{query}', + permanent: true, + }), }); new cdk.CfnOutput(this, 'albDNS', { From ac4527dab0bf949f0c56612404b30b241ab8b57e Mon Sep 17 00:00:00 2001 From: Olin Blodgett Date: Mon, 11 Sep 2023 21:59:31 -0400 Subject: [PATCH 64/85] Updated Swagger routers --- apps/main-app/src/routes.js | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/apps/main-app/src/routes.js b/apps/main-app/src/routes.js index 34d67e683..5a6132c3f 100644 --- a/apps/main-app/src/routes.js +++ b/apps/main-app/src/routes.js @@ -44,6 +44,22 @@ export default ( }} /> + { + window.location.href = `${props.location.pathname}${props.location.search}`; + return null; + }} + /> + + { + window.location.href = `${props.location.pathname}${props.location.search}`; + return null; + }} + /> + { From 578a8b7948ce9d5348536a7d1b539834c3fe18f1 Mon Sep 17 00:00:00 2001 From: Olin Blodgett Date: Mon, 11 Sep 2023 22:12:11 -0400 Subject: [PATCH 65/85] More routes --- apps/main-app/src/constants.js | 2 +- apps/main-app/src/routes.js | 8 ++++++++ apps/main-app/webpack.config.babel.js | 10 ++++++++++ 3 files changed, 19 insertions(+), 1 deletion(-) diff --git a/apps/main-app/src/constants.js b/apps/main-app/src/constants.js index 7c552a539..0b140819d 100644 --- a/apps/main-app/src/constants.js +++ b/apps/main-app/src/constants.js @@ -80,7 +80,7 @@ export const NAV_MENU = [ }, { label: 'API', - route: '/api/swagger-ui', + route: '/swagger-ui', external: true, }, { diff --git a/apps/main-app/src/routes.js b/apps/main-app/src/routes.js index 5a6132c3f..625002496 100644 --- a/apps/main-app/src/routes.js +++ b/apps/main-app/src/routes.js @@ -76,6 +76,14 @@ export default ( }} /> + { + window.location.href = `${props.location.pathname}${props.location.search}`; + return null; + }} + /> + } /> diff --git a/apps/main-app/webpack.config.babel.js b/apps/main-app/webpack.config.babel.js index 94b678b1c..b63531bc5 100644 --- a/apps/main-app/webpack.config.babel.js +++ b/apps/main-app/webpack.config.babel.js @@ -42,6 +42,16 @@ const devServer = { secure: false, changeOrigin: true }, + '/swagger-ui': { + target: process.env.API_URL || 'http://localhost:8080', + secure: false, + changeOrigin: true + }, + '/openapi': { + target: process.env.API_URL || 'http://localhost:8080', + secure: false, + changeOrigin: true + }, '/apollo': { target: process.env.APOLLO_URL || process.env.API_URL, secure: false, From b73d318597b1b3b82222701be5d6d57c620d4f28 Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Tue, 12 Sep 2023 11:44:53 +0100 Subject: [PATCH 66/85] SCRUM-3222: paralogy UI fix for method names --- .../src/components/homology/constants.js | 32 +++---------------- .../src/components/homology/methodCell.js | 22 +++++++------ .../src/components/homology/methodHeader.js | 17 ++++++---- .../src/components/homology/methodLogo.js | 9 +++--- .../components/orthology/orthologyTable.js | 1 + .../src/components/paralogy/methods.js | 4 +++ .../src/components/paralogy/paralogyTable.js | 10 +++--- 7 files changed, 42 insertions(+), 53 deletions(-) create mode 100644 apps/main-app/src/components/paralogy/methods.js diff --git a/apps/main-app/src/components/homology/constants.js b/apps/main-app/src/components/homology/constants.js index 6c743ee40..ba47dc486 100644 --- a/apps/main-app/src/components/homology/constants.js +++ b/apps/main-app/src/components/homology/constants.js @@ -1,34 +1,10 @@ -const ALL_METHODS = { - 'Ensembl Compara': { - }, - HGNC: { - }, - Hieranoid: { - }, - InParanoid: { - }, - OMA: { - }, - OrthoFinder: { - }, - OrthoInspector: { - }, - PANTHER: { - }, - PhylomeDB: { - }, - SonicParanoid: { - }, - Xenbase: { - }, - ZFIN: { - } -}; +const ORTHOLOGY_METHODS = ['Ensembl Compara', 'HGNC','Hieranoid','InParanoid','OMA','OrthoFinder', + 'OrthoInspector','PANTHER','PhylomeDB','SonicParanoid','Xenbase','ZFIN']; const methodCellWidth = 25; const methodHeaderStyle = { - minWidth: methodCellWidth * Object.keys(ALL_METHODS).length, + minWidth: methodCellWidth * ORTHOLOGY_METHODS.length, height: '100px', }; @@ -52,7 +28,7 @@ const STRINGENCY_MED = 'moderate'; const STRINGNECY_LOW = 'low'; export { - ALL_METHODS, + ORTHOLOGY_METHODS, methodCellStyle, methodCellWidth, methodHeaderCellStyle, diff --git a/apps/main-app/src/components/homology/methodCell.js b/apps/main-app/src/components/homology/methodCell.js index fb979287a..e322a21fa 100644 --- a/apps/main-app/src/components/homology/methodCell.js +++ b/apps/main-app/src/components/homology/methodCell.js @@ -1,33 +1,34 @@ import PropTypes from 'prop-types'; import { UncontrolledTooltip } from 'reactstrap'; -import { ALL_METHODS, methodCellStyle } from './constants'; +import { ORTHOLOGY_METHODS, methodCellStyle } from './constants'; +import PARALOGY_METHODS from '../paralogy/methods'; const MethodCell = (props) => { const { predictionMethodsMatched, predictionMethodsNotMatched, - rowKey + rowKey, + paralogy } = props; const predictionMethodsMatchedSet = new Set(predictionMethodsMatched); const predictionMethodsNotMatchedSet = new Set(predictionMethodsNotMatched); - + const methods = paralogy ? PARALOGY_METHODS : ORTHOLOGY_METHODS; + return ( { - Object.keys(ALL_METHODS).sort().map((method) => { - const methodDisplayName = (ALL_METHODS[method] || {}).displayName || method; - + methods.map( (method) => { let symbol, tipText; if (predictionMethodsMatchedSet.has(method)) { symbol = '\u2611'; - tipText = `Match by ${methodDisplayName}`; + tipText = `Match by ${method}`; } else if (predictionMethodsNotMatchedSet.has(method)) { symbol = '\u2610'; - tipText = `No match by ${methodDisplayName}`; + tipText = `No match by ${method}`; } else { symbol = '\u00a0'; - tipText = `Comparision not available on ${methodDisplayName}`; + tipText = `Comparision not available on ${method}`; } const id = `${rowKey}-${method}`.replace(/[\s:]/g, '-'); @@ -50,7 +51,8 @@ const MethodCell = (props) => { MethodCell.propTypes = { predictionMethodsMatched: PropTypes.arrayOf(PropTypes.string), predictionMethodsNotMatched: PropTypes.arrayOf(PropTypes.string), - rowKey: PropTypes.string + rowKey: PropTypes.string, + paralogy: PropTypes.bool }; export default MethodCell; diff --git a/apps/main-app/src/components/homology/methodHeader.js b/apps/main-app/src/components/homology/methodHeader.js index 4981fdfb2..8724dc10b 100644 --- a/apps/main-app/src/components/homology/methodHeader.js +++ b/apps/main-app/src/components/homology/methodHeader.js @@ -1,18 +1,23 @@ import PropTypes from 'prop-types'; import MethodLogo from './methodLogo'; -import { ALL_METHODS, methodHeaderStyle } from './constants'; +import { ORTHOLOGY_METHODS, methodHeaderStyle } from './constants'; +import PARALOGY_METHODS from '../paralogy/methods' -const MethodHeader = ({name}) => ( +const MethodHeader = ({name, paralogy}) => { + const methods = paralogy ? PARALOGY_METHODS : ORTHOLOGY_METHODS; + return ( +
{name}
-
{ - Object.keys(ALL_METHODS).sort().map((methodKey) => ( +
{ + methods.map((methodKey) => ( )) }
-); +)}; MethodHeader.propTypes = { - name: PropTypes.string + name: PropTypes.string, + paralogy: PropTypes.bool }; export default MethodHeader; diff --git a/apps/main-app/src/components/homology/methodLogo.js b/apps/main-app/src/components/homology/methodLogo.js index 32cd5e4cb..1cbc3ba58 100644 --- a/apps/main-app/src/components/homology/methodLogo.js +++ b/apps/main-app/src/components/homology/methodLogo.js @@ -1,22 +1,21 @@ import PropTypes from 'prop-types'; import { UncontrolledTooltip } from 'reactstrap'; -import { ALL_METHODS, methodHeaderCellStyle } from './constants'; +import { methodHeaderCellStyle } from './constants'; const MethodLogo = ({methodKey}) => { - const methodName = (ALL_METHODS[methodKey] || {}).displayName || methodKey; const id = 'methodLogo-' + methodKey.replace(/\s/g, '-'); return ( - {methodName} + {methodKey} - {methodName} + {methodKey} ); }; MethodLogo.propTypes = { - methodKey: PropTypes.string + methodKey: PropTypes.string, }; export default MethodLogo; diff --git a/apps/main-app/src/components/orthology/orthologyTable.js b/apps/main-app/src/components/orthology/orthologyTable.js index c0cf6a9b8..c2d5e7006 100644 --- a/apps/main-app/src/components/orthology/orthologyTable.js +++ b/apps/main-app/src/components/orthology/orthologyTable.js @@ -92,6 +92,7 @@ class OrthologyTable extends Component { predictionMethodsMatched={orthData.predictionMethodsMatched} predictionMethodsNotMatched={orthData.predictionMethodsNotMatched} rowKey={orthId} + paralogy={false} /> ); diff --git a/apps/main-app/src/components/paralogy/methods.js b/apps/main-app/src/components/paralogy/methods.js new file mode 100644 index 000000000..515a6e2a9 --- /dev/null +++ b/apps/main-app/src/components/paralogy/methods.js @@ -0,0 +1,4 @@ +const PARALOGY_METHODS = ['Ensembl Compara','HGNC','InParanoid','OMA','OrthoFinder','OrthoInspector', + 'PANTHER','PhylomeDB','SonicParanoid','SGD']; + +export default PARALOGY_METHODS; diff --git a/apps/main-app/src/components/paralogy/paralogyTable.js b/apps/main-app/src/components/paralogy/paralogyTable.js index ef604e684..705290257 100644 --- a/apps/main-app/src/components/paralogy/paralogyTable.js +++ b/apps/main-app/src/components/paralogy/paralogyTable.js @@ -37,17 +37,18 @@ const ParalogyTable = ({geneId}) => { Gene symbol Rank - Alignment Length + Alignment Length (aa) Similarity % Identity % Method Count - + { results.map( result => { - return ( + const rowKey = 'paralogyrowkey-' + result.homologGene.id.replace(/\s/g, '-'); + return ( @@ -61,7 +62,8 @@ const ParalogyTable = ({geneId}) => { + rowKey={result.homologGene.id} + paralogy={true}/> )}) } From b24c41f6529a47f7db83a99b99616a492b39ec72 Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Tue, 12 Sep 2023 14:33:04 +0100 Subject: [PATCH 67/85] SCRUM-3222: add alignment help --- .../src/components/paralogy/alignmentHelp.js | 15 +++++++++++++++ .../src/components/paralogy/paralogyTable.js | 3 ++- 2 files changed, 17 insertions(+), 1 deletion(-) create mode 100644 apps/main-app/src/components/paralogy/alignmentHelp.js diff --git a/apps/main-app/src/components/paralogy/alignmentHelp.js b/apps/main-app/src/components/paralogy/alignmentHelp.js new file mode 100644 index 000000000..5bcd594ee --- /dev/null +++ b/apps/main-app/src/components/paralogy/alignmentHelp.js @@ -0,0 +1,15 @@ +export default function AlignmentHelp() { + return ( +
+

+ For the purpose of identifying alignment lengths, protein sequences were + obtained from the NCBI RefSeq database release 207. In scenarios where + multiple isoforms were available, the longest isoform was utilized. + + Alignments of the sequences were carried out via EMBOSS water software + utilizing the BLOSUM62 matrix and retaining all default configurations. +

+
+ ); + } + \ No newline at end of file diff --git a/apps/main-app/src/components/paralogy/paralogyTable.js b/apps/main-app/src/components/paralogy/paralogyTable.js index 705290257..93488503b 100644 --- a/apps/main-app/src/components/paralogy/paralogyTable.js +++ b/apps/main-app/src/components/paralogy/paralogyTable.js @@ -8,6 +8,7 @@ import MethodHeader from '../homology/methodHeader'; import MethodCell from '../homology/methodCell'; import HelpPopup from '../helpPopup'; import RankHelp from './rankHelp'; +import AlignmentHelp from './alignmentHelp'; const ParalogyTable = ({geneId}) => { const { data, isLoading } = useGeneParalogy(geneId); @@ -37,7 +38,7 @@ const ParalogyTable = ({geneId}) => { Gene symbol Rank - Alignment Length (aa) + Alignment length (aa) Similarity % Identity % Method Count From 317f078e52dfd9af2a90c3519b6bd11d5130aae6 Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Tue, 12 Sep 2023 15:07:16 +0100 Subject: [PATCH 68/85] SCRUM-3222: format numbers in table --- apps/main-app/src/components/paralogy/paralogyTable.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/apps/main-app/src/components/paralogy/paralogyTable.js b/apps/main-app/src/components/paralogy/paralogyTable.js index 93488503b..eb1c0585d 100644 --- a/apps/main-app/src/components/paralogy/paralogyTable.js +++ b/apps/main-app/src/components/paralogy/paralogyTable.js @@ -56,9 +56,9 @@ const ParalogyTable = ({geneId}) => { {result.rank} - {result.length} - {result.similarity} - {result.identity} + {result.length ? parseInt(result.length, 10) : ''} + {result.similarity ? (result.similarity*100).toFixed(1) : ''} + {result.identity ? (result.identity*100).toFixed(1) : ''} {result.methodCount} of {result.totalMethodCount} Date: Tue, 12 Sep 2023 11:33:19 -0400 Subject: [PATCH 69/85] Renamed files --- ...tage-alb-stack.ts => amplify-alb-stack.ts} | 27 +++++++++++-------- cdk/{cdk-stage.ts => cdk-app.ts} | 0 2 files changed, 16 insertions(+), 11 deletions(-) rename cdk/{stage-alb-stack.ts => amplify-alb-stack.ts} (79%) rename cdk/{cdk-stage.ts => cdk-app.ts} (100%) diff --git a/cdk/stage-alb-stack.ts b/cdk/amplify-alb-stack.ts similarity index 79% rename from cdk/stage-alb-stack.ts rename to cdk/amplify-alb-stack.ts index c5ec4cd9e..384b18c10 100644 --- a/cdk/stage-alb-stack.ts +++ b/cdk/amplify-alb-stack.ts @@ -6,15 +6,20 @@ import * as elbv2 from 'aws-cdk-lib/aws-elasticloadbalancingv2'; import * as targets from 'aws-cdk-lib/aws-elasticloadbalancingv2-targets'; import * as cdk from 'aws-cdk-lib'; -export class StageALBStack extends cdk.Stack { - constructor(scope: cdk.App, id: string, props?: cdk.StackProps) { +interface MultistackProps extends cdk.StackProps { + dnsName?: string, + targetInstanceId?: string +} + +export class AmplifyALBStack extends cdk.Stack { + constructor(scope: cdk.App, id: string, props?: MultistackProps) { super(scope, id, props); const vpc = ec2.Vpc.fromLookup(this, 'Docker', { vpcName: 'Docker' }); const sg1 = ec2.SecurityGroup.fromLookupById(this, 'default', 'sg-21ac675b'); const sg2 = ec2.SecurityGroup.fromLookupById(this, 'HTTP/HTTPS', 'sg-0415cab61ab6b45c5'); const cert = elbv2.ListenerCertificate.fromArn('arn:aws:acm:us-east-1:100225593120:certificate/047a56a2-09dd-4857-9f28-32d23650d4da'); - const stage = new targets.InstanceIdTarget('i-0d7ea7b7cc11a2e8f') + const targetInstance = new targets.InstanceIdTarget(props.targetInstanceId) const public_zone = route53.HostedZone.fromHostedZoneAttributes(this, 'Public Zone', { zoneName: 'alliancegenome.org', hostedZoneId: 'Z3IZ3D6V94JEC2' }); const private_zone = route53.HostedZone.fromHostedZoneAttributes(this, 'Private Zone', { zoneName: 'alliancegenome.org', hostedZoneId: 'Z007692222A6W93AZVSPD' }); @@ -28,13 +33,13 @@ export class StageALBStack extends cdk.Stack { new route53.CnameRecord(this, "Public DNS", { zone: public_zone, - recordName: "stage-alb", + recordName: props.dnsName + '-alb', domainName: alb.loadBalancerDnsName, ttl: cdk.Duration.minutes(5) }); new route53.CnameRecord(this, "Private DNS", { zone: private_zone, - recordName: "stage-alb", + recordName: props.dnsName + '-alb', domainName: alb.loadBalancerDnsName, ttl: cdk.Duration.minutes(5) }); @@ -45,7 +50,7 @@ export class StageALBStack extends cdk.Stack { certificates: [cert] }); - listener_https.addTargets("Backend Stage", { + listener_https.addTargets("Backend Server", { healthCheck: { path: '/robots.txt', unhealthyThresholdCount: 3, @@ -53,19 +58,19 @@ export class StageALBStack extends cdk.Stack { interval: cdk.Duration.seconds(60), }, port: 80, - targets: [stage], + targets: [targetInstance], }); /* - listener_https.addAction("Redirect to Stage", { + listener_https.addAction("Redirect to Server", { priority: 10, conditions: [ - elbv2.ListenerCondition.hostHeaders(['stage-alb.alliancegenome.org']), + elbv2.ListenerCondition.hostHeaders([props.dnsName + '-alb.alliancegenome.org']), ], action: elbv2.ListenerAction.redirect({ protocol: 'HTTPS', port: '443', - host: 'stage.alliancegenome.org', + host: '#{host}', path: '/#{path}', query: '#{query}', permanent: true, @@ -79,7 +84,7 @@ export class StageALBStack extends cdk.Stack { defaultAction: elbv2.ListenerAction.redirect({ protocol: 'HTTPS', port: '443', - host: 'stage.alliancegenome.org', + host: '#{host}', path: '/#{path}', query: '#{query}', permanent: true, diff --git a/cdk/cdk-stage.ts b/cdk/cdk-app.ts similarity index 100% rename from cdk/cdk-stage.ts rename to cdk/cdk-app.ts From f43089ade1fd3fc6e42da2418552c388e9de340c Mon Sep 17 00:00:00 2001 From: Olin Blodgett Date: Tue, 12 Sep 2023 12:05:59 -0400 Subject: [PATCH 70/85] Updated to multi stack cdk --- Makefile | 7 +++++-- cdk.json | 2 +- cdk/cdk-app.ts | 16 ++++++++++++++-- 3 files changed, 20 insertions(+), 5 deletions(-) diff --git a/Makefile b/Makefile index 7b158aab2..7c544beb1 100644 --- a/Makefile +++ b/Makefile @@ -23,8 +23,11 @@ test: run: npm start -alb-deploy: - npx aws-cdk deploy --outputs-file ./cdk-outputs.json +stage-alb-deploy: + npx aws-cdk deploy stage-alb-stack + +prod-alb-deploy: + npx aws-cdk deploy prod-alb-stack uirun: npm start diff --git a/cdk.json b/cdk.json index f0c49fded..5425dfa10 100644 --- a/cdk.json +++ b/cdk.json @@ -1,4 +1,4 @@ { - "app": "npx ts-node --prefer-ts-exts cdk/cdk-stage.ts", + "app": "npx ts-node --prefer-ts-exts cdk/cdk-app.ts", "context": {} } diff --git a/cdk/cdk-app.ts b/cdk/cdk-app.ts index 1514b7b37..b7d88bdde 100644 --- a/cdk/cdk-app.ts +++ b/cdk/cdk-app.ts @@ -1,11 +1,23 @@ #!/usr/bin/env node import * as cdk from 'aws-cdk-lib'; -import {StageALBStack} from './stage-alb-stack'; +import { AmplifyALBStack } from './amplify-alb-stack'; const app = new cdk.App(); -new StageALBStack(app, 'stage-alb-stack', { +new AmplifyALBStack(app, 'stage-alb-stack', { stackName: 'stage-alb-stack', + dnsName: 'stage', + targetInstanceId: 'i-0d7ea7b7cc11a2e8f', + env: { + region: process.env.CDK_DEFAULT_REGION, + account: process.env.CDK_DEFAULT_ACCOUNT, + }, +}); + +new AmplifyALBStack(app, 'prod-alb-stack', { + stackName: 'prod-alb-stack', + dnsName: 'prod', + targetInstanceId: 'i-0b3eb7fefadda7616', env: { region: process.env.CDK_DEFAULT_REGION, account: process.env.CDK_DEFAULT_ACCOUNT, From 8f14eb36b36d6dc2cc1edc6a8ae087d601fedb02 Mon Sep 17 00:00:00 2001 From: Olin Blodgett Date: Tue, 12 Sep 2023 13:36:42 -0400 Subject: [PATCH 71/85] Fix typescript error --- cdk/amplify-alb-stack.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/cdk/amplify-alb-stack.ts b/cdk/amplify-alb-stack.ts index 384b18c10..54d4ab733 100644 --- a/cdk/amplify-alb-stack.ts +++ b/cdk/amplify-alb-stack.ts @@ -6,13 +6,13 @@ import * as elbv2 from 'aws-cdk-lib/aws-elasticloadbalancingv2'; import * as targets from 'aws-cdk-lib/aws-elasticloadbalancingv2-targets'; import * as cdk from 'aws-cdk-lib'; -interface MultistackProps extends cdk.StackProps { - dnsName?: string, - targetInstanceId?: string +export interface MultistackProps extends cdk.StackProps { + dnsName: string, + targetInstanceId: string } export class AmplifyALBStack extends cdk.Stack { - constructor(scope: cdk.App, id: string, props?: MultistackProps) { + constructor(scope: cdk.App, id: string, props: MultistackProps) { super(scope, id, props); const vpc = ec2.Vpc.fromLookup(this, 'Docker', { vpcName: 'Docker' }); From 4be6875960889ede960bb9a14afc7e780f8edc92 Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Wed, 13 Sep 2023 14:08:39 +0100 Subject: [PATCH 72/85] SCRUM-3222: remove formatting since API is doing it now --- apps/main-app/src/components/paralogy/paralogyTable.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/apps/main-app/src/components/paralogy/paralogyTable.js b/apps/main-app/src/components/paralogy/paralogyTable.js index eb1c0585d..93488503b 100644 --- a/apps/main-app/src/components/paralogy/paralogyTable.js +++ b/apps/main-app/src/components/paralogy/paralogyTable.js @@ -56,9 +56,9 @@ const ParalogyTable = ({geneId}) => { {result.rank} - {result.length ? parseInt(result.length, 10) : ''} - {result.similarity ? (result.similarity*100).toFixed(1) : ''} - {result.identity ? (result.identity*100).toFixed(1) : ''} + {result.length} + {result.similarity} + {result.identity} {result.methodCount} of {result.totalMethodCount} Date: Thu, 14 Sep 2023 13:46:34 +0100 Subject: [PATCH 73/85] SCRUM-3222: remove auto-capitalization --- apps/main-app/src/components/paralogy/paralogyTable.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/main-app/src/components/paralogy/paralogyTable.js b/apps/main-app/src/components/paralogy/paralogyTable.js index 93488503b..a990838dd 100644 --- a/apps/main-app/src/components/paralogy/paralogyTable.js +++ b/apps/main-app/src/components/paralogy/paralogyTable.js @@ -34,11 +34,11 @@ const ParalogyTable = ({geneId}) => {
- + - + From 8e77e8656a72677ee8943327f0093038d5a50d38 Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Thu, 14 Sep 2023 14:12:35 +0100 Subject: [PATCH 74/85] SCRUM-3222: expand help paragraph for rank --- apps/main-app/src/components/paralogy/rankHelp.js | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/apps/main-app/src/components/paralogy/rankHelp.js b/apps/main-app/src/components/paralogy/rankHelp.js index 374d50a1b..1cc6797b7 100644 --- a/apps/main-app/src/components/paralogy/rankHelp.js +++ b/apps/main-app/src/components/paralogy/rankHelp.js @@ -5,12 +5,17 @@ export default function RankHelp() {

Rank is calculated via the highest percent similarity within four quartiles of alignment length (determined by using four 25% - quartiles derived from the longest paralog alignment length). - + quartiles derived from the longest paralog alignment length). +

+

Paralogs with the longest alignment and greatest similarity - percentage are ranked highest and DIOPT algorithm matches are - used as secondary ranking criteria in cases of equal similarity - within alignment length quartiles. Multiple entries can share the same rank. + percentage are ranked highest. Identity is used as a secondary + criteria for paralogs with identical alignment and similarity. +

+

+ DIOPT algorithm matches are used as a tertiary ranking criteria + in cases of equal similarity and identity within alignment + length quartiles. Multiple entries can share the same rank.

); } From 007e428bb7ab947aafd1f4bc1c9e342ccb0ff336 Mon Sep 17 00:00:00 2001 From: Scott Cain Date: Fri, 15 Sep 2023 11:04:22 -0700 Subject: [PATCH 75/85] bumping sequence panel version to address https://agr-jira.atlassian.net/browse/KANBAN-382 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 35e4ec9f1..bbb58c0da 100644 --- a/package.json +++ b/package.json @@ -50,7 +50,7 @@ "custom-event-polyfill": "^1.0.6", "d3-selection": "2.0.0", "document-register-element": "1.13.1", - "generic-sequence-panel": "^1.2.1", + "generic-sequence-panel": "^1.2.3", "html-react-parser": "^0.10.0", "immutable": "^3.8.1", "js-yaml": "^4.1.0", From 914471ff38653c33ea9a18ace4810645af470473 Mon Sep 17 00:00:00 2001 From: Scott Cain Date: Mon, 18 Sep 2023 11:05:34 -0700 Subject: [PATCH 76/85] fixing spacing and class issues --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index bbb58c0da..e232d1dee 100644 --- a/package.json +++ b/package.json @@ -50,7 +50,7 @@ "custom-event-polyfill": "^1.0.6", "d3-selection": "2.0.0", "document-register-element": "1.13.1", - "generic-sequence-panel": "^1.2.3", + "generic-sequence-panel": "^1.2.4", "html-react-parser": "^0.10.0", "immutable": "^3.8.1", "js-yaml": "^4.1.0", From 2dc6a65d169b99c14fe2b1195b1480f695768540 Mon Sep 17 00:00:00 2001 From: Scott Cain Date: Thu, 21 Sep 2023 11:30:29 -0700 Subject: [PATCH 77/85] bumping seqpanel version improving the look and feel: updated button text per Paul's suggestion and removed the download arrows --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index e232d1dee..37385019b 100644 --- a/package.json +++ b/package.json @@ -50,7 +50,7 @@ "custom-event-polyfill": "^1.0.6", "d3-selection": "2.0.0", "document-register-element": "1.13.1", - "generic-sequence-panel": "^1.2.4", + "generic-sequence-panel": "^1.2.5", "html-react-parser": "^0.10.0", "immutable": "^3.8.1", "js-yaml": "^4.1.0", From f613d49f9dd5562f6852cd1c7e694ef776946981 Mon Sep 17 00:00:00 2001 From: Christopher Tabone Date: Mon, 25 Sep 2023 14:09:40 -0300 Subject: [PATCH 78/85] Updated rank description. --- .../src/components/paralogy/rankHelp.js | 20 +++++++++---------- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/apps/main-app/src/components/paralogy/rankHelp.js b/apps/main-app/src/components/paralogy/rankHelp.js index 1cc6797b7..08cc21109 100644 --- a/apps/main-app/src/components/paralogy/rankHelp.js +++ b/apps/main-app/src/components/paralogy/rankHelp.js @@ -1,21 +1,19 @@ - export default function RankHelp() { return (

- Rank is calculated via the highest percent similarity within - four quartiles of alignment length (determined by using four 25% - quartiles derived from the longest paralog alignment length). + The ranking score is calculated using a weighted formula: + Score = w₁ x (Alignment Length x Similarity %) + w₂ x (Alignment Length x Identity %) + w₃ x (Method Count) + w₄ x (Alignment Length).

- Paralogs with the longest alignment and greatest similarity - percentage are ranked highest. Identity is used as a secondary - criteria for paralogs with identical alignment and similarity. + Where the weights are as follows: + - w₁ = 1.000: Weight for the absolute number of similar amino acids. + - w₂ = 1.000: Weight for the absolute number of identical amino acids. + - w₃ = 1.500: Weight for the method count. + - w₄ = 1.500: Weight for the alignment length.

- DIOPT algorithm matches are used as a tertiary ranking criteria - in cases of equal similarity and identity within alignment - length quartiles. Multiple entries can share the same rank. + Multiple entries can share the same rank.

); - } + } \ No newline at end of file From 67b120ce90d560faeb3d59ce522ce2780bd83eb0 Mon Sep 17 00:00:00 2001 From: Olin Blodgett Date: Mon, 25 Sep 2023 18:50:32 -0700 Subject: [PATCH 79/85] Update test ALB --- cdk.context.json | 90 ++++++++++++++++++++++++++++++++++++++++++++++++ cdk/cdk-app.ts | 10 ++++++ 2 files changed, 100 insertions(+) create mode 100644 cdk.context.json diff --git a/cdk.context.json b/cdk.context.json new file mode 100644 index 000000000..52aef963e --- /dev/null +++ b/cdk.context.json @@ -0,0 +1,90 @@ +{ + "vpc-provider:account=100225593120:filter.tag:Name=Docker:region=us-east-1:returnAsymmetricSubnets=true": { + "vpcId": "vpc-55522232", + "vpcCidrBlock": "172.31.0.0/16", + "ownerAccountId": "100225593120", + "availabilityZones": [], + "subnetGroups": [ + { + "name": "Public", + "type": "Public", + "subnets": [ + { + "subnetId": "subnet-3ebf4477", + "cidr": "172.31.0.0/20", + "availabilityZone": "us-east-1a", + "routeTableId": "rtb-c63af6a0" + }, + { + "subnetId": "subnet-df7c7487", + "cidr": "172.31.16.0/20", + "availabilityZone": "us-east-1b", + "routeTableId": "rtb-c63af6a0" + }, + { + "subnetId": "subnet-81c95ee4", + "cidr": "172.31.64.0/20", + "availabilityZone": "us-east-1c", + "routeTableId": "rtb-c63af6a0" + }, + { + "subnetId": "subnet-ff838bd5", + "cidr": "172.31.48.0/20", + "availabilityZone": "us-east-1d", + "routeTableId": "rtb-c63af6a0" + }, + { + "subnetId": "subnet-af62dca3", + "cidr": "172.31.80.0/20", + "availabilityZone": "us-east-1f", + "routeTableId": "rtb-c63af6a0" + } + ] + }, + { + "name": "Private", + "type": "Private", + "subnets": [ + { + "subnetId": "subnet-0d4703177afb1797d", + "cidr": "172.31.96.0/24", + "availabilityZone": "us-east-1a", + "routeTableId": "rtb-05e12b551f60b37ed" + }, + { + "subnetId": "subnet-04262fc338f638054", + "cidr": "172.31.97.0/24", + "availabilityZone": "us-east-1b", + "routeTableId": "rtb-05e12b551f60b37ed" + }, + { + "subnetId": "subnet-044457c061edf85f2", + "cidr": "172.31.98.0/24", + "availabilityZone": "us-east-1c", + "routeTableId": "rtb-05e12b551f60b37ed" + }, + { + "subnetId": "subnet-04019d42d5c9e6fb9", + "cidr": "172.31.99.0/24", + "availabilityZone": "us-east-1d", + "routeTableId": "rtb-05e12b551f60b37ed" + }, + { + "subnetId": "subnet-049778993fb504a7c", + "cidr": "172.31.101.0/24", + "availabilityZone": "us-east-1f", + "routeTableId": "rtb-05e12b551f60b37ed" + } + ] + } + ] + }, + "security-group:account=100225593120:region=us-east-1:securityGroupId=sg-21ac675b": { + "securityGroupId": "sg-21ac675b", + "allowAllOutbound": false + }, + "security-group:account=100225593120:region=us-east-1:securityGroupId=sg-0415cab61ab6b45c5": { + "securityGroupId": "sg-0415cab61ab6b45c5", + "allowAllOutbound": false + } +} diff --git a/cdk/cdk-app.ts b/cdk/cdk-app.ts index b7d88bdde..048aabbb9 100644 --- a/cdk/cdk-app.ts +++ b/cdk/cdk-app.ts @@ -14,6 +14,16 @@ new AmplifyALBStack(app, 'stage-alb-stack', { }, }); +new AmplifyALBStack(app, 'test-alb-stack', { + stackName: 'test-alb-stack', + dnsName: 'test', + targetInstanceId: 'i-0b3c6166858f87457', + env: { + region: process.env.CDK_DEFAULT_REGION, + account: process.env.CDK_DEFAULT_ACCOUNT, + }, +}); + new AmplifyALBStack(app, 'prod-alb-stack', { stackName: 'prod-alb-stack', dnsName: 'prod', From b6bda42053d6959600abd5a0b882c6c248fc7095 Mon Sep 17 00:00:00 2001 From: Olin Blodgett Date: Mon, 25 Sep 2023 18:59:12 -0700 Subject: [PATCH 80/85] Added make target for test ALB deployment --- Makefile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Makefile b/Makefile index 7c544beb1..97aaea787 100644 --- a/Makefile +++ b/Makefile @@ -26,6 +26,9 @@ run: stage-alb-deploy: npx aws-cdk deploy stage-alb-stack +test-alb-deploy: + npx aws-cdk deploy test-alb-stack + prod-alb-deploy: npx aws-cdk deploy prod-alb-stack From 2f2cb966bebdd3972b5f8e23e6933a44b48d079d Mon Sep 17 00:00:00 2001 From: Chris Tabone Date: Tue, 26 Sep 2023 09:27:50 -0300 Subject: [PATCH 81/85] Update rankHelp.js --- apps/main-app/src/components/paralogy/rankHelp.js | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/apps/main-app/src/components/paralogy/rankHelp.js b/apps/main-app/src/components/paralogy/rankHelp.js index 08cc21109..b2d7e45e3 100644 --- a/apps/main-app/src/components/paralogy/rankHelp.js +++ b/apps/main-app/src/components/paralogy/rankHelp.js @@ -6,14 +6,14 @@ export default function RankHelp() { Score = w₁ x (Alignment Length x Similarity %) + w₂ x (Alignment Length x Identity %) + w₃ x (Method Count) + w₄ x (Alignment Length).

- Where the weights are as follows: - - w₁ = 1.000: Weight for the absolute number of similar amino acids. - - w₂ = 1.000: Weight for the absolute number of identical amino acids. - - w₃ = 1.500: Weight for the method count. - - w₄ = 1.500: Weight for the alignment length. + Where the weights are as follows:
+ w₁ = 1.000: Weight for the absolute number of similar amino acids.
+ w₂ = 1.000: Weight for the absolute number of identical amino acids.
+ w₃ = 1.500: Weight for the method count.
+ w₄ = 1.500: Weight for the alignment length.

Multiple entries can share the same rank.

); - } \ No newline at end of file + } From f98ab4a0fc068f3f0900d6ec44d80492f7a4e9cb Mon Sep 17 00:00:00 2001 From: Chris Tabone Date: Tue, 26 Sep 2023 09:29:30 -0300 Subject: [PATCH 82/85] Update rankHelp.js --- apps/main-app/src/components/paralogy/rankHelp.js | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/apps/main-app/src/components/paralogy/rankHelp.js b/apps/main-app/src/components/paralogy/rankHelp.js index b2d7e45e3..5613157fe 100644 --- a/apps/main-app/src/components/paralogy/rankHelp.js +++ b/apps/main-app/src/components/paralogy/rankHelp.js @@ -7,10 +7,12 @@ export default function RankHelp() {

Where the weights are as follows:
- w₁ = 1.000: Weight for the absolute number of similar amino acids.
- w₂ = 1.000: Weight for the absolute number of identical amino acids.
- w₃ = 1.500: Weight for the method count.
- w₄ = 1.500: Weight for the alignment length.
+

    +
  • w₁ = 1.000: Weight for the absolute number of similar amino acids.
  • +
  • w₂ = 1.000: Weight for the absolute number of identical amino acids.
  • +
  • w₃ = 1.500: Weight for the method count.
  • +
  • w₄ = 1.500: Weight for the alignment length.
  • +

Multiple entries can share the same rank. From f36729727f66d85c84050de05de011b6bf3fc9bf Mon Sep 17 00:00:00 2001 From: Andres Becerra Date: Tue, 26 Sep 2023 15:58:55 +0100 Subject: [PATCH 83/85] Fix html tag --- apps/main-app/src/components/paralogy/rankHelp.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/main-app/src/components/paralogy/rankHelp.js b/apps/main-app/src/components/paralogy/rankHelp.js index 5613157fe..7a256fd65 100644 --- a/apps/main-app/src/components/paralogy/rankHelp.js +++ b/apps/main-app/src/components/paralogy/rankHelp.js @@ -6,14 +6,14 @@ export default function RankHelp() { Score = w₁ x (Alignment Length x Similarity %) + w₂ x (Alignment Length x Identity %) + w₃ x (Method Count) + w₄ x (Alignment Length).

- Where the weights are as follows:
+ Where the weights are as follows: +

  • w₁ = 1.000: Weight for the absolute number of similar amino acids.
  • w₂ = 1.000: Weight for the absolute number of identical amino acids.
  • w₃ = 1.500: Weight for the method count.
  • w₄ = 1.500: Weight for the alignment length.
-

Multiple entries can share the same rank.

From b0efd5c8afb9698a6ebfc20797c0891efc30c195 Mon Sep 17 00:00:00 2001 From: Scott Cain Date: Wed, 27 Sep 2023 10:40:16 -0700 Subject: [PATCH 84/85] adding help text for seq details. UNTESTED! --- .../sequencePanel/sequencePanelSectionHelp.js | 44 +++++++++++++++++++ .../main-app/src/containers/genePage/index.js | 3 +- 2 files changed, 46 insertions(+), 1 deletion(-) create mode 100644 apps/main-app/src/components/sequencePanel/sequencePanelSectionHelp.js diff --git a/apps/main-app/src/components/sequencePanel/sequencePanelSectionHelp.js b/apps/main-app/src/components/sequencePanel/sequencePanelSectionHelp.js new file mode 100644 index 000000000..7e44ec4bc --- /dev/null +++ b/apps/main-app/src/components/sequencePanel/sequencePanelSectionHelp.js @@ -0,0 +1,44 @@ +import React from 'react'; + +const SequencePanelSectionHelp = () => ( +
+

+ The set of genome features contributed by each MOD is used by this + section to obtain the sequence of the gene and a list of transcripts. + When a transcript is selected, Sequence Details will highlight it + according to the scheme selected in the “Mode” menu. The options are: +

+
    +
  • gene - The genomic sequence from start to end with portions that + are UTR and coding highlighted
  • +
  • CDS - The coding sequence of the mRNA that is the result of in + silico splicing
  • +
  • cDNA - The CDS with UTRs added
  • +
  • protein - The amino acid sequence that results from the CDS in + silico transcription
  • +
  • genomic - The stretch of sequence from start to end with no + special highlighting
  • +
  • genomic +500bp up and down stream - The stretch of sequence from + start to end with 500 base pairs of padding on both ends
  • +
  • gene with collapsed introns - same as gene, but the introns are + compressed to 10 base pairs at the splice junction and the remainder + replaced with ellipses
  • +
  • gene with 500bp up and down stream - same as “gene” but with 500bp + of up and down stream sequence added
  • +
  • gene with 500bp up and down stream and collapsed introns - same as + “gene with collapsed introns” but with up and downstream padding + added
  • +
+

+ After selecting the mode, you can copy either the “plain text” of the + sequence (that is, without any color highlighting) or copy the + highlighted text with the provided buttons. The plain text option is + provided for copying into web forms (such as BLAST) and text editors that + don’t allow formatting. The copy with highlights button will allow you to + paste into a “rich” text editor that will preserve the highlighting from + the web page. +

+
+); + +export default SequencePanelSectionHelp; diff --git a/apps/main-app/src/containers/genePage/index.js b/apps/main-app/src/containers/genePage/index.js index f3739a796..49aa2c9d8 100644 --- a/apps/main-app/src/containers/genePage/index.js +++ b/apps/main-app/src/containers/genePage/index.js @@ -45,6 +45,7 @@ import GeneSymbol from '../../components/GeneSymbol'; import PhenotypeCrossRefs from './PhenotypeCrossRefs'; import SpeciesName from '../../components/SpeciesName'; import SequenceFeatureViewerSectionHelp from '../../components/sequenceFeatureViewer/sequenceFeatureViewerSectionHelp'; +import SequencePanelSectionHelp from '../../components/sequencePanel/sequencePanelSectionHelp'; import TransgenicAlleleSectionHelp from '../../components/transgenicAlleles/transgenicAllelesSectionHelp'; import DiseaseSectionHelp from '../../components/disease/diseaseSectionHelp'; @@ -212,7 +213,7 @@ const GenePage = ({geneId}) => { /> - + help={} Date: Wed, 27 Sep 2023 12:21:36 -0700 Subject: [PATCH 85/85] fixed formatting/syntax --- apps/main-app/src/containers/genePage/index.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/apps/main-app/src/containers/genePage/index.js b/apps/main-app/src/containers/genePage/index.js index 49aa2c9d8..9faef3115 100644 --- a/apps/main-app/src/containers/genePage/index.js +++ b/apps/main-app/src/containers/genePage/index.js @@ -213,7 +213,10 @@ const GenePage = ({geneId}) => { /> - help={} + } + title={SEQUENCE_DETAILS} + >
Gene symbol Rank Alignment length (aa) Alignment Length (aa) Similarity % Identity % Method Count