Revert "refactor: use short-lived sessions when accessing the database"
The introduction of short-lived sessions caused issues with functions, which return database objects. Such objects are not accessible (due to lazy loading), after the session is closed. Instead we should either move the session scope the respective callers or use a request-based session handling (e.g. the one provided by flask-sqlalchemy). This reverts commit 0b594e50 and 70ffd1a0. See: #93