dschulten edited a comment on pull request #5332: URL: https://github.com/apache/camel/pull/5332#issuecomment-821819464
I have changed the ServiceFilter implementation so that it takes the current exchange now, breaking existing `ServiceFilter` implementations as suggested. `RibbonServiceLoadBalancer` uses a Netflix `ZoneAwareLoadBalancer` which has no concept of a current exchange, so it can't pass the current exchange into `ServiceFilter`. I now pass a dummy exchange to the server filter in `RibbonServerList`. I had to create a `DummyExchange` class since the `DefaultExchange` did not work - the build complained about a missing `com.netflix.servo.annotations.DataSourceType` class file (a runtime scope dependency of ribbon-loadbalancer) which I have been unable to resolve so far (unless I add servo-core as a compile or provided dependency, but I didn't want to change the ribbon dependencies without discussing it first): ``` Error: Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.8.1:compile (default-compile) on project camel-ribbon: Compilation failure: Compilation failure: Error: /home/runner/work/camel/camel/components/camel-ribbon/src/main/java/org/apache/camel/component/ribbon/cloud/RibbonServiceLoadBalancer.java:[47,28] error: cannot find symbol Error: symbol: class DefaultCamelContext Error: location: package org.apache.camel.impl Error: reason: class file for com.netflix.servo.annotations.DataSourceType not found Error: warning: unknown enum constant DataSourceType.GAUGE Error: warning: unknown enum constant DataSourceType.GAUGE Error: warning: unknown enum constant DataSourceType.GAUGE Error: warning: unknown enum constant DataSourceType.INFORMATIONAL Error: warning: unknown enum constant DataSourceType.INFORMATIONAL Error: /home/runner/work/camel/camel/components/camel-ribbon/src/main/java/org/apache/camel/component/ribbon/cloud/RibbonServiceLoadBalancer.java:[213,57] error: cannot find symbol Error: symbol: class DefaultCamelContext Error: location: class RibbonServerList ``` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org