Skip to main content

Configuration Reference

This is the comprehensive reference for Fire Arrow Server's application.yaml configuration. Properties are organized by section, with descriptions, defaults, and examples.

spring.datasource -- Database Connection

Fire Arrow Server uses PostgreSQL as its primary data store. For quick local experimentation, H2 in-memory is also supported.

spring:
datasource:
url: jdbc:postgresql://localhost:5432/hapi
username: hapi
password: hapi
driverClassName: org.postgresql.Driver
hikari:
maximum-pool-size: 20
minimum-idle: 5
jpa:
properties:
hibernate.dialect: ca.uhn.fhir.jpa.model.dialect.HapiFhirPostgres94Dialect
hibernate.search.enabled: false

H2 In-Memory (Development Only)

spring:
datasource:
url: jdbc:h2:mem:hapi;DB_CLOSE_ON_EXIT=FALSE
username: sa
password:
driverClassName: org.h2.Driver
jpa:
properties:
hibernate.dialect: ca.uhn.fhir.jpa.model.dialect.HapiFhirH2Dialect
warning

H2 is suitable for quick experiments only. Data is lost when the server stops. Always use PostgreSQL for persistent deployments.

PropertyDescriptionDefault
urlJDBC connection URLjdbc:postgresql://localhost:5432/hapi
usernameDatabase usernamehapi
passwordDatabase passwordhapi
driverClassNameJDBC driver classorg.postgresql.Driver
hikari.maximum-pool-sizeMaximum connections in the pool20
hikari.minimum-idleMinimum idle connections maintained5

hapi.fhir -- FHIR Server Behavior

Controls the FHIR server's capabilities, supported resources, and API features.

hapi:
fhir:
fhir_version: R4
graphql_enabled: true
openapi_enabled: true
default_page_size: 20
max_page_size: 200
search_index_full_text_enabled: false
cors:
enabled: true
allowed_origins:
- "*"
subscription:
resthook_enabled: false
websocket_enabled: false
email:
enabled: false
from: "[email protected]"
PropertyDescriptionDefault
fhir_versionFHIR specification versionR4
graphql_enabledEnable the GraphQL API endpointtrue
openapi_enabledEnable Swagger UI and OpenAPI spectrue
default_page_sizeDefault number of results per page20
max_page_sizeMaximum results per page200
search_index_full_text_enabledEnable full-text search (_text, _content parameters)false
cors.enabledEnable CORS headerstrue
cors.allowed_originsAllowed CORS origins["*"]
subscription.resthook_enabledEnable REST hook subscription channelfalse
subscription.websocket_enabledEnable WebSocket subscription channelfalse
subscription.email.enabledEnable email subscription channelfalse
subscription.email.fromSender address for email subscriptions--

fire-arrow.authentication -- Authentication Providers

Configure OAuth 2.0 / OIDC providers and API token support. See Authentication for a detailed guide.

fire-arrow:
authentication:
enabled: true
providers:
- name: my_oidc_provider
type: oidc
enabled: true
oidc-uri: "https://login.example.com"
audience: "api://fire-arrow"
api-scope: "fhir.access"
claim-mapping:
scope-claim: "scp"
roles-claim: "roles"
subject-claim: "sub"
email-claim: "email"
name-claim: "name"
fhir-resource-type-claim: "resource_type"
fhir-id-claim: "fhir_id"
identity-resolution:
identifier-system: "https://your-app.example.com/fhir/user-id"
auto-create-enabled: true
api-tokens:
hmac-secret: "${API_TOKEN_SECRET}"
PropertyDescriptionDefault
enabledEnable authentication globallyfalse
providers[].nameUnique provider name--
providers[].typeProvider type (oidc, azure-identity)--
providers[].enabledEnable this providertrue
providers[].oidc-uriOIDC issuer URI--
providers[].audienceExpected token audience--
providers[].api-scopeRequired API scope--
providers[].claim-mapping.*Maps token claims to identity fields--
providers[].identity-resolution.identifier-systemFHIR identifier system for user lookup--
providers[].identity-resolution.auto-create-enabledCreate FHIR resources for new usersfalse
api-tokens.hmac-secretSecret key for API token generation/validation--

fire-arrow.authorization -- Access Control

Configure role-based access control rules. See Authorization for a detailed guide.

