Use mysql instead of sqlite for Cloud Controller

Also did some refactoring