1 2 Previous Next 15 Replies Latest reply on Nov 22, 2012 4:13 AM by venkatesh grandhi

    Failover Performance

    venkatesh grandhi Newbie

      Hi everyone...I'm a newbie to Hornetq...anywaz i'm trying to implement failover concept given from the examples of Hornetq.I considered live and backup servers to be two diffferent system and these two servers are using a shared store which is in another different system.The configuration in the examples worked very well but i am unable sort out with two problems.

       

      The first one is the performance of message transfer between Publisher and Subscriber which is about 30 msgs/sec but the example in the Horentq(jms/transaction-failover) was able to deliver like 14500msgs/sec .The performance was far low from expected .The only difference in my code is the parameters of the session(Session session = connection.createSession(true, 0)) which caused the change.I changed the parameters to (Session session = connection.createSession(false, Session.Acknowledge) ).I changed this because the subscriber is unable to receive the messages who is on a different IP.

       

      The second one is the failover concept,the client was unable to connect to backup server even though it was announced successfully i.e, it session was not updated with the new server(backup server)

       

       

      System Configurations

      -----------------------------------

      OS:Window7

      Processor-Intel(R) Core(TM) i3-2100  CPU@3.10GHz

      Ram -4GB

        • 1. Re: Failover Performance
          Clebert Suconic Master

          what version are you using?

          What mode are you using on failover? (replication / shared storage)

          what transaction mode are you using on producing?

          • 2. Re: Failover Performance
            Yong Hao Gao Master

            In your live configuration you seems not set <shared-store> to true.

             

            Using auto ack mode is not efficient because each message will cause a round-trip ack signal between client-server. Transactional is better because messages are acked in batches.

             

            I don't understand why the changing of session creation can solve your subscriber problem, can you explain more?

             

            Also what type of shared storage you are using? is it samba on windows?

             

            Howard

            • 3. Re: Failover Performance
              venkatesh grandhi Newbie

              Clebert Suconic wrote:

               

              what version are you using?

              What mode are you using on failover? (replication / shared storage)

              what transaction mode are you using on producing?

               

               

              Thank's for your quick reply Clebert..

               

              1.Version-2.2.14

              2.Shared store

              3.Transaction mode in the sense??

              • 4. Re: Failover Performance
                Clebert Suconic Master

                How you are sending messages.... how you are committing on each send.

                 

                 

                Each send will perform a round trip.

                 

                 

                The server will share the hardware resources and many producers should scale up the disk and network capacity.

                • 5. Re: Failover Performance
                  Clebert Suconic Master

                  Regarding the backup... look at the failover examples..

                   

                   

                  Since you're using Windows... I'm not sure the shared storage works on Windows. I don't think NTFS will work on the shared storage.

                  • 6. Re: Failover Performance
                    venkatesh grandhi Newbie

                    In your live configuration you seems not set <shared-store> to true.

                     

                    Using auto ack mode is not efficient because each message will cause a round-trip ack signal between client-server. Transactional is better because messages are acked in batches.

                     

                    I don't understand why the changing of session creation can solve your subscriber problem, can you explain more?

                     

                    Also what type of shared storage you are using? is it samba on windows?

                     

                    Howard

                     

                     

                    Thank's for your repsonse Yong and yes i have just commented it..anywaz the performance is the same...and i am using windows OS....and regarding the session issue ,the producer must seamless connect to the backup server to send messaged which is not happening...

                    • 7. Re: Failover Performance
                      venkatesh grandhi Newbie

                      How you are sending messages.... how you are committing on each send.

                       

                       

                      Each send will perform a round trip.

                       

                       

                      The server will share the hardware resources and many producers should scale up the disk and network capacity.

                      I wanted to use  transactiional mode but the subscriber is unable to receive messages from the publisher that is the reason why im using non-transactional mode the subscriber is able to receice mesaages and i'm committing the session once the publisher has send the messages.So let me know the changes in the code to the improve performance.I used this to send in batches as send in the user manual and correct me if am wrong.

                      Session session = connection.createSession(false,Session.DUPS_OK_ACKNOWLEDGE);

                      • 8. Re: Failover Performance
                        Yong Hao Gao Master

                        Re: regarding the session issue ,the producer must seamless connect to the backup server to send messaged which is not happening...

                         

                        Are you saying that after change the session to be non-transactional this issue is solved? It couldn't be so imo.

                        • 9. Re: Failover Performance
                          venkatesh grandhi Newbie

                          Regarding the backup... look at the failover examples..

                           

                           

                          Since you're using Windows... I'm not sure the shared storage works on Windows. I don't think NTFS will work on the shared storage.

                          Yes the backup is able to annouce successfully and also when I run the example(transaction failover example in Hornetq ) with the configurations I have its giving good results like 14k msgs/sec.The only change I can see is the session.(Session session = connection.createSession(false,Session.DUPS_OK_ACKNOWLEDGE);) from my code.

                          • 10. Re: Failover Performance
                            venkatesh grandhi Newbie

                            Yong Hao Gao wrote:

                             

                            Re: regarding the session issue ,the producer must seamless connect to the backup server to send messaged which is not happening...

                             

                            Are you saying that after change the session to be non-transactional this issue is solved? It couldn't be so imo.

                            when i'm using transactional failover(  Session session = connection.createSession(true, 0))...the subscriber who is in listening mode was unable to receive any messages from publisher that is the reason I changed the configuration to non-transactional so please tell me what might be the reason for this.

                            • 11. Re: Failover Performance
                              Andy Taylor Master

                              .The only difference in my code is the parameters of the session(Session session = connection.createSession(true, 0)) which caused the change.I changed the parameters to (Session session = connection.createSession(false, Session.Acknowledge) )

                              It seems obvious to me that if you change the client then this will effect performance.

                               

                              Also changing the PI will have an effect, if you use an external IP (i.e. not localhost like the example) then network traffic will take longer.

                               

                              Oh, and didnt you already raise this in a previous post?

                              • 12. Re: Failover Performance
                                venkatesh grandhi Newbie

                                Andy Taylor wrote:

                                 

                                .The only difference in my code is the parameters of the session(Session session = connection.createSession(true, 0)) which caused the change.I changed the parameters to (Session session = connection.createSession(false, Session.Acknowledge) )

                                It seems obvious to me that if you change the client then this will effect performance.

                                 

                                Also changing the PI will have an effect, if you use an external IP (i.e. not localhost like the example) then network traffic will take longer.

                                 

                                Oh, and didnt you already raise this in a previous post?

                                Hi Andy,as you said to raise it as a discussion, so i did..anywaz you mean to say when publisher and subscribers are in two diffferent IP,then it will have an effect in performance.

                                • 13. Re: Failover Performance
                                  Andy Taylor Master

                                  Yes, the example just uses localhost so no traffic actually goes on the network, localhost just uses memory to copy buffers so obviously will be much faster

                                  • 14. Re: Failover Performance
                                    Yong Hao Gao Master

                                    This seems makes no sense to me. Perhaps you forget to commit after message is received?

                                     

                                    venkatesh grandhi wrote:

                                     

                                    Yong Hao Gao wrote:

                                     

                                    Re: regarding the session issue ,the producer must seamless connect to the backup server to send messaged which is not happening...

                                     

                                    Are you saying that after change the session to be non-transactional this issue is solved? It couldn't be so imo.

                                    when i'm using transactional failover(  Session session = connection.createSession(true, 0))...the subscriber who is in listening mode was unable to receive any messages from publisher that is the reason I changed the configuration to non-transactional so please tell me what might be the reason for this.

                                    1 2 Previous Next