Skip to content

Commit

Permalink
Release/v6.0.0 alpha.3 (#383)
Browse files Browse the repository at this point in the history
* No issue - bump version

* Bump sq2cql and ontology version

* #288 - Load availability files from file(s) (#364)

#288 - Load availability files from file(s)

* Add Update availability script and example file

* #367 - Sort unavailable criteria to the bottom

- add a function score query that boosts all queries with availability > 0 by 100 in score. It does not make a difference if the availability is 10 or 10000, all are boosted by the same fixed value

* #366 - Builtin swagger doc is broken

- move files back to /v3/api-docs since swagger ui wants to load a config file from there anyways. Supplying a custom config file under another folder did not work
- update springdoc-openapi-starter-webmvc-ui to 2.6.0 so it can handle openapi 3.1.0

* #370 - Update fhir-resources dependency

- update to  6.3.26

* #371 - Update spring boot to 3.3.4

- self-explanatory

* #363 - Add "results" to GET query/{queryId} response

- Add the totalNumberOfPatients from the saved query object back to the response when reading a query
- the demanded queryId from the issue is already present as "id" - so nothing to do here imho

* #376 - Allow Empty Search with filters (#377)

#376 - Allow Empty Search with filters

- Change score modification to add an offset instead of multiplying when availability > 0
- remove the inner "must" part of the bool query when searchterm is empty

* bump ontology version

* No issue - update undertow to 2.3.17.Final to fix CVE-2024-7885

* #380 - Change structure of dse profile_tree and profile details for translations (#381)

* #380 - Change structure of dse profile_tree and profile details for translations

- update ontology to v3.0.0-test.11
- modify DseProfile and Field according to changes in dse profile database entry
- modify DseProfileTreeNode according to changes in profile_tree.json

* Bump ontology version to v3.0.0-alpha and add ne aliases to sq2cql config

* Release v6.0.0-alpha.3

---------

Co-authored-by: Michael Folz <folz@med.uni-frankfurt.de>
  • Loading branch information
juliangruendner and michael-82 authored Oct 20, 2024
1 parent 601104a commit fbc5333
Show file tree
Hide file tree
Showing 28 changed files with 513 additions and 133 deletions.
190 changes: 131 additions & 59 deletions .github/integration-test/ontology/dse/profile_tree.json
Original file line number Diff line number Diff line change
@@ -1,63 +1,135 @@
{
"name": "Root",
"module": "no-module",
"url": "no-url",
"children": [
"name": "Root",
"module": "no-module",
"url": "no-url",
"children": [
{
"id": "e5dbef02-a690-4f5a-b1b9-081302aff04d",
"name": "modul-medikation",
"display": {
"original": "Medikation",
"translations": [
{
"language": "de-DE",
"value": "Medikation"
},
{
"language": "en-US",
"value": "Medication"
}
]
},
"url": "modul-medikation",
"module": "modul-medikation",
"selectable": false,
"leaf": false,
"children": [
{
"id": "de5c2903-00aa-4d64-92e5-2161d56e3daf",
"children": [
{
"id": "69f4718f-1767-4517-90f8-6c079f627eed",
"name": "MII_PR_Medikation_MedicationStatement",
"display": "MII PR Medikation MedicationStatement",
"module": "modul-medikation",
"url": "https://www.medizininformatik-initiative.de/fhir/core/modul-medikation/StructureDefinition/MedicationStatement",
"leaf": true,
"selectable": true
},
{
"id": "83b4d6be-b3e1-451a-adf2-c307477e7b97",
"name": "MII_PR_Medikation_Medikationsliste",
"display": "MII PR Medikation Medikationsliste",
"module": "modul-medikation",
"url": "https://www.medizininformatik-initiative.de/fhir/core/modul-medikation/StructureDefinition/medikationsliste",
"leaf": true,
"selectable": true
},
{
"id": "fd375ed9-b3cd-414f-8a56-c70e10bb9609",
"name": "MII_PR_Medikation_MedicationRequest",
"display": "MII PR Medikation MedicationRequest",
"module": "modul-medikation",
"url": "https://www.medizininformatik-initiative.de/fhir/core/modul-medikation/StructureDefinition/MedicationRequest",
"leaf": true,
"selectable": true
},
{
"id": "323a3ad1-1c10-45f5-848a-2dc5fb100c47",
"name": "MII_PR_Medikation_Medication",
"display": "MII PR Medikation Medication",
"module": "modul-medikation",
"url": "https://www.medizininformatik-initiative.de/fhir/core/modul-medikation/StructureDefinition/Medication",
"leaf": true,
"selectable": true
},
{
"id": "81ed0f03-1d77-49c9-8391-d4c25702652c",
"name": "MII_PR_Medikation_MedicationAdministration",
"display": "MII PR Medikation MedicationAdministration",
"module": "modul-medikation",
"url": "https://www.medizininformatik-initiative.de/fhir/core/modul-medikation/StructureDefinition/MedicationAdministration",
"leaf": true,
"selectable": true
}
],
"name": "modul-medikation",
"display": "Medikation",
"url": "https://www.medizininformatik-initiative.de/fhir/core/modul-medikation/StructureDefinition/MedicationStatement",
"module": "modul-medikation",
"selectable": true,
"leaf": false
"id": "5486577b-430b-4a42-a3c8-28c6d6eaf4e8",
"name": "MII_PR_Medikation_MedicationStatement",
"display": {
"original": "MII PR Medikation MedicationStatement",
"translations": [
{
"language": "de-DE",
"value": ""
},
{
"language": "en-US",
"value": "MII PR Medikation MedicationStatement"
}
]
},
"module": "modul-medikation",
"url": "https://www.medizininformatik-initiative.de/fhir/core/modul-medikation/StructureDefinition/MedicationStatement",
"leaf": true,
"selectable": true
},
{
"id": "491759f1-8afc-4a35-9a35-34642211f02a",
"name": "MII_PR_Medikation_Medikationsliste",
"display": {
"original": "MII PR Medikation Medikationsliste",
"translations": [
{
"language": "de-DE",
"value": ""
},
{
"language": "en-US",
"value": "MII PR Medikation Medicationlist"
}
]
},
"module": "modul-medikation",
"url": "https://www.medizininformatik-initiative.de/fhir/core/modul-medikation/StructureDefinition/medikationsliste",
"leaf": true,
"selectable": true
},
{
"id": "9d1fe081-3964-4951-b743-716d1b60d779",
"name": "MII_PR_Medikation_MedicationRequest",
"display": {
"original": "MII PR Medikation MedicationRequest",
"translations": [
{
"language": "de-DE",
"value": ""
},
{
"language": "en-US",
"value": "MII PR Medikation MedicationRequest"
}
]
},
"module": "modul-medikation",
"url": "https://www.medizininformatik-initiative.de/fhir/core/modul-medikation/StructureDefinition/MedicationRequest",
"leaf": true,
"selectable": true
},
{
"id": "1026f31f-78ec-4e20-9b40-c5b02b857bc3",
"name": "MII_PR_Medikation_Medication",
"display": {
"original": "MII PR Medikation Medication",
"translations": [
{
"language": "de-DE",
"value": ""
},
{
"language": "en-US",
"value": "MII PR Medikation Medication"
}
]
},
"module": "modul-medikation",
"url": "https://www.medizininformatik-initiative.de/fhir/core/modul-medikation/StructureDefinition/Medication",
"leaf": true,
"selectable": true
},
{
"id": "d8affe77-892f-45b5-8747-b5ca5400d1be",
"name": "MII_PR_Medikation_MedicationAdministration",
"display": {
"original": "MII PR Medikation MedicationAdministration",
"translations": [
{
"language": "de-DE",
"value": ""
},
{
"language": "en-US",
"value": "MII PR Medikation MedicationAdministration"
}
]
},
"module": "modul-medikation",
"url": "https://www.medizininformatik-initiative.de/fhir/core/modul-medikation/StructureDefinition/MedicationAdministration",
"leaf": true,
"selectable": true
}
]
]
}
]
}
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -56,4 +56,6 @@ googleCodeStyle.xml

result.log
ontology
update-availability/*
!update-availability/README.md

15 changes: 15 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,21 @@ All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),

## [UNRELEASED] - yyyy-mm-dd

### Added
### Changed
### Deprecated
### Removed
### Fixed
### Security

## [6.0.0-alpha.3] - 2024-10-21

### Changed
- Allow empty search
- Change structure of dse profile and details for new translation structure

## [6.0.0-alpha.2] - 2024-09-04

### Added
Expand Down
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ services:
condition: service_healthy
environment:
ELASTIC_HOST: http://dataportal-elastic:9200
ELASTIC_GIT_TAG: v3.0.0-test.2
ELASTIC_GIT_TAG: v3.0.0-alpha
ELASTIC_FILEPATH: https://github.com/medizininformatik-initiative/fhir-ontology-generator/raw/TAGPLACEHOLDER/example/fdpg-ontology/
ELASTIC_FILENAME: elastic.zip
# if set to false, existing indices are not overridden.
Expand Down
17 changes: 17 additions & 0 deletions elastic-update-availability.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#!/usr/bin/env bash
set -e

BASE_DIR="$( cd -- "$(dirname "$0")" >/dev/null 2>&1 || exit 1 ; pwd -P )"
ES_BASE_URL=${ES_BASE_URL:-http://localhost:9200}
ES_INDEX=${ES_INDEX:-ontology}

FILES=("$BASE_DIR"/update-availability/*)
for availUpdateBundle in "${FILES[@]}"; do
if [[ $(basename "$availUpdateBundle") == *.json ]]; then
echo "Sending Availability Update bundle $availUpdateBundle ..."
response=$(curl --write-out "%{http_code}" -s --output /dev/null -XPOST -H 'Content-Type: application/json' --data-binary @"$availUpdateBundle" "$ES_BASE_URL/$ES_INDEX/_bulk")
echo "$response"
else
echo "Skipping $availUpdateBundle (not a .json file)"
fi
done
22 changes: 14 additions & 8 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>3.3.3</version>
<version>3.3.4</version>
<relativePath /> <!-- lookup parent from repository -->
</parent>

<groupId>de.medizininformatik-initiative</groupId>
<artifactId>DataportalBackend</artifactId>
<version>6.0.0-alpha.2</version>
<version>6.0.0-alpha.3</version>

<name>Dataportal Backend</name>
<description>Backend of the Dataportal</description>
Expand All @@ -27,7 +27,7 @@
<java.version>17</java.version>
<mockwebserver.version>4.10.0</mockwebserver.version>
<okhttp3.version>4.10.0</okhttp3.version>
<ontology-tag>v3.0.0-test.2</ontology-tag>
<ontology-tag>v3.0.0-alpha</ontology-tag>
</properties>

<dependencies>
Expand All @@ -49,17 +49,17 @@
<dependency>
<groupId>io.undertow</groupId>
<artifactId>undertow-core</artifactId>
<version>2.3.16.Final</version>
<version>2.3.17.Final</version>
</dependency>
<dependency>
<groupId>io.undertow</groupId>
<artifactId>undertow-servlet</artifactId>
<version>2.3.16.Final</version>
<version>2.3.17.Final</version>
</dependency>
<dependency>
<groupId>io.undertow</groupId>
<artifactId>undertow-websockets-jsr</artifactId>
<version>2.3.16.Final</version>
<version>2.3.17.Final</version>
</dependency>

<dependency>
Expand Down Expand Up @@ -141,7 +141,7 @@
<dependency>
<groupId>org.springdoc</groupId>
<artifactId>springdoc-openapi-starter-webmvc-ui</artifactId>
<version>2.0.4</version>
<version>2.6.0</version>
</dependency>

<dependency>
Expand Down Expand Up @@ -198,6 +198,12 @@
<version>6.6.2</version>
</dependency>

<dependency>
<groupId>ca.uhn.hapi.fhir</groupId>
<artifactId>org.hl7.fhir.utilities</artifactId>
<version>6.3.26</version>
</dependency>

<dependency>
<groupId>com.bucket4j</groupId>
<artifactId>bucket4j-core</artifactId>
Expand Down Expand Up @@ -237,7 +243,7 @@
<dependency>
<groupId>de.medizininformatik-initiative</groupId>
<artifactId>sq2cql</artifactId>
<version>0.3.0</version>
<version>v0.5.0-alpha.1</version>
</dependency>

<dependency>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public class WebSecurityConfig {
public static final String PATH_DSE = "/dse";
public static final String PATH_CODEABLE_CONCEPT = "/codeable-concept";
public static final String PATH_SWAGGER_UI = "/swagger-ui/**";
public static final String PATH_SWAGGER_CONFIG = "/v4/api-docs/**";
public static final String PATH_SWAGGER_CONFIG = "/v3/api-docs/**";
@Value("${app.keycloakAllowedRole}")
private String keycloakAllowedRole;

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
package de.numcodex.feasibility_gui_backend.dse.api;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import lombok.Builder;

import java.util.List;

@JsonInclude(JsonInclude.Include.NON_NULL)
@Builder
public record DisplayEntry(
@JsonProperty String original,
@JsonProperty List<LocalizedValue> translations
) {
}
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
@Builder
public record DseProfile(
@JsonProperty String url,
@JsonProperty String display,
@JsonProperty DisplayEntry display,
@JsonProperty List<Field> fields,
@JsonProperty List<Filter> filters,
@JsonProperty String errorCode,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ public record DseProfileTreeNode(
@JsonProperty String id,
@JsonProperty List<DseProfileTreeNode> children,
@JsonProperty String name,
@JsonProperty String display,
@JsonProperty DisplayEntry display,
@JsonProperty String module,
@JsonProperty String url,
@JsonProperty boolean leaf,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
@Builder
public record Field(
@JsonProperty String id,
@JsonProperty String display,
@JsonProperty String name,
@JsonProperty DisplayEntry display,
@JsonProperty DisplayEntry description,
@JsonProperty String type,
@JsonProperty List<Field> children
) {
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
package de.numcodex.feasibility_gui_backend.dse.api;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import lombok.Builder;

@JsonInclude(JsonInclude.Include.NON_NULL)
@Builder
public record LocalizedValue(
@JsonProperty String language,
@JsonProperty String value
) {
}
Loading

0 comments on commit fbc5333

Please sign in to comment.