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

API: PUT conflict on apps #367

Open
akavlie opened this issue Apr 7, 2012 · 0 comments
Open

API: PUT conflict on apps #367

akavlie opened this issue Apr 7, 2012 · 0 comments
Assignees

Comments

@akavlie
Copy link

akavlie commented Apr 7, 2012

We have two possible PUT reuquests on /apps/<appname> -- one for updating the starting app name, and another for starting/stopping the app.

Taking two completely separate actions, depending on the key sent, is problematic, because the convention is to send the full model when doing a PUT request.

This is causing a problem with the admin panel:

  1. Start/stop an app as appropriate
  2. Response has start attribute, which gets copied to the model
  3. Start/stop the same app without refreshing page
  4. Full model info, including both running and start attributes is sent to the API. That seems to trigger the starting app name update, not the start/stop app action.

Suggested changes:

  1. API needs to check for changes on both attributes when a PUT request is sent to this endpoint
  2. Respective actions should be triggered only if the value is changed
@ghost ghost assigned alejandro Jul 12, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants