Question

I'm planning to make use of Oracle AQ Asynchronous notification feature in an OLTP application.The number of messages it enqueues might go up to 1000 within a minute during peak hours. The dequeue callback procedure will process the message and inserts an entry into a table which is determined by the type of message.

My concern is that, does the large number of enqueue notifications it generates(the PL/SQL callback procedure that is being called in turn for every notification) cause database contention ? Is it advisable to use Asynchronous notification for this purpose or Should I go with dequeue polling process where I can dequeue one message a time in a continous loop.

My database version is 10gR2

Your expert help is highly appreciated!!

Was it helpful?

Solution

For each message enqueued into the queue, ORACLE background process invokes the related callback procedure by creating a scheduler job. As you are expecting 1000 messages with in a minute if you depend on the callback procedure it increases the load on ORACLE background processes and also creates those many onetime scheduler jobs, again if the no.of parallel scheduler jobs created is more than the "job_queue_processes" (ORACLE parameter) value configured in your database that delays the message processing, instead if you choose for polling to dequeue by using AQ listener, a single job can process all the messages enqueued in to the queue.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top