09.12.2012 Views

Advanced Queuing - Oracle

Advanced Queuing - Oracle

Advanced Queuing - Oracle

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

JMS Propagation<br />

processes can be skewed based on the arrival rate of messages in the different<br />

source topics. If one process is overburdened with several active schedules while<br />

another is less loaded with many passive schedules, propagation automatically<br />

re-distributes the schedules among the processes such that they are loaded<br />

uniformly.<br />

Example Scenario<br />

In the BooksOnLine example, the OE_bookedorders_topic is busy since<br />

messages in it are propagated to different shipping sites. The following example<br />

code illustrates the calls supported by enhanced propagation scheduling for error<br />

checking and schedule monitoring.<br />

Example Code<br />

CONNECT OE/OE;<br />

/* get averages<br />

select avg_time, avg_number, avg_size from user_queue_schedules;<br />

/* get totals<br />

select total_time, total_number, total_bytes from user_queue_schedules;<br />

/* get maximums for a window<br />

select max_number, max_bytes from user_queue_schedules;<br />

/* get current status information of schedule<br />

select process_name, session_id, instance, schedule_disabled<br />

from user_queue_schedules;<br />

/* get information about last and next execution<br />

select last_run_date, last_run_time, next_run_date, next_run_time<br />

from user_queue_schedules;<br />

/* get last error information if any<br />

select failures, last_error_msg, last_error_date, last_error_time<br />

from user_queue_schedules;<br />

Exception Handling During Propagation<br />

When a system errors such as a network failure occurs, AQ will continue to attempt<br />

to propagate messages using an exponential back-off algorithm. In some situations<br />

that indicate application errors AQ will mark messages as UNDELIVERABLE if there<br />

is an error in propagating the message.<br />

12-92 <strong>Oracle</strong>9i Application Developer’s Guide - <strong>Advanced</strong> <strong>Queuing</strong>

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!