Subject: npds Digest V2 #63

From: Listar <nospam_listar_at_ml.free_dot_fr>
Date: Thu, 06 Sep 2001 03:11:10 +0200 (CEST)

------------------------------------
npds Digest	Wed, 05 Sep 2001	Volume: 02  Issue: 063

In This Issue:
		[NPDS] Re: Bugs, they taste good.
		[NPDS] [ANN] NPDS Watcher 009ac

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

Date: Wed, 5 Sep 2001 08:10:57 +0200
From: Paul Guyot <nospam_pguyot_at_kallisys_dot_net>
Subject: [NPDS] Re: Bugs, they taste good.

>I'm crashing every hour or so, and the Watcher does its job on reboot, but
>my Farallon cord's LED nearly always goes out right during the "Engaging the
>Ethernet Driver" dialog. Is there a 'toggle' somewhere in this routine that
>simply changes state instead of checking to see whether there is the right
>condition for proceeding?

No. However, what you describe is a timing problem with your driver, 
and it could easily be fixed by making a little change in the watcher.

But first, what is the state of the check box "Start up NPDS after 5 
seconds" in the watcher's prefs? and what happens if you toggle it?

Paul
-- 
Home page: http://www.kallisys.com/
Newton-powered WebServer: http://newt.dyndns.org:8080/

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

Date: Wed, 5 Sep 2001 12:10:26 +0200
From: Paul Guyot <nospam_pguyot_at_kallisys_dot_net>
Subject: [NPDS] [ANN] NPDS Watcher 009ac

Hi folks,

There is a new version of NPDS Watcher available on the updates websites.
http://npds.free.fr/NPDS%20Watcher/

Changes:
--------

Fixed the bug experienced by Paul Filmer (411, 440 & 441):
	Now, if the endpoint's disposal function fails, we gonna restart.
Fixed the bug experienced by Grant Hutchinson (53):
	Now, if the endpoint's bind fails, we gonna restart.
The checking interval pickers now shows the actual strings instead
	of the number of seconds when the prefs are open.
Fixed the bug experienced by Alex Humffray (4/9/01 7:30, 5/9/01 2:51)
	The state of the button and the status line isn't updated if they're
	not visible (it will be updated when they'll show up).

A couple of notes on this new version & on NPDS Watcher in general:
-------------------------------------------------------------------
I haven't tested this version at all, I just have compiled it and 
installed it 6 minutes ago (at 1146) according to PkgInfo. So beware, 
as usual (but if you don't test it, nobody else will ;).

Paul you mentionned you had a lot of reboots recently. When 
discussing with Alex I discovered that the default checking interface 
(10 secs) isn't too low (for the NS Task Checking).

Let me explain things again.
We have two separated checking tasks in NPDS Watcher. One checks that 
there is no error message from the server indicating that it's no 
longer serving (don't dismiss these error messages) and it's also 
checking that the Newton is still listening on the port it's supposed 
to listen on.
The way this last test is done is simply that the watcher tries to 
listen on the same port. If the system doesn't report that his 
request cannot be fulfilled because someone else is listening on that 
port, the watcher considers that things are ok. This error must be 
reported within 3 checking intervals. If no error is reported, the 
Watcher reboots. This is important because all these operations are 
async, and the server can be stolen the port by the watcher (hence 
having checks done not too frequently is a good idea). If this 
happens, the watcher will of course reboot the Newton, but it is 
responsible for the fact that the server went down.
When a server error dialog pops out or when the watcher detects that 
the Newton is no longer listening on the port it should be listening 
on, the watcher starts the count-down reboot (with the buzzer sound).

The other checks is nearly totally independant from the previous one. 
It's a check that the NewtonScript task is alive. In fact, it's a 
check that the NewtonScript task went idle often enough. If you do 
some lengthy operation with your Newton, the NewtonScript task won't 
go idle and the NS Task Check will think that the NewtonScript task 
crashed. Therefore, it will reboot. Since the count-down reboot 
requires the NewtonScript task to be alive, here we have a silent 
reboot. The NewtonScript task should go idle at least once per 4 * 
the checking interval in average.

Therefore, if you're experiencing too many silent reboots especially 
when you were doing something (Alex was retrieving usenet messages), 
increase the checking interval. You can also simply disable the NS 
Task Check. Please note that I didn't implement this only for the 
technologiedemonstration but also because I got some NS Task crashes 
which of course locked the server.

The known bugs left:
--------------------

As you all know, there is a big problem with NPDS not being thread 
safe and the hack I wrote to support multiple connections. That's 
actually why the NPDS watcher is there :-/

I consider Paul Filmer's 428 bug report to be caused by this (among 
other things).

I'm going to work on Grant's 44/45 & 63/64, although it might be a 
problem with his prefs. And I'll see if 46 & 65 aren't linked with 
that. But first, I have a bug to fix in ATA Support (among others) 
which made that my Newton stopped serving web pages at 0327 because 
the linear cards wasn't recognized as such.

Paul
-- 
Home page: http://www.kallisys.com/
Newton-powered WebServer: http://newt.dyndns.org:8080/

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

End of npds Digest V2 #63
*************************