[
https://issues.apache.org/jira/browse/CAMEL-11843?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16182202#comment-16182202
]
James Netherton commented on CAMEL-11843:
-----------------------------------------
Turns out this component is a little odd. The endpoint is isLenientProperties =
true.
It allows users to configure different URI options depending on the docker
operation. Hence there is no fixed set of URI params.
We could change it to isLenientProperties = false so that the generic
validation kicks in. But this would throw an error on a URI like
{{docker:stats?host=foo&port=bar&containerId=abc123}}, because containerId is
not an @UriOption in the DockerConfiguration class.
All of the extra docker operation specific URI params can already be configured
as headers. So is it ok to force users to configure these extra options only
via headers instead of URI params?
> Unable to configure some URI options on DockerEndpoint
> -------------------------------------------------------
>
> Key: CAMEL-11843
> URL: https://issues.apache.org/jira/browse/CAMEL-11843
> Project: Camel
> Issue Type: Bug
> Components: camel-docker
> Affects Versions: 2.19.3
> Reporter: James Netherton
> Assignee: James Netherton
> Priority: Minor
> Fix For: 2.19.4, 2.20.0
>
>
> The docker component triggers some [custom
> logic|https://github.com/apache/camel/blob/master/components/camel-docker/src/main/java/org/apache/camel/component/docker/DockerComponent.java#L65]
> to validate URI options.
> It does not handle all of the valid set of URI options. E.g setting
> exchangePattern, maxTotalConnections and others, results in:
> {code}
> Caused by: com.github.dockerjava.api.exception.DockerClientException:
> bridgeErrorHandler is not a valid URI parameter
> at
> org.apache.camel.component.docker.DockerHelper.validateParameters(DockerHelper.java:56)
> at
> org.apache.camel.component.docker.DockerComponent.createEndpoint(DockerComponent.java:65)
> at
> org.apache.camel.impl.DefaultComponent.createEndpoint(DefaultComponent.java:126)
> at
> org.apache.camel.impl.DefaultCamelContext.getEndpoint(DefaultCamelContext.java:703)
> ... 51 more
> {code}
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)