![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
I'm adding code to my application to make it TAF-aware. *TAF an excellent feature and I haven't had much problem getting the extra error checking in place. 1. *Is there some place where symbolic names for the ORA-XXXXX * * codes are defined? 2. *Is there some grouping or categorizing, such as "this is * * the set of all ORA errors you can get on a connect and * * that would benefit from a retry". My code currently looks as per below, and I would like to be able to remove a bit of the hardcoded numbers. *I've built up these numbers by trial and error. Many TIA! Mark * * # connect to the database, and retry on fixable exceptions * * try: * * * * conn=cx_Oracle.connect(connstr) * * except cx_Oracle.DatabaseError,e: * * * * # ORA-01033: ORACLE initialization or shutdown in progress * * * * # ORA-12537: TNS:connection closed * * * * # ORA-12528: TNS:listener: all appropriate instances are blocking * * * * # * * * * * *new connections * * * * # ORA-12521: TNS:listener does not currently know of instance * * * * # * * * * * *requested in connect descriptor * * * * # ORA-12520: TNS:listener could not find available handler for * * * * # * * * * * *requested type of server * * * * if e.message.code in [1033,12537,12528,12521,12520]: * * * * * * print 'RETRYING:', e.message.message.strip() * * * * * * ... -- Mark Harrison Pixar Animation Studios |
#3
| |||
| |||
|
|
find $ORACLE_HOME -name *msg |
|
Metalink and some other web sites like http://www.ora-error.com/ have the generic definitions also. Metalink may have some troubleshooting type docs, search for troubleshooting taf, troubleshooting sql oracle~net, etc. There's just so many obscure things that rarely happen... |
![]() |
| Thread Tools | |
| Display Modes | |
| |