Skip to content

Commit 0d25f3e

Browse files
committed
Add initial configuration and sample data files
Introduce application properties for database configuration and dashboard settings. Add Docker commands for local development with weights configuration. Include weights.csv as sample data and dictonaryReqeust.http for testing API requests.
1 parent 0545f11 commit 0d25f3e

File tree

5 files changed

+56
-0
lines changed

5 files changed

+56
-0
lines changed

dictionaryweights/README.md

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
## Docker commands for local development
2+
### Docker build
3+
```bash
4+
docker build --no-cache --build-arg SPRING_PROFILE=bdc-dev -t weights:latest .
5+
```
6+
7+
### Docker run
8+
You will need a local weights.csv file.
9+
```bash
10+
docker run --rm -t --name dictionary-weights --network=host -v ./weights.csv:/weights.csv weights:latest
11+
```
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
spring.application.name=dictionaryweights
2+
spring.main.web-application-type=none
3+
4+
spring.datasource.url=jdbc:postgresql://localhost:5432/dictionary_db?currentSchema=dict
5+
spring.datasource.username=username
6+
spring.datasource.password=password
7+
spring.datasource.driver-class-name=org.postgresql.Driver
8+
9+
weights.filename=/weights.csv

dictionaryweights/weights.csv

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
concept_node.DISPLAY,2
2+
concept_node.CONCEPT_PATH,2
3+
dataset.FULL_NAME,1
4+
dataset.DESCRIPTION,1
5+
parent.DISPLAY,1
6+
grandparent.DISPLAY,1
7+
concept_node_meta_str,1

dictonaryReqeust.http

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# curl 'https://dev.picsure.biodatacatalyst.nhlbi.nih.gov/picsure/proxy/dictionary-api/concepts?page_number=1&page_size=1'
2+
# -H 'origin: https://dev.picsure.biodatacatalyst.nhlbi.nih.gov'
3+
# -H 'referer: https://dev.picsure.biodatacatalyst.nhlbi.nih.gov/'
4+
# --data-raw '{"facets":[],"search":"","consents":[]}'
5+
POST http://localhost:80/concepts?page_number=0&page_size=100
6+
Content-Type: application/json
7+
8+
{"facets":[],"search":"lipid triglyceride"}
9+
10+
###
11+
12+
POST http://localhost:80/search
13+
Content-Type: application/json
14+
15+
{"@type":"GeneralQueryRequest","resourceCredentials":{},"query":{"searchTerm":"breast","includedTags":[],"excludedTags":[],"returnTags":"true","offset":0,"limit":10000000},"resourceUUID":null}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
spring.application.name=dictionary
2+
spring.datasource.url=jdbc:postgresql://localhost:5432/dictionary_db?currentSchema=dict
3+
spring.datasource.username=username
4+
spring.datasource.password=password
5+
spring.datasource.driver-class-name=org.postgresql.Driver
6+
server.port=80
7+
8+
dashboard.columns={abbreviation:'Abbreviation',name:'Name',clinvars:'Clinical Variables'}
9+
dashboard.column-order=abbreviation,name,clinvars
10+
dashboard.nonmeta-columns=abbreviation,name
11+
dashboard.enable.extra_details=true
12+
dashboard.enable.bdc_hack=true
13+
14+
filtering.unfilterable_concepts=stigmatized

0 commit comments

Comments
 (0)