Skip to content

Commit 867d3e1

Browse files
Merge pull request #798 from samply/release-v0.18.0
Release v0.18.0
2 parents 40c0939 + c8a8078 commit 867d3e1

File tree

158 files changed

+3690
-760
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

158 files changed

+3690
-760
lines changed

.github/scripts/batch-metadata.sh

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
#!/bin/bash -e
2+
3+
#
4+
# This script fetches the CapabilityStatement through a batch request.
5+
#
6+
7+
BASE="http://localhost:8080/fhir"
8+
9+
bundle() {
10+
cat <<END
11+
{
12+
"resourceType": "Bundle",
13+
"type": "batch",
14+
"entry": [
15+
{
16+
"request": {
17+
"method": "GET",
18+
"url": "metadata"
19+
}
20+
}
21+
]
22+
}
23+
END
24+
}
25+
RESULT=$(curl -sH "Content-Type: application/fhir+json" -d "$(bundle)" "$BASE")
26+
27+
RESOURCE_TYPE="$(echo "$RESULT" | jq -r .resourceType)"
28+
if [ "$RESOURCE_TYPE" = "Bundle" ]; then
29+
echo "OK: the resource type is Bundle"
30+
else
31+
echo "Fail: the resource type is $RESOURCE_TYPE, expected Bundle"
32+
exit 1
33+
fi
34+
35+
BUNDLE_TYPE="$(echo "$RESULT" | jq -r .type)"
36+
if [ "$BUNDLE_TYPE" = "batch-response" ]; then
37+
echo "OK: the bundle type is batch-response"
38+
else
39+
echo "Fail: the bundle type is $BUNDLE_TYPE, expected batch-response"
40+
exit 1
41+
fi
42+
43+
RESPONSE_STATUS="$(echo "$RESULT" | jq -r .entry[].response.status)"
44+
if [ "$RESPONSE_STATUS" = "200" ]; then
45+
echo "OK: the response status is 200"
46+
else
47+
echo "Fail: the response status is $RESPONSE_STATUS, expected 200"
48+
exit 1
49+
fi
50+
51+
RESPONSE_RESOURCE_TYPE="$(echo "$RESULT" | jq -r .entry[].resource.resourceType)"
52+
if [ "$RESPONSE_RESOURCE_TYPE" = "CapabilityStatement" ]; then
53+
echo "OK: resource type is CapabilityStatement"
54+
else
55+
echo "Fail: resource type was $RESPONSE_RESOURCE_TYPE but should be CapabilityStatement"
56+
exit 1
57+
fi

.github/scripts/batch.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,6 @@ RESPONSE_PATIENT_ID="$(echo "$RESULT" | jq -r .entry[].resource.id)"
5555
if [ "$RESPONSE_PATIENT_ID" = "$PATIENT_ID" ]; then
5656
echo "OK: patient id's match"
5757
else
58-
echo "Fail: response patient id was $RESPONSE_PATIENT_ID but should be $RESPONSE_PATIENT_ID"
58+
echo "Fail: response patient id was $RESPONSE_PATIENT_ID but should be $PATIENT_ID"
5959
exit 1
6060
fi
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
#!/bin/bash -e
2+
3+
BASE="http://localhost:8080/fhir"
4+
TYPE=$1
5+
QUERY=$2
6+
SORT=$3
7+
EXPECTED_SIZE=$4
8+
FILE_NAME_PREFIX="$(uuidgen)"
9+
10+
blazectl --server "$BASE" download "$TYPE" -q "_sort=$SORT&$QUERY" -o "$FILE_NAME_PREFIX-get".ndjson
11+
12+
SIZE=$(wc -l "$FILE_NAME_PREFIX-get".ndjson | xargs | cut -d ' ' -f1)
13+
if [ "$EXPECTED_SIZE" = "$SIZE" ]; then
14+
echo "Success: download size matches for GET request"
15+
else
16+
echo "Fail: download size was ${SIZE} but should be ${EXPECTED_SIZE} for GET request"
17+
exit 1
18+
fi
19+
20+
blazectl --server "$BASE" download "$TYPE" -p -q "_sort=$SORT&$QUERY" -o "$FILE_NAME_PREFIX-post".ndjson
21+
22+
SIZE=$(wc -l "$FILE_NAME_PREFIX-post".ndjson | xargs | cut -d ' ' -f1)
23+
if [ "$EXPECTED_SIZE" = "$SIZE" ]; then
24+
echo "Success: download size matches for POST request"
25+
else
26+
echo "Fail: download size was ${SIZE} but should be ${EXPECTED_SIZE} for POST request"
27+
exit 1
28+
fi
29+
30+
if [ "$(diff "$FILE_NAME_PREFIX-get.ndjson" "$FILE_NAME_PREFIX-post.ndjson")" = "" ]; then
31+
echo "Success: both downloads are identical"
32+
else
33+
echo "Fail: the GET and the POST download differ"
34+
exit 1
35+
fi
36+
37+
# test sorting, ignoring the milliseconds because Blaze strips them in the index
38+
LAST_UPDATED=$(cat "$FILE_NAME_PREFIX-get.ndjson" | jq -r '.meta.lastUpdated' | cut -d'.' -f1 | uniq)
39+
if [[ "$SORT" == -* ]]; then
40+
LAST_UPDATED_SORT=$(echo "$LAST_UPDATED" | sort -r)
41+
else
42+
LAST_UPDATED_SORT=$(echo "$LAST_UPDATED" | sort)
43+
fi
44+
if [ "$LAST_UPDATED" = "$LAST_UPDATED_SORT" ]; then
45+
echo "Success: resources are sorted"
46+
else
47+
echo "Fail: resources are not sorted"
48+
exit 1
49+
fi

