Work in progress on rewriting the plugin API.