Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove all service resources #14584

Merged
merged 1 commit into from
Apr 3, 2017
Merged

Remove all service resources #14584

merged 1 commit into from
Apr 3, 2017

Conversation

jntullo
Copy link

@jntullo jntullo commented Mar 30, 2017

This is an additional API action to remove all service resources:

POST /api/services
{
    'action' : 'remove_all_resources',
    'resources' : [
       { 'href' : '/api/services/:id' },
       { 'href' :  '/api/services/:id' }
     ]
}

or

POST /api/services/:id
{ "action" : "remove_all_resources" }

cc: @mkanoor
@miq-bot add_label enhancement, api
@miq-bot assign @abellotti

it 'can remove all resources from a service' do
api_basic_authorize collection_action_identifier(:services, :remove_all_resources)

run_post(services_url(svc.id), 'action' => 'remove_all_resources')
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

could you replace all these with :action => "..." for consistency with other tests.

@abellotti
Copy link
Member

I think this is fine @jntullo, minor changes to spec.

/cc @mkanoor is this master only or needed for fine ?

@blomquisg
Copy link
Member

closing and opening to kick travis

@blomquisg blomquisg closed this Mar 31, 2017
@blomquisg blomquisg reopened this Mar 31, 2017
@abellotti
Copy link
Member

@jntullo please rebase.

ping @mkanoor is this for Fine ? Thanks.

@miq-bot
Copy link
Member

miq-bot commented Apr 3, 2017

This pull request is not mergeable. Please rebase and repush.

spec consistency
@miq-bot
Copy link
Member

miq-bot commented Apr 3, 2017

Checked commit jntullo@815bd37 with ruby 2.2.6, rubocop 0.47.1, and haml-lint 0.20.0
3 files checked, 0 offenses detected
Everything looks good. 🏆

@abellotti
Copy link
Member

Thanks @jntullo for updating the PR.

@abellotti abellotti added this to the Sprint 58 Ending Apr 10, 2017 milestone Apr 3, 2017
@abellotti abellotti merged commit d7b0aed into ManageIQ:master Apr 3, 2017
simaishi pushed a commit that referenced this pull request Apr 3, 2017
Remove all service resources
(cherry picked from commit d7b0aed)
@simaishi
Copy link
Contributor

simaishi commented Apr 3, 2017

Fine backport details:

$ git log -1
commit 4b327fcb19f1e4b134d5dd2e9f557646738d89dc
Author: Alberto Bellotti <abellotti@users.noreply.github.com>
Date:   Mon Apr 3 17:11:18 2017 -0400

    Merge pull request #14584 from jntullo/enhancement/remove_all_resources
    
    Remove all service resources
    (cherry picked from commit d7b0aedf25d61a2c4e2a9def389ad2824c0f0f1a)

@jntullo jntullo deleted the enhancement/remove_all_resources branch April 11, 2017 14:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants