fix buildSession call for database handler
Merge pull request #4499 from alprs/fix/db-session-create

Fix buildSession call for database handler