Skip to content
Snippets Groups Projects
Commit 1d1b8953 authored by Konstantin Osipov's avatar Konstantin Osipov
Browse files

A pre-requisite patch for multi-statement transactions.

Refactor statement transaction lifecycle. Avoid nested
statement transactions. Make sure there is no more than 1
statement transaction present in the system at the moment.

Resolve the bugs this revealed:
- in local hot standby we would parasite on the main or
script fiber session to process requests. When an assert
was added that there is no more than 1 transaction active
at a given moment in time, it turned out that transactions
running on behalf of local hot standby were running in
the scope of session of the run_script or sched fibers.

Create and use an own session there.

- refactor session on_connect/on_disconnect trigger
invocation: do not invoke these triggers for just any session,
only for real connects/disconnects (iproto, admin).

- split session creation/destruction and trigger invocation
Conclude that session storage implementation needs to be
done differently.
parent d5b2cb64
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment