With Camel proxy I can do the following:
public class MyBean {
@Produce(uri = "direct:mybean")
private MyProxy producer;
public void doSomething() {
String response = producer.sayHello("James");
}
}
where MyProxy is interface with one method - sayHello()
.
But in my case I want to have multiple methods in the MyProxy
interface which ideally would have separate URI endpoints. Otherwise I will have an interface for every endpoint that I want to proxy.
The anotations @Produce
and @EndpointInject
can be set on methods too so I guess that this is possible. Is it? And if not can you recommend me another approach?