Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Looking for the best way to do this...

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CICS
View previous topic :: :: View next topic  
Author Message
rss0213

New User


Joined: 20 Jan 2010
Posts: 26
Location: Alabama

PostPosted: Thu Mar 08, 2012 9:50 am    Post subject: Looking for the best way to do this...
Reply with quote

I have a COBOL CICS program that needs to provide reporting of completed transactions' data to a batch BAI reporting process. The BAI reporting job runs every 15 minutes. I would like to have some opinions about the best way to do this. A couple options I was thinking of are:

1. write the transactions to a message queue
2. write the transactions to a VSAM file (ESDS?)
3. others?

Thanks in advance for the feedback!
Back to top
View user's profile Send private message

dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Thu Mar 08, 2012 12:05 pm    Post subject:
Reply with quote

Sounds good to me
Back to top
View user's profile Send private message
Bill O'Boyle

CICS Moderator


Joined: 14 Jan 2008
Posts: 2502
Location: Atlanta, Georgia, USA

PostPosted: Thu Mar 08, 2012 5:33 pm    Post subject: Reply to: Looking for the best way to do this...
Reply with quote

Do you have a 3rd-Party monitor product at your site, such as TMONCICS or Omegamon?

TMONCICS provides a great deal of information at the transaction level.

Has management defined the necessary information for logging and how finite is their requirement?

From an applications standpoint (even CICS/Assembler), your information access/availability will be limited.

Take a look at the IBM transaction STAT and perhaps, you could use it as an alternative?

Mr. Bill
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 7907
Location: Bellevue, IA

PostPosted: Thu Mar 08, 2012 5:48 pm    Post subject:
Reply with quote

Questions that YOU need to answer to complete a design:
1. Is yourCICS program supposed to report on ALL transactions in the region or just certain ones?
2. If reporting on all transactions, how are you going to capture the source data?
3. What capabilities does the batch interface have?
4. If you write the tranaction data to a file, how are you going to flush the buffers?
5. How do you ensure the CICS program runs at the appropriate time?
6. What happens if the CICS program abends?
7. How much data do you expect to collect each reporting period? each day?
Back to top
View user's profile Send private message
rss0213

New User


Joined: 20 Jan 2010
Posts: 26
Location: Alabama

PostPosted: Thu Mar 08, 2012 7:03 pm    Post subject: Clarification
Reply with quote

Thank you all for the info thus far, but I don't think I was clear what I meant by 'transactions'...

This program receives transactions, which are really LU6.2 messages, over an SNA connection from a server-based application (Distributed Transaction Programming model). The purpose of the program is to serve as a middleware solution between the server application and our bank's DDA (checking/savings) applications.

What I need to do is make the data from completed posting transactions (i.e. customer account debits and credits) available to this batch reporting process.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Thu Mar 08, 2012 7:36 pm    Post subject:
Reply with quote

count the records in the file

how many instances can this 'middleware' program simultaneously be running?
is an instance ATI'd for every transaction coming from the toys
or what?

do you have db2?
mqs?

you have a batch program that will read and report whatever this 'middleware' program writes?

as long as it is one instance per transaction
(transaction goes back to front end, and middleware program dies)
db2 and mqs are the only methods that i know that allow for
realtime, no problem communication of data between cics and batch.

there are still a few questions unanswered,
otherwise we have to continually keep guessing and qualifying our answers.
i am not going to do thatl: provide some more infomation.
how is the middleware module invoked, what is the life cycle, etc...
Back to top
View user's profile Send private message
rss0213

New User


Joined: 20 Jan 2010
Posts: 26
Location: Alabama

PostPosted: Thu Mar 08, 2012 8:10 pm    Post subject:
Reply with quote

Based on my understanding, there could be multiple instances running in the region. We do not have DB2 - only VSAM and MQSeries. Yes, a batch job will run every 15 minutes to report on all completed transactions/messages in the last 15 minutes.

