Skip to content

txm: not serializable read before rollback #6325

@Egor2001

Description

@Egor2001
os.execute("rm -rf *.snap *.xlog")
txn_proxy = require("txn_printer")
box.cfg{memtx_use_mvcc_engine = true}
s=box.schema.space.create("s", {engine="memtx"})
ti=s:create_index("ti", {type="tree"})

tx1 = txn_proxy.new()
tx2 = txn_proxy.new()
tx3 = txn_proxy.new()

tx1:begin()
tx2:begin()
tx3:begin()

tx1("s:insert{1,'A'}")
tx2("s:insert{1,'B'}")
tx3("s:select{1}")
tx3("s:insert{2,'C'}")

tx1:rollback()
tx2:commit()
tx3:commit()

Result

...
$ tx3:commit()
> ""

Expected

...
$ tx3:commit()
> [{"error":"Transaction has been aborted by conflict"}]

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions