Dev Services Overview
Quarkus supports the automatic provisioning of unconfigured services in development and test mode. We refer to this capability as Dev Services. From a developer’s perspective this means that if you include an extension and don’t configure it then Quarkus will automatically start the relevant service (usually using Testcontainers behind the scenes) and wire up your application to use this service.
All this functionality is part of the Quarkus deployment
modules, so does not affect the production application in any
way. If you want to disable all Dev Services you can use the quarkus.devservices.enabled=false
config property, although
in most cases this is not necessary as simply configuring the service will result in the Dev Service being disabled automatically.
Note that the default startup timeout is 60s, if this is not enough you can increase it with the quarkus.devservices.timeout
property.
This page lists all the Dev Services that Quarkus supports.
In order to use Dev Services you will generally need a working Docker environment (remote environments are supported). If you don’t have Docker installed you will need to configure your services normally. |
AMQP
The AMQP Dev Service will be enabled when the quarkus-smallrye-reactive-messaging-amqp
extension is present in your application, and
the broker address has not been explicitly configured. More information can be found at the
AMQP Dev Services Guide.
Configuration property fixed at build time - All other configuration properties are overridable at runtime
Type |
Default |
|
---|---|---|
If Dev Services for AMQP has been explicitly enabled or disabled. Dev Services are generally enabled by default, unless there is an existing configuration present. For AMQP, Dev Services starts a broker unless |
boolean |
|
Optional fixed port the dev service will listen to. If not defined, the port will be chosen randomly. |
int |
|
The image to use. Note that only |
string |
|
The value of the |
string |
|
Indicates if the AMQP broker managed by Quarkus Dev Services is shared. When shared, Quarkus looks for running containers using label-based service discovery. If a matching container is found, it is used, and so a second one is not started. Otherwise, Dev Services for AMQP starts a new container.
The discovery uses the |
boolean |
|
The value of the |
string |
|
Apicurio Registry
The Apicurio Dev Service will be enabled when the quarkus-apicurio-registry-avro
extension is present in your application, and it’s
address has not been explicitly configured. More information can be found at the
Apicurio Registry Dev Services Guide.
Configuration property fixed at build time - All other configuration properties are overridable at runtime
Type |
Default |
|
---|---|---|
If Dev Services for Apicurio Registry has been explicitly enabled or disabled. Dev Services are generally enabled by default, unless there is an existing configuration present. For Apicurio Registry, Dev Services starts a registry unless |
boolean |
|
Optional fixed port the dev service will listen to. If not defined, the port will be chosen randomly. |
int |
|
The Apicurio Registry image to use. Note that only Apicurio Registry 2.x images are supported. |
string |
|
Indicates if the Apicurio Registry instance managed by Quarkus Dev Services is shared. When shared, Quarkus looks for running containers using label-based service discovery. If a matching container is found, it is used, and so a second one is not started. Otherwise, Dev Services for Apicurio Registry starts a new container.
The discovery uses the |
boolean |
|
The value of the |
string |
|
Databases
The database Dev Services will be enabled when a reactive or JDBC datasource extension is present in the application, and the database URL has not been configured. More information can be found at the Databases Dev Services Guide.
Quarkus provides Dev Services for all databases it supports. Most of these are run in a container, except H2 and Derby which are run in-process. Dev Services are supported for both JDBC and reactive drivers.
Those relational databases that are running in a container are started using Testcontainers and support "reusable instances";
this implies that if you add the property testcontainers.reuse.enable=true
in your Testcontainers configuration file,
a property file named .testcontainers.properties
in your user home, then the databases will not be stopped aggressively
after each run, and can be reused.
N.B. if you opt in for this feature, Quarkus will not reset the state of the database between runs unless you explicitly configure it to.
Configuration property fixed at build time - All other configuration properties are overridable at runtime
Type |
Default |
|
---|---|---|
If DevServices has been explicitly enabled or disabled. DevServices is generally enabled by default, unless there is an existing configuration present. When DevServices is enabled Quarkus will attempt to automatically configure and start a database when running in Dev or Test mode. |
boolean |
|
The container image name to use, for container based DevServices providers. If the provider is not container based (e.g. a H2 Database) then this has no effect. |
string |
|
Optional fixed port the dev service will listen to. If not defined, the port will be chosen randomly. |
int |
|
The container start command to use, for container based DevServices providers. If the provider is not container based (e.g. a H2 Database) then this has no effect. |
string |
|
Generic properties that are passed for additional container configuration. Properties defined here are database specific and are interpreted specifically in each database dev service implementation. |
|
|
Generic properties that are added to the database connection URL. |
|
|
If DevServices has been explicitly enabled or disabled. DevServices is generally enabled by default, unless there is an existing configuration present. When DevServices is enabled Quarkus will attempt to automatically configure and start a database when running in Dev or Test mode. |
boolean |
|
The container image name to use, for container based DevServices providers. If the provider is not container based (e.g. a H2 Database) then this has no effect. |
string |
|
Generic properties that are passed for additional container configuration. Properties defined here are database specific and are interpreted specifically in each database dev service implementation. |
|
|
Generic properties that are added to the database connection URL. |
|
|
Optional fixed port the dev service will listen to. If not defined, the port will be chosen randomly. |
int |
|
The container start command to use, for container based DevServices providers. If the provider is not container based (e.g. a H2 Database) then this has no effect. |
string |
Kafka
The Kafka Dev Service will be enabled when the quarkus-kafka-client
extension is present in your application, and
the broker address has not been explicitly configured. More information can be found at the
Kafka Dev Services Guide.
Configuration property fixed at build time - All other configuration properties are overridable at runtime
Type |
Default |
|
---|---|---|
If Dev Services for Kafka has been explicitly enabled or disabled. Dev Services are generally enabled by default, unless there is an existing configuration present. For Kafka, Dev Services starts a broker unless |
boolean |
|
Optional fixed port the dev service will listen to. If not defined, the port will be chosen randomly. |
int |
|
The Kafka container image to use.
Only Redpanda and Strimzi images are supported. Default image is Redpanda.
Note that Strimzi images are launched in Kraft mode. In order to use a Strimzi image you need to set a compatible image name such as |
string |
|
Indicates if the Kafka broker managed by Quarkus Dev Services is shared. When shared, Quarkus looks for running containers using label-based service discovery. If a matching container is found, it is used, and so a second one is not started. Otherwise, Dev Services for Kafka starts a new container.
The discovery uses the |
boolean |
|
The value of the |
string |
|
Timeout for admin client calls used in topic creation. Defaults to 2 seconds. |
|
|
Enables transaction support. Also enables the producer idempotence. Find more info about Red Panda transaction support on https://vectorized.io/blog/fast-transactions/. Notice that KIP-447 (producer scalability for exactly once semantic) and KIP-360 (Improve reliability of idempotent/transactional producer) are not supported. |
boolean |
|
The topic-partition pairs to create in the Dev Services Kafka broker. After the broker is started, given topics with partitions are created, skipping already existing topics. For example, |
|
About the Duration format
The format for durations uses the standard You can also provide duration values starting with a number.
In this case, if the value consists only of a number, the converter treats the value as seconds.
Otherwise, |
Keycloak
The Keycloak Dev Service will be enabled when the quarkus-oidc
extension is present in your application, and
the server address has not been explicitly configured. More information can be found at the
OIDC Dev Services Guide.
Configuration property fixed at build time - All other configuration properties are overridable at runtime
Type |
Default |
|
---|---|---|
If DevServices has been explicitly enabled or disabled. When DevServices is enabled Quarkus will attempt to automatically configure and start Keycloak when running in Dev or Test mode and when Docker is running. |
boolean |
|
The container image name to use, for container based DevServices providers. Image with a Quarkus based distribution is used by default. Image with a WildFly based distribution can be selected instead, for example: 'quay.io/keycloak/keycloak:18.0.1-legacy'. Note Keycloak Quarkus and Keycloak WildFly images are initialized differently. By default, Dev Services for Keycloak will assume it is a Keycloak Quarkus image if the image version does not end with a '-legacy' string. Set 'quarkus.keycloak.devservices.keycloak-x-image' to override this check. |
string |
|
If Keycloak-X image is used. By default, Dev Services for Keycloak will assume a Keycloak-X image is used if the image name contains a 'keycloak-x' string. Set 'quarkus.keycloak.devservices.keycloak-x-image' to override this check which may be necessary if you build custom Keycloak-X or Keycloak images. You do not need to set this property if the default check works. |
boolean |
|
Indicates if the Keycloak container managed by Quarkus Dev Services is shared. When shared, Quarkus looks for running containers using label-based service discovery. If a matching container is found, it is used, and so a second one is not started. Otherwise, Dev Services for Keycloak starts a new container.
The discovery uses the |
boolean |
|
The value of the |
string |
|
The class or file system path to a Keycloak realm file which will be used to initialize Keycloak. |
string |
|
The JAVA_OPTS passed to the keycloak JVM |
string |
|
The Keycloak realm name. This property will be used to create the realm if the realm file pointed to by the 'realm-path' property does not exist, default value is 'quarkus' in this case. If the realm file pointed to by the 'realm-path' property exists then it is still recommended to set this property for Dev Services for Keycloak to avoid parsing the realm file in order to determine the realm name. |
string |
|
Indicates if the Keycloak realm has to be created when the realm file pointed to by the 'realm-path' property does not exist. Disable it if you’d like to create a realm using Keycloak Administration Console or Keycloak Admin API from |
boolean |
|
Optional fixed port the dev service will listen to. If not defined, the port will be chosen randomly. |
int |
|
The Keycloak users map containing the username and password pairs. If this map is empty then two users, 'alice' and 'bob' with the passwords matching their names will be created. This property will be used to create the Keycloak users if the realm file pointed to by the 'realm-path' property does not exist. |
|
|
The Keycloak user roles. If this map is empty then a user named 'alice' will get 'admin' and 'user' roles and all other users will get a 'user' role. This property will be used to create the Keycloak roles if the realm file pointed to by the 'realm-path' property does not exist. |
|
Kogito
The Kogito Dev Service will be enabled when either kogito-quarkus
or kogito-quarkus-processes
extension is present in your application. More information can be found at the Kogito Dev Services Guide.
Configuration property fixed at build time - All other configuration properties are overridable at runtime
Type |
Default |
|
---|---|---|
If DevServices has been explicitly enabled or disabled. DevServices is generally enabled by default, unless there is an existing configuration present. When DevServices is enabled Quarkus will attempt to automatically configure and start a Data Index when running in Dev mode. |
boolean |
true |
The container image name to use. |
string |
quay.io/kiegroup/kogito-data-index-ephemeral |
Optional fixed port the dev service will listen to. If not defined, the port will be chosen randomly. |
int |
8180 |
Indicates if the Data Index instance managed by Quarkus Dev Services is shared. When shared, Quarkus looks for running containers using label-based service discovery. If a matching container is found, it is used, and so a second one is not started. Otherwise, Dev Services for Kogito starts a new container. The discovery uses the |
boolean |
true |
The value of the |
string |
kogito-data-index |
MongoDB
The MongoDB Dev Service will be enabled when the quarkus-mongodb-client
extension is present in your application, and
the server address has not been explicitly configured. More information can be found at the
MongoDB Guide.
Configuration property fixed at build time - All other configuration properties are overridable at runtime
Type |
Default |
|
---|---|---|
If DevServices has been explicitly enabled or disabled. DevServices is generally enabled by default, unless there is an existing configuration present. When DevServices is enabled Quarkus will attempt to automatically configure and start a database when running in Dev or Test mode. |
boolean |
|
The container image name to use, for container based DevServices providers. |
string |
|
Optional fixed port the dev service will listen to. If not defined, the port will be chosen randomly. |
int |
|
Generic properties that are added to the connection URL. |
|
RabbitMQ
The RabbitMQ Dev Service will be enabled when the quarkus-smallrye-reactive-messaging-rabbitmq
extension is present in your application, and
the broker address has not been explicitly configured. More information can be found at the
RabbitMQ Dev Services Guide.
Configuration property fixed at build time - All other configuration properties are overridable at runtime
Type |
Default |
|
---|---|---|
If Dev Services for RabbitMQ has been explicitly enabled or disabled. Dev Services are generally enabled by default, unless there is an existing configuration present. For RabbitMQ, Dev Services starts a broker unless |
boolean |
|
Optional fixed port the dev service will listen to. If not defined, the port will be chosen randomly. |
int |
|
The image to use. |
string |
|
Indicates if the RabbitMQ broker managed by Quarkus Dev Services is shared. When shared, Quarkus looks for running containers using label-based service discovery. If a matching container is found, it is used, and so a second one is not started. Otherwise, Dev Services for RabbitMQ starts a new container.
The discovery uses the |
boolean |
|
The value of the |
string |
|
Type of exchange: direct, topic, headers, fanout, etc. |
string |
|
Should the exchange be deleted when all queues are finished using it? |
boolean |
|
Should the exchange remain after restarts? |
boolean |
|
Extra arguments for the exchange definition. |
|
|
Should the queue be deleted when all consumers are finished using it? |
boolean |
|
Should the queue remain after restarts? |
boolean |
|
Extra arguments for the queue definition. |
|
|
Source exchange to bind to. Defaults to name of binding instance. |
string |
|
Routing key specification for the source exchange. |
string |
|
Destination exchange or queue to bind to. Defaults to name of binding instance. |
string |
|
Destination type for binding: queue, exchange, etc. |
string |
|
Extra arguments for the binding definition. |
|
Redis
The Redis Dev Service will be enabled when the quarkus-redis-client
extension is present in your application, and
the server address has not been explicitly configured. More information can be found at the
Redis Dev Services Guide.
Configuration property fixed at build time - All other configuration properties are overridable at runtime
Type |
Default |
|
---|---|---|
If DevServices has been explicitly enabled or disabled. DevServices is generally enabled by default, unless there is an existing configuration present. When DevServices is enabled Quarkus will attempt to automatically configure and start a database when running in Dev or Test mode and when Docker is running. |
boolean |
|
The container image name to use, for container based DevServices providers. |
string |
|
Optional fixed port the dev service will listen to. If not defined, the port will be chosen randomly. |
int |
|
Indicates if the Redis server managed by Quarkus Dev Services is shared. When shared, Quarkus looks for running containers using label-based service discovery. If a matching container is found, it is used, and so a second one is not started. Otherwise, Dev Services for Redis starts a new container.
The discovery uses the |
boolean |
|
The value of the |
string |
|
If DevServices has been explicitly enabled or disabled. DevServices is generally enabled by default, unless there is an existing configuration present. When DevServices is enabled Quarkus will attempt to automatically configure and start a database when running in Dev or Test mode and when Docker is running. |
boolean |
|
The container image name to use, for container based DevServices providers. |
string |
|
Optional fixed port the dev service will listen to. If not defined, the port will be chosen randomly. |
int |
|
Indicates if the Redis server managed by Quarkus Dev Services is shared. When shared, Quarkus looks for running containers using label-based service discovery. If a matching container is found, it is used, and so a second one is not started. Otherwise, Dev Services for Redis starts a new container.
The discovery uses the |
boolean |
|
The value of the |
string |
|
Vault
The Vault Dev Service will be enabled when the quarkus-vault
extension is present in your application, and
the server address has not been explicitly configured. More information can be found at the
Vault Guide.
Neo4j
The Neo4j Dev Service will be enabled when the quarkus-neo4j
extension is present in your application, and
the server address has not been explicitly configured. More information can be found at the
Neo4j Guide.
Infinispan
The Infinispan Dev Service will be enabled when the quarkus-infinispan-client
extension is present in your application, and
the server address has not been explicitly configured. More information can be found at the
Infinispan Guide.
Configuration property fixed at build time - All other configuration properties are overridable at runtime
Type |
Default |
|
---|---|---|
If DevServices has been explicitly enabled or disabled. DevServices is generally enabled by default, unless there is an existing configuration present. When DevServices is enabled Quarkus will attempt to automatically configure and start a database when running in Dev or Test mode and when Docker is running. |
boolean |
|
Optional fixed port the dev service will listen to. If not defined, the port will be chosen randomly. |
int |
|
Indicates if the Infinispan server managed by Quarkus Dev Services is shared. When shared, Quarkus looks for running containers using label-based service discovery. If a matching container is found, it is used, and so a second one is not started. Otherwise, Dev Services for Infinispan starts a new container.
The discovery uses the |
boolean |
|
The value of the |
string |
|
List of the artifacts to automatically download and add to the Infinispan server libraries. For example a Maven coordinate (org.postgresql:postgresql:42.3.1) or a dependency location url. If an invalid value is passed, the Infinispan server will throw an error when trying to start. |
list of string |
Elasticsearch
The Elasticsearch Dev Service will be enabled when one of the Elasticsearch based extensions (Elasticsearch client or Hibernate Search ORM Elasticsearch) is present in your application, and the server address has not been explicitly configured. More information can be found at the Elasticsearch Dev Services Guide.
Configuration property fixed at build time - All other configuration properties are overridable at runtime
Type |
Default |
|
---|---|---|
If Dev Services for Elasticsearch has been explicitly enabled or disabled. Dev Services are generally enabled by default, unless there is an existing configuration present. For Elasticsearch, Dev Services starts a server unless |
boolean |
|
Optional fixed port the dev service will listen to. If not defined, the port will be chosen randomly. |
int |
|
The Elasticsearch container image to use. Defaults to the elasticsearch image provided by Elastic. |
string |
|
The value for the ES_JAVA_OPTS env variable. Defaults to setting the heap to 1GB. |
string |
|
Indicates if the Elasticsearch server managed by Quarkus Dev Services is shared. When shared, Quarkus looks for running containers using label-based service discovery. If a matching container is found, it is used, and so a second one is not started. Otherwise, Dev Services for Elasticsearch starts a new container.
The discovery uses the |
boolean |
|
The value of the |
string |
|