q:Using AQ effectively ?

  • From: Amihay Gonen <AmihayG@xxxxxxxxx>
  • To: "Oracle-L (oracle-l@xxxxxxxxxxxxx)" <oracle-l@xxxxxxxxxxxxx>
  • Date: Thu, 23 Jun 2005 11:29:33 +0300

 Hi ,
I've to implement an actions system.

I've one side which put action in Advance queue system , and other
side (c++ application ) that get the action and do it. Each action has
type which use to define connection between action and application
(For example 'EMAIL' -- email application)

I've two options to do it in AQ :

1. Define subscriber with a rule
DBMS_AQADM.ADD_SUBSCRIBER (
  queue_name => 'Queue' ,    subscriber  => new
sys.aq$_agent('EMAIL',null,null),
  rule =>  'tab.user_data.type=''EMAIL''  ' ;
2. deqeue user subscriber name.

Or
1. When defining subscriber leave the rule empty.
2. on the DBMS_AQ.ENQUEUE  command use
message_properties_t.recipient-_list to define which subscriber should
get the message. for example:
declare
...
 a AQ$_RECIPIENT_LIST_T := new AQ$_RECIPIENT_LIST_T(new
sys.aq$_agent('EMAIL',null,null));
....

I wonder with of the option will has better performance ? And what the
best practice in the area ? 
 

Amihay Gonen
DBA,
972-3-9268280 

Be there ... -> http://golan/Forum%20DBA/default.aspx
<http://golan/Forum%20DBA/default.aspx> 

 

Other related posts:

  • » q:Using AQ effectively ?