SmppClient.DisconnectAsync lasts long time

Post Reply
vikarius
Posts: 4
Joined: Mon Jul 12, 2021 4:03 pm

SmppClient.DisconnectAsync lasts long time

Post by vikarius » Mon Jul 12, 2021 4:14 pm

SmppClient.DisconnectAsync lasts about 60 seconds. SmppClient.Disconnect lasts the same time as well. We works with Smsc.ru. ConnectAsync and BindAsync work succesfully and last about 1 second.
alt
Site Admin
Posts: 985
Joined: Tue Apr 25, 2006 9:45 am

Re: SmppClient.DisconnectAsync lasts long time

Post by alt » Tue Jul 13, 2021 10:32 am

Hi vikarius,

Which library version are you using now?
Is library logging enabled in your application?
alt
Site Admin
Posts: 985
Joined: Tue Apr 25, 2006 9:45 am

Re: SmppClient.DisconnectAsync lasts long time

Post by alt » Tue Jul 13, 2021 10:53 am

some possible reasons of such behavior:
- smpp client waits until all received PDUs are processed.
- evDisconnected event handler method in the application does some processing
vikarius
Posts: 4
Joined: Mon Jul 12, 2021 4:03 pm

Re: SmppClient.DisconnectAsync lasts long time

Post by vikarius » Tue Jul 13, 2021 1:16 pm

We use 2.9.9 version. How can I switch on and use logging functionality?
We don't subscribe on evDisconnected.
We use only connectasync, bindasync and sendasync and evDeliverSm handler.
alt
Site Admin
Posts: 985
Joined: Tue Apr 25, 2006 9:45 am

Re: SmppClient.DisconnectAsync lasts long time

Post by alt » Tue Jul 13, 2021 1:29 pm

vikarius wrote:
Tue Jul 13, 2021 1:16 pm
How can I switch on and use logging functionality?
https://docs.inetlab.com/smpp/v2.9/arti ... gging.html

Samples with some popular logging frameworks https://gitlab.com/inetlab/smpp-samples/
vikarius wrote:
Tue Jul 13, 2021 1:16 pm
We use 2.9.9 version.
Please update to latest version 2.9.12
vikarius
Posts: 4
Joined: Mon Jul 12, 2021 4:03 pm

Re: SmppClient.DisconnectAsync lasts long time

Post by vikarius » Tue Jul 13, 2021 3:51 pm

Code: Select all