.github/scripts/install-blazectl.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/bash -e
22

3-
VERSION=0.8.5
3+
VERSION=0.9.0
44

55
curl -sLO https://github.com/samply/blazectl/releases/download/v${VERSION}/blazectl-${VERSION}-linux-amd64.tar.gz
66
tar xzf blazectl-${VERSION}-linux-amd64.tar.gz

.github/scripts/search-patient-last-updated.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ BASE="http://localhost:8080/fhir"
1010
NOW=$(date +%Y-%m-%dT%H:%M:%S)
1111
PATIENT_COUNT=$(curl -sH 'Prefer: handling=strict' "$BASE/Patient?_lastUpdated=gt$NOW&_summary=count" | jq -r .total)
1212

13-
if [ $PATIENT_COUNT -eq 0 ]; then
13+
if [ "$PATIENT_COUNT" -eq 0 ]; then
1414
echo "Success: no patents are updated after $NOW"
1515
else
1616
echo "Fail: $PATIENT_COUNT patents are updated after $NOW"

.github/workflows/build.yml

Lines changed: 49 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222
- name: Setup clj-kondo
2323
uses: DeLaGuardo/setup-clj-kondo@master
2424
with:
25-
version: '2022.06.22'
25+
version: '2022.09.08'
2626

2727
- name: Check out Git repository
2828
uses: actions/checkout@v3
@@ -85,7 +85,7 @@ jobs:
8585
- name: Setup Clojure
8686
uses: DeLaGuardo/setup-clojure@master
8787
with:
88-
cli: '1.11.1.1149'
88+
cli: '1.11.1.1165'
8989

9090
- name: Check out Git repository
9191
uses: actions/checkout@v3
@@ -116,7 +116,7 @@ jobs:
116116
- name: Setup Clojure
117117
uses: DeLaGuardo/setup-clojure@master
118118
with:
119-
cli: '1.11.1.1149'
119+
cli: '1.11.1.1165'
120120

121121
- name: Check out Git repository
122122
uses: actions/checkout@v3
@@ -158,7 +158,7 @@ jobs:
158158
- name: Setup Clojure
159159
uses: DeLaGuardo/setup-clojure@master
160160
with:
161-
cli: '1.11.1.1149'
161+
cli: '1.11.1.1165'
162162

163163
- name: Check out Git repository
164164
uses: actions/checkout@v3
@@ -186,7 +186,7 @@ jobs:
186186
- name: Setup Clojure
187187
uses: DeLaGuardo/setup-clojure@master
188188
with:
189-
cli: '1.11.1.1149'
189+
cli: '1.11.1.1165'
190190

191191
- name: Check out Git repository
192192
uses: actions/checkout@v3
@@ -325,9 +325,21 @@ jobs:
325325
- name: Download Observation Resources of male Patients
326326
run: .github/scripts/download-resources-query.sh Observation "patient.gender=male" 20466
327327

328+
- name: Download Observation Resources of male Patients Sorted Ascending
329+
run: .github/scripts/download-resources-query-sort.sh Observation "patient.gender=male" "_lastUpdated" 20466
330+
331+
- name: Download Observation Resources of male Patients Sorted Descending
332+
run: .github/scripts/download-resources-query-sort.sh Observation "patient.gender=male" "-_lastUpdated" 20466
333+
328334
- name: Download Observation Resources of female Patients
329335
run: .github/scripts/download-resources-query.sh Observation "patient.gender=female" 22463
330336

337+
- name: Download Observation Resources of female Patients Sorted Ascending
338+
run: .github/scripts/download-resources-query-sort.sh Observation "patient.gender=female" "_lastUpdated" 22463
339+
340+
- name: Download Observation Resources of female Patients Sorted Descending
341+
run: .github/scripts/download-resources-query-sort.sh Observation "patient.gender=female" "-_lastUpdated" 22463
342+
331343
- name: Download Observation Resources - Including Patients
332344
run: blazectl --no-progress --server http://localhost:8080/fhir download Observation -q '_include=Observation:patient' -o Observation-Patient.ndjson
333345

