Skip to content

Commit badc171

Browse files
committed
Sync documentation of main branch
1 parent 7334535 commit badc171

File tree

3 files changed

+43
-14
lines changed

3 files changed

+43
-14
lines changed

_versions/main/guides/deploying-to-openshift.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -483,7 +483,7 @@ quarkus.openshift.cron-job.schedule=0 * * * *
483483
----
484484

485485
IMPORTANT: CronJob resources require the https://en.wikipedia.org/wiki/Cron[Cron] expression to specify when to launch the job through the `quarkus.openshift.cron-job.schedule` property.
486-
If thet are not provided, the build fails.
486+
If they are not provided, the build fails.
487487

488488
You can configure the rest of the Kubernetes CronJob configuration by using the properties under `quarkus.openshift.cron-job.xxx` (for more information, see xref:deploying-to-openshift.adoc#quarkus-kubernetes_quarkus-openshift-cron-job-parallelism[quarkus.openshift.cron-job.parallelism]).
489489

_versions/main/guides/hibernate-reactive.adoc

Lines changed: 27 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -357,27 +357,41 @@ public class SomeTest {
357357
----
358358
====
359359

360-
[[hr-named-datasource]]
361-
==== Named data sources
360+
[[multiple-persistence-units]]
361+
=== Multiple persistence units
362362

363-
Hibernate Reactive supports having named data sources
363+
==== Setting up multiple persistence units
364+
365+
In a similar fashion to Hibernate ORM, Hibernate Reactive supports multiple persistence units.
366+
367+
You can define multiple persistence units and datasources, and they can mix blocking and reactive datasources.
368+
To ensure that a datasource supports reactive, you need to set the `reactive` property to `true`.
364369

365370
[source,properties]
366371
.Example `{config-file}`
367372
----
368-
# datasource configuration
369-
quarkus.hibernate-orm.datasource = named-datasource
370-
quarkus.datasource."named-datasource".db-kind" = postgresql
373+
quarkus.datasource."users".reactive.url=vertx-reactive:postgresql://localhost/users <1>
374+
quarkus.datasource."users".db-kind=postgresql
375+
%prod.quarkus.datasource."users".username=hibernate_orm_test
376+
%prod.quarkus.datasource."users".password=hibernate_orm_test
371377
372-
# drop and create the database at startup (use `update` to only update the schema)
373-
%prod.quarkus.hibernate-orm.schema-management.strategy=drop-and-create
374-
%prod.quarkus.datasource."named-datasource".reactive" = true
375-
%prod.quarkus.datasource."named-datasource".username" = quarkus_test
376-
%prod.quarkus.datasource."named-datasource".password" = quarkus_test
377-
%prod.quarkus.datasource.reactive.url = vertx-reactive:postgresql://localhost/quarkus_test <1>
378+
quarkus.datasource."inventory".reactive.url=vertx-reactive:postgresql://localhost/inventory <2>
379+
quarkus.datasource."inventory".db-kind=postgresql
380+
%prod.quarkus.datasource."inventory".username=hibernate_orm_test
381+
%prod.quarkus.datasource."inventory".password=hibernate_orm_test
382+
383+
quarkus.hibernate-orm."users".datasource=users <3>
384+
quarkus.hibernate-orm."users".packages=io.quarkus.hibernate.reactive.multiplepersistenceunits.model.config.user
385+
386+
quarkus.hibernate-orm."inventory".datasource=inventory <4>
387+
quarkus.hibernate-orm."inventory".packages=io.quarkus.hibernate.orm.multiplepersistenceunits.model.config.inventory
378388
----
389+
<1> Define a reactive datasource named `users`.
390+
<2> Define a reactive datasource named `inventory`.
391+
<3> Define a persistence unit named `users` and specify the datasource.
392+
<4> Define a persistence unit named `inventory` and specify the datasource.
379393

380-
When using a named data source, you need to set the `quarkus.hibernate-orm.datasource` property to the name of the data source.
394+
When using named persistence units, you must set the `datasource` property to the name of the corresponding datasource.
381395

382396
[[hr-limitations]]
383397
== Limitations and other things you should know

_versions/main/guides/kubernetes-dev-services.adoc

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,21 @@ And then add the following property to your `application.properties`:
8888
quarkus.kubernetes-client.devservices.manifests=kubernetes/namespace.yaml
8989
```
9090

91+
When applying multiple properties, you can apply them as:
92+
```
93+
quarkus.kubernetes-client.devservices.manifests=kubernetes/first_manifest.yaml,kubernetes/second_manifest.yaml
94+
```
95+
96+
It is also possible to apply manifests from a URL. So the following syntax would also be possible:
97+
```
98+
quarkus.kubernetes-client.devservices.manifests=https://example.com/kubernetes/namespace.yaml
99+
```
100+
101+
NOTE: Quarkus will apply the manifests in the order they are specified in the list.
102+
103+
NOTE: Quarkus will await resources such as deployments to be ready before moving on to the next manifest.
104+
All applied resources are guaranteed to be ready by the time your application finishes startup.
105+
91106
=== Deploying helm charts
92107
`quarkus.kubernetes-client.devservices.manifests` only supports manifests. If you want to deploy a helm chart, you can use the `k3s` flavor and deploy a `HelmChart` manifest. See https://docs.k3s.io/helm for more information on how to use helm charts with k3s.
93108

0 commit comments

Comments
 (0)