You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In my project I have a setup that requires reading one message and then sending to another. If it fails I need to put the message on a DLQ or backout queue. But for some reason in the decorator that implements SubscriberDecorator the channel doesn't show up.
Take a look at the following.
@Incoming(REQUEST_INCOMING_CHANNEL)
@Outgoing(RESPONSE_OUTGOING_CHANNEL)
public void handleSomeData(double price) {
// process your price.
}
@ApplicationScoped
public class ConsumedMessageDecorator implements PublisherDecorator {
private final Map<String, AtomicLong> counters = new HashMap<>();
@Override
public Multi<? extends Message<?>> decorate(Multi<? extends Message<?>> publisher, String channelName,
boolean isConnector) {
if (channelName.contains(REQUEST_INCOMING_CHANNEL)) {
//some code
} else {
return publisher;
}
}
@Override
public int getPriority() {
return 10;
}
public long getMessageCount(String channel) {
return counters.get(channel).get();
}
}
If I have both @incoming and @Outgoing on the handleSomeData method. The channelName.contains will never be true.
But if I only have @incoming it does appear in the channelName.
This has to be a bug, but I haven't been able to figure out why.
I have currently done a workaround by using the MutinyEmitter and just sending the message directly to the Reponse queue in the handleSomeData method.
The text was updated successfully, but these errors were encountered:
In my project I have a setup that requires reading one message and then sending to another. If it fails I need to put the message on a DLQ or backout queue. But for some reason in the decorator that implements SubscriberDecorator the channel doesn't show up.
Take a look at the following.
If I have both @incoming and @Outgoing on the handleSomeData method. The channelName.contains will never be true.
But if I only have @incoming it does appear in the channelName.
This has to be a bug, but I haven't been able to figure out why.
I have currently done a workaround by using the MutinyEmitter and just sending the message directly to the Reponse queue in the handleSomeData method.
The text was updated successfully, but these errors were encountered: