IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

CICS program with Delay question


IBM Mainframe Forums -> CICS
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
MSTP

New User


Joined: 21 Jun 2007
Posts: 30
Location: Baltimore

PostPosted: Tue Dec 11, 2018 11:18 pm
Reply with quote

Hello

I have a CICS program and its behaving differently each time. Not sure what is wrong.

1) DECLARE CURSOR WITH HOLD OPTION
2) FETCH 1 ROW write it into an array
3) FETCH Next row and write into an array and then process the prev read record.
4) Determine How many MQ messages (let says 4) to be written into a Queue for prev read record
5) Write the message into the Queue and then issue CICS SYNCPOINT to release the message in the queue and next statement issue CEE3DLY for 20 seconds so that the message in the queue which were released process .
6) STEP 5 is being performed using an INLINE perform until limit of 4 is reached.
7) CLOSE the cursor
8) DELETE the table rows for which the cursor was opened
9) ISSUE CICS SYNCPOINT

The problem is during STEP 5 which it has to perform 4 times it is going back to STEP 1 in middle of the perform. Not sure what is wrong. Please advise. When I perform the same transaction using XPEDITER I get correct results.

thanks
Prasad.
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 2455
Location: Hampshire, UK

PostPosted: Wed Dec 12, 2018 3:21 pm
Reply with quote

No idea as there is no code to analyse.
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 3055
Location: NYC,USA

PostPosted: Wed Dec 12, 2018 8:51 pm
Reply with quote

Prasad,
Quote:
5) Write the message into the Queue and then issue CICS SYNCPOINT to release the message in the queue and next statement issue CEE3DLY for 20 seconds so that the message in the queue which were released process .

1.Why do you need to issue SYNCPOINT for every messages? ain't you be doing this per UOW which in this case is 4 messages?
2.Why do you need to Delay here? Ideally without Delay it should be processed. It is a bad design to delay for 20 seconds for every messages to get processed and especially in online environments. Ain't your MQs suppose to be defined with Trigger Type as F when you are processing messages as bulk than one at a time?
Code:
Trigger type . . . . . . : F  F=First, E=Every, D=Depth, N=None

3. Check your Perform statements make sure THRU has a correct EXIT Name.
4. Do you aware of CICS DELAY? If yes then why don't you use that if at all required?
Back to top
View user's profile Send private message
John Poulakos

Active User


Joined: 13 Jun 2012
Posts: 178
Location: United States

PostPosted: Tue Jun 04, 2019 8:41 pm
Reply with quote

CICS DELAY is not threadsafe and your program uses DB2, which runs with it's own storage protect key. Your potential for a hung transaction is very high.
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 3055
Location: NYC,USA

PostPosted: Tue Jun 04, 2019 9:33 pm
Reply with quote

CICS DELAY is threadsafe when the interval is 0 and by default it is 0.

Moreover TS did not come back to discuss further, so let us save our time replying to this post any further.
Back to top
View user's profile Send private message
John Poulakos

Active User


Joined: 13 Jun 2012
Posts: 178
Location: United States

PostPosted: Tue Jun 04, 2019 10:19 pm
Reply with quote

Sorry, I didn't see the date.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> CICS

 


Similar Topics
Topic Forum Replies
No new posts Using API Gateway from CICS program CICS 0
No new posts Calling an Open C library function in... CICS 1
No new posts How to 'Ping' a CICS region in JCL CICS 2
No new posts Parallelization in CICS to reduce res... CICS 4
No new posts DB2 Event passed to the Application P... DB2 1
Search our Forums:

Back to Top