You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
To test against a running instance that only accepts SSL/TLS connection (example: `https://1.2.3.4:4321`) set the system property `quarkus.http.test-ssl-enabled` to `true`.
1434
+
To test against a running instance that only accepts SSL/TLS connection (example: `https://1.2.3.4:4321`) set the system property `quarkus.http.test-ssl-enabled` to `true` and `quarkus.http.test-ssl-port` to the target HTTPS port.
TIP: The condition in a ternary operator evaluates to `true` if the value is not considered `falsy` as described in <<if_section>>.
@@ -2263,22 +2267,23 @@ NOTE: Superfluous matching conditions are ignored. The conditions sorted by prio
2263
2267
2264
2268
An extension method may declare parameters.
2265
2269
If no namespace is specified then the first parameter that is not annotated with `@TemplateAttribute` is used to pass the base object, i.e. `org.acme.Item` in the first example.
2266
-
If matching any name or using a regular expression, then a string method parameter needs to be used to pass the property name.
2270
+
If matching any name or using a regular expression, then a string method parameter (not not annotated with `@TemplateAttribute`) needs to be used to pass the property name.
2267
2271
Parameters annotated with `@TemplateAttribute` are obtained via `TemplateInstance#getAttribute()`.
2268
-
All other parameters are resolved when rendering the template and passed to the extension method.
2272
+
All other parameters are treated as virtual method parameters and resolved when rendering the template and passed to the extension method.
2269
2273
2270
2274
.Multiple Parameters Example
2271
2275
[source,java]
2272
2276
----
2273
2277
@TemplateExtension
2274
2278
class BigDecimalExtensions {
2275
2279
2276
-
static BigDecimal scale(BigDecimal val, int scale, RoundingMode mode) { <1>
<1> This method matches an expression with base object of the type `BigDecimal.class`, with the `scale` virtual method name and two virtual method parameters.
2286
+
<1> This method matches an expression with base object of the type `BigDecimal.class`, with the `scale()`/`setScale()` virtual method name and two virtual method parameters - `scale` and `mode`.
- Types that have a constructor that accepts a single link:{jdkapi}/java/lang/String.html[`String`] argument.
2890
-
- Types that have a static method named `valueOf` or `fromString` with a single link:{jdkapi}/java/lang/String.html[`String`] argument
2888
+
2. Primitive types.
2889
+
3. Types that have a constructor that accepts a single link:{jdkapi}/java/lang/String.html[`String`] argument.
2890
+
4. Types that have a static method named `valueOf` or `fromString` with a single link:{jdkapi}/java/lang/String.html[`String`] argument
2891
2891
that return an instance of the type. If both methods are present then `valueOf` will be used unless
2892
2892
the type is an `enum` in which case `fromString` will be used.
2893
-
- link:{jdkapi}/java/util/List.html[`List<T>`], link:{jdkapi}/java/util/Set.html[`Set<T>`], or
2894
-
link:{jdkapi}/java/util/SortedSet.html[`SortedSet<T>`], where `T` satisfies any above criterion.
2893
+
5. link:{jdkapi}/java/util/List.html[`List<T>`], link:{jdkapi}/java/util/Set.html[`Set<T>`], or
2894
+
link:{jdkapi}/java/util/SortedSet.html[`SortedSet<T>`], where `T` satisfies 1, 3 or 4 above.
2895
+
2896
+
For 3 and 4, constructor instantiation is prioritesed above method instantiation. Public, protected, and package private constructors and methods are supported for instantiation.
2895
2897
2896
2898
The following example illustrates all those possibilities:
Impacted servers and clients may need to listen to the `CertificateUpdatedEvent` to apply the new certificates.
852
-
This is automatically done for the Quarkus HTTP server, such as the Quarkus REST server, gRPC server, and WebSocket server, as well as the management interface if it is enabled.
852
+
This is automatically done for the Quarkus HTTP server, as well as the Quarkus REST server, gRPC server, and WebSocket server, as well as the management interface if it is enabled.
853
+
On the client side, Quarkus REST Client automatically handles certificate update events.
853
854
====
854
855
855
856
NOTE: In Quarkus dev mode, when files are touched, it will trigger the `CertificateUpdatedEvent` much more frequently.
0 commit comments