fire-arrow:
authorization:
default-validator: Forbidden
debug: false
cache:
enabled: true
ttl-seconds: 300
validation-rules:
- client-role: "Patient"
resource: "Patient"
operation: "read"
validator: "PatientCompartment"
- client-role: "Patient"
resource: "Patient"
operation: "graphql-read"
validator: "PatientCompartment"
- client-role: "Practitioner"
resource: "Patient"
operation: "search"
validator: "LegitimateInterest"
PropertyDescriptionDefault
default-validatorValidator applied when no rule matchesForbidden
debugEnable authorization debug mode (logs detailed rule evaluation)false
cache.enabledCache authorization decisionstrue
cache.ttl-secondsCache entry time-to-live in seconds300
validation-rules[]List of authorization rules[]
validation-rules[].client-roleRole this rule applies to (Patient, Practitioner, RelatedPerson, Device, Public)--
validation-rules[].resourceFHIR resource type this rule applies to--
validation-rules[].operationOperation (read, search, create, write, delete, graphql-read, graphql-search, me, binary-upload, subscribe, generate-durable-token, generate-one-time-token)--
validation-rules[].validatorValidator to use (PatientCompartment, LegitimateInterest, CareTeam, Forbidden, Permit)--
Authorization Debug Mode

Set debug: true during development to see detailed logs of how each request is evaluated against your authorization rules. Disable it in production -- debug mode logs sensitive information.

fire-arrow.binary-storage -- Azure Blob Storage

Configure binary file storage. See Binary Storage for the full guide.

fire-arrow:
binary-storage:
enabled: false
azure:
connection-string: "${AZURE_STORAGE_CONNECTION_STRING}"
container-name: "fhir-binaries"
max-file-size: 10485760
pre-signed-url-expiration-seconds: 120
PropertyDescriptionDefault
enabledEnable binary storagefalse
azure.connection-stringAzure Blob Storage connection string--
azure.endpointAzure Blob endpoint (for managed identity)--
azure.container-nameBlob container name--
azure.max-file-sizeMaximum upload size in bytes10485760 (10 MB)
azure.pre-signed-url-expiration-secondsPre-signed URL lifetime120

fire-arrow.careplan-events -- CarePlan Scheduling

Configure server-side CarePlan activity materialization. See CarePlan Events for the full guide.

fire-arrow:
careplan-events:
enabled: false
scheduling:
horizon-duration: "P30D"
check-interval: "PT1H"
subscriptions:
max-ttl: "P90D"
delivery:
max-retries: 3
retry-interval: "PT30S"
failure-threshold: 5
cleanup:
interval: "P1D"
completed-task-retention: "P90D"
task:
auto-transition-to-ready: true
PropertyDescriptionDefault
enabledEnable CarePlan event processingfalse
scheduling.horizon-durationHow far ahead to materialize tasks (ISO 8601 duration)P30D
scheduling.check-intervalHow often to run the materialization checkPT1H
subscriptions.max-ttlMaximum subscription lifetimeP90D
delivery.max-retriesWebhook delivery retry attempts3
delivery.retry-intervalDelay between retriesPT30S
delivery.failure-thresholdConsecutive failures before disabling subscription5
cleanup.intervalCleanup job frequencyP1D
cleanup.completed-task-retentionRetention period for completed tasksP90D
task.auto-transition-to-readyAuto-transition tasks to ready when duetrue

fire-arrow.subscription.azure-queue -- Azure Storage Queue

Configure the Azure Storage Queue subscription delivery channel. See Subscriptions for details.

fire-arrow:
subscription:
azure-queue:
enabled: false
connection-string: "${AZURE_STORAGE_CONNECTION_STRING}"
queue-name: "fhir-subscription-events"
PropertyDescriptionDefault
enabledEnable Azure Storage Queue deliveryfalse
connection-stringAzure Storage account connection string--
queue-nameTarget queue name--

fire-arrow.license -- License Configuration

Configure the Fire Arrow Server license. See Licensing for the full guide.

fire-arrow:
license:
source: file
path: "/etc/fire-arrow/license.key"
deployment-id: "my-deployment-prod"
runtime-environment: prod
PropertyDescriptionValues
sourceLicense delivery methodfile, inline
pathPath to license fileFile path (when source: file)
contentInline license stringLicense content (when source: inline)
deployment-idDeployment identifierMust match the issued license
runtime-environmentDeployment tierprod, nonprod

fire-arrow.admin -- Admin Web UI

Configure the browser-based administration interface.

fire-arrow:
admin:
enabled: true
config-viewer:
enabled: true
auth-profiles:
- name: "Development"
token: "${ADMIN_DEV_TOKEN}"
PropertyDescriptionDefault
enabledEnable the admin web UI at /admin/true
config-viewer.enabledShow server configuration in the admin UItrue
auth-profiles[]Pre-configured auth profiles for the admin GraphQL explorer[]
auth-profiles[].nameDisplay name for the profile--
auth-profiles[].tokenBearer token to use with this profile--

