[
https://issues.apache.org/jira/browse/JCLOUDS-545?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Jeremy Daggett resolved JCLOUDS-545.
------------------------------------
Resolution: Fixed
> SwiftApi and related Apis improvements
> --------------------------------------
>
> Key: JCLOUDS-545
> URL: https://issues.apache.org/jira/browse/JCLOUDS-545
> Project: jclouds
> Issue Type: Bug
> Components: jclouds-labs-openstack
> Affects Versions: 1.7.2
> Reporter: Everett Toews
> Assignee: Jeremy Daggett
> Fix For: 1.8.0, 1.7.3
>
>
> So far there are a number of issue with the Beta SwiftApi and related Apis.
> # All of the methods in SwiftApi are misnamed. Every single other top-level
> OpenStack API in jclouds is of the form *get* WhateverApi *For*
> Zone/RegionAndSomething.
> ## The methods to get the second-level APIs need to follow this form: get,
> and For must be used to be consistent with all of the other OpenStack APIs.
> ## configuredRegions() should be getConfiguredRegions()
> ## These name changes should be *added* to SwiftApi. The old methods
> deprecated (to be removed in 1.8) and point users to the new methods.
> # ObjectApi.replace() is not a good name. I understand the reasoning behind
> it but it's not intuitive for users looking to put/upload something. The
> semantics of put already say "If the URI refers to an already existing
> resource, it is modified". This method should be renamed put().
> ## This name change should be *added* to ObjectApi. The old method deprecated
> (to be removed in 1.8) and point users to the new method.
> # ObjectApi.replace() forces users to include metadata as the last parameter.
> This must be optional.
> # ObjectApi.get() forces users to include GetOptions as the last parameter.
> This must be optional.
> # ContainerApi.list() needs a comment that metadata is not returned and
> head() must be called to get metadata
> # ContainerApi.createIfAbsent() forces users to include options as the last
> parameter. This must be optional.
> # In all of the Swift domain objects toStringHelper("") is called with an
> empty String so no class name is given. This is inconsistent with the usage
> of toStringHelper("") everywhere else and doesn't provide as much
> information. It needs to be changed to toStringHelper().
--
This message was sent by Atlassian JIRA
(v6.2#6252)