set direct resource on createOnDemand