Skip to content

Commit 7c850cc

Browse files
committed
Sync documentation of main branch
1 parent a183769 commit 7c850cc

10 files changed

+76
-118
lines changed

_generated-doc/main/config/quarkus-all-config.adoc

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14295,7 +14295,7 @@ endif::add-copy-button-to-config-props[]
1429514295

1429614296
[.description]
1429714297
--
14298-
Origins allowed for CORS Comma separated list of valid URLs, e.g.: http://www.quarkus.io,http://localhost:3000 In case an entry of the list is surrounded by forward slashes, it is interpreted as a regular expression.
14298+
The origins allowed for CORS. A comma-separated list of valid URLs, such as `http://www.quarkus.io,http://localhost:3000`. URLs enclosed in forward slashes are interpreted as regular expressions.
1429914299

1430014300

1430114301
ifdef::add-copy-button-to-env-var[]
@@ -14316,7 +14316,7 @@ endif::add-copy-button-to-config-props[]
1431614316

1431714317
[.description]
1431814318
--
14319-
HTTP methods allowed for CORS Comma separated list of valid methods. ex: GET,PUT,POST The filter allows any method if this is not set. default: returns any requested method as valid
14319+
The HTTP methods allowed for CORS requests. A comma-separated list of valid HTTP methods, such as `GET,PUT,POST`. If not set, the filter allows any HTTP method by default. Default: Any HTTP request method is allowed.
1432014320

1432114321

1432214322
ifdef::add-copy-button-to-env-var[]
@@ -14337,7 +14337,7 @@ endif::add-copy-button-to-config-props[]
1433714337

1433814338
[.description]
1433914339
--
14340-
HTTP headers allowed for CORS Comma separated list of valid headers. ex: X-Custom,Content-Disposition The filter allows any header if this is not set. default: returns any requested header as valid
14340+
The HTTP headers allowed for CORS requests. A comma-separated list of valid headers, such as `X-Custom,Content-Disposition`. If not set, the filter allows any header by default. Default: Any HTTP request header is allowed.
1434114341

1434214342

1434314343
ifdef::add-copy-button-to-env-var[]
@@ -14358,7 +14358,7 @@ endif::add-copy-button-to-config-props[]
1435814358

1435914359
[.description]
1436014360
--
14361-
HTTP headers exposed in CORS Comma separated list of valid headers. ex: X-Custom,Content-Disposition default: empty
14361+
The HTTP headers exposed in CORS responses. A comma-separated list of headers to expose, such as `X-Custom,Content-Disposition`. Default: No headers are exposed.
1436214362

1436314363

1436414364
ifdef::add-copy-button-to-env-var[]
@@ -14379,7 +14379,7 @@ endif::add-copy-button-to-config-props[]
1437914379

1438014380
[.description]
1438114381
--
14382-
The `Access-Control-Max-Age` response header value indicating how long the results of a pre-flight request can be cached.
14382+
The `Access-Control-Max-Age` response header value in `java.time.Duration` format. Informs the browser how long it can cache the results of a preflight request.
1438314383

1438414384

1438514385
ifdef::add-copy-button-to-env-var[]
@@ -14400,7 +14400,7 @@ endif::add-copy-button-to-config-props[]
1440014400

1440114401
[.description]
1440214402
--
14403-
The `Access-Control-Allow-Credentials` header is used to tell the browsers to expose the response to front-end JavaScript code when the requests credentials mode Request.credentials is include”. The value of this header will default to `true` if `quarkus.http.cors.origins` property is set and there is a match with the precise `Origin` header.
14403+
The `Access-Control-Allow-Credentials` response header. Tells browsers if front-end JavaScript can be allowed to access credentials when the request's credentials mode, `Request.credentials`, is set to `include`. Default: `true` if the `quarkus.http.cors.origins` property is set and matches the precise `Origin` header value.
1440414404

1440514405

1440614406
ifdef::add-copy-button-to-env-var[]

_generated-doc/main/config/quarkus-vertx-http_quarkus.http.adoc

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2301,7 +2301,7 @@ endif::add-copy-button-to-config-props[]
23012301

