Replies: 3 comments 1 reply
-
Both the server and the client need to start, but there's no specific order they must follow. The server will send messages to the |
Beta Was this translation helpful? Give feedback.
-
After new tests, I'm convinced that IDistributedEventHandler fails to meet the requirements. Moreover, a new issue has been found: when the server and client are deployed in a distributed manner, messages cannot be guaranteed to be delivered to the client via IDistributedEventHandler.PublishAsync, which is unacceptable in my business scenario. I checked the source code and found that ABP always has a Consumer resident during startup. This causes the server to receive messages even if it doesn't need to consume them. Additionally, the source code logic is that if the consumer doesn't encounter errors during consumption, it defaults to a successful consumption. This is very problematic for me, as it results in the client not receiving all messages. I'm not sure if I'm using it incorrectly or if it's designed this way. I can only look for another solution. |
Beta Was this translation helpful? Give feedback.
-
I solved this problem by using two different Queues for the client and the server, which well meets my requirements. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi,
I was working with IDistributedEventHandler in my code and ran into this thing. My setup splits the work between a Server and a Client app.
Here's what's weird: If I start just the Server by itself (without the Client running), then whenever the Server uses IDistributedEventHandler.PublishAsync to send something out, the messages end up empty in RabbitMQ. Like, there's nothing useful in them.
But, if I start both the Server and the Client together, everything works perfectly fine – messages go through normally.
So my big question is: Do I have to start the Client before the Server? And what happens if the Client starts later, or crashes and has to restart? Does that mean any messages the Server sends out while the Client is down or starting late are just... gone forever?
Beta Was this translation helpful? Give feedback.
All reactions