Autonomous Transaction Sequencing

From: Stefan Knecht <knecht.stefan_at_gmail.com>
Date: Sat, 13 Jan 2018 15:01:49 +0700
Message-ID: <CAP50yQ8yQmmSpaH-29Q_+2mNEs48RfxUVOvs5SXwFRZWJJP=2g_at_mail.gmail.com>



Hi all

If you have a code structure similar to this:

begin
procedure set_start
is
pragma autonomous_transaction;
begin
update t set start_time=systimestamp;
commit;
end;
procedure set_end
is
pragma autonomous_transaction;
begin
update t set end_time=systimestamp;
commit;
end;
begin
set_start;
-- run some code here that takes anywhere between 0.1 and 2 seconds to
complete
commit;
set_end;
end;
/

I have some executions of this code, 40 out of 6000 runs, where I end up with the end_time being a timestamp BEFORE the begin_time and not just a microsecond or two. 0.4 seconds, 0.6 seconds. A significant amount of time.

This leads me to believe that Oracle somehow fires autonomous transactions asynchronously or out of order of the code structure?

Before I go off on a digging spree - has anyone seen this before or has an explanation?

Oracle 12.1 on *nix.

Cheers

Stefan

--

//
zztat - The Next-Gen Oracle Performance Monitoring and Reaction Framework! Visit us at zztat.net | Support our Indiegogo campaign at igg.me/at/zztat | _at_zztat_oracle

--
http://www.freelists.org/webpage/oracle-l
Received on Sat Jan 13 2018 - 09:01:49 CET

Original text of this message