new plugin structure and go implementation