|  | 
 
  
    | RSS Feed - WebSphere MQ Support | RSS Feed - Message Broker Support |  
 
  
	|    |  |  
  
	| Oracle autononomous commits in called stored proc | « View previous topic :: View next topic » |  
  	| 
		
		
		  | Author | Message |  
		  | Rookwood | 
			  
				|  Posted: Wed Dec 13, 2006 10:27 am    Post subject: Oracle autononomous commits in called stored proc |   |  |  
		  | Novice
 
 
 Joined: 26 Aug 2004Posts: 13
 
 
 | 
			  
				| Hi all, 
 have several strange issues with our MB v5.0 (csd 7) and Oracle 9.2i installation on Solaris.  No XA coordination involved.
 
 Problem A.
 1. Message flow calls Oracle stored proc.
 2. Error occurs in stored proc which is caught in pl/sql code and internal pl/sql error handling process writes error info to an Oracle table and runs commit statement. (autonomous commit)
 3. Pl/sql error handling then throws exception so broker is notified of a problem and broker throws error and performs rollback of input message.
 
 Expected result of the above is that message is backed out and error data is found in the Oracle table.
 Actual result, 99 times out of 100 the actual = expected. 1 time out 100 the data does not appear in the error table until the message flow has been killed.
 
 Problem B
 1. Message flow calls Oracle pl/sql procedure.
 2. said procedure 'seeds' and table with data, calls commit statement (autononomous commit)
 3.  pl/sql proc then calls java procedure to utlise seeded table data for further processing.
 4. java proc reports that it cannot find said seeded data in the table, i.e it appears that the commit did actually take place.
 
 Heres the nub of the problem: If the Oracle developer calls his stored proc from TOAD using the same userid as the broker uses, passing the same parameters the broker passes, then the java proc is able to see the seeded data; i.e. the commit seems to have been achieved. Java process completes and returns control to the pl/sql proc which completes ok.
 
 In both instances it almost seems that the broker is 'hijacking' the Oracle commit and preventing it from being processed by the database.
 
 Has anyone seen anything similar or are we making naive assumptions about what we'd expect to see happening.
 [/list]
 _________________
 GS
 |  |  
		  | Back to top |  |  
		  |  |  
		  | jefflowrey | 
			  
				|  Posted: Wed Dec 13, 2006 11:22 am    Post subject: |   |  |  
		  | Grand Poobah
 
 
 Joined: 16 Oct 2002Posts: 19981
 
 
 | 
			  
				| Is the Input message persistent that one time out of 100? _________________
 I am *not* the model of the modern major general.
 |  |  
		  | Back to top |  |  
		  |  |  
		  | Rookwood | 
			  
				|  Posted: Thu Dec 14, 2006 4:55 am    Post subject: |   |  |  
		  | Novice
 
 
 Joined: 26 Aug 2004Posts: 13
 
 
 | 
			  
				| As far as I'm aware all our messages are persistent and we utilise a common subflow as input to all our flows which as the input node configured with Transaction Mode = 'Yes'. 
 Could well be a problem with the way the Oracle stuff is written which is out of our hands but just interested in any feedback so we can push back at oracle team.
 _________________
 GS
 |  |  
		  | Back to top |  |  
		  |  |  
		  | JosephGramig | 
			  
				|  Posted: Thu Dec 14, 2006 5:20 am    Post subject: |   |  |  
		  |  Grand Master
 
 
 Joined: 09 Feb 2006Posts: 1244
 Location: Gold Coast of Florida, USA
 
 | 
			  
				| Interesting. Not that this is directly related, but... 
 Somebody was doing a PASSTHRU with the following select:
 
 SELECT TO_CHAR(KEYFIELD.NEXTVAL, '99999999') FROM SOMETABLE
 
 To get the next unique key and make it a right justified left space filled eight character field.
 
 Well, it didn't work all the time and indeed it seemed to fail most of the time. I took out the TO_CHAR function and used the OVERLAY WMB function to achieve the same result.
 
 Just another failure of Oracle.
 _________________
 Joseph
 Administrator - IBM WebSphere MQ (WMQ) V6.0, IBM WebSphere Message Broker (WMB) V6.1 & V6.0
 Solution Designer - WMQ V6.0
 Solution Developer - WMB V6.1 & V6.0, WMQ V5.3
 |  |  
		  | Back to top |  |  
		  |  |  
		  |  |  |  
  
	|    |  | Page 1 of 1 |  
 
 
  
  	| 
		
		  | 
 
 | You cannot post new topics in this forum You cannot reply to topics in this forum
 You cannot edit your posts in this forum
 You cannot delete your posts in this forum
 You cannot vote in polls in this forum
 
 |  |  |  |