resubmit message part on throttling

.NET library for SMPP protocol
Locked
mobilyws
Posts: 14
Joined: Sat Jan 14, 2012 1:25 pm

resubmit message part on throttling

Post by mobilyws » Wed Jul 15, 2015 1:02 pm

hi alt

some time i got throttling error on a message part

is there is any way to resubmit this message part when i got throttling?

regards
murtz
Posts: 15
Joined: Thu May 14, 2015 11:04 am

Re: resubmit message part on throttling

Post by murtz » Wed Oct 26, 2016 10:51 am

Hi mobilyws,

Did you find a way to resubmit failed part in case of throttling or any other error?

please share your workaround

thanks
alt
Site Admin
Posts: 985
Joined: Tue Apr 25, 2006 9:45 am

Re: resubmit message part on throttling

Post by alt » Sat Oct 29, 2016 9:04 pm

One possible way how to handle THROTTLED status

Code: Select all


        _client.evSubmitComplete += (sender, response) =>
                                            {
                                                if (response.Status == CommandStatus.ESME_RTHROTTLED)
                                                {
                                                    //allow library to assign next sequence number by submitting.
                                                    response.Request.Sequence = 0;

                                                    //make a delay
                                                    Thread.Sleep(1000);

                                                    // or try to change speed limit
                                                    _client.SendSpeedLimit = 2f / 60f;

                                                    //Resubmit PDU
                                                  _client.SubmitAsync(response.Request);   
                                                }
                                                
                                                
                                            };
Locked