Home » Server Options » Streams & AQ » AQ propagation over internet
AQ propagation over internet [message #126447] Mon, 04 July 2005 11:03 Go to next message
jeffhu
Messages: 1
Registered: July 2005
Junior Member
Hi everyone,

I'm trying to create a simple Oracle-to-Oracle data replication service over the Internet using AQ. Right now I'm developing various pieces on one Oracle instance (9.2.0.5.0 Enterprise) residing on our intranet. The AQXmlServlet is running on a different machine (Tomcat 4.1 on XP Pro sp2), also on intranet.

The sender and the receiver are in their respective schema -- fmis_aq0 and fmis_aq1. The message payload is a custom type containing two numbers, two strings and two Spatial type objects (sdo_geometry). I'll post the scripts if someone is interested.

When I test the setup over an ordinary dblink, it works as expected. i.e. the data is moved from the source queue to the destination queue and triggers a PL/SQL procedure which saves the data in the receiving table.

However, when I try to use an HTTP-based dblink, I always get errors complaining about premature end of message in the response. more specifically the error message looks like this:

ORA-29266: end-of-body reached
ORA-06512: at "SYS.DBMS_PRVTAQIP", line 2750
ORA-06512: at line 1

Upon closer inspection I found that the source queque sends something like this to the servlet:

<?xml version="1.0"?>
<Envelope xmlns="http://ns.oracle.com/AQ/schemas/envelope">
<Body>
<AQXmlPush xmlns="http://ns.oracle.com/AQ/schemas/access">
<push_options>
<destination>FMIS_AQ1.FMIS_REQ_IN_QUEUE</destination>
<sequence_number>293</sequence_number>
<database_link>LAOS92.LULEA.LM.SE</database_link>
<source_qid>31290</source_qid>
</push_options>
<message_set>
<message>
<message_header>
<priority>1</priority>
<sender_id>
<address>
FMIS_AQ0.FMIS_REQ_OUT_QUEUE
</address>
<protocol>0</protocol>
</sender_id>
<recipient_list>
<recipient>
<address>
FMIS_AQ1.FMIS_REQ_IN_QUEUE
</address>
<protocol>0</protocol>
</recipient>
</recipient_list>
</message_header>
<message_payload>
<REQUEST_MSG_TYPE>
<MSG_ID>0</MSG_ID>
<OPERATION>test</OPERATION>
<OBJECT_ID>12</OBJECT_ID>
<LABEL_TEXT>test label</LABEL_TEXT>
</REQUEST_MSG_TYPE>
</message_payload>
</message>
</message_set>
</AQXmlPush>
</Body>
</Envelope>

(Note that the two Spatial objects are set to null for testing)

And the destination queue returns an empty response. In addition, the beforeAQOperation gets called but the afterAQOperation does not.

After that the source queue sends an AQXmlRollback which triggers both beforeAQOperation and afterAQOperation.

I've searched through the Oracle documents, AskTom and of course this forum and found no reference to AQXmlPush. If someone knows about this problem or has a working example, please respond.

Many thanks in advance.
Jeffrey
AQ propagation over internet => I have a question [message #159794 is a reply to message #126447] Tue, 21 February 2006 09:46 Go to previous messageGo to next message
nallan_hara
Messages: 2
Registered: February 2006
Location: India
Junior Member
Jeffrey,

I do not have an answer to the question you posted, but have a question for which you might have an asnwer.

Please let me know if you could.

You said you had setup http access. Did you have to write a separate servlet that extended the AQXMLServlet and had its own init, service and destroy methods? Or did just deploying the AQXMLServlet help?

Thanks,
Nallan
Re: AQ propagation over internet [message #329770 is a reply to message #126447] Thu, 26 June 2008 08:10 Go to previous message
Faceless
Messages: 1
Registered: June 2008
Junior Member
This error is caused by missing xdb.jar library.
After i've fixed this error, HTTP propagation works nice and smootly with any AQ payload, either JMS or SQL type.
Previous Topic: Oracle Stream is working for INSERTs, but does not on UPDATEs & DELETEs
Next Topic: Add New Destination
Goto Forum:
  


Current Time: Fri Apr 18 08:56:51 CDT 2014

Total time taken to generate the page: 0.11312 seconds