Auth profiles let you switch between different user identities in the admin GraphQL explorer without manually copying tokens. This is useful during development when you want to test queries as different roles.

fire-arrow.mutex -- Distributed Locking

Controls how Fire Arrow Server coordinates background tasks across nodes.

fire-arrow:
mutex:
type: local
PropertyDescriptionValues
typeLock implementationlocal (single node), jdbc (multi-node via PostgreSQL)

Use jdbc when running multiple Fire Arrow Server instances to ensure CarePlan materialization and subscription processing run on exactly one node at a time.

Environment Variable Override Pattern

Every YAML property can be overridden with an environment variable. The conversion rules:

  1. Remove the YAML hierarchy and join with underscores
  2. Convert to uppercase
  3. Replace dots and hyphens with underscores

Examples:

YAML PathEnvironment Variable
spring.datasource.urlSPRING_DATASOURCE_URL
spring.datasource.passwordSPRING_DATASOURCE_PASSWORD
hapi.fhir.graphql_enabledHAPI_FHIR_GRAPHQL_ENABLED
fire-arrow.authentication.enabledFIRE_ARROW_AUTHENTICATION_ENABLED
fire-arrow.binary-storage.azure.connection-stringFIRE_ARROW_BINARY_STORAGE_AZURE_CONNECTION_STRING
fire-arrow.careplan-events.scheduling.horizon-durationFIRE_ARROW_CAREPLAN_EVENTS_SCHEDULING_HORIZON_DURATION
fire-arrow.license.sourceFIRE_ARROW_LICENSE_SOURCE
fire-arrow.mutex.typeFIRE_ARROW_MUTEX_TYPE

Complete Example

Here's a production-ready application.yaml with all major features enabled:

spring:
datasource:
url: jdbc:postgresql://db:5432/hapi
username: ${DB_USERNAME}
password: ${DB_PASSWORD}
driverClassName: org.postgresql.Driver
hikari:
maximum-pool-size: 20
jpa:
properties:
hibernate.dialect: ca.uhn.fhir.jpa.model.dialect.HapiFhirPostgres94Dialect

hapi:
fhir:
fhir_version: R4
graphql_enabled: true
openapi_enabled: true
default_page_size: 20
max_page_size: 200
cors:
enabled: true
allowed_origins:
- "https://your-app.example.com"
subscription:
resthook_enabled: true
websocket_enabled: true

fire-arrow:
authentication:
enabled: true
providers:
- name: primary_oidc
type: oidc
enabled: true
oidc-uri: "https://login.example.com"
audience: "api://fire-arrow"
api-scope: "fhir.access"
claim-mapping:
scope-claim: "scp"
roles-claim: "roles"
subject-claim: "sub"
email-claim: "email"
name-claim: "name"
fhir-resource-type-claim: "resource_type"
fhir-id-claim: "fhir_id"
identity-resolution:
identifier-system: "https://your-app.example.com/fhir/user-id"
auto-create-enabled: true
api-tokens:
hmac-secret: ${API_TOKEN_SECRET}

authorization:
default-validator: Forbidden
debug: false
cache:
enabled: true
ttl-seconds: 300
validation-rules:
- client-role: "Patient"
resource: "Patient"
operation: "read"
validator: "PatientCompartment"
- client-role: "Patient"
resource: "Patient"
operation: "graphql-read"
validator: "PatientCompartment"
- client-role: "Patient"
resource: "Observation"
operation: "graphql-search"
validator: "PatientCompartment"
- client-role: "Practitioner"
resource: "Patient"
operation: "search"
validator: "LegitimateInterest"

binary-storage:
enabled: true
azure:
connection-string: ${AZURE_STORAGE_CONNECTION_STRING}
container-name: "fhir-binaries"
max-file-size: 10485760

careplan-events:
enabled: true
scheduling:
horizon-duration: "P30D"
check-interval: "PT1H"
subscriptions:
max-ttl: "P90D"
delivery:
max-retries: 3
failure-threshold: 5

subscription:
azure-queue:
enabled: true
connection-string: ${AZURE_STORAGE_CONNECTION_STRING}
queue-name: "fhir-events"

license:
source: inline
content: ${FIRE_ARROW_LICENSE_CONTENT}
deployment-id: "production-01"
runtime-environment: prod

admin:
enabled: true

mutex:
type: jdbc