refacted newDomainCache