DB support

add hibernate + mysql, add registartion, some fixes