-
Notifications
You must be signed in to change notification settings - Fork 568
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Clickhouse mode of study view (#11224)
Add Clickhouse implementation of study view endpoints (off by default) with legacy api intact --------- Co-authored-by: haynescd <[email protected]> --------- Co-authored-by: haynescd <[email protected]> Co-authored-by: Charles Haynes <[email protected]> Co-authored-by: Onur Sumer <[email protected]> Co-authored-by: Neel Kuila <[email protected]> Co-authored-by: Bryan Lai <[email protected]> Co-authored-by: Zhaoyuan (Ryan) Fu <[email protected]> Co-authored-by: Qi-Xuan Lu <[email protected]> Co-authored-by: Bryan Lai <[email protected]> Co-authored-by: Gaofei Zhao <[email protected]> Co-authored-by: Robert Sheridan <[email protected]> Co-authored-by: Zain Nasir <[email protected]> Co-authored-by: Zain Nasir <[email protected]> Co-authored-by: haynescd <[email protected]>
- Loading branch information
1 parent
be86bae
commit 39caae5
Showing
137 changed files
with
26,236 additions
and
431 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -223,6 +223,134 @@ jobs: | |
DOCKER_IMAGE_SESSION_SERVICE: cbioportal/session-service:0.5.0 | ||
FRONTEND_TEST_DO_NOT_LOAD_EXTERNAL_FRONTEND: true | ||
|
||
pull_cbioportal_test_codebase: | ||
machine: | ||
image: ubuntu-2204:2024.08.1 | ||
resource_class: medium | ||
working_directory: /tmp/repos | ||
steps: | ||
- run: | ||
name: Checkout cbioportal/cbioportal-test | ||
environment: | ||
TEST_REPO_URL: https://github.com/cBioPortal/cbioportal-test | ||
command: | | ||
git clone ${TEST_REPO_URL} | ||
- persist_to_workspace: | ||
root: /tmp/repos | ||
paths: | ||
- cbioportal-test | ||
|
||
pull_cbioportal_frontend_codebase: | ||
machine: | ||
image: ubuntu-2204:2024.08.1 | ||
resource_class: medium | ||
working_directory: /tmp/repos | ||
steps: | ||
- run: | ||
name: Checkout cbioportal/cbioportal-frontend | ||
environment: | ||
FRONTEND_REPO_URL: https://github.com/cBioPortal/cbioportal-frontend.git | ||
FRONTEND_REPO_BRANCH: master | ||
command: | | ||
git clone -b ${FRONTEND_REPO_BRANCH} --single-branch ${FRONTEND_REPO_URL} | ||
- persist_to_workspace: | ||
root: /tmp/repos | ||
paths: | ||
- cbioportal-frontend | ||
|
||
build_push_image: | ||
machine: | ||
image: ubuntu-2204:2024.08.1 | ||
resource_class: medium | ||
working_directory: /tmp/repos | ||
steps: | ||
- attach_workspace: | ||
at: /tmp/repos | ||
- checkout: | ||
path: /tmp/repos/cbioportal | ||
- run: | ||
name: Build cBioPortal docker image | ||
environment: | ||
DOCKER_REPO: cbioportal/cbioportal-dev | ||
command: | | ||
export DOCKER_TAG=$CIRCLE_SHA1 | ||
URL="https://hub.docker.com/v2/repositories/cbioportal/cbioportal-dev/tags/$DOCKER_TAG-web-shenandoah" | ||
TAG_FOUND=$(curl -s $URL | jq -r .name) | ||
if [ $TAG_FOUND = "$DOCKER_TAG-web-shenandoah" ]; then | ||
echo "Image already exists. Skipping build step!" | ||
exit 0 | ||
fi | ||
cd cbioportal-test | ||
./scripts/build-push-image.sh --src=/tmp/repos/cbioportal --push=true --skip_web_and_data=true | ||
EXISTS=$(docker manifest inspect $DOCKER_REPO:$DOCKER_TAG-web-shenandoah > /dev/null; echo $?) | ||
if [ $EXISTS -eq 0 ]; then | ||
echo "Build succeeded!" | ||
else | ||
echo "Build failed!" | ||
exit 1 | ||
fi | ||
run_api_tests: | ||
machine: | ||
image: ubuntu-2204:2024.08.1 | ||
docker_layer_caching: true | ||
resource_class: large | ||
working_directory: /tmp/repos | ||
steps: | ||
- attach_workspace: | ||
at: /tmp/repos | ||
- checkout: | ||
path: /tmp/repos/cbioportal | ||
- run: | ||
name: Instantiate a cbioportal instance | ||
environment: | ||
DOCKER_REPO: cbioportal/cbioportal-dev | ||
APP_CLICKHOUSE_MODE: "true" | ||
command: | | ||
cd cbioportal-test | ||
export DOCKER_IMAGE_CBIOPORTAL=$DOCKER_REPO:$CIRCLE_SHA1-web-shenandoah | ||
nohup ./scripts/docker-compose.sh >> /tmp/repos/docker-compose-logs.txt 2>&1 & | ||
- run: | ||
name: Wait for cbioportal to be live at localhost | ||
command: | | ||
cd cbioportal-test | ||
./utils/check-connection.sh --url=localhost:8080 | ||
- run: | ||
name: Confirm cbioportal config matches PR | ||
command: | | ||
cd cbioportal | ||
echo "Matching gitCommitId..." | ||
INSTANCE_COMMIT_ID=$(curl -s http://localhost:8080/api/info | jq -r '.["gitCommitId"]') | ||
PR_COMMIT_ID=$CIRCLE_SHA1 | ||
if [ "$INSTANCE_COMMIT_ID" = "$PR_COMMIT_ID" ]; then | ||
echo "gitCommitId successfully matched!" | ||
echo "cBioPortal is ready:" | ||
curl -s http://localhost:8080/api/info | jq | ||
exit 0 | ||
else | ||
echo "gitCommitIds do not match!" | ||
echo "Instance Commit ID: $INSTANCE_COMMIT_ID" | ||
echo "PR Commit ID: $PR_COMMIT_ID" | ||
exit 1 | ||
fi | ||
- run: | ||
name: Run API Tests | ||
environment: | ||
API_TEST_HOST: http://localhost:8080 | ||
BACKEND_ROOT: /tmp/repos/cbioportal | ||
command: | | ||
cd cbioportal-frontend | ||
nvm install 15.2.1 | ||
nvm use 15.2.1 | ||
npm install -g [email protected] | ||
yarn --ignore-engines | ||
yarn run apitests | ||
- store_artifacts: | ||
path: /tmp/repos/cbioportal-test/web-metadata.json | ||
- store_artifacts: | ||
path: /tmp/repos/docker-compose-logs.txt | ||
|
||
|
||
workflows: | ||
version: 2 | ||
|
@@ -238,3 +366,22 @@ workflows: | |
- build_backend | ||
- pull_frontend_codebase | ||
- install_yarn | ||
api_tests: | ||
jobs: | ||
- pull_cbioportal_test_codebase | ||
- pull_cbioportal_frontend_codebase | ||
- wait_for_approval: | ||
type: approval | ||
requires: | ||
- pull_cbioportal_test_codebase | ||
- pull_cbioportal_frontend_codebase | ||
- build_push_image: | ||
context: | ||
- api-tests | ||
requires: | ||
- wait_for_approval | ||
- run_api_tests: | ||
context: | ||
- api-tests | ||
requires: | ||
- build_push_image |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
package org.cbioportal.model; | ||
|
||
public enum AlterationType { | ||
MUTATION, | ||
COPY_NUMBER_ALTERATION | ||
MUTATION_EXTENDED, | ||
COPY_NUMBER_ALTERATION, | ||
STRUCTURAL_VARIANT, | ||
GENERIC_ASSAY; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 3 additions & 1 deletion
4
src/main/java/org/cbioportal/model/ClinicalViolinPlotBoxData.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
src/main/java/org/cbioportal/model/ClinicalViolinPlotData.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 3 additions & 1 deletion
4
src/main/java/org/cbioportal/model/ClinicalViolinPlotIndividualPoint.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
src/main/java/org/cbioportal/model/ClinicalViolinPlotRowData.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.