Manage resources with promises