[openstack-dev] [Quantum][LBaaS] LBaaS API 1.0 spec draft
JC Martin
jcmartin at ebaysf.com
Fri Nov 2 16:58:18 UTC 2012
Missed that one,
This sentence caused some of the confusion :
For example, if a client issues an HTTP PUT request to add a member to a pool, there is no guarantee that the member can receive traffic when the HTTP call returns. However, it is guaranteed that a subsequent HTTP GET request to view the members on the pool returns a list that would contain the added member.
Thanks,
JC
From: Youcef Laribi <Youcef.Laribi at eu.citrix.com<mailto:Youcef.Laribi at eu.citrix.com>>
Reply-To: "openstack-dev at lists.openstack.org<mailto:openstack-dev at lists.openstack.org>" <openstack-dev at lists.openstack.org<mailto:openstack-dev at lists.openstack.org>>
Date: Fri, 2 Nov 2012 16:28:08 +0000
To: "openstack-dev at lists.openstack.org<mailto:openstack-dev at lists.openstack.org>" <openstack-dev at lists.openstack.org<mailto:openstack-dev at lists.openstack.org>>
Subject: Re: [openstack-dev] [Quantum][LBaaS] LBaaS API 1.0 spec draft
JC,
If you look at the spec (http://wiki.openstack.org/Quantum/LBaaS/API_1.0#Update_a_Pool), you will see that you cannot update the “members” attribute of the pool this way.
This is what the spec says:
The caller of this operation may update the following attributes of the Pool:
· name
· description
· lb_method
· admin_state_up
As you can see, the “members” attribute is not part of these. The way you update the members of a pool is by removing or adding members.
Youcef
From: JC Martin [mailto:jcmartin at ebaysf.com]
Sent: Friday, November 2, 2012 8:53 AM
To: openstack-dev at lists.openstack.org<mailto:openstack-dev at lists.openstack.org>
Subject: Re: [openstack-dev] [Quantum][LBaaS] LBaaS API 1.0 spec draft
Yousef,
But you can do PUT on /v1.0./pools/xxxxxxxxxxxxxx
With body :
{
"pool":{
members:[
"xxxxxxxxyyyxxyxyxyxyxyxy"
]
}
}
How should we interpret this if the previous value of pools.members had 3 elements ?
JC
From: Youcef Laribi <Youcef.Laribi at eu.citrix.com<mailto:Youcef.Laribi at eu.citrix.com>>
Reply-To: "openstack-dev at lists.openstack.org<mailto:openstack-dev at lists.openstack.org>" <openstack-dev at lists.openstack.org<mailto:openstack-dev at lists.openstack.org>>
Date: Fri, 2 Nov 2012 01:45:35 +0000
To: "openstack-dev at lists.openstack.org<mailto:openstack-dev at lists.openstack.org>" <openstack-dev at lists.openstack.org<mailto:openstack-dev at lists.openstack.org>>
Subject: Re: [openstack-dev] [Quantum][LBaaS] LBaaS API 1.0 spec draft
JC,
The API doesn’t define PUT operations on lists, so we don’t have this issue. To update the membership of the list, one removes and adds elements to it. To update a specific element, one operates directly on the element.
Thanks,
Youcef
From: JC Martin [mailto:jcmartin at ebaysf.com]
Sent: Thursday, November 1, 2012 6:35 PM
To: openstack-dev at lists.openstack.org<mailto:openstack-dev at lists.openstack.org>
Subject: Re: [openstack-dev] [Quantum][LBaaS] LBaaS API 1.0 spec draft
Youcef,
How do you distinguish between removing elements in a list and updating only some members ?
For example, if you update the members attribute in a pool, is the semantic that you replace the list of members with the one in the put request ?
Is the rule that attribute values are always replaced by the values in put request (even lists) ?
Thanks,
JC
From: Youcef Laribi <Youcef.Laribi at eu.citrix.com<mailto:Youcef.Laribi at eu.citrix.com>>
Reply-To: "openstack-dev at lists.openstack.org<mailto:openstack-dev at lists.openstack.org>" <openstack-dev at lists.openstack.org<mailto:openstack-dev at lists.openstack.org>>
Date: Thu, 1 Nov 2012 05:05:58 +0000
To: "openstack-dev at lists.openstack.org<mailto:openstack-dev at lists.openstack.org>" <openstack-dev at lists.openstack.org<mailto:openstack-dev at lists.openstack.org>>
Subject: Re: [openstack-dev] [Quantum][LBaaS] LBaaS API 1.0 spec draft
Let's add a note that all update operations adopt patch semantics (like Quantum does)
Good point. Yes, the semantics of “PUT” in REST is not universally agreed upon :)
_______________________________________________ OpenStack-dev mailing list OpenStack-dev at lists.openstack.org<mailto:OpenStack-dev at lists.openstack.org> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
_______________________________________________ OpenStack-dev mailing list OpenStack-dev at lists.openstack.org<mailto:OpenStack-dev at lists.openstack.org> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-dev/attachments/20121102/4c4602d3/attachment.html>
More information about the OpenStack-dev
mailing list