23022302
[.description]
23032303
--
2304-
Origins allowed for CORS Comma separated list of valid URLs, e.g.: http://www.quarkus.io,http://localhost:3000 In case an entry of the list is surrounded by forward slashes, it is interpreted as a regular expression.
2304+
The origins allowed for CORS. A comma-separated list of valid URLs, such as `http://www.quarkus.io,http://localhost:3000`. URLs enclosed in forward slashes are interpreted as regular expressions.
23052305

23062306

23072307
ifdef::add-copy-button-to-env-var[]
@@ -2322,7 +2322,7 @@ endif::add-copy-button-to-config-props[]
23222322

23232323
[.description]
23242324
--
2325-
HTTP methods allowed for CORS Comma separated list of valid methods. ex: GET,PUT,POST The filter allows any method if this is not set. default: returns any requested method as valid
2325+
The HTTP methods allowed for CORS requests. A comma-separated list of valid HTTP methods, such as `GET,PUT,POST`. If not set, the filter allows any HTTP method by default. Default: Any HTTP request method is allowed.
23262326

23272327

23282328
ifdef::add-copy-button-to-env-var[]
@@ -2343,7 +2343,7 @@ endif::add-copy-button-to-config-props[]
23432343

23442344
[.description]
23452345
--
2346-
HTTP headers allowed for CORS Comma separated list of valid headers. ex: X-Custom,Content-Disposition The filter allows any header if this is not set. default: returns any requested header as valid
2346+
The HTTP headers allowed for CORS requests. A comma-separated list of valid headers, such as `X-Custom,Content-Disposition`. If not set, the filter allows any header by default. Default: Any HTTP request header is allowed.
23472347

23482348

23492349
ifdef::add-copy-button-to-env-var[]
@@ -2364,7 +2364,7 @@ endif::add-copy-button-to-config-props[]
23642364

23652365
[.description]
23662366
--
2367-
HTTP headers exposed in CORS Comma separated list of valid headers. ex: X-Custom,Content-Disposition default: empty
2367+
The HTTP headers exposed in CORS responses. A comma-separated list of headers to expose, such as `X-Custom,Content-Disposition`. Default: No headers are exposed.
23682368

23692369

23702370
ifdef::add-copy-button-to-env-var[]
@@ -2385,7 +2385,7 @@ endif::add-copy-button-to-config-props[]
23852385

23862386
[.description]
23872387
--
2388-
The `Access-Control-Max-Age` response header value indicating how long the results of a pre-flight request can be cached.
2388+
The `Access-Control-Max-Age` response header value in `java.time.Duration` format. Informs the browser how long it can cache the results of a preflight request.
23892389

23902390

23912391
ifdef::add-copy-button-to-env-var[]
@@ -2406,7 +2406,7 @@ endif::add-copy-button-to-config-props[]
24062406

24072407
[.description]
24082408
--
2409-
The `Access-Control-Allow-Credentials` header is used to tell the browsers to expose the response to front-end JavaScript code when the requests credentials mode Request.credentials is include”. The value of this header will default to `true` if `quarkus.http.cors.origins` property is set and there is a match with the precise `Origin` header.
2409+
The `Access-Control-Allow-Credentials` response header. Tells browsers if front-end JavaScript can be allowed to access credentials when the request's credentials mode, `Request.credentials`, is set to `include`. Default: `true` if the `quarkus.http.cors.origins` property is set and matches the precise `Origin` header value.
24102410

24112411

24122412
ifdef::add-copy-button-to-env-var[]

_generated-doc/main/config/quarkus-vertx-http_quarkus.http.cors.adoc

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ endif::add-copy-button-to-config-props[]
1515

1616
[.description]
1717
--
18-
Origins allowed for CORS Comma separated list of valid URLs, e.g.: http://www.quarkus.io,http://localhost:3000 In case an entry of the list is surrounded by forward slashes, it is interpreted as a regular expression.
18+
The origins allowed for CORS. A comma-separated list of valid URLs, such as `http://www.quarkus.io,http://localhost:3000`. URLs enclosed in forward slashes are interpreted as regular expressions.
1919

2020

2121
ifdef::add-copy-button-to-env-var[]
@@ -36,7 +36,7 @@ endif::add-copy-button-to-config-props[]
3636

