Update to new resources map and context creation