updating apply_async_with_reservation to accept resource type and id and combine them for resource reservation to avoid locking resources of different types with same id