3737
[.description]
3838
--
39-
HTTP methods allowed for CORS Comma separated list of valid methods. ex: GET,PUT,POST The filter allows any method if this is not set. default: returns any requested method as valid
39+
The HTTP methods allowed for CORS requests. A comma-separated list of valid HTTP methods, such as `GET,PUT,POST`. If not set, the filter allows any HTTP method by default. Default: Any HTTP request method is allowed.
4040

4141

4242
ifdef::add-copy-button-to-env-var[]
@@ -57,7 +57,7 @@ endif::add-copy-button-to-config-props[]
5757

5858
[.description]
5959
--
60-
HTTP headers allowed for CORS Comma separated list of valid headers. ex: X-Custom,Content-Disposition The filter allows any header if this is not set. default: returns any requested header as valid
60+
The HTTP headers allowed for CORS requests. A comma-separated list of valid headers, such as `X-Custom,Content-Disposition`. If not set, the filter allows any header by default. Default: Any HTTP request header is allowed.
6161

6262

6363
ifdef::add-copy-button-to-env-var[]
@@ -78,7 +78,7 @@ endif::add-copy-button-to-config-props[]
7878

7979
[.description]
8080
--
81-
HTTP headers exposed in CORS Comma separated list of valid headers. ex: X-Custom,Content-Disposition default: empty
81+
The HTTP headers exposed in CORS responses. A comma-separated list of headers to expose, such as `X-Custom,Content-Disposition`. Default: No headers are exposed.
8282

8383

8484
ifdef::add-copy-button-to-env-var[]
@@ -99,7 +99,7 @@ endif::add-copy-button-to-config-props[]
9999

100100
[.description]
101101
--
102-
The `Access-Control-Max-Age` response header value indicating how long the results of a pre-flight request can be cached.
102+
The `Access-Control-Max-Age` response header value in `java.time.Duration` format. Informs the browser how long it can cache the results of a preflight request.
103103

104104

105105
ifdef::add-copy-button-to-env-var[]
@@ -120,7 +120,7 @@ endif::add-copy-button-to-config-props[]
120120

121121
[.description]
122122
--
123-
The `Access-Control-Allow-Credentials` header is used to tell the browsers to expose the response to front-end JavaScript code when the requests credentials mode Request.credentials is include”. The value of this header will default to `true` if `quarkus.http.cors.origins` property is set and there is a match with the precise `Origin` header.
123+
The `Access-Control-Allow-Credentials` response header. Tells browsers if front-end JavaScript can be allowed to access credentials when the request's credentials mode, `Request.credentials`, is set to `include`. Default: `true` if the `quarkus.http.cors.origins` property is set and matches the precise `Origin` header value.
124124

125125

126126
ifdef::add-copy-button-to-env-var[]

_generated-doc/main/infra/quarkus-all-build-items.adoc

Lines changed: 4 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -5822,17 +5822,6 @@ h|Attributes
58225822

58235823

58245824

5825-
a| https://github.com/quarkusio/quarkus/blob/main/extensions/opentelemetry/deployment/src/main/java/io/quarkus/opentelemetry/deployment/tracing/DropApplicationUrisBuildItem.java[`io.quarkus.opentelemetry.deployment.tracing.DropApplicationUrisBuildItem`, window="_blank"]
5826-
[.description]
5827-
--
5828-
Represents an application uri that must be ignored for tracing.
5829-
-- a|`java.lang.String uri`
5830-
5831-
_No Javadoc found_
5832-
5833-
5834-
5835-
58365825
a| https://github.com/quarkusio/quarkus/blob/main/extensions/opentelemetry/deployment/src/main/java/io/quarkus/opentelemetry/deployment/tracing/DropNonApplicationUrisBuildItem.java[`io.quarkus.opentelemetry.deployment.tracing.DropNonApplicationUrisBuildItem`, window="_blank"]
58375826
[.description]
58385827
--
@@ -5904,14 +5893,14 @@ h|Attributes
59045893

59055894

59065895

