-
Notifications
You must be signed in to change notification settings - Fork 2.5k
This issue was moved to a discussion.
You can continue the conversation there. Go to discussion →
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SQS Sending/Receiving Message in mutiny reactive #40587
Comments
/cc @cescoffier (mutiny), @jponge (mutiny) |
I don't believe the SQS connector is supported in Quarkus. For sure adding the ASM dependency is not great (lots of clashes). I think @ozangunalp had an example somewhere. |
Normally you don't need the asm dependency, there must be some incompatible versioning.
The |
when used consume event and passed an param as part of function it fails with Caused by: java.lang.ClassNotFoundException: org.objectweb.asm.ClassVisitor do you have any suggestions on triggering to sqs via event bus or alternate approaches to receive param |
When providing a stack trace, please provide the full stack trace, not just the message. Otherwise it's impossible for us to know what triggered it. Also your dependency tree might be of interest. |
apologies @gsmet here we have the trace.
dependencies
|
+1 Also the event bus |
you mean sqs outgoing channel? //At producer Existing
private final EventBus eventBus;
//Existing
.invoke(usageDataEntity -> eventBus.send("EVENTBUS", usageDataEntity))
// new?
.invoke(usageDataEntity -> eventBus.send("sqs-channel", usageDataEntity)) //At consumer responsible for sending events to sqs
@Outgoing("sqs-channel") //Existing
@ConsumeEvent("EVENTBUS")
@Outgoing("sqs-channel") // new?
public Multi<Message<String>> generate(final List<String> itemsTOSqs) {
return Multi.createFrom().iterable(itemsTOSqs).map(udmUsageData -> Message.of(itemTOSqs, Metadata.of(SqsOutboundMetadata.builder()
.deduplicationId("id001")
.groupId("groupId")
.build())));
} is this what you are expecting |
You can either use the emitter directly :
Or use an internal channel instead of event bus:
Or if your
The pseudocode may have some errors but I hope you get the idea. |
@ozangunalp Thanks for your response. I have tried with emitter way which doesn't have any issue till sending messages, however it doesn't log error or emit message to queue eventBus.send("SQS_EVENT", List.of("Sample")) // producer
@Channel("sqs_channel")
Emitter<String> sqsEmitter;
@ConsumeEvent("SQS_EVENT")
public void sendToSQSQueue(final List<String> itemsToSqs) {
sqsEmitter.send("...message"); // some plain string to test
}
public class SqsConfig {
@Produces
public SqsAsyncClient sqsAsyncClient() {
return SqsAsyncClient.builder()
.region(Region.of("us-west-2"))
.build();
}
} using a internal channel on field fails with injection error '@Outgoing' not applicable to field @Outgoing("sqs-sender")
private final Emitter<List<String>> sqsEmitter; If possible can you share a working example or let me know if needed a reproducible code. |
I've pushed an example project here: https://github.com/ozangunalp/quarkus-aws-sqs-connector If you send a reproducer I can take a look. I am changing this issue to a discussion. |
This issue was moved to a discussion.
You can continue the conversation there. Go to discussion →
Description
reactive messaging SQS
as per documentation I have used below two dependencies
which fails with "Caused by: java.lang.ClassNotFoundException: org.objectweb.asm.ClassVisitor" ended up adding
can we have an example with SQS sending and receiving messages.
using application.yaml
which doesn't log any error and I don't see messages in sqs queue. Can we have a clear dependencies list and enhance documentation which would really help.
Implementation ideas
No response
The text was updated successfully, but these errors were encountered: