Andrew Gaul
e2bf20a619
Throw ContainerNotFoundException from removeBlob
...
This makes removeBlob consistent with all other user-facing methods.
2014-08-28 18:26:59 -07:00
John Walker
9efd0f5a33
JCLOUDS-676: Fix reflection warnings / Clojure
...
JCLOUDS-676: Fix reflection warnings / Clojure
Also fixed a typo in a doc string
2014-08-17 12:05:33 -07:00
Andrew Gaul
32acc35804
JCLOUDS-650: ContainerNotFoundException on putBlob
...
Found with Ceph s3-tests and s3proxy.
2014-08-09 00:25:34 -07:00
Andrew Gaul
7f31cd6051
Handle possibly null message from IOException
2014-07-27 19:41:45 -07:00
Andrew Gaul
1e1eb5a092
Add deleteContainerIfEmpty to BlobStore
...
This matches how most blobstores operate: delete container is a single
operation, not a compound operation which recursively deletes blobs.
Azure is the only provider which allows deleting a non-empty
container.
2014-07-25 23:02:39 -07:00
Andrew Phillips
5732bdcd94
Escaping regex special chars (esp. '\') in delimiter matching
...
Uncovered by 370194b
2014-07-22 13:35:52 -04:00
Andrew Gaul
a8b106c2bb
JCLOUDS-622: remove calls to InputSupplier methods
...
Guava 16 deprecated these methods and Guava 18 will remove them.
2014-07-15 03:09:58 -07:00
Andrew Gaul
f4eca0422d
Enforce correct MD5 for local blobstores
...
Matches behavior of real blobstores.
2014-07-10 22:19:42 -07:00
Andrew Gaul
e799a7409c
JCLOUDS-597: HashCode methods for Content-MD5
...
This works more naturally with Guava Hashing methods and immutability
provides better safety guarantees. Also deprecate existing byte[]
methods.
2014-06-12 15:29:17 -07:00
Andrew Gaul
9cdd53b0b7
JCLOUDS-546: Remove Javadoc @author annotations
...
Annotations removed with:
find -name \*.java | xargs sed -i /@author/d
Empty Javadoc removed with multiple iterations of:
find -name \*.java | xargs sed -i -z 's/ \*\n \*\// \*\//'
find -name \*.java | xargs sed -i -z 's/ \* \n \*\// \*\//'
find -name \*.java | xargs sed -i -z 's/\/\*\*\n \*\/\n//'
2014-06-07 21:44:54 -07:00
Andrew Gaul
2342abd3c5
Address Checkstyle violations
2014-05-30 11:10:14 -07:00
Andrew Gaul
186f052022
Remove BlobBuilder and Payloads.calculateMD5
...
Callers should instead explicitly set contentMD5, usually with the
results from Guava Hashing.md5(). This narrows the API and removes a
strange IOException from callers. Further it removes a dangerous
rebuffering of arbitrarily-large non-repeatable Payloads.
2014-05-28 12:54:18 -07:00
Andrew Gaul
c6d4e6645c
JCLOUDS-402: Allow Guava MediaType Content-Type
...
This promotes type-safety. Keep the String interface for unknown
content types.
2014-05-28 11:45:00 -07:00
Andrew Gaul
70cf3e1f7c
Make constants final classes instead of interfaces
...
This commit prohibits implementation of the empty interface and
instantiation of the class. Refer to _Effective Java_ item 19 for
more background.
2014-05-16 09:45:52 -07:00
Andrew Gaul
8d51ad6f87
Prefer Guava HttpHeaders over JAX-RS
...
jclouds code contains more instances of the former and Guava has
additional constants like CONTENT_MD5.
2014-05-15 01:55:51 -07:00
Andrew Gaul
7f28dcef07
Remove deprecation from getConsistencyModel
...
This method informs callers of the expected blobstore behavior,
avoiding unnecessary work for providers which support strict
consistency (Azure, mock blobstores).
2014-05-09 13:20:42 -07:00
Andrew Gaul
2d88f5164e
Enforce that all commas have trailing whitespace
2014-05-08 18:28:08 -07:00
Andrew Gaul
a45124c51a
JCLOUDS-505: Remove unused ObjectMD5
...
The only users of this seem to be
org.jclouds.atmos.blobstore.strategy.FindMD5InUserMetadata and
org.jclouds.azureblob.blobstore.strategy.FindMD5InBlobProperties which
are themselves unused.
2014-05-07 10:16:18 +02:00
Shri Javadekar
c6cb169dee
Creating a separate function to delete directories
...
Small refactoring to reuse some code.
2014-04-22 11:22:13 +02:00
Shri Javadekar
655aa444d7
JCLOUDS-510 Delete objects in a container efficiently.
...
The existing approach for deleting objects in a container suffers
from a head-of-line blocking problem. This commit implements a better
scheme which does not have that problem. This scheme uses a counting
semaphore for making sure that a certain number of futures are
issued in parallel. As each of these futures is completed, one
permit of the semaphore is released.
Added unit tests for testing this new scheme.
2014-03-26 13:48:28 -07:00
Andrew Gaul
d7e0b3b10c
Remove WriteTo
...
Guava helpers capture this functionality in a more idiomatic way.
2014-02-21 17:13:31 -08:00
Andrew Gaul
9a1aae8cfc
JCLOUDS-410: Remove StreamingPayload
...
Only two tests use this class. Callers should use ByteSourcePayload
or InputStreamPayload instead.
2014-02-19 21:27:31 -08:00
Andrew Gaul
f5c9a72243
Add ByteSource Payload support for Clojure
2014-02-19 21:09:55 -08:00
Andrew Gaul
c7b0f66544
Replace calls to Closeables.closeQuietly
...
Guava 16 removes this API. Replace with Closeables2.closeQuietly.
References JCLOUDS-413 and JCLOUDS-415.
2013-12-21 12:30:59 -08:00
Andrew Gaul
d25e972344
JCLOUDS-401. Make BlobName Function type-safe
2013-12-16 15:04:14 -08:00
Andrew Gaul
ac06e32e72
JCLOUDS-399: Deprecate BlobBuilder.calculateMD5
...
Callers should instead call BlobBuilder.contentMD5, usually with the
results from Guava Hashing.md5(). This narrows the API and removes a
strange IOException from callers.
2013-12-16 13:40:38 -08:00
Andrew Gaul
e48d4985ea
JCLOUDS-410. Add support for ByteSource Payloads
...
Also deprecate byte[], File, InputSupplier<InputStream>, and String
Payloads. Callers should instead provide a ByteSource via
ByteSource.wrap(byte[]) and Files.asByteSource(File)
2013-12-16 13:06:30 -08:00
Andrew Gaul
828d8790c2
Enforce no unused imports via Checkstyle
...
Removed with:
mvn checkstyle:checkstyle --quiet -Dcheckstyle.output.file=/dev/stdout -Dcheckstyle.output.format=plain | tac | while read i; do echo $i | sed -n 's/\([^:]*\):\([^:]*\):.*/sed -i \2d \1/p' | bash; done
2013-12-11 17:27:43 -08:00
Andrew Gaul
7d20658b02
JCLOUDS-334. Return URI only if container created
...
This allows us to honor the BlobStore.createContainerInLocation
interface and gives consistency with other providers.
2013-10-08 13:03:55 -07:00
Andrew Gaul
5f8961723f
Remove BlobStore Map abstractions
...
These provide little end-user benefit and make evolving the core API
more difficult. We deprecated these in 1.6.0.
2013-09-25 20:46:31 -07:00
Andrew Gaul
3ad6b275d4
Run some filesystem integration tests
...
Previously no integration tests ran, now we see:
Tests run: 43, Failures: 0, Errors: 0, Skipped: 8
2013-09-04 13:26:46 -07:00
Andrew Gaul
d387a25113
Enforce a non-negative content length
2013-08-26 20:20:49 -04:00
Andrew Gaul
86147cd961
Remove AsyncBlobStore from DeleteAllKeysInList
...
We deprecated AsyncBlobStore in 1.6.0. Subsequent commits will
require the caller to provide an ExecutorService.
2013-06-05 10:41:55 -07:00
Andrew Gaul
64e9a4e4c6
Remove Strings2.replaceAll(String, char, String)
...
String.replace(String, String) serves this purpose better.
2013-06-03 14:41:18 -07:00
adriancole
ed2f18a1af
JCLOUDS-31. updated to ASF headers via mvn com.mycila.maven-license-plugin:maven-license-plugin:format
2013-05-16 21:30:37 -07:00
Andrew Bayer
7923009eb5
JCLOUDS-37. Fix RAT violations in incubator-jclouds, master branch
2013-05-13 19:17:50 -07:00
Andrew Gaul
04fad88fd3
Remove duplicate Utils getters
...
Rename callers as required.
2013-04-12 16:24:37 -07:00
adriancole
fbe9f945e7
rename bindMappedApi -> bindSyncToAsyncApi
2013-04-10 08:57:32 -07:00
adriancole
61067d3683
Deprecated remaining code related to RestContext, RestApiMetadata, and RestClientModule for ApiContext, HttpApiMetadata, HttpApiModule
2013-04-09 22:07:43 -07:00
adriancole
f56da43db1
deprecated blobstore interfaces that imply complex internal code
2013-04-09 14:37:34 -07:00
Andrew Gaul
15f4d041b4
Parameterize max errors for clear container
...
Also use setter injection for max request time.
2013-03-29 13:36:57 -07:00
Andrew Gaul
faf6b2f39e
Prohibit null and empty blob names in BlobBuilder
2013-02-27 11:36:29 -08:00
Andrew Gaul
ec4cdfda05
Address FindBugs complaints
2013-02-22 09:29:22 -08:00
Andrew Gaul
b51ce5994a
Expose resource creation date
2013-02-18 11:26:44 -08:00
Andrew Gaul
3734fe8100
Replace unneeded Function with imperative approach
...
The latter is more concise, faster, and compact. .class size in bytes
before:
LocalAsyncBlobStore$5.class 1883
LocalAsyncBlobStore.class 20743
and after:
LocalAsyncBlobStore.class 21041
2013-02-05 10:20:24 -08:00
adriancole
40d9f8bfe7
changes that facilitate synchronous fallbacks and http invocation
2013-01-29 04:09:45 -08:00
Andrew Gaul
60a7d1b4f8
Call BlobUtils.clearContainer directly
...
BaseAsyncBlobStore.clearContainer returns a Future which we previously
did not manage correctly, hanging when deleting non-existent
containers. Call BlobUtils.clearContainer directly to address this.
2013-01-23 22:27:18 -08:00
Adrian Cole
b890e1d36b
Merge pull request #1218 from maginatics/delete-container-skip-exponential-backoff
...
Skip exponential backoff if we exceed maxErrors
2013-01-21 19:59:44 -08:00
Andrew Gaul
25b012587d
Skip exponential backoff if we exceed maxErrors
2013-01-21 18:22:41 -08:00
Adrian Cole
37e587ee51
changes related to centralizing construction of invokables
2013-01-19 17:17:30 -08:00