5907-
a| https://github.com/quarkusio/quarkus/blob/main/extensions/panache/panache-hibernate-common/deployment/src/main/java/io/quarkus/panache/common/deployment/HibernateEnhancersRegisteredBuildItem.java[`io.quarkus.panache.common.deployment.HibernateEnhancersRegisteredBuildItem`, window="_blank"]
5896+
a| https://github.com/quarkusio/quarkus/blob/main/extensions/panache/panache-hibernate-common/deployment/src/main/java/io/quarkus/panache/hibernate/common/deployment/HibernateEnhancersRegisteredBuildItem.java[`io.quarkus.panache.hibernate.common.deployment.HibernateEnhancersRegisteredBuildItem`, window="_blank"]
59085897
[.description]
59095898
--
59105899
Purely marker build item so that you can register enhancers after Hibernate registers its enhancers, which would make your enhancers run before the Hibernate enhancers
59115900
-- a|None
59125901
59135902
5914-
a| https://github.com/quarkusio/quarkus/blob/main/extensions/panache/panache-hibernate-common/deployment/src/main/java/io/quarkus/panache/common/deployment/HibernateMetamodelForFieldAccessBuildItem.java[`io.quarkus.panache.common.deployment.HibernateMetamodelForFieldAccessBuildItem`, window="_blank"]
5903+
a| https://github.com/quarkusio/quarkus/blob/main/extensions/panache/panache-hibernate-common/deployment/src/main/java/io/quarkus/panache/hibernate/common/deployment/HibernateMetamodelForFieldAccessBuildItem.java[`io.quarkus.panache.hibernate.common.deployment.HibernateMetamodelForFieldAccessBuildItem`, window="_blank"]
59155904
[.description]
59165905
--
59175906
_No Javadoc found_
@@ -5922,7 +5911,7 @@ _No Javadoc found_
59225911

59235912

59245913

5925-
a| https://github.com/quarkusio/quarkus/blob/main/extensions/panache/panache-hibernate-common/deployment/src/main/java/io/quarkus/panache/common/deployment/HibernateModelClassCandidatesForFieldAccessBuildItem.java[`io.quarkus.panache.common.deployment.HibernateModelClassCandidatesForFieldAccessBuildItem`, window="_blank"]
5914+
a| https://github.com/quarkusio/quarkus/blob/main/extensions/panache/panache-hibernate-common/deployment/src/main/java/io/quarkus/panache/hibernate/common/deployment/HibernateModelClassCandidatesForFieldAccessBuildItem.java[`io.quarkus.panache.hibernate.common.deployment.HibernateModelClassCandidatesForFieldAccessBuildItem`, window="_blank"]
59265915
[.description]
59275916
--
59285917
_No Javadoc found_
@@ -6777,7 +6766,7 @@ h|Attributes
67776766

67786767

67796768

6780-
a| https://github.com/quarkusio/quarkus/blob/main/extensions/resteasy-reactive/rest-jackson-common/deployment/src/main/java/io/quarkus/resteasy/reactive/jackson/deployment/processor/ResteasyReactiveJacksonProviderDefinedBuildItem.java[`io.quarkus.resteasy.reactive.jackson.deployment.processor.ResteasyReactiveJacksonProviderDefinedBuildItem`, window="_blank"]
6769+
a| https://github.com/quarkusio/quarkus/blob/main/extensions/resteasy-reactive/rest-jackson-common/deployment/src/main/java/io/quarkus/resteasy/reactive/jackson/common/deployment/processor/ResteasyReactiveJacksonProviderDefinedBuildItem.java[`io.quarkus.resteasy.reactive.jackson.common.deployment.processor.ResteasyReactiveJacksonProviderDefinedBuildItem`, window="_blank"]
67816770
[.description]
67826771
--
67836772
A BuildItem to mark that the server side jackson provider is defined. If not "emitted" by any of the processors, the reactive rest client (if used) will add its own jackson provider

_versions/main/guides/getting-started-testing.adoc

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1236,7 +1236,20 @@ public @interface WithRepeatableTestResource {
12361236
}
12371237
----
12381238

1239+
=== Usage of `@WithTestResources`
12391240

1241+
While test resources provided by `@QuarkusTestResource` are available either globally or restricted to the annotated test class (`restrictToAnnotatedClass`), the annotation `@WithTestResources` allows to additionally group tests by test resources for execution.
1242+
`@WithTestResources` has a `scope` property that takes a `TestResourceScope` enum value:
1243+
1244+
- `TestResourceScope.MATCHING_RESOURCES` (default): Quarkus will group tests with the same test resources and run them together. After a group has been executed, all test resources will be stopped, and the next group will be executed.
1245+
- `TestResourceScope.RESTRICTED_TO_CLASS`: The test resource is available only for the annotated test class and will be stopped after the test class has been executed.
1246+
- `TestResourceScope.GLOBAL`: Test resources apply to all tests in the testsuite
1247+
1248+
Quarkus needs to restart if one of the following is true:
1249+
1250+
- At least one the existing test resources is restricted to the test class
1251+
- At least one the next test resources is restricted to the test class
1252+
- Different {@code MATCHING_RESOURCE} scoped test resources are being used
12401253

