Package io.quarkiverse.cxf
Interface CxfConfig
@ConfigMapping(prefix="quarkus.cxf")
@ConfigRoot(phase=RUN_TIME)
public interface CxfConfig
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionclients()Configure client proxies.An URI base to use as a prefix of `quarkus.cxf.client.myClient.decoupled-endpoint`.Choose the path of each web services.default CxfClientConfiginternal()This exists just as a convenient way to get a `CxfClientConfig` with all defaults set.default booleanisClientPresent(String key) logging()Global logging related configuration
-
Method Details
-
decoupledEndpointBase
An URI base to use as a prefix of `quarkus.cxf.client.myClient.decoupled-endpoint`. You will typically want to set this to something like the following: [source,properties] ---- quarkus.cxf.decoupled-endpoint-base = https://api.example.com:${quarkus.http.ssl-port}${quarkus.cxf.path} # or for plain HTTP quarkus.cxf.decoupled-endpoint-base = http://api.example.com:${quarkus.http.port}${quarkus.cxf.path} ---- If you invoke your WS client from within a HTTP handler, you can leave this option unspecified and rather set it dynamically on the request context of your WS client using the `org.apache.cxf.ws.addressing.decoupled.endpoint.base` key. Here is an example how to do that from a RESTeasy handler method: [source,java] ---- import java.util.Map; import jakarta.inject.Inject; import jakarta.ws.rs.POST; import jakarta.ws.rs.Path; import jakarta.ws.rs.Produces; import jakarta.ws.rs.core.Context; import jakarta.ws.rs.core.MediaType; import jakarta.ws.rs.core.UriInfo; import jakarta.xml.ws.BindingProvider; import io.quarkiverse.cxf.annotation.CXFClient; import org.eclipse.microprofile.config.inject.ConfigProperty; @Path("/my-rest") public class MyRestEasyResource { @Inject @CXFClient("hello") HelloService helloService; @ConfigProperty(name = "quarkus.cxf.path") String quarkusCxfPath; @POST @Path("/hello") @Produces(MediaType.TEXT_PLAIN) public String hello(String body, @Context UriInfo uriInfo) throws IOException { // You may consider doing this only once if you are sure that your service is accessed // through a single hostname String decoupledEndpointBase = uriInfo.getBaseUriBuilder().path(quarkusCxfPath); Map>String, Object< requestContext = ((BindingProvider) helloService).getRequestContext(); requestContext.put("org.apache.cxf.ws.addressing.decoupled.endpoint.base", decoupledEndpointBase); return wsrmHelloService.hello(body); } } ----- Since:
- 2.7.0
-
endpoints
Choose the path of each web services. -
clients
Configure client proxies. -
internal
CxfConfig.InternalConfig internal()This exists just as a convenient way to get a `CxfClientConfig` with all defaults set. It is not intended to be used by end users. -
logging
LoggingConfig.GlobalLoggingConfig logging()Global logging related configuration -
isClientPresent
-
getClient
-