Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.java.programmer > #12634
| From | Knute Johnson <nospam@knutejohnson.com> |
|---|---|
| Newsgroups | comp.lang.java.programmer |
| Subject | Re: Strange Socket problem |
| Date | 2012-03-03 17:48 -0800 |
| Organization | A noiseless patient Spider |
| Message-ID | <jiuhm2$iin$1@dont-email.me> (permalink) |
| References | (1 earlier) <5j4529-ln2.ln1@s.simpson148.btinternet.com> <jiopp1$arb$1@dont-email.me> <9ab529-1r3.ln1@s.simpson148.btinternet.com> <jip4ek$avf$1@dont-email.me> <5m3929-6b4.ln1@s.simpson148.btinternet.com> |
On 3/3/2012 1:08 AM, Steven Simpson wrote:
> On 02/03/12 00:32, Knute Johnson wrote:
>> On 3/1/2012 2:54 PM, Steven Simpson wrote:
>>> I'm thinking that maybe a listener is throwing an unchecked exception.
>>>
>>
>> It cycles fine until it hangs.
>
>
> I'm trying to understand what 'fine' is, and how much of the failing
> cycle appears fine before it fails. The previous 'fine' cycle must end
> with a "Disconnected" message. The failing cycle might get as far as
> printing "Connected", before jumping to the "Disconnected" message.
>
> It's just that when you say "it just prints 'Disconnected'", you're
> obviously truncating the entire trace to something manageable, but I
> can't distinguish these cases:
>
> * You're just showing the last message.
> * You're showing all messages in the final cycle, and they happen to
> include only one message.
>
> These would be distinguishable by truncating just before the last
> message of the previous cycle. The first case would then be indicated by:
>
> Disconnected
> Disconnected
>
> ...and the second case by:
>
> Disconnected
> Connected
> Disconnected
>
> I suppose you mean that it's the first case by this:
>
> ********* I know that the line below is not being executed **********
>
> fireConnectionEvent(ConnectionEvent.CONNECTED);
> socket.setSoTimeout(3600000); // one hour timeout
> System.out.println("SportsWinClient: Connected");
>
> ...but I'm not clear on how you know this.
>
> Perhaps you have a listener for the ConnectionEvent, and you can see
> that it doesn't execute. But that could also mean that it or an earlier
> listener in the chain has thrown an unchecked exception.
> fireConnectionEvent doesn't protect itself against this.
>
>
Yes I do have a listener and it doesn't hear. Once it has stopped the
listening component says it is not connected. The connect/disconnect
messages are in the appropriate order and the last message received is a
Disconnect message.
--
Knute Johnson
Back to comp.lang.java.programmer | Previous | Next — Previous in thread | Next in thread | Find similar
Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-01 11:49 -0800
Re: Strange Socket problem Steven Simpson <ss@domain.invalid> - 2012-03-01 20:59 +0000
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-01 13:30 -0800
Re: Strange Socket problem Steven Simpson <ss@domain.invalid> - 2012-03-01 22:54 +0000
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-01 16:32 -0800
Re: Strange Socket problem Steven Simpson <ss@domain.invalid> - 2012-03-03 09:08 +0000
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-03 17:48 -0800
Re: Strange Socket problem markspace <-@.> - 2012-03-01 14:08 -0800
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-01 16:48 -0800
Re: Strange Socket problem markspace <-@.> - 2012-03-02 08:33 -0800
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-02 15:29 -0800
Re: Strange Socket problem markspace <-@.> - 2012-03-03 09:33 -0800
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-03 17:55 -0800
Re: Strange Socket problem markspace <-@.> - 2012-03-03 20:06 -0800
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-03 21:02 -0800
Re: Strange Socket problem "John B. Matthews" <nospam@nospam.invalid> - 2012-03-05 00:00 -0500
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-05 09:44 -0800
Re: Strange Socket problem Martin Gregorie <martin@address-in-sig.invalid> - 2012-03-01 22:15 +0000
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-01 16:43 -0800
Re: Strange Socket problem Martin Gregorie <martin@address-in-sig.invalid> - 2012-03-03 02:01 +0000
Reiteration: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-01 16:51 -0800
Re: Reiteration: Strange Socket problem Martin Gregorie <martin@address-in-sig.invalid> - 2012-03-03 02:02 +0000
Re: Strange Socket problem x <x@x.x> - 2012-03-02 21:18 +0100
Re: Strange Socket problem Lew <noone@lewscanon.com> - 2012-03-02 15:06 -0800
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-02 15:38 -0800
Re: Strange Socket problem Lew <noone@lewscanon.com> - 2012-03-02 16:00 -0800
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-02 17:18 -0800
Re: Strange Socket problem Martin Gregorie <martin@address-in-sig.invalid> - 2012-03-03 02:13 +0000
Re: Strange Socket problem Steven Simpson <ss@domain.invalid> - 2012-03-03 08:41 +0000
Re: Strange Socket problem Martin Gregorie <martin@address-in-sig.invalid> - 2012-03-03 18:26 +0000
Re: Strange Socket problem x <x@x.x> - 2012-03-03 11:32 +0100
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-03 17:59 -0800
Re: Strange Socket problem Lew <noone@lewscanon.com> - 2012-03-03 23:21 -0800
Re: Strange Socket problem x <x@x.x> - 2012-03-03 10:59 +0100
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-03 18:08 -0800
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-02 15:33 -0800
Re: Strange Socket problem Paka Small <paka-en@tumia.org> - 2012-03-03 03:32 -0800
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-03 18:00 -0800
Re: Strange Socket problem x <x@x.x> - 2012-03-03 12:45 +0100
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-03 18:02 -0800
csiph-web