× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



On Tue, Sep 9, 2008 at 4:12 PM, Scott Klement <rpg400-l@xxxxxxxxxxxxxxxx> wrote:
I'm thinking you could put the the signal stuff, including the
procedure that handles the SIGARLM, in a service program that runs in
a named AG.

Have a third *NOPASS parm defined on the trigger program, have the
SIGALRM handling procedure call the trigger program passing the third
parm. which lets the trigger program know to close the files if they
are still open.

That would solve the activation group issue, though you'd need some way
for the srvpgm to communicate to the trigger that it has to close it's
files. (A Callback procedure would work).

I don't understand your *NOPASS idea -- the service prgoram can't call
the trigger program, since the service program is invoked by the
trigger, isn't it?

Why couldn't it? A trigger program is a *PGM object, you can call
programs from service programs. By the time the signal handler ran,
the trigger program should be off the call stack, so recursion
wouldn't be an issue.

But as I think about it, a callback procedure would probably work
better anyway.


But, I still don't know what would happen if another program int he job
called alarm() or changed the signal handler for SIGALRM.
Me neither.

I agree with what you said earlier about changing the process so it
doesn't matter if the trigger files are open.


Charles

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.