Skip to content

Commit

Permalink
release 1.9.0
Browse files Browse the repository at this point in the history
  • Loading branch information
oliveregger committed Mar 10, 2022
1 parent 4118ecf commit 128c395
Show file tree
Hide file tree
Showing 8 changed files with 79 additions and 48 deletions.
33 changes: 16 additions & 17 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@ a public test server is hosted at [https://test.ahdis.ch/matchbox/fhir](https://
## containers

The docker file will create a docker image with no preloaded implementation guides. A list of implementation guides to load can be passed as config-map.
A second docker file will create an image with fixed configuration and preloaded implementation guides. That docker image does not need to download the implementation guides afterwards.

## Prerequisites

- [This project](https://github.com/ahdis/matchbox) checked out. You may wish to create a GitHub Fork of the project and check that out instead so that you can customize the project and save the results to GitHub. Check out the main branch (master is kept in sync with [hapi-fhir-jpaserver-starter](https://github.com/hapifhir/hapi-fhir-jpaserver-starter)
Expand All @@ -30,7 +28,7 @@ With no implementation guide:
```bash
mvn clean install -DskipTests spring-boot:run
```
Load example implementation guides:
Load example implementation guides (needs postgres):
```bash
mvn clean install -DskipTests spring-boot:run -Dspring-boot.run.arguments=--spring.config.additional-location=file:with-preload/application.yaml
```
Expand All @@ -47,10 +45,21 @@ mvn clean install -DskipTests spring-boot:run -Dspring-boot.run.jvmArguments="-X
Then, browse to the following link to use the server:

[http://localhost:8080/matchbox/fhir](http://localhost:8080/matchbox/fhir)
or
[http://localhost:8080/matchbox/#/](http://localhost:8080/matchbox/#/)

## Using docker-compose with a persistent postgreSQL database

The database will be stored in the "data" directory. The configuration can be found in the "with-postgres" directory.
The database will be stored in the "data" directory. The configuration can be found in the "with-postgres" directory or in the "with-preload" directory.

Change to either with-posgres directory or the with-preload directory (contains a list of swiss ig's).

For the first time, you might need to do

```
docker-compose up matchbox-db
```
that the database gets initialized before matchbox is starting up (needs a fix)

```
mkdir data
Expand All @@ -60,7 +69,7 @@ docker-compose up
```

matchbox will be available at [http://localhost:8080/matchbox/fhir](http://localhost:8080/matchbox/fhir)
matchbox-formfiller will be available at [http://localhost:4300/matchbox-formfiller/#/](http://localhost:4300/matchbox-formfiller/#/)
matchbox-gui will be available at [http://localhost:8080/matchbox/#/](http://localhost:8080/matchbox/#/)


Export the DB data:
Expand Down Expand Up @@ -88,21 +97,11 @@ Server will then be accessible at http://localhost:8080/matchbox/fhir/metadata.
To dynamically configure run in a kubernetes environment and add a kubernetes config map that provides /config/application.yaml file with implementation guide list like in "with-preload/application.yaml"


### Image with preloaded implementation guides

After building the base image:
```bash
cd with-preload
docker build -t matchbox-swissepr .
docker run -d --name matchbox-swissepr -p 8080:8080 matchbox-swissepr
```

### making container available
```
docker tag matchbox eu.gcr.io/fhir-ch/matchbox:v182
docker tag matchbox eu.gcr.io/fhir-ch/matchbox:v190
docker push eu.gcr.io/fhir-ch/matchbox:v182
docker push eu.gcr.io/fhir-ch/matchbox-swissepr:v170
docker push eu.gcr.io/fhir-ch/matchbox:v190
```

API
Expand Down
4 changes: 3 additions & 1 deletion changelog.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
2022/03/09 Release 1.9.0
2022/03/10 Release 1.9.0
- Updated to hap-fhir 5.7.0, fhir.core.version (validator) 5.6.27
- Extended Mobile Access Gateway support for PMP (replacing FHIR documents with selected Patient in Mobile Access Gateway, transforming to CDA and MDH publish)
- base release with no ig's configured: docker pull eu.gcr.io/fhir-ch/matchbox:v190
- docker-compose setup for postgres and for postgres and swiss igs

2022/02/21 Release 1.8.2
- OAuth integration for [Mobile Access Gateway](https://github.com/i4mi/MobileAccessGateway) in webapp
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -368,10 +368,10 @@ protected void initialize() throws ServletException {

// If subscriptions are enabled, we want to register the interceptor that
// will activate them and match results against them
if (appProperties.getSubscription() != null) {
// FIXME not specified but is still triggered: if (appProperties.getSubscription() != null) {
// Subscription debug logging
interceptorService.registerInterceptor(new SubscriptionDebugLogInterceptor());
}
// interceptorService.registerInterceptor(new SubscriptionDebugLogInterceptor());
// }

// Cascading deletes

Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/application.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ spring:
properties:
hibernate.format_sql: false
hibernate.show_sql: false
# hibernate.dialect: org.hibernate.dialect.h2dialect
hibernate.dialect: ca.uhn.fhir.jpa.model.dialect.HapiFhirH2Dialect
# hibernate.hbm2ddl.auto: update
# hibernate.jdbc.batch_size: 20
# hibernate.cache.use_query_cache: false
Expand Down
File renamed without changes.
4 changes: 0 additions & 4 deletions with-preload/Dockerfile

This file was deleted.

51 changes: 29 additions & 22 deletions with-preload/application.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
server:
servlet:
context-path: /matchbox
spring:
datasource:
url: 'jdbc:postgresql://matchbox-db:5432/matchbox'
username: matchbox
password: matchbox
driverClassName: org.postgresql.Driver

# database connection pool size
hikari:
maximum-pool-size: 10
jpa:
properties:
hibernate.dialect: org.hibernate.dialect.PostgreSQL95Dialect
hapi:
fhir:
implementationguides:
Expand All @@ -8,26 +24,22 @@ hapi:
cdach:
url: http://build.fhir.org/ig/hl7ch/cda-fhir-maps/package.tgz
name: ch.fhir.ig.cda-fhir-maps
version: 0.2.0
version: 0.3.0
iheformatcodefhir:
url: https://profiles.ihe.net/fhir/ihe.formatcode.fhir/package.tgz
name: ihe.formatcode.fhir
version: 1.0.0
# terminology:
# name: hl7.terminology.r4
# version: 2.1.0
eprterm:
name: ch.fhir.ig.ch-epr-term
version: 2.0.6
version: 2.0.7
core:
name: ch.fhir.ig.ch-core
version: 2.0.0
emed:
name: ch.fhir.ig.ch-emed
version: 1.0.0
version: 2.0.0
vacd:
name: ch.fhir.ig.ch-vacd
version: 1.0.0
version: 2.0.0
atc:
name: ch.fhir.ig.ch-atc
version: 3.1.0
Expand All @@ -36,31 +48,26 @@ hapi:
version: 2.7.0
chorf:
name: ch.fhir.ig.ch-orf
version: 0.10.0
version: 1.0.0
chradorder:
name: ch.fhir.ig.ch-rad-order
version: 0.1.0
version: 1.0.0
hl7fhiruvips:
name: hl7.fhir.uv.ips
version": 1.0.0
chetoc:
name: ch.fhir.ig.ch-etoc
version: 0.1.0
version: 1.0.0
url: https://build.fhir.org/ig/hl7ch/ch-etoc/branches/main/package.tgz
mhd:
name: ihe.mhd.fhir
version: 4.0.1
version: 4.0.1
pixm:
name: IHE.ITI.PIXm
version: 3.0.0
cheprmhealth:
url: https://fhir.ch/ig/ch-epr-mhealth/package.tgz
name: ch.fhir.ig.ch-epr-mhealth
version: 1.0.0
challergyintolerance:
name: ch.fhir.ig.ch-allergyintolerance
version": 0.2.0
chradorderpoc:
url: https://build.fhir.org/ig/ahdis/ch-rad-poc/package.tgz
name: ch.ahdis.ig.ch-rad-poc
version: 0.1.0
chalis:
url: https://build.fhir.org/ig/ahdis/ch-alis/package.tgz
name: ch.fhir.ig.ch-alis
version": 0.2.0
version": 1.0.0
27 changes: 27 additions & 0 deletions with-preload/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
services:
matchbox:
# build: .
image: matchbox:latest
container_name: matchbox
restart: on-failure
ports:
- "8080:8080"
links:
- matchbox-db
volumes:
- ./with-preload:/config
matchbox-db:
image: postgres:latest
container_name: matchbox-db
restart: always
# Comment out to not log queries
command: ["postgres", "-c", "log_statement=all"]
# End comment out
ports:
- "5432:5432"
environment:
POSTGRES_DB: 'matchbox'
POSTGRES_USER: 'matchbox'
POSTGRES_PASSWORD: 'matchbox'
volumes:
- ./data:/var/lib/postgresql/data

0 comments on commit 128c395

Please sign in to comment.