Make metadata code independent of mysql. Make sure metadata repositories get properly decorated.

Why use creator? Why not plug-in the Repository as a parameter?