Skip to Main Content

DevOps, CI/CD and Automation

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Use Blocking mode or Non-blocking mode?

302096Sep 21 2002
Platforms: MS Windows/Linux/Solaris, ORACLE 8.1.7 (64bit on solaris)
Volume of data to dump: terabytes size databases for a day (as quick as possible)
Question: Which execution mode is suitable, blocking mode or non-blocking mode?

Description: I am working on a plugin (library) for database-engine of our product. I am new to OCI....I am confused about which mode should I use. I benchmarked blocking and no-blocking mode. Blocking mode works out to be much faster. The problem with blocking mode is that whenever there is resource busy kid of error, the OCIStmtExecute(...) call keeps waiting to finish of its work. There is no feedback. If there is such kind of situation then I need to write feedback log for the administrator in the application TRACE log. I have been wondering if there is some way to get feedback from the server about what is making OCIStmtExecute(...) take so long (waiting) to give an ERROR or SUCCESS status. Infact if the resource is busy for 4 hours the OCIStmtExecute(...) keeps waiting for 4 hours. Can some expert throw some light on this and guide me on how to handle it?

If I use non-blocking mode then the performance comes-down to an easily noticeable level. Also even in non-blocking mode I do not get errror like ORA-00054: Resource busy and acquire with NOWAIT specified, instead I get error ORA-03123: Operation would block. Something is wrong or missing. Can any one tell what?

The library inserts data into Oracle using BULK INSERT and gets errors with the help of OCI_BATCH_ERRORS mode. At present, I am inserting 4000 records in one batch insert.

Please suggest me which mode should I use for my library and how can I get status feedback about what OCIStmtExecute() is doing. Some expert way of handling data/oracle related errors..? Any specific handling in callback routines..?

Thanks
jAGzZz!!!


Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Oct 23 2002
Added on Sep 21 2002
4 comments
612 views