Some refactoring of the instance definition
moved to plugins folder