GithubHelp home page GithubHelp logo

hl7-be / matchbox Goto Github PK

View Code? Open in Web Editor NEW

This project forked from ahdis/matchbox

0.0 0.0 0.0 10.02 MB

License: Apache License 2.0

Dockerfile 0.06% Shell 0.01% Java 98.04% HTML 1.33% Batchfile 0.01% Smarty 0.56%

matchbox's Introduction

matchbox

matchbox is a FHIR server based on the hapifhir/hapi-fhir-jpaserver-starter

  • (pre-)load FHIR implementation guides from the package server for conformance resources (StructureMap, Questionnaire, CodeSystem, ValueSet, ConceptMap, NamingSystem, StructureDefinition). The "with-preload" subfolder contains an example with the implementation guides provided for the public test server.
  • validation support: [server]/$validate for checking FHIR resources conforming to the loaded implementation guides
  • FHIR Mapping Language endpoints for creation of StructureMaps and support for the StructureMap/$transform operation
  • SDC (Structured Data Capture) extraction support based on the FHIR Mapping language and Questionnaire/$extract

a public test server is hosted at https://test.ahdis.ch/matchbox/fhir with a corresponding gui https://test.ahdis.ch/matchbox/

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.

Prerequisites

  • This project 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
  • Oracle Java (JDK) installed: Minimum JDK11 or newer.
  • Apache Maven build tool (newest version)

Running locally

The easiest way to run this server entirely depends on your environment requirements. At least, the following 4 ways are supported:

Using spring-boot

With no implementation guide:

mvn clean install -DskipTests spring-boot:run

Load example implementation guides (needs postgres):

mvn clean install -DskipTests spring-boot:run -Dspring-boot.run.arguments=--spring.config.additional-location=file:with-preload/application.yaml

or

java -Dspring.config.additional-location=file:with-preload/application.yaml -jar target/matchbox.jar
mvn clean install -DskipTests spring-boot:run -Dspring-boot.run.jvmArguments="-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=5005"

Then, browse to the following link to use the server:

http://localhost:8080/matchbox/fhir or 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 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
mvn clean package -DskipTests
docker build -t matchbox .
docker-compose up

matchbox will be available at http://localhost:8080/matchbox/fhir matchbox-gui will be available at http://localhost:8080/matchbox/#/

Export the DB data:

docker-compose exec -T matchbox-test-db pg_dump -Fc -U matchbox matchbox > mydump

Reimport the DB data:

docker-compose exec -T matchbox-test-db pg_restore -c -U matchbox -d matchbox < mydump

building with Docker

Configurable base image:

mvn package -DskipTests
docker build -t matchbox .
docker run -d --name matchbox -p 8080:8080 matchbox

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"

making container available

docker tag matchbox eu.gcr.io/fhir-ch/matchbox:v200

docker push eu.gcr.io/fhir-ch/matchbox:v200

API

Use VSCode, REST Client to work with the API:

Kubernetes

kubectl cp matchbox-test-0:fhir.logdir_IS_UNDEFINED ./fhir.logdir/

kubectl cp matchbox-test-app-d684cf865 ./fhir.logdir/

matchbox's People

Contributors

jamesagnew avatar oliveregger avatar jvitrifork avatar seanmcilvenna avatar costateixeira avatar tadgh avatar jkiddo avatar patrick-werner avatar chgl avatar alexander-kreutz avatar fil512 avatar michaelabuckley avatar frankjtao avatar jjcosare avatar xluanlhc avatar ralych avatar psavva avatar vladonemo avatar malcomm avatar jschneid-nmdp avatar winfriedgerlach avatar thegotoguy avatar jaison-b avatar johnpoth avatar dependabot[bot] avatar sidharthramesh avatar oi-tremend avatar mattmorgis avatar muhammad-levi avatar javaimpala avatar

matchbox's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.