I'm trying to write a long-running process which handles intermittent
data collection from a database. Basically my process will connect to
the database, and then sit there, occasionally querying the database
and passing data back to client applications.
If the database goes down, my application will be written to deal with
this - it will trap the error, and reconnect as necessary once the
database comes back.
Basically, I'm only keeping a connection open to ensure fast
turnaround of queries. The only problem I have is that I cannot afford
for my application to stop a SHUTDOWN NORMAL of the target database.
We have some admin tasks that do a shutdown normal, and they can't be
modified to take into account this extra process.
Is there any way of creating a cx_Oracle connection which doesn't
block a SHUTDOWN NORMAL? The Oracle Intelligent agent seems to work
like this (agent connections are present in the database, but SHUTDOWN
NORMAL still works), so I suspect it's possible, but I can't find
anything in the documentation which tells me how.
Thanks in advance,
Paul.
|