On 02/27/2014 06:00 PM, Alex Xu wrote:
Does mean our code looks like as below?
if client_version > 2:
elif client_version > 3
elif client_version > 4:
elif client_version > 5:
elif client_version > 6:
And we need test each version... That looks bad...
I don't think the code would look like that
Each part of the API could look at the version separately. And each
part of the API only needs to check the client version if it has made a
So a part of the API that only made one backwards-incompatible change at
version 3 would only need one check.
if client_version >= 3
Maybe some other part of the API made a change at v6 (assuming global
versioning). That part of the API would also only need one check.
if client version >= 6
OpenStack-dev mailing list