Refactor etcd lookup plugin for v2 API support and more robust functionality when used in the 'with_etcd' syntax.