@@ -352,6 +364,12 @@ jobs:
352364
- name: Download MedicationRequest Resources of Medications with code 854235
353365
run: .github/scripts/download-resources-query.sh MedicationRequest "medication.code=1736854" 112
354366

367+
- name: Download MedicationRequest Resources of Medications with code 854235 Sorted Ascending
368+
run: .github/scripts/download-resources-query-sort.sh MedicationRequest "medication.code=1736854" "_lastUpdated" 112
369+
370+
- name: Download MedicationRequest Resources of Medications with code 854235 Sorted Descending
371+
run: .github/scripts/download-resources-query-sort.sh MedicationRequest "medication.code=1736854" "-_lastUpdated" 112
372+
355373
- name: Download MedicationRequest Resources - Including Medications
356374
run: blazectl --no-progress --server http://localhost:8080/fhir download MedicationRequest -q '_include=MedicationRequest:medication' -o MedicationRequest.ndjson
357375

@@ -433,6 +451,9 @@ jobs:
433451
- name: Batch
434452
run: .github/scripts/batch.sh
435453

454+
- name: Batch Metadata
455+
run: .github/scripts/batch-metadata.sh
456+
436457
- name: Transaction
437458
run: .github/scripts/transaction.sh
438459

@@ -583,7 +604,7 @@ jobs:
583604
- name: Setup Clojure
584605
uses: DeLaGuardo/setup-clojure@master
585606
with:
586-
cli: '1.11.1.1149'
607+
cli: '1.11.1.1165'
587608

588609
- name: Check out Git repository
589610
uses: actions/checkout@v3
@@ -745,9 +766,21 @@ jobs:
745766
- name: Download Observation Resources of male Patients
746767
run: .github/scripts/download-resources-query.sh Observation "patient.gender=male" 20466
747768

769+
- name: Download Observation Resources of male Patients Sorted Ascending
770+
run: .github/scripts/download-resources-query-sort.sh Observation "patient.gender=male" "_lastUpdated" 20466
771+
772+
- name: Download Observation Resources of male Patients Sorted Descending
773+
run: .github/scripts/download-resources-query-sort.sh Observation "patient.gender=male" "-_lastUpdated" 20466
774+
748775
- name: Download Observation Resources of female Patients
749776
run: .github/scripts/download-resources-query.sh Observation "patient.gender=female" 22463
750777

778+
- name: Download Observation Resources of female Patients Sorted Ascending
779+
run: .github/scripts/download-resources-query-sort.sh Observation "patient.gender=female" "_lastUpdated" 22463
780+
781+
- name: Download Observation Resources of female Patients Sorted Descending
782+
run: .github/scripts/download-resources-query-sort.sh Observation "patient.gender=female" "-_lastUpdated" 22463
783+
751784
- name: Download Observation Resources - Including Patients
752785
run: blazectl --no-progress --server http://localhost:8080/fhir download Observation -q '_include=Observation:patient' -o Observation-Patient.ndjson
753786

@@ -772,6 +805,12 @@ jobs:
772805
- name: Download MedicationRequest Resources of Medications with code 854235
773806
run: .github/scripts/download-resources-query.sh MedicationRequest "medication.code=1736854" 112
774807

808+
- name: Download MedicationRequest Resources of Medications with code 854235 Sorted Ascending
809+
run: .github/scripts/download-resources-query-sort.sh MedicationRequest "medication.code=1736854" "_lastUpdated" 112
810+
811+
- name: Download MedicationRequest Resources of Medications with code 854235 Sorted Descending
812+
run: .github/scripts/download-resources-query-sort.sh MedicationRequest "medication.code=1736854" "-_lastUpdated" 112
813+
775814
- name: Download MedicationRequest Resources - Including Medications
776815
run: blazectl --no-progress --server http://localhost:8080/fhir download MedicationRequest -q '_include=MedicationRequest:medication' -o MedicationRequest.ndjson
777816

@@ -853,6 +892,9 @@ jobs:
853892
- name: Batch
854893
run: .github/scripts/batch.sh
855894

895+
- name: Batch Metadata
896+
run: .github/scripts/batch-metadata.sh
897+
856898
- name: Transaction
857899
run: .github/scripts/transaction.sh
858900

@@ -894,7 +936,7 @@ jobs:
894936
- name: Setup Clojure
895937
uses: DeLaGuardo/setup-clojure@master
896938
with:
897-
cli: '1.11.1.1149'
939+
cli: '1.11.1.1165'
898940

899941
- name: Check out Git repository
900942
uses: actions/checkout@v3

