Use ReentrantLock as a lock (not a monitor) when marking DB as open.

4 jobs for !1549 with fix-database-locking in 9 minutes and 35 seconds (queued for 23 seconds)
latest detached
Status Job ID Name Coverage
  Test
passed test #13054

00:09:35

failed test #13039

01:54:26

 
  Optional Tests
manual android test #13040
kvm allowed to fail manual
manual bridge test #13041
allowed to fail manual