Re: Looking for advice: How to detect a job is actually doing work

Charles Wilt <[email protected]>
Newsgroups gmane.comp.lang.as400.java
Message-ID <CAJ=Tnc6gmG0W1pqkrLia3mDJowLr0LKtszrHnuw=uBJn4iCKZw@mail.gmail.com>
On Thu, Aug 5, 2021 at 8:27 AM David Gibbs via JAVA400-L <
[email protected]> wrote:

> Folks:
>
> I'm looking for advice on the best way to detect if a job is actually
> doing work.
>
> If the current call stack is different from the previous call stack, I'm
> taking that as a hint that the job is doing work.
>
> Are there any other job attributes, or techniques, you can think of that
> would be useful in identifying a hung vs. active job?
>
>
How often do you see a "hung" job?  I don't think I've seen one in the
25yrs I've been on the platform..

I have however seen lots of jobs stuck in a poorly written loop.  Checking
the call stack isn't usually enough to determine if that's what's actually
happening as it does usually change...but we do have a lot of ILE
procedures.  With OPM, I suppose only the statement # is prone to change.

Our monitoring looks for "high" (> 5% or so) CPU use over an
extended period of 60min or so I think.

But even then, it usually is up to the on-call person to debug the job and
see if it's looping or working as designed.

Charles
-- 
This is the Java Programming on and around the IBM i (JAVA400-L) mailing list
To post a message email: [email protected]
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/java400-l
or email: JAVA400-L-request-+hD5IHI5Xscn3HwCXmMcX9BPR1lH4CV8@public.gmane.org
Before posting, please take a moment to review the archives
at https://archive.midrange.com/java400-l.

Help support midrange.com by shopping at amazon.com with our affiliate
link: https://amazon.midrange.com
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.