You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by artemisn00b <pr...@nokia.com> on 2019/03/12 22:07:25 UTC

When is the ACK sent?

Suppose I have a symmetric cluster of 3 artemis servers. I send a message to
server 1, and it forwards it to other servers who have consumers. Now, when
exactly does the producer get an ACK?

I have a couple of scenarios where I wouldn't be able to figure out how it
works -

A) Server 1 forwarded a message to Server 2 and Server 3, and before
receiving the message, both the servers go down. Would I still receive the
ACK?

B) Server 1 forwarded a message to Server 2 and Server 3, and both receive
the message but before they send an ACK, they go down. Would I still receive
the ACK?

So, TLDR - I want to know when exactly does an Artemis server send an
acknowledgement, given I'm using auto acknowledge. Is it right after server
1 receives the message, or after all servers receive it, or after server 2
and server 3 send an ACK to server 1? Hope I'm clear enough!

Thanks! :)



--
Sent from: http://activemq.2283324.n4.nabble.com/ActiveMQ-User-f2341805.html

Re: When is the ACK sent?

Posted by artemisn00b <pr...@nokia.com>.
Thanks! :)



--
Sent from: http://activemq.2283324.n4.nabble.com/ActiveMQ-User-f2341805.html

Re: When is the ACK sent?

Posted by artemisn00b <pr...@nokia.com>.
Thanks! :)



--
Sent from: http://activemq.2283324.n4.nabble.com/ActiveMQ-User-f2341805.html

Re: When is the ACK sent?

Posted by mi...@me.com.INVALID.
If the brokers are not ha then the ack would return as soon as it has been received and persisted by the broker you send to.




Get Outlook for Android







On Wed, Mar 13, 2019 at 8:07 PM +0000, "artemisn00b" <pr...@nokia.com> wrote:










Thanks for the detailed response..However, this is not an HA solution as
such. I'm basically forwarding messages from a server to another, in a
symmetric cluster. I just wanted to know at what point exactly would a
client send an ack. Will a client send an ack on receiving it, or only after
it forwards the message to the other servers, and they receive it?

Thanks.



--
Sent from: http://activemq.2283324.n4.nabble.com/ActiveMQ-User-f2341805.html






Re: When is the ACK sent?

Posted by artemisn00b <pr...@nokia.com>.
Thanks for the detailed response..However, this is not an HA solution as
such. I'm basically forwarding messages from a server to another, in a
symmetric cluster. I just wanted to know at what point exactly would a
client send an ack. Will a client send an ack on receiving it, or only after
it forwards the message to the other servers, and they receive it?

Thanks.



--
Sent from: http://activemq.2283324.n4.nabble.com/ActiveMQ-User-f2341805.html

Re: When is the ACK sent?

Posted by mi...@me.com.INVALID.
This is the exact point of a messaging broker. That you hand control of the message to it decoupling the producers from the consumers. As such you will get an ack on the producer as soon as the broker receives the message and has met the persistence and replication requirements that you configured when creating the broker.




Persistence is configurable at the journal config level by default it will use NIO and requires pesistent messages to flush to disk before ack.




Replication this is very dependant on the ha setup you have. 


If you're using shared storage for ha there is none as the disk where sharing of data between master and slave occurs. If you're using master slave replicated pair, then the master will replicate to slave before ack occurs.




This is in documention so i would heavily suggest reading it before setting up brokers especially before going to production.




Get Outlook for Android







On Tue, Mar 12, 2019 at 10:07 PM +0000, "artemisn00b" <pr...@nokia.com> wrote:










Suppose I have a symmetric cluster of 3 artemis servers. I send a message to
server 1, and it forwards it to other servers who have consumers. Now, when
exactly does the producer get an ACK?

I have a couple of scenarios where I wouldn't be able to figure out how it
works -

A) Server 1 forwarded a message to Server 2 and Server 3, and before
receiving the message, both the servers go down. Would I still receive the
ACK?

B) Server 1 forwarded a message to Server 2 and Server 3, and both receive
the message but before they send an ACK, they go down. Would I still receive
the ACK?

So, TLDR - I want to know when exactly does an Artemis server send an
acknowledgement, given I'm using auto acknowledge. Is it right after server
1 receives the message, or after all servers receive it, or after server 2
and server 3 send an ACK to server 1? Hope I'm clear enough!

Thanks! :)



--
Sent from: http://activemq.2283324.n4.nabble.com/ActiveMQ-User-f2341805.html