Re: Aq and wls 8

From: Nigel Thomas <>
Date: Mon, 8 Feb 2010 08:27:52 +0000
Message-ID: <>


On 8 February 2010 00:25, Ujang Jaenudin <> wrote:

can we use aq, from bea juSt post messages to aq, and let plsql dequeue to batch insert to auditing table per 200 trx or per 5 sec whichever the first

Sending a message on AQ involves posting changes into a queue table, which will be committed at the same time as the "real" transaction. That's not going to help any, is it? Plus, you will also need something running (a queue receiver, message driven bean or whatever) to dequeue the messages.

As you say you are using BEA (WebLogic I presume) you could try using it's built-in WebLogic JMS to send the audit transactions - then set up message driven beans or worker jobs to dequeue the messages and post the audit trail in batches as you like. That way, the audit data only hits the Oracle database once, asynchronously to the real transactions.

Of course, you will either need to send the audit messages as part of an XA transaction (and have the extra cost of 2-phase commit) or keep things simple (don't coordinate Oracle and JMS) and accept a small risk that a transaction may succeed but the audit message be lost (or vice versa) in the event of a system failure.

HTH Nigel

Received on Mon Feb 08 2010 - 02:27:52 CST

Original text of this message