Moving network db access to a threaded encapsulated version