12411254
== Hang Detection
12421255

_versions/main/guides/hibernate-orm.adoc

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1159,27 +1159,33 @@ From the implementation above, tenants are resolved from the request path so tha
11591159

11601160
[NOTE]
11611161
====
1162-
If you also use xref:security-openid-connect-multitenancy.adoc[OIDC multitenancy] and both OIDC and Hibernate ORM tenant IDs are the same and must be extracted from the Vert.x `RoutingContext` then you can pass the tenant id from the OIDC Tenant Resolver to the Hibernate ORM Tenant Resolver as a `RoutingContext` attribute, for example:
1162+
If you also use xref:security-openid-connect-multitenancy.adoc[OIDC multitenancy] and both OIDC and Hibernate ORM tenant IDs are the same,
1163+
you can get the OIDC tenant id from a `RoutingContext` attribute like in the example below:
11631164
11641165
[source,java]
11651166
----
11661167
import io.quarkus.hibernate.orm.runtime.tenant.TenantResolver;
1168+
import io.quarkus.oidc.runtime.OidcUtils;
11671169
import io.vertx.ext.web.RoutingContext;
11681170
11691171
@PersistenceUnitExtension
11701172
@RequestScoped
11711173
public class CustomTenantResolver implements TenantResolver {
11721174
11731175
@Inject
1174-
RoutingContext context;
1176+
RoutingContext context; <1>
11751177
...
11761178
@Override
11771179
public String resolveTenantId() {
1178-
// OIDC TenantResolver has already calculated the tenant id and saved it as a RoutingContext `tenantId` attribute:
1179-
return context.get("tenantId");
1180+
// OIDC has saved the tenant id as the RoutingContext attribute:
1181+
return context.get(OidcUtils.TENANT_ID_ATTRIBUTE);
11801182
}
11811183
}
11821184
----
1185+
<1> If the Hibernate `TenantResolver` also resolves tenants when there is no active HTTP request,
1186+
for example when you query database from a scheduler, the `RoutingContext` CDI bean will not be available.
1187+
Please inject the `io.quarkus.vertx.http.runtime.CurrentVertxRequest` CDI bean instead and get the `RoutingContext` from this bean.
1188+
11831189
====
11841190

11851191
=== Configuring the application

_versions/main/guides/mongodb-panache.adoc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1275,12 +1275,12 @@ and then `quarkus.mongodb.database` property.
12751275
[NOTE]
12761276
====
12771277
If you also use xref:security-openid-connect-multitenancy.adoc[OIDC multitenancy], then if the OIDC tenantID and MongoDB
1278-
database are the same and must be extracted from the Vert.x `RoutingContext` you can pass the tenant id from the OIDC `TenantResolver`
1279-
to the MongoDB with Panache `MongoDatabaseResolver` as a `RoutingContext` attribute, for example:
1278+
database are the same, you can access the OIDC tenant id from a `RoutingContext` attribute like in the example below:
12801279
12811280
[source,java]
12821281
----
12831282
import io.quarkus.mongodb.panache.common.MongoDatabaseResolver;
1283+
import io.quarkus.oidc.runtime.OidcUtils;
12841284
import io.vertx.ext.web.RoutingContext;
12851285
12861286
@RequestScoped
@@ -1291,8 +1291,8 @@ public class CustomMongoDatabaseResolver implements MongoDatabaseResolver {
12911291
...
12921292
@Override
12931293
public String resolve() {
1294-
// OIDC TenantResolver has already calculated the tenant id and saved it as a RoutingContext `tenantId` attribute:
1295-
return context.get("tenantId");
1294+
// OIDC has saved the tenant id as the RoutingContext attribute:
1295+
return context.get(OidcUtils.TENANT_ID_ATTRIBUTE);
12961296
}
12971297
}
12981298
----

0 commit comments

Comments
 (0)