yugabyte / yugabyte-db

YugabyteDB - the cloud native distributed SQL database for mission-critical applications.
https://www.yugabyte.com
Other
8.98k stars 1.07k forks source link

[YSQL][SQLsmith] ERROR: Operation failed. Try again: [Operation failed. Try again (yb/tablet/transaction_participant.cc:296): Unknown transaction, could be recently aborted (pgsql error 40001)] #11226

Open def- opened 2 years ago

def- commented 2 years ago

Jira Link: DB-866

Description

Sporadic SQLsmith failure during UPDATEs, can't reproduce:

CREATE TABLE test_yb (col int);

update public.test_yb set 
  col = public.test_yb.col
returning 
  public.test_yb.col as c0, 
  (select pg_catalog.max(amopstrategy) from pg_catalog.pg_amop)
     as c1, 
  (select pg_catalog.stddev_pop(heap_blks_read) from pg_catalog.pg_statio_user_tables)
     as c2, 
  public.test_yb.col as c3, 
  public.test_yb.col as c4, 
  public.test_yb.col as c5, 
  public.test_yb.col as c6;

Failed with:

ERROR:  Operation failed. Try again: [Operation failed. Try again (yb/tablet/transaction_participant.cc:296): Unknown transaction, could be recently aborted: 40d74095-d58f-40a6-83f5-8367f9503a10 (pgsql error 40001)]
codeArtisanry commented 2 years ago

I'm Getting the same issue

williamoliveira commented 2 years ago

Having this error while running migrations on Sequelize

ERROR: SequelizeDatabaseError: Operation failed. Try again: Unknown transaction, could be recently aborted: e1371625-734d-4d0e-a769-c1dfb7e61e01

def- commented 1 year ago

I'm also seeing this during upgrade testing from 2.12.4.2-b1 to 2.17.1.0-b290 when verifying objects at the same time: https://phabricator.dev.yugabyte.com/D20539

Operation failed. Try again: Unknown transaction, could be recently aborted: b807985f-7f10-494e-b52a-38c7ace57a20

Seems easier to reproduce there.