CHANGELOG.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,16 @@
11
# Changelog
22

3+
## v0.18.0
4+
5+
### New Features
6+
7+
* Allow Population Basis Differ from Subject in Measures ([#768](https://github.com/samply/blaze/pull/768))
8+
* Implement Sorting by _lastUpdated ([#98](https://github.com/samply/blaze/issues/98))
9+
* Allow Metadata Requests in Batches ([#781](https://github.com/samply/blaze/pull/781))
10+
* Allow to Set Separate RocksDB WAL Dirs ([#791](https://github.com/samply/blaze/pull/791))
11+
12+
The full changelog can be found [here](https://github.com/samply/blaze/milestone/36?closed=1).
13+
314
## v0.17.12
415

516
### Security

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ The goal of this project is to provide a FHIR® Store with an internal CQL Evalu
1414

1515
Blaze passes all [Touchstone FHIR 4.0.1 Basic Tests][12] and almost all [CQL Tests][3]. Please refer to the [Conformance](docs/conformance.md) section and report any issues you encounter during evaluation.
1616

17-
Latest release: [v0.17.12][5]
17+
Latest release: [v0.18.0][5]
1818

1919
## Quick Start
2020

@@ -24,7 +24,7 @@ In order to run Blaze just execute the following:
2424

2525
```sh
2626
docker volume create blaze-data
27-
docker run -p 8080:8080 -v blaze-data:/app/data samply/blaze:0.17
27+
docker run -p 8080:8080 -v blaze-data:/app/data samply/blaze:0.18
2828
```
2929

3030
Blaze will create multiple directories inside the `blaze-data` volume on its first start and use the same directories on subsequent starts.
@@ -72,7 +72,7 @@ Unless required by applicable law or agreed to in writing, software distributed
7272

7373
[3]: <https://cql.hl7.org/tests.html>
7474
[4]: <https://alexanderkiel.gitbook.io/blaze/deployment>
75-
[5]: <https://github.com/samply/blaze/releases/tag/v0.17.12>
75+
[5]: <https://github.com/samply/blaze/releases/tag/v0.18.0>
7676
[6]: <https://www.yourkit.com/java/profiler/>
7777
[7]: <https://www.yourkit.com/.net/profiler/>
7878
[8]: <https://www.yourkit.com/youmonitor/>

deps.edn

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
{:mvn/version "1.3.6"}
4242

4343
org.slf4j/slf4j-nop
44-
{:mvn/version "1.7.36"}}
44+
{:mvn/version "2.0.2"}}
4545

4646
:aliases
4747
{:depstar
@@ -66,7 +66,7 @@
6666
:kaocha
6767
{:extra-deps
6868
{lambdaisland/kaocha
69-
{:mvn/version "1.68.1059"}}
69+
{:mvn/version "1.70.1086"}}
7070

7171
:main-opts ["-m" "kaocha.runner"]}
7272

@@ -80,10 +80,10 @@
8080
:outdated
8181
{:replace-deps
8282
{com.github.liquidz/antq
83-
{:mvn/version "1.9.863"}
83+
{:mvn/version "2.1.927"}
8484

8585
org.slf4j/slf4j-nop
86-
{:mvn/version "1.7.36"}}
86+
{:mvn/version "2.0.2"}}
8787

8888
:main-opts
8989
["-m" "antq.core"

docker-compose.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
version: '3.2'
22
services:
33
blaze:
4-
image: "samply/blaze:0.17"
4+
image: "samply/blaze:0.18"
55
environment:
66
BASE_URL: "http://localhost:8080"
77
JAVA_TOOL_OPTIONS: "-Xmx2g"

docs/README.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# Documentation
2+
3+
* [Deployment](deployment/README.md)
4+
* [FHIR RESTful API](api.md)
5+
* [Importing Data](importing-data.md)
6+
* [Sync Data](data-sync.md)
7+
* [Conformance](conformance.md)
8+
* [Performance](performance.md)
9+
* [Tuning Guide](tuning-guide.md)
10+
* [Tooling](tooling.md)
11+
* [CQL Queries](cql-queries.md)
12+
* [Authentication](authentication.md)
13+
* [Architecture](architecture.md)
14+
* [Implementation](implementation/README.md)

docs/cql-queries.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ The most accessible way to create and execute CQL queries is to use the Quality
1717
If you don't already have Blaze running, you can read about how to do it in [Deployment](deployment/README.md). If you have Docker available just run:
1818

1919
```
20-
docker run -p 8080:8080 -v blaze-data:/app/data samply/blaze:0.17
20+
docker run -p 8080:8080 -v blaze-data:/app/data samply/blaze:0.18
2121
```
2222

2323
Start the Quality Reporting UI. You should see an empty measure list.

0 commit comments

Comments
 (0)