updates to allow the plugin to handle multiple pools at once