Slightly refactoring the database subsystem
Bringing it to work back after database subsystem refactoring…
Merging the master branch…