add resource
add resource entity and join tables for resource and resourcenode