Re: smpp reconnect bugfix

Vibhu Mohindra <[email protected]>
Newsgroups gmane.comp.mobile.kannel.devel
Message-ID <[email protected]>
On Sun, Sep 29, 2002 at 10:49:15AM +0300, Oded Arbel wrote:
> Against which version of Kannel this patch was generated ?
> Please - before fixing a but, check the CVS to see if it wasn't fixed
> already, and it it hasn't - generate your patch against latest CVS.

I checked the latest CVS version and it hasn't been fixed. I didn't
bother to regenerate the patch against this version because when I tested
patching the CVS version, my version of patch was smart enough to do it
correctly. Thanks for the feedback. Next time I'll take the trouble to
re-generate a patch against the CVS version.

> Also - I don't think that this patch is correct - it will only make the
> receiver thread not being able to change the status of the connection if
> a transmitter exist. maybe a better approach would be to have two status
> variables ?

I don't understand. Do you mean that in certain situations we may not have
a transmitter thread at all? If so, then note that the status will never
become SMSCCONN_ACTIVE - it can only rise up to SMSCCONN_ACTIVE_RECV. This
is not right, I'm sure.

Right now, the transmitter thread updates the status to SMSCCONN_ACTIVE
upon a bind_response. The receiver thread updates the status only to
SMSCCONN_ACTIVE_RECV upon a bind_response. However if either socket
snaps, the status drops to SMSCCONN_RECONNECTING. If the status is not
SMSCCONN_ACTIVE, outgoing messages are queued, not sent. Each thread
sets the status without knowing of the existence of the other thread.

The earlier objection was regarding the status administrative info
generated by Kannel. I agree with that - if the receiver doesn't indicate
that it is down, the status page will not show any problems. If you could
help me to understand how else this patch could fail, I'd appreciate it.

Thanks,

Vibhu
signature.asc (application/pgp-signature, 232 B)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE9lsR6vgqsqbNQjqcRArfrAJ9/J3YaDpJFBl/X5gL/xumIn+Kx1QCggJkf
qguK0NsYCLWEPnVbcAHQdDo=
=9awd
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.