[Tendrl-devel] REST API consistency

Rohan Kanade rkanade at redhat.com
Fri Jun 2 17:37:33 UTC 2017


Anup, this topic seems like something you can discuss more about.

@Martin

While I dont have a problem with the RESTful structure suggested by you.
Tendrl choose the Amazon AWS style [0] Action based http API style because
it maps well with the Flows exposed by backend (1:1)

I am not of favor of changing the current API style unless there's actual
use cases for the style proposed by Martin.

HTTP verbs mapped to Tendrl API actions/flows can be reviewed and corrected

[0]:
http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_Operations.html

On Fri, Jun 2, 2017 at 10:57 PM, Martin Bukatovic <mbukatov at redhat.com>
wrote:

> ping
>
> On 06/01/2017 01:42 PM, Martin Bukatovic wrote:
> > ping
> >
> > On 05/30/2017 04:23 PM, Martin Kudlej wrote:
> >> Hi all,
> >>
> >> I would like to ask if there is any movement in this area?
> >>
> >> On 04/26/2017 09:58 AM, Martin Kudlej wrote:
> >>> Hi all,
> >>>
> >>> I think there is still time to unify Tendrl API functions according
> >>> some rules.
> >>> I've filed https://github.com/Tendrl/documentation/issues/70 couple of
> >>> months ago without response.
> >>>
> >>> One example for all.
> >>> There are these functions for Ceph cluster(Flows on cluster):
> >>>      "name": "CephCreatePool",
> >>>      "method": "POST",
> >>>
> >>>      "name": "CephCreateECProfile",
> >>>      "method": "POST",
> >>>
> >>>      "name": "CephDeleteECProfile",
> >>>      "method": "DELETE",
> >>>
> >>>      "name": "CephCreateRbd",
> >>>      "method": "POST",
> >>>
> >>>      "name": "CephDeleteRbd",
> >>>      "method": "DELETE",
> >>>
> >>>      "name": "CephResizeRbd",
> >>>      "method": "PUT",
> >>>
> >>>      "name": "CephDeletePool",
> >>>      "method": "DELETE",
> >>>
> >>>      "name": "CephUpdatePool",
> >>>      "method": "PUT",
> >>>
> >>> and according documentation there should be also
> >>>      "name": "CephPoolList"
> >>>      "method": "GET"
> >>>
> >>> I think that there should be also "GET" "CephPool" because of
> >>> performance.
> >>>
> >>> I think that these functions should be transformed avoiding verb
> >>> duplicity. Also I believe if API function names are renamed
> >>> integration with other projects will be much easier.
> >>>
> >>> Pool CRUD
> >>>      "name": ":ceph_cluster_id:/pool",
> >>>      "method": "POST",
> >>>
> >>>      "name": ":ceph_cluster_id:/pool/:ceph_pool_id:",
> >>>      "method": "GET",
> >>>
> >>>      "name": ":ceph_cluster_id:/pool/:ceph_pool_id:",
> >>>      "method": "PUT",
> >>>
> >>>      "name": ":ceph_cluster_id:/pool/:ceph_pool_id:",
> >>>      "method": "DELETE",
> >>>
> >>> RBD CRUD
> >>>
> >>>      "name": ":ceph_cluster_id:/rbd",
> >>>      "method": "POST",
> >>>
> >>>      "name": ":ceph_cluster_id:/rbd/:ceph_pool_id:",
> >>>      "method": "GET",
> >>>
> >>>      "name": ":ceph_cluster_id:/rbd/:ceph_pool_id:",
> >>>      "method": "PUT",
> >>>
> >>>      "name": ":ceph_cluster_id:/rbd/:ceph_pool_id:",
> >>>      "method": "DELETE",
> >>>
> >>> EC Profile CRUD
> >>>
> >>>      "name": ":ceph_cluster_id:/ecprofile",
> >>>      "method": "POST",
> >>>
> >>>      "name": ":ceph_cluster_id:/ecprofile/:ec_profile_id:",
> >>>      "method": "GET",
> >>>
> >>> (update if it is possible)
> >>>      "name": ":ceph_cluster_id:/ecprofile/:ec_profile_id:",
> >>>      "method": "PUT",
> >>>
> >>>      "name": ":ceph_cluster_id:/ecprofile/:ec_profile_id:",
> >>>      "method": "DELETE",
> >>>
> >>>
> >>> Lists
> >>>
> >>>      "name": ":ceph_cluster_id:/pool"
> >>>      "method": "GET"
> >>>
> >>>      "name": ":ceph_cluster_id:/rbd"
> >>>      "method": "GET"
> >>>
> >>>      "name": ":ceph_cluster_id:/ecprofile"
> >>>      "method": "GET"
> >>>
> >>> Please consider this rename until is not too late and there are not
> >>> many projects which are integrated with Tendrl.
> >>>
> >>
> >
> >
>
>
> --
> Martin Bukatovic
> USM QE team
> Red Hat
>
> _______________________________________________
> Tendrl-devel mailing list
> Tendrl-devel at redhat.com
> https://www.redhat.com/mailman/listinfo/tendrl-devel
>



More information about the Tendrl-devel mailing list