Thread-local DB.
Creates a new DB instance for the current thread.
Returns the DB instance for this thread. It's nullable.
DB instance