hi
can anybody solve my problem, plz
my script:
1-destination script:
create type mytype as object (n number);
/
Begin
dbms_aqadm.create_queue_table('queue_table','mytype',multiple_consumers => true);
End;
/
begin
dbms_aqadm.create_queue('queue2','queue_table');
end;
/
begin
dbms_aqadm.start_queue('queue2');
end;
/
begin
dbms_aqadm.add_subscriber(queue_name => 'queue2',
subscriber => sys.aq$_agent('SUBS2',null,null));
end;
/
3-source script:
Begin
dbms_aqadm.create_queue_table('queue_table_source','mytype',multiple_consumers => true);
End;
/
begin
dbms_aqadm.create_queue('queue1','queue_table_source');
end;
/
begin
dbms_aqadm.start_queue('queue1');
end;
/
begin
dbms_aqadm.add_subscriber(queue_name => 'queue1',
subscriber =>
sys.aq$_agent('SUBS1','[email protected]_to_slsp',null), queue_to_queue => true);
end;
/
begin
dbms_aqadm.schedule_propagation(queue_name => 'queue1',
destination => 'symadm_to_slsp'
,start_time => sysdate
,duration => 10
,next_time => 'sysdate'
,latency => 25
,destination_queue => 'symadm.queue2');
end;
/
declare
rc binary_integer;
nq_opt dbms_aq.enqueue_options_t;
nq_pro dbms_aq.message_properties_t;
datas mytype;
msgid raw(16);
begin
nq_opt.visibility := dbms_aq.immediate;
nq_pro.expiration := dbms_aq.never;
datas := mytype(200);
dbms_aq.enqueue('queue1',nq_opt,nq_pro,datas,msgid);
end;
/
4- deque script in destination:
declare
dq_opt dbms_aq.dequeue_options_t;
dq_prop dbms_aq.message_properties_t;
datas mytype;
msg_id raw(16);
begin
dq_opt.consumer_name := 'SUBS2';
dq_opt.dequeue_mode := dbms_aq.browse;
dq_opt.navigation := dbms_aq.first_message;
dq_opt.wait := dbms_aq.no_wait;
dbms_aq.dequeue(queue_name => 'QUEUE2'
,dequeue_options => dq_opt
,message_properties => dq_prop
,payload => datas
,msgid => msg_id);
dbms_output.put_line('Message dequeued='||datas.n);
end;
/
error message:
ORA-25228: timeout or end-of-fetch during message dequeue from U282.QUEUE2
ORA-06512: at "SYS.DBMS_AQ", line 335
ORA-06512: at line 14
thanks for all