|
>We are going to have the situation of an OPM program >calling a series of ILE programs. The ILE programs >are compiled with an activation group of *caller, and >all is well. The only problem we have is that there are >files opened in service programs that are not be closed >when the OPM program is exited. > >We've come up with three options of handling this: > >1. Have the OPM program execute a shut down routine >that would close all files that have been opened. The >problem with this is, how do you know what files have >been opened, unless you know all of the details of each >file that was opened when a service program was called. Hi Jade! You can use global variables within your service program to store status about what files are open. Alternatively, use the %open BIF. Set the variable at open time, and test it or the BIF at cleanup time. >2. Use a named activation group when calling the ILE >programs, and have the OPM program reclaim the >activation group at the end of the process. That's easy enough as long as everybody understands that the files are open until EOJ. >3. Leave the files open. What issues are we >going to have to deal with if we do this? It's basically the same as #2, except that the files will be open a little while longer (until the caller goes to LR.) --buck
As an Amazon Associate we earn from qualifying purchases.
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.