[katello-devel] On the plane, I tried 2 controllers worth of API changes

Bryan Kearney bkearney at redhat.com
Mon Jul 9 08:01:19 UTC 2012


someone should really check the pull request i sent in, since I was not 
able to really test. Here were some notes I took while playing with the 
code:

changesets_content_controller
=============================

* entire api controller returns text instead of json.
* passing in a non existent product id still gets you a 200 return code. 
(look at render_after_removal)
* Looks like the posts take in query parameters instead of JSON in the 
body. Any reason for that?
* For remove_* is seems nasty to have to pass in the product id. Dont we 
just know this since it is in the changeset already?
* For URLS like this:

   api :DELETE, "/changesets/:changeset_id/templates/:id", "

why use :changeset_id and then :id (as opposed to template_id"

Changeset_controller
====================
* Update and create seems to do json, which is good
* is organization_id ever checked?
* Why is name used in #index
* Promote seems icky. We are POSTING to /promote which is more of an RPC 
call. Can we do a POST to another environment instead?
* The promotion API automatically moves the changeset to REVIEW. Should 
we instead make that a unique call?




More information about the katello-devel mailing list