puppetlabs/puppet — pull request #3404 by skoef (2014-12-08 12:47:39+00:00)
Title: refactored way of checking for zfs

We run machines on ZFS with relatively slow hard drives and relatively many filesystems (couple of hundred). When we want to manage ZFSes with Puppet, this is very slow. Investigation shows that for every Zfs resource the provider does a ```zfs list``` and then parses the output to see if a particular ZFS shows up. At least on our systems, this takes forever. I think I came up with a far more effective way of checking whether a ZFS exists or not.
Tested by ensuring a ZFS, running puppet a couple of times seeing that it only creates it once, and when ensuring the resource to be absent, the ZFS was removed.