func NewFinder(zcHandler func(*zonecut.Request) *errors.ErrorStack, conf *tools.TransdepConfig) *Finder {
	nr := new(Finder)
	if err := nameresolver.CreateCacheDir(conf.CacheRootDir); err != nil {
		return nil
	}
	nr.config = conf
	var err error
	nr.workerPoll, err = lru.NewWithEvict(conf.LRUSizes.NameResolverFinder, nr.writeOnDisk)
	if err != nil {
		return nil
	}
	nr.zcHandler = zcHandler
	nr.reqs = make(chan *nameresolver.Request, REQ_CHAN_CAPACITY)
	nr.closedReqChan = false
	nr.joinChan = make(chan bool, 1)
	nr.start()
	return nr
}
/* NewFinder instantiates a new Finder

zcHandler is a function that may be called to submit new requests for zone cut/delegation info discovery.

maxWorkerCount is the number of concurrent workers that will be maintained by this finder. Once this number of workers reached,
the Finder will shut down those that were the least recently used (LRU).

cacheRootDir is the root directory for caching. Workers that are shut down store the result that they are distributing
into a cache file, for later use.
package nameresolver
import (
	"fmt"
	"github.com/hashicorp/golang-lru"
	"github.com/ANSSI-FR/transdep/messages/nameresolver"
	"github.com/ANSSI-FR/transdep/messages/zonecut"
	"github.com/ANSSI-FR/transdep/tools"
	"github.com/ANSSI-FR/transdep/errors"
)
const REQ_CHAN_CAPACITY = 10
type Finder struct {
	reqs chan *nameresolver.Request
	closedReqChan bool
	zcHandler func(*zonecut.Request) *errors.ErrorStack
	workerPoll *lru.Cache
	joinChan     chan bool
	config    *tools.TransdepConfig
}