Showing posts with label Oracle Streams Advanced Queuing. Show all posts
Showing posts with label Oracle Streams Advanced Queuing. Show all posts

Sunday, February 28, 2010

Recreating Queues and Queue Tables (Oracle Streams Advanced Queuing)

Stop all the queues in the queue table.

When you create a queue table, it also creates an exception queue implicitly. Make sure that you also stop the exception queue.
begin dbms_aqadm.stop_queue('TEST_OUTBOUND_QUEUE'); end; /

begin dbms_aqadm.stop_queue('AQ$_TEST_OUTBOUND_QT_E'); end; /

Drop the queue table.


begin dbms_aqadm.drop_queue_table(queue_table => 'TEST_OUTBOUND_QT', force => TRUE); end; /

Create the Queue Table.
begin dbms_aqadm.create_queue_table( queue_table => 'TEST_OUTBOUND_QT', queue_payload_type => 'TEST_TYPE', comment => 'Queue Table for Outbound messages', multiple_consumers => TRUE ); end; /

Create the Queues.

begin dbms_aqadm.create_queue( queue_name => 'TEST_OUTBOUND_QUEUE', queue_table => 'TEST_OUTBOUND_QT', queue_type => DBMS_AQADM.NORMAL_QUEUE, max_retries => 5, retry_delay => 0, comment => 'test queue for all outbound messages'); end; /

Screen shots: