implement delete_stack, delete_layer, delete_instance, delete_app.