merget workflow resource and engine resource
refactor