There are many utilities out there, and the way you are doing it seems
to be the most common way to do it. Others have pointed out some
products that do it. We have been using the MONJOBMSGW utility here for
years. http://www.oocities.org/~alex_nubla/tips.htm The only mod we
made was like you to exclude jobs whose user is QSPLJOB.




Kevin Bucknum
Senior Programmer Analyst
MEDDATA/MEDTRON
Tel: 985-893-2550

-----Original Message-----
From: MIDRANGE-L [mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of
Paul Bailey
Sent: Thursday, September 22, 2016 8:43 AM
To: Midrange Systems Technical Discussion
Subject: Monitoring for MSGW

Hi,

I've been tasked with finding a way to notify relevant people the moment
when *any* job goes into the MSGW status. The notification has to tell
those people which job is in the MSGW status, when it entered that
status and what the MSGID is (I also don't want to spam them with
notifications!).
I am not interested in notifying anyone about jobs in the QSPL
subsystem, but apart from that I want notification for any batch or
interactive job on the local machine requiring a user's response to a
message.

I've put together a small routine that loops forever using the QUSLJOB
API which works (thanks to Eric Pell), but I'd prefer a different
approach because continuously reading the job list over and over just
seems like an awkward way to do what I want. Is there a way to have a
program called (or dtaq/file added to) when any job in the system goes
into the MSGW status?
Trigger, or exit point, etc?

Any tips, ideas, web searches I may have missed?


-Paul.


PS Eric Pell's code, an adjustment to code from "jamief", can be found
here:
http://www.code400.com/forum/forum/tips-techniques-tools-announcements/t
ips-for-the-iseries-as400/1227-use-the-qusljob-api-to-whip-thru-wrkactjo
b?p=51441#post51441
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe,
unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take a
moment to review the archives at http://archive.midrange.com/midrange-l.

Please contact support@xxxxxxxxxxxx for any subscription related
questions.

As an Amazon Associate we earn from qualifying purchases.

This thread ...

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.