The middleware module is invoked when a message comes across from the server application - that is the nature of DTP. The middleware program reformats the message for the posting call, links to the posting program, receives a response from the posting program, and sends a response back to the server application.

I was thinking of writing the data to be reported to a queue or ESDS VSAM file. The VSAM approach is simpler (to me), but I would need to add a field to the file that could be 'flagged' when the record has been reported so it won't be reported twice. MQ might be the best option, but I don't have as much experience with it, and I have to rely on another group for the MQ setup in different CICS regions. I can control the VSAM in all regions except production.

I just want to know if there are any gotchas to this approach, or if I've missed anything. And just general opinions about one approach vs. the other(s).

Thanks again.
Back to top
View user's profile Send private message
Bill O'Boyle

CICS Moderator


Joined: 14 Jan 2008
Posts: 2502
Location: Atlanta, Georgia, USA

PostPosted: Thu Mar 08, 2012 8:17 pm    Post subject: Reply to: Looking for the best way to do this...
Reply with quote

If you're going to log this information to an ESDS file, you should have an "A" and a "B" file.

You would need to use ENQ/DEQ logic to update (for example) a CWA byte, which would inform the system which ESDS is currently active.

Once a file-switch occurs, let's say from "A" to "B", then the CICS program would issue a CLOSE/DISABLE of the "A" file (required for ESDS), then you could use the CICS "SPOOL" facility (just a suggestion) to build the JCL and submit it from CICS.

Any program in the CICS region, which updates this CWA byte, must also use ENQ/DEQ logic to ensure serial usage.

Just an idea....

Mr. Bill
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Thu Mar 08, 2012 8:21 pm    Post subject:
Reply with quote

Quote:
but I would need to add a field to the file that could be 'flagged' when the record has been reported so it won't be reported twice.


i would not add that requirement to the report-file, especially if you are VSAMing.

if you add a field, put some kind of timestamp/dfhsession id
and maintain a separate file for batch only
to save the last reported timestamp/dfhsession id
(with multiple instances, it is conceivable to have duplicate timestamps
but not a combination of timestamp/cics session id.

i personnally don't like using a vsam in cics and batch simultaneously,
but i have been in db2 for so long, vsam is no longer on my expertise list
although the other contributors to this thread are, and can counsel you.
Back to top
View user's profile Send private message
rss0213

New User


Joined: 20 Jan 2010
Posts: 26
Location: Alabama

PostPosted: Thu Mar 08, 2012 8:54 pm    Post subject:
Reply with quote

Based on the last two responses, I think MQ might be the cleaner solution (even though it is a little more of a headache for me to work with). I can do a get-for-browse and log the message IDs that have been reported throughout the day to a VSAM file and look up message IDs to ensure they haven't been processed. That would eliminate the need for an online VSAM file.

Anyone disagree? If not, I think I have a plan.
Back to top
View user's profile Send private message
Bill O'Boyle

CICS Moderator


Joined: 14 Jan 2008
Posts: 2502
Location: Atlanta, Georgia, USA

PostPosted: Thu Mar 08, 2012 9:08 pm    Post subject: Reply to: Looking for the best way to do this...
Reply with quote

I'm not that MQ savvy.

So, if MQ is your forté, then have at it.... icon_wink.gif

Mr. Bill
Back to top
View user's profile Send private message
Jose Mateo

Active User


Joined: 29 Oct 2010
Posts: 110
Location: Puerto Rico

PostPosted: Sat Mar 10, 2012 2:06 am    Post subject:
Reply with quote

Good afternoon to all!

'That would eliminate the need for an online VSAM file.' I really don't know what you mean with this statement because MQ works with VSAM files.
You could use MQ for what you want to do, put the completed transaction to a request queue which will trigger your online program which inturn process your completed transaction and write a record to a VSAM file for your batch process(you could use Bill suggestion on using two VSAM files so your online process won't be effected). You could also write a record to a reply queue for your DTP. Also look into VSAM Redirector which might also work for what you want to do.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CICS All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:



Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us