How much CSA is involved?  Why is fragmentation of CSA an issue?  Little pieces 
of CSA are constantly being acquired and freed, just as happens with SQA.

There are many easy ways to serialize the entry and exiting of an ENF exit or 
any other kind of hook so that you can know when it is safe to free up the CSA 
it uses and remove the code.  One way I have used in the past is to increment 
an exit-in-use counter with CS logic upon entry and decrement it with similar 
CS logic upon exit.  If the counter is zero, you can free up the CSA control 
block.  Of course, you must first ensure that the routine is never entered 
again before you start the removal process.

Bill Fairchild
Programmer
Rocket Software
408 Chamberlain Park Lane * Franklin, TN 37069-2526 * USA
t: +1.617.614.4503 *  e: bfairch...@rocketsoftware.com * w: 
www.rocketsoftware.com

-----Original Message-----
From: IBM Mainframe Discussion List [mailto:IBM-MAIN@bama.ua.edu] On Behalf Of 
Phil Smith
Sent: Thursday, June 07, 2012 4:20 PM
To: IBM-MAIN@bama.ua.edu
Subject: ENF Listener usage

We have a long-running Started Task that controls the use of an ENF listener 
for SMF interval record collection with an operator command.  The ENF listener 
requires use of CSA storage.

When the Started Task receives an operator command to start SMF interval 
processing it allocates CSA storage, registers the ENF listener, and WAITs for 
interval expiration.

The question is: what should it do when the operator command says to stop SMF 
interval processing?

The options seem to be:


1)      Deregister the ENF listener and free the CSA storage, meaning an
operator can switch SMF interval processing on and off, causing CSA storage to 
be allocated and deallocated, possibly fragmenting CSA storage.  But when we 
aren't collecting SMF interval data, we won't have an ENF listener registered.


2)      Leave the ENF listener registered, but stop writing records when the
interval expires. Don't stop the ENF listener and free CSA until the Started 
Task terminates (or possibly a special operator command like /f stcname,SMF 
STOP).  This approach is easier on CSA allocations for the case where the 
operator is switching SMF interval collection on and off.  But it leaves an ENF 
listener registered when one is not needed.

Which approach have you seen? Which is "better" (and why)?

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions, send email to 
lists...@bama.ua.edu with the message: INFO IBM-MAIN

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@bama.ua.edu with the message: INFO IBM-MAIN

Reply via email to