13.07.2021 18:40:41:DEBUG:  1: Connecting to InterNetwork/smpp.smsc.ru:3700
13.07.2021 18:40:41:INFO : 12: 192.168.100.3:60094 => InterNetwork/smpp.smsc.ru:3700 Connection established.
13.07.2021 18:40:41:DEBUG:  5: Send PDU: BindTransceiver, Sequence: 1
13.07.2021 18:40:41:DEBUG:  5: PDU Received: BindTransceiverResp, Status: ESME_ROK, Sequence: 1, SystemId: SMSC
13.07.2021 18:40:41:DEBUG:  1: Connecting to InterNetwork/smpp2.smsc.ru:3700
13.07.2021 18:40:42:INFO :  3: 192.168.100.3:60095 => InterNetwork/smpp2.smsc.ru:3700 Connection established.
13.07.2021 18:40:42:DEBUG:  5: Send PDU: BindTransceiver, Sequence: 1
13.07.2021 18:40:42:DEBUG:  6: PDU Received: BindTransceiverResp, Status: ESME_ROK, Sequence: 1, SystemId: SMSC
13.07.2021 18:40:42:DEBUG:  1: Connecting to InterNetwork/smpp.smsc.ru:3700
13.07.2021 18:40:42:INFO : 12: 192.168.100.3:60096 => InterNetwork/smpp.smsc.ru:3700 Connection established.
13.07.2021 18:40:42:DEBUG:  5: Send PDU: BindTransceiver, Sequence: 1
13.07.2021 18:40:42:DEBUG:  7: PDU Received: BindTransceiverResp, Status: ESME_ROK, Sequence: 1, SystemId: SMSC
13.07.2021 18:40:42:DEBUG:  1: Connecting to InterNetwork/smpp2.smsc.ru:3700
13.07.2021 18:40:42:INFO :  3: 192.168.100.3:60097 => InterNetwork/smpp2.smsc.ru:3700 Connection established.
13.07.2021 18:40:42:DEBUG:  5: Send PDU: BindTransceiver, Sequence: 1
13.07.2021 18:40:42:DEBUG:  5: PDU Received: BindTransceiverResp, Status: ESME_ROK, Sequence: 1, SystemId: SMSC
13.07.2021 18:40:51:DEBUG:  7: Send PDU: SubmitSm, Status: ESME_ROK, Sequence: 2, SourceAddr: E100, DestAddr: +375295235630
13.07.2021 18:40:51:DEBUG:  5: PDU Received: SubmitSmResp, Status: ESME_ROK, Sequence: 2, MessageId: 709621368
13.07.2021 18:40:53:DEBUG: 15: PDU Received: DeliverSm, Status: ESME_ROK, Sequence: 326566248, SourceAddr: 375295235630, DestAddr: SMSC.RU
13.07.2021 18:40:54:DEBUG:  5: Send PDU: DeliverSmResp, Status: ESME_ROK, Sequence: 326566248
13.07.2021 18:40:54:DEBUG:  7: Send PDU: SubmitSm, Status: ESME_ROK, Sequence: 2, SourceAddr: E100, DestAddr: +375295235630
13.07.2021 18:40:54:DEBUG: 20: PDU Received: SubmitSmResp, Status: ESME_ROK, Sequence: 2, MessageId: 709621452
13.07.2021 18:40:54:DEBUG: 24: PDU Received: DeliverSm, Status: ESME_ROK, Sequence: 326566265, SourceAddr: 375295235630, DestAddr: E100
[b]13.07.2021 18:40:55:DEBUG:  7: Send PDU: DeliverSmResp, Status: ESME_ROK, Sequence: 326566265
13.07.2021 18:43:00:INFO : 49: 192.168.100.3:60095 => InterNetwork/smpp2.smsc.ru:3700 disconnected.[/b]
13.07.2021 18:43:00:INFO : 14: 192.168.100.3:60097 => InterNetwork/smpp2.smsc.ru:3700 disconnected.
13.07.2021 18:43:00:DEBUG: 59: Starting connection recovery.
13.07.2021 18:43:00:DEBUG: 59: Connecting to InterNetwork/smpp2.smsc.ru:3700
13.07.2021 18:43:00:DEBUG: 60: Starting connection recovery.
13.07.2021 18:43:00:DEBUG: 60: Connecting to InterNetwork/smpp2.smsc.ru:3700
13.07.2021 18:43:00:INFO : 50: 192.168.100.3:52473 => InterNetwork/smpp2.smsc.ru:3700 Connection established.
13.07.2021 18:43:00:INFO : 58: 192.168.100.3:52474 => InterNetwork/smpp2.smsc.ru:3700 Connection established.
13.07.2021 18:43:00:DEBUG: 51: Send PDU: BindTransceiver, Sequence: 2
13.07.2021 18:43:00:DEBUG: 52: Send PDU: BindTransceiver, Sequence: 2
13.07.2021 18:43:00:DEBUG: 52: PDU Received: BindTransceiverResp, Status: ESME_ROK, Sequence: 2, SystemId: SMSC
13.07.2021 18:43:00:DEBUG: 51: Recovery succeeded. Status Bound
13.07.2021 18:43:00:DEBUG: 56: PDU Received: BindTransceiverResp, Status: ESME_ROK, Sequence: 2, SystemId: SMSC
13.07.2021 18:43:00:DEBUG: 52: Recovery succeeded. Status Bound
13.07.2021 18:43:10:INFO : 14: 192.168.100.3:60096 => InterNetwork/smpp.smsc.ru:3700 disconnected.
13.07.2021 18:43:10:INFO : 50: 192.168.100.3:60094 => InterNetwork/smpp.smsc.ru:3700 disconnected.
13.07.2021 18:43:10:DEBUG: 67: Starting connection recovery.
13.07.2021 18:43:10:DEBUG: 67: Connecting to InterNetwork/smpp.smsc.ru:3700
13.07.2021 18:43:10:INFO : 58: 192.168.100.3:52604 => InterNetwork/smpp.smsc.ru:3700 Connection established.
13.07.2021 18:43:10:DEBUG: 51: Send PDU: BindTransceiver, Sequence: 3
13.07.2021 18:43:10:DEBUG: 51: PDU Received: BindTransceiverResp, Status: ESME_ROK, Sequence: 3, SystemId: SMSC
13.07.2021 18:43:10:DEBUG: 52: Recovery succeeded. Status Bound
Two minutes delay
vikarius
Posts: 4
Joined: Mon Jul 12, 2021 4:03 pm

Re: SmppClient.DisconnectAsync lasts long time

Post by vikarius » Tue Jul 13, 2021 3:55 pm

Aftrer updating to 2.9.12 the issue is gone. Thank you.
Post Reply