This is an automated email from the ASF dual-hosted git repository.

davsclaus pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git


The following commit(s) were added to refs/heads/main by this push:
     new d838241222a CAMEL-22050: camel-rest-openapi - Component configuration 
should be used in endpoint
d838241222a is described below

commit d838241222a04a1c35fb9716ca3dc3526137ecad
Author: Claus Ibsen <claus.ib...@gmail.com>
AuthorDate: Thu May 8 09:23:16 2025 +0200

    CAMEL-22050: camel-rest-openapi - Component configuration should be used in 
endpoint
---
 .../apache/camel/component/rest/openapi/RestOpenApiComponent.java | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git 
a/components/camel-rest-openapi/src/main/java/org/apache/camel/component/rest/openapi/RestOpenApiComponent.java
 
b/components/camel-rest-openapi/src/main/java/org/apache/camel/component/rest/openapi/RestOpenApiComponent.java
index 97f6cf256eb..f490e3da351 100644
--- 
a/components/camel-rest-openapi/src/main/java/org/apache/camel/component/rest/openapi/RestOpenApiComponent.java
+++ 
b/components/camel-rest-openapi/src/main/java/org/apache/camel/component/rest/openapi/RestOpenApiComponent.java
@@ -163,11 +163,15 @@ public final class RestOpenApiComponent extends 
DefaultComponent implements SSLC
         endpoint.setComponentName(getComponentName());
         endpoint.setConsumerComponentName(getConsumerComponentName());
         endpoint.setConsumes(getConsumes());
-        endpoint.setHost(getHost());
+        if (getHost() != null) {
+            endpoint.setHost(getHost());
+        }
         endpoint.setProduces(getProduces());
         endpoint.setRequestValidationEnabled(isRequestValidationEnabled());
         
endpoint.setRestOpenapiProcessorStrategy(getRestOpenapiProcessorStrategy());
-        endpoint.setSpecificationUri(getSpecificationUri());
+        if (getSpecificationUri() != null) {
+            endpoint.setSpecificationUri(getSpecificationUri());
+        }
         endpoint.setMissingOperation(getMissingOperation());
         endpoint.setMockIncludePattern(getMockIncludePattern());
         
endpoint.setRestOpenapiProcessorStrategy(getRestOpenapiProcessorStrategy());

Reply via email to