Added logging, database classes.
Same as before
Same as before.