YottaDB / YDB

Mirrored from https://gitlab.com/YottaDB/DB/YDB
Other
76 stars 37 forks source link

Bump LOCK_TRIES from 50 seconds to 200 seconds (4x) on 1-CPU systems to address occasional test failures #260

Closed nars1 closed 6 years ago

nars1 commented 6 years ago

We have seen assert failures in debug builds in in-house testing on 1-CPU systems (Raspberry Pi Zero and Beagblebone Black) in various tests occasionally.

The assert that fails is always the following.

%YDB-F-ASSERT, Assert failed in /Distrib/YottaDB/V999_R120/sr_port/relqueopi.c line 205 for expression (FALSE)

This is in the remqhi1() function when it has waited for 50 seconds to get the queue header latch (GET_SWAPLOCK).

The 1-CPU systems that we have seen this failure on are slow boxes so this commit gives such systems 4x the time (4 * 50 seconds) before signaling an assert failure.

In production builds, one would have gotten a DBCCERR error though we have not yet seen such a failure in our in-house testing.

With the fix, the assert failure and DBCCERR error failures are expected to go away.