prepare for resource define