jclouds-labs-aws.git
10 months agofix typo in project.version master
andreaturli [Wed, 21 Feb 2018 15:57:09 +0000 (16:57 +0100)] 
fix typo in project.version

- from 2.2.0-SNAPSHOST to 2.2.0-SNAPSHOT

11 months agoNext development version 2.2.0-SNAPSHOST
andreaturli [Fri, 16 Feb 2018 10:29:15 +0000 (11:29 +0100)] 
Next development version 2.2.0-SNAPSHOST

11 months agoApache jclouds 2.1.0-rc3 release rel/jclouds-labs-aws-2.1.0 rel/jclouds-labs-aws-2.1.0-rc3
andreaturli [Fri, 16 Feb 2018 10:28:53 +0000 (11:28 +0100)] 
Apache jclouds 2.1.0-rc3 release

16 months agoAvoid injecting on final fields
Andrew Gaul [Tue, 29 Aug 2017 04:13:54 +0000 (21:13 -0700)] 
Avoid injecting on final fields

This can cause thread visibility issues.  Found via error-prone.

22 months agoRemove all sonatype snapshot repositories
Ignasi Barrera [Wed, 1 Mar 2017 10:58:59 +0000 (11:58 +0100)] 
Remove all sonatype snapshot repositories

23 months ago- added subnet api
Justin Thompson [Fri, 27 Jan 2017 17:00:07 +0000 (17:00 +0000)] 
- added subnet api
    - added new binders
    - added new methods to the load balancer api
    - renamed availabilityZoneResultHandler to more generic MemberResultHandler
    - updated jclouds version to 2.1.0
    - added BaseELBApiMockTest
    - added subnet mock test
    - added com.squareup.okhttp dependency for mock tests
    - removed checkNotNull on policyType description because this field is not always present
    - made some of the tests signle threaded
    - updated BindSubnetIdsToIndexedFormParams for readability
    - added subnet live test

2 years agoNext development version 2.1.0-SNAPSHOT
Ignasi Barrera [Tue, 15 Nov 2016 00:13:00 +0000 (01:13 +0100)] 
Next development version 2.1.0-SNAPSHOT

2 years agoApache jclouds 2.0.0-rc3 release rel/jclouds-labs-aws-2.0.0 rel/jclouds-labs-aws-2.0.0-rc3
Ignasi Barrera [Wed, 9 Nov 2016 21:47:20 +0000 (22:47 +0100)] 
Apache jclouds 2.0.0-rc3 release

2 years agoAvoid C-style array declarations
Andrew Gaul [Sun, 23 Oct 2016 20:50:13 +0000 (13:50 -0700)] 
Avoid C-style array declarations

Found via error-prone.

2 years agoAdd a system setting for Glacier's initial wait.
Timur Alperovich [Mon, 4 Jul 2016 23:26:35 +0000 (16:26 -0700)] 
Add a system setting for Glacier's initial wait.

Glacier has an initial wait parameter, which is used to check on the
progress of a job. By default, it is set to 3 hours. This may work
well against existing AWS Glacier interface, however, against a
Glacier emulator the timeout should be overriden. The change allows
setting the timeout to an arbitrary shorter value with
-Dtest.glacier.initial-wait.

2 years agoDo not assume an endpoint in tests.
Timur Alperovich [Mon, 4 Jan 2016 00:39:02 +0000 (16:39 -0800)] 
Do not assume an endpoint in tests.

jclouds should not assume a particular endpoint when running glacier
tests, as it's possible that a glacier emulator is used (e.g.
glacier-proxy).

2 years agoJCLOUDS-1028: Configure idempotent methods
Andrew Gaul [Wed, 15 Jun 2016 23:37:53 +0000 (16:37 -0700)] 
JCLOUDS-1028: Configure idempotent methods

Enable for Glacier.

2 years agoJCLOUDS-1125: Glacier list multipart uploads
Andrew Gaul [Mon, 13 Jun 2016 23:33:01 +0000 (16:33 -0700)] 
JCLOUDS-1125: Glacier list multipart uploads

Not yet implemented.

2 years agoRemove unnecessary static imports
Andrew Gaul [Fri, 29 Jan 2016 17:21:08 +0000 (09:21 -0800)] 
Remove unnecessary static imports

Found via error-prone.

3 years agoAdd support for GlacierBlobStore.getBlobAccess
Rita Zhang [Tue, 5 Jan 2016 23:48:23 +0000 (15:48 -0800)] 
Add support for GlacierBlobStore.getBlobAccess
It is currently throwing UnsupportedOperationException exception.

3 years agoJCLOUDS-844: Glacier putBlob ACLs
Andrew Gaul [Tue, 22 Dec 2015 07:23:32 +0000 (23:23 -0800)] 
JCLOUDS-844: Glacier putBlob ACLs

3 years agoJCLOUDS-217: AWS IAM: Do not use encoded params
Andrew Gaul [Tue, 8 Sep 2015 23:51:58 +0000 (16:51 -0700)] 
JCLOUDS-217: AWS IAM: Do not use encoded params

3 years agoJCLOUDS-894: Fake portable multipart upload for Glacier
Andrew Gaul [Mon, 8 Jun 2015 05:50:38 +0000 (22:50 -0700)] 
JCLOUDS-894: Fake portable multipart upload for Glacier

3 years agoJCLOUDS-894: Expose GCS multipart operations
Andrew Gaul [Fri, 1 May 2015 20:30:45 +0000 (13:30 -0700)] 
JCLOUDS-894: Expose GCS multipart operations

Not yet implemented

3 years agoAddress Google error-prone warnings
Andrew Gaul [Tue, 31 Mar 2015 02:03:39 +0000 (19:03 -0700)] 
Address Google error-prone warnings

3 years agoNext development version 2.0.0-SNAPSHOT
Ignasi Barrera [Tue, 24 Mar 2015 10:05:08 +0000 (11:05 +0100)] 
Next development version 2.0.0-SNAPSHOT

3 years agoApache jclouds 1.9.0 release jclouds-labs-aws-1.9.0 jclouds-labs-aws-1.9.0-rc2
Ignasi Barrera [Tue, 24 Mar 2015 10:03:53 +0000 (11:03 +0100)] 
Apache jclouds 1.9.0 release

3 years agoRevert jclouds.version bump
Ignasi Barrera [Sat, 14 Mar 2015 23:21:32 +0000 (00:21 +0100)] 
Revert jclouds.version bump

3 years ago[maven-release-plugin] rollback the release of jclouds-labs-aws-1.9.0-rc1
Ignasi Barrera [Sat, 14 Mar 2015 22:41:49 +0000 (23:41 +0100)] 
[maven-release-plugin] rollback the release of jclouds-labs-aws-1.9.0-rc1

3 years ago[maven-release-plugin] prepare for next development iteration
Ignasi Barrera [Sat, 14 Mar 2015 22:36:56 +0000 (23:36 +0100)] 
[maven-release-plugin] prepare for next development iteration

3 years ago[maven-release-plugin] prepare release jclouds-labs-aws-1.9.0-rc1
Ignasi Barrera [Sat, 14 Mar 2015 22:36:56 +0000 (23:36 +0100)] 
[maven-release-plugin] prepare release jclouds-labs-aws-1.9.0-rc1

3 years agoFixed jclouds.version property to the release version
Ignasi Barrera [Sat, 14 Mar 2015 20:44:10 +0000 (21:44 +0100)] 
Fixed jclouds.version property to the release version

3 years agoJCLOUDS-732: Glacier portable object ACLs
Andrew Gaul [Sat, 21 Feb 2015 18:39:46 +0000 (10:39 -0800)] 
JCLOUDS-732: Glacier portable object ACLs

Not implemented for Glacier.

3 years agoJCLOUDS-660: Glacier portable container ACLs
Andrew Gaul [Fri, 13 Feb 2015 02:30:29 +0000 (18:30 -0800)] 
JCLOUDS-660: Glacier portable container ACLs

Not implemented for Glacier.

3 years agoFixed the CONTRIBUTING links
Ignasi Barrera [Thu, 5 Feb 2015 14:12:59 +0000 (15:12 +0100)] 
Fixed the CONTRIBUTING links

4 years agoUse AutoService for creation of Service Loader Metadata
Jeremy Daggett [Tue, 9 Dec 2014 23:06:15 +0000 (15:06 -0800)] 
Use AutoService for creation of Service Loader Metadata

4 years agoFixed ambiguous methods in tests
Jeremy Daggett [Mon, 8 Dec 2014 19:51:26 +0000 (11:51 -0800)] 
Fixed ambiguous methods in tests

4 years agoUpgrade to OkHttp 2.1.0
Ignasi Barrera [Thu, 27 Nov 2014 10:33:25 +0000 (11:33 +0100)] 
Upgrade to OkHttp 2.1.0

4 years agoJCLOUDS-534 Avoid runtime incompatibility introduced by Guava's closeQuietly.
Adrian Cole [Mon, 27 Oct 2014 16:07:55 +0000 (09:07 -0700)] 
JCLOUDS-534 Avoid runtime incompatibility introduced by Guava's closeQuietly.

4 years agoRevert "JCLOUDS-653: Address Guava 18 deprecations"
Adrian Cole [Fri, 24 Oct 2014 02:50:46 +0000 (19:50 -0700)] 
Revert "JCLOUDS-653: Address Guava 18 deprecations"

This reverts commit 710a7784eae58129a7796ac06c5e7b1d231ab4cf.

4 years agoJCLOUDS-40 unasync Fallback.
Adrian Cole [Mon, 6 Oct 2014 20:42:44 +0000 (13:42 -0700)] 
JCLOUDS-40 unasync Fallback.

4 years agoRevert "Fix poms so that modernizer doesn't fail on snapshot."
Andrew Phillips [Sun, 5 Oct 2014 22:52:00 +0000 (18:52 -0400)] 
Revert "Fix poms so that modernizer doesn't fail on snapshot."

This reverts commit 70a3a4f86c82bf2e7b112de1599062141b46b120. The
snapshot repository has now been added to the jclouds-project POM.
See commit 79d4b48 to jclouds/jclouds.

4 years agoFix poms so that modernizer doesn't fail on snapshot.
Adrian Cole [Sun, 5 Oct 2014 18:07:33 +0000 (11:07 -0700)] 
Fix poms so that modernizer doesn't fail on snapshot.

4 years agoJCLOUDS-40 Remove last reference to AsyncBlobStore in Glacier.
Adrian Cole [Sun, 5 Oct 2014 17:57:54 +0000 (10:57 -0700)] 
JCLOUDS-40 Remove last reference to AsyncBlobStore in Glacier.

4 years agoJCLOUDS-40 unasync glacier.
Adrian Cole [Sat, 4 Oct 2014 06:16:46 +0000 (23:16 -0700)] 
JCLOUDS-40 unasync glacier.

4 years agoFix glacier's pom structure.
Adrian Cole [Sat, 4 Oct 2014 17:53:24 +0000 (10:53 -0700)] 
Fix glacier's pom structure.

4 years agoAdd missing @Override annotations
Andrew Gaul [Mon, 1 Sep 2014 02:49:03 +0000 (19:49 -0700)] 
Add missing @Override annotations

4 years agoRemove redundant modifiers from interfaces
Andrew Gaul [Fri, 29 Aug 2014 02:50:02 +0000 (19:50 -0700)] 
Remove redundant modifiers from interfaces

4 years agoRemove maven-license-plugin
Andrew Gaul [Mon, 11 Aug 2014 17:43:47 +0000 (10:43 -0700)] 
Remove maven-license-plugin

This never seemed to work and we will enforce license text via
Checkstyle instead.

4 years agoCorrect license headers
Andrew Gaul [Sun, 10 Aug 2014 05:51:08 +0000 (22:51 -0700)] 
Correct license headers

4 years agoJCLOUDS-457: Extend javadoc and add README.md
Roman Coedo [Fri, 1 Aug 2014 13:27:40 +0000 (15:27 +0200)] 
JCLOUDS-457: Extend javadoc and add README.md

Added more javadoc documentation. This covers the basics of the
provider.

4 years agoJCLOUDS-653: Address Guava 18 deprecations
Andrew Gaul [Thu, 7 Aug 2014 00:08:44 +0000 (17:08 -0700)] 
JCLOUDS-653: Address Guava 18 deprecations

Mostly renaming Objects.toStringHelper to MoreObjects.toStringHelper.

4 years agoReset StringBuilder instead of creating new ones
Andrew Gaul [Wed, 6 Aug 2014 18:26:44 +0000 (11:26 -0700)] 
Reset StringBuilder instead of creating new ones

This avoids unneeded garbage, especially during XML parsing.  Replaced
with:

find -name \*.java | xargs sed -i 's/^\( *[^ ]*\) = new StringBuilder();$/\1.setLength(0);/'

4 years agoJCLOUDS-457: Implementing getBlob without options
Roman Coedo [Sun, 3 Aug 2014 21:27:06 +0000 (23:27 +0200)] 
JCLOUDS-457: Implementing getBlob without options

The missing getBlob implementation has been added.

4 years agoUpdating project and jclouds.version to 2.0.0-SNAPSHOT
Andrew Phillips [Tue, 5 Aug 2014 09:28:15 +0000 (11:28 +0200)] 
Updating project and jclouds.version to 2.0.0-SNAPSHOT

Follow-up to 8fba1f2

4 years agoUp to 2.0.0-SNAPSHOT after the 1.8.0 release
Andrew Phillips [Tue, 5 Aug 2014 08:37:58 +0000 (10:37 +0200)] 
Up to 2.0.0-SNAPSHOT after the 1.8.0 release

4 years agoAdd .mailmap
Andrew Gaul [Tue, 5 Aug 2014 06:01:44 +0000 (23:01 -0700)] 
Add .mailmap

4 years agoFollow-up to Glacier pull request reviews
Roman Coedo [Sat, 2 Aug 2014 09:08:07 +0000 (11:08 +0200)] 
Follow-up to Glacier pull request reviews

* updating Javadocs
* minor style changes

4 years agoUpdating documentation and a configuration property name
Roman Coedo [Mon, 28 Jul 2014 15:04:55 +0000 (17:04 +0200)] 
Updating documentation and a configuration property name

Follow-on from 95d9b00

4 years agoJCLOUDS-457: Small fixes and documentation
Roman Coedo [Mon, 28 Jul 2014 07:49:25 +0000 (09:49 +0200)] 
JCLOUDS-457: Small fixes and documentation

Now the BlobStore and the strategy implementations are annotated with @Singleton.

Added a small documentation to the blobstore classes.

4 years agoJCLOUDS-457: Fix deleteContainer
Roman Coedo [Mon, 28 Jul 2014 06:13:48 +0000 (08:13 +0200)] 
JCLOUDS-457: Fix deleteContainer

The ClearVaultStrategy now ignores ResourceNotFound exceptions.

deleteContainer now tries to delete the vault first to avoid long waits.
If the delete request fails, retries it every 24 hours.

4 years agoJCLOUDS-457: Add Clear vault strategy
Roman Coedo [Sat, 26 Jul 2014 10:12:29 +0000 (12:12 +0200)] 
JCLOUDS-457: Add Clear vault strategy

Added a proper implementation to the Clear vault strategy

4 years agoJCLOUDS-457: Add blobExists and blobMetadata
Roman Coedo [Wed, 23 Jul 2014 22:51:29 +0000 (00:51 +0200)] 
JCLOUDS-457: Add blobExists and blobMetadata

Now the BlobStore abstraction supports the blobExists and the
blobMetadata operations.

4 years agoJCLOUDS-457: Add list operation
Roman Coedo [Wed, 23 Jul 2014 21:55:19 +0000 (23:55 +0200)] 
JCLOUDS-457: Add list operation

Now the BlobStore abstraction supports the list Operation

4 years agoJCLOUDS-457: Add getBlob operation
Roman Coedo [Wed, 23 Jul 2014 21:53:09 +0000 (23:53 +0200)] 
JCLOUDS-457: Add getBlob operation

Now the BlobStore abstraction supports the getBlob Operation

4 years agoJCLOUDS-457: Add polling strategy
Roman Coedo [Tue, 22 Jul 2014 11:16:04 +0000 (13:16 +0200)] 
JCLOUDS-457: Add polling strategy

The polling strategy interface for job operations
and a simple implementation class have been added.
This implementation waits an initial time and then
polls at regular intervals.

4 years agoJCLOUDS-457: List containers and remove blob
Roman Coedo [Sun, 13 Jul 2014 20:54:23 +0000 (22:54 +0200)] 
JCLOUDS-457: List containers and remove blob

List containers and remove blob operations have
been added.

4 years agoJCLOUDS-457: Long live tests
Roman Coedo [Sat, 12 Jul 2014 12:08:06 +0000 (14:08 +0200)] 
JCLOUDS-457: Long live tests

The long live tests have been added. These tests takes several
hours and will leave traces in your AWS account.

4 years agoJCLOUDS-457: BlobStore MultiPartUpload strategy
Roman Coedo [Fri, 18 Jul 2014 23:47:14 +0000 (01:47 +0200)] 
JCLOUDS-457: BlobStore MultiPartUpload strategy

The code related to the MultiPartUpload strategy has been added.
MultiPart uploads use an upload strategy (e.g. sequential vs parallel)
and also a slicing strategy to split the payload in different parts.

4 years agoJCLOUDS-457: Fix complete MPU archive size
Roman Coedo [Sun, 13 Jul 2014 10:32:23 +0000 (12:32 +0200)] 
JCLOUDS-457: Fix complete MPU archive size

The completeMultipartUpload operation is taking the archive size
parameter in MB but it should be bytes.

4 years agoJCLOUDS-457: BlobStore Skeleton
Roman Coedo [Sun, 13 Jul 2014 10:22:50 +0000 (12:22 +0200)] 
JCLOUDS-457: BlobStore Skeleton

The Amazon Glacier BlobStore skeleton has been added.

4 years agoJCLOUDS-457: Add JobStatus enum
Roman Coedo [Tue, 15 Jul 2014 21:08:35 +0000 (23:08 +0200)] 
JCLOUDS-457: Add JobStatus enum

Now the job status is stored as an enum instead of
a String. This is useful when comparing the status to
check if a job is completed, failed or still in progress.

4 years agoJCLOUDS-457: Test groups and improvements
Roman Coedo [Sat, 12 Jul 2014 10:28:23 +0000 (12:28 +0200)] 
JCLOUDS-457: Test groups and improvements

Test groups have been added. Also, the live tests were
refactored to reduce the number of RPCs.

4 years agoJCLOUDS-457: uploadPart return type fix
Roman C. Coedo [Thu, 3 Jul 2014 22:25:28 +0000 (00:25 +0200)] 
JCLOUDS-457: uploadPart return type fix

The uploadPart method now returns HashCode instead
of String.

4 years agoUse assertj extraction feature to shorten test
Roman C. Coedo [Thu, 3 Jul 2014 21:50:20 +0000 (23:50 +0200)] 
Use assertj extraction feature to shorten test

4 years agoUsing assertj assertions
Roman C. Coedo [Thu, 3 Jul 2014 14:15:21 +0000 (16:15 +0200)] 
Using assertj assertions

testng assertions have been replaced with assertj
assertions.

4 years agoDefault value for aws identity/credential property
Roman C. Coedo [Wed, 2 Jul 2014 09:35:41 +0000 (11:35 +0200)] 
Default value for aws identity/credential property

Every project was using undefined properties in their pom.xml.
A default value for test.aws.identity and test.aws.credential was
added.

4 years agoExclude the CONTRIBUTING file from the rat check
Ignasi Barrera [Wed, 2 Jul 2014 15:38:47 +0000 (17:38 +0200)] 
Exclude the CONTRIBUTING file from the rat check

4 years agoAdded the CONTRIBUTING file
Ignasi Barrera [Wed, 2 Jul 2014 15:08:32 +0000 (17:08 +0200)] 
Added the CONTRIBUTING file

4 years agoImprove use of assertj
Andrew Gaul [Wed, 2 Jul 2014 05:00:14 +0000 (22:00 -0700)] 
Improve use of assertj

4 years agoUse assertj fluent assertions where appropriate
Andrew Gaul [Sun, 29 Jun 2014 19:33:40 +0000 (12:33 -0700)] 
Use assertj fluent assertions where appropriate

This commit demonstrates a few instances where assertj yields more
informative error messages than testng assertEquals and assertTrue.
Note that we could replace all testng asserts with assertj.

4 years agoJCLOUDS-457: Added the retrieve output operations
Roman C. Coedo [Wed, 25 Jun 2014 20:20:44 +0000 (22:20 +0200)] 
JCLOUDS-457: Added the retrieve output operations

Now the Glacier client can retrieve data.

4 years agoJCLOUDS-457: Added listJobs operation
Roman C. Coedo [Wed, 25 Jun 2014 20:13:28 +0000 (22:13 +0200)] 
JCLOUDS-457: Added listJobs operation

Now the Glacier client supports the listJobs operation.

4 years agoJCLOUDS-457: Added describeJob operation
Roman C. Coedo [Wed, 25 Jun 2014 20:04:36 +0000 (22:04 +0200)] 
JCLOUDS-457: Added describeJob operation

Now Glacier client supports the describeJob operation.

4 years agoJCLOUDS-457: Multiple fixes
Roman C. Coedo [Fri, 27 Jun 2014 07:28:36 +0000 (09:28 +0200)] 
JCLOUDS-457: Multiple fixes

This commit addresses some problems found in the code:

- Now VaultMetadata returns a copy of the creation date instead
of their own instance.

- Added a checkNotNull for PaginatedVaultCollection iterable.

- Added a test for listVaults with an empty list of vaults.

4 years agoJCLOUDS-457: Cleanup for binder classes
Roman C. Coedo [Fri, 27 Jun 2014 07:35:03 +0000 (09:35 +0200)] 
JCLOUDS-457: Cleanup for binder classes

The binder classes were making unnecessary checks. They have
been cleaned up.

4 years agoJCLOUDS-457: Added initiateJob
Roman C. Coedo [Wed, 25 Jun 2014 19:26:12 +0000 (21:26 +0200)] 
JCLOUDS-457: Added initiateJob

Now the Glacier client supports the initiateJob operation.

4 years agoJCLOUDS-457: limit body size for specific test
Roman C. Coedo [Thu, 26 Jun 2014 20:40:56 +0000 (22:40 +0200)] 
JCLOUDS-457: limit body size for specific test

For each test, we were forcing the server to discard the content of
the request body on @BeforeMethod. We need to do this on tests with a
huge body, but it may interfere with other tests which actually use
the body data.  To fix this problem, we moved the body limit
restriction to the tests that require it.

4 years agoBug fix for ContentRange equals
Roman C. Coedo [Wed, 25 Jun 2014 00:21:50 +0000 (02:21 +0200)] 
Bug fix for ContentRange equals

4 years agoJCLOUDS-457: Added list Multipart operations
Roman C. Coedo [Sun, 1 Jun 2014 21:03:29 +0000 (23:03 +0200)] 
JCLOUDS-457: Added list Multipart operations

Added listParts and listMultipartUploads operations to the Glacier
client.

4 years agoJCLOUDS-457: Call BeforeMethod and AfterMethod
Andrew Gaul [Sun, 22 Jun 2014 21:26:02 +0000 (14:26 -0700)] 
JCLOUDS-457: Call BeforeMethod and AfterMethod

Use these annotations to initialize before every test.  BeforeTest and
AfterTest initialize once before a single test in this suite.

4 years agoJCLOUDS-457: Added completeMultipartUpload and abortMultipartUplod.
Roman C. Coedo [Sun, 1 Jun 2014 19:19:25 +0000 (21:19 +0200)] 
JCLOUDS-457: Added completeMultipartUpload and abortMultipartUplod.

Now the Glacier client supports completeMultipartUpload and i
abortMultipartUpload operations.

4 years agoJCLOUDS-457: Clean up for the validators and the TreeHash class.
Roman C. Coedo [Thu, 19 Jun 2014 23:26:48 +0000 (01:26 +0200)] 
JCLOUDS-457: Clean up for the validators and the TreeHash class.

Now the validators use checkArgument instead of throwing an
exception by calling an static method.

There were some missing validators on the Async client, these
were fixed too.

Lastly, TreeHash inner class was removed. Now the factory methods
are in the TreeHash class.

4 years agoJCLOUDS-457: Added initiateMultipartUpload and uploadPart operations.
Roman C. Coedo [Sat, 31 May 2014 14:37:17 +0000 (16:37 +0200)] 
JCLOUDS-457: Added initiateMultipartUpload and uploadPart operations.

Now the Glacier client supports initiateMultipartUpload and
uploadPart operations.

4 years agoUse Square's mockwebserver
Roman C. Coedo [Thu, 19 Jun 2014 01:50:23 +0000 (03:50 +0200)] 
Use Square's mockwebserver

4 years agoJCLOUDS-457: Clean up for GlacierClientMockTest.
Roman C. Coedo [Wed, 18 Jun 2014 23:27:24 +0000 (01:27 +0200)] 
JCLOUDS-457: Clean up for GlacierClientMockTest.

GlacierClientMockTest was growing uncontrollably. This commit
is an attempt to fix this problem.

The first measure taken moves the duplicated strings to constants
and the JSON response bodies to resource files. In addition, some
repeated code was moved to static classes, where they can be reused.

We also use @BeforeTest and @AfterTest to make instances of the
MockWebServer and shut them down for each test.

4 years agoStore hashes as HashCode for type-safety
Andrew Gaul [Mon, 16 Jun 2014 23:46:56 +0000 (16:46 -0700)] 
Store hashes as HashCode for type-safety

4 years agoJCLOUDS-457: Part of the code has been cleaned up
Roman C. Coedo [Tue, 17 Jun 2014 22:36:27 +0000 (00:36 +0200)] 
JCLOUDS-457: Part of the code has been cleaned up

On the last commit we added TestUtils class. On this commit
the VaultNameValidator and the ThreeHashTest tests make use
of it.

GlacierClientMockTest was not using GlacierHeaders references.
This commit fixes this problem too.

In addition, the AWSRequestSignerV4, the TreeHash and the
VaultNameValidator classes are now final.

4 years agoJCLOUDS-457: Added deleteArchive and uploadArchive operations.
Roman C. Coedo [Tue, 17 Jun 2014 22:19:31 +0000 (00:19 +0200)] 
JCLOUDS-457: Added deleteArchive and uploadArchive operations.

Now the Glacier client supports upload and delete archive
operations.

An static TestUtils class has been made for the archive operations
tests. This class allows us to build payloads and build ByteSources.

4 years agoJCLOUDS-457: Changed the ArrayLists in TreeHash util to ImmutableLists.
Roman C. Coedo [Tue, 17 Jun 2014 08:23:34 +0000 (10:23 +0200)] 
JCLOUDS-457: Changed the ArrayLists in TreeHash util to ImmutableLists.

4 years agoAvoid buffering entire input when hashing
Andrew Gaul [Fri, 13 Jun 2014 20:50:42 +0000 (13:50 -0700)] 
Avoid buffering entire input when hashing

Also ensure that we close the InputStream.

4 years agoJCLOUDS-457: Added TreeHash util class and its test.
Roman C. Coedo [Fri, 13 Jun 2014 12:11:30 +0000 (14:11 +0200)] 
JCLOUDS-457: Added TreeHash util class and its test.

The TreeHash class stores two HashCodes, the linear and the
tree HashCode. The TreeHash class also has an static inner class
named Hasher, which allows us to calculate the hashes.

Both Hashes (tree and linear) are needed for the upload archive
and the multipart upload operations. When completing a multipart
upload operation we also need to calculate the tree hash of the
individual part's hashes.

4 years agoJCLOUDS-457: Use random vault names in live tests
Roman C. Coedo [Fri, 13 Jun 2014 12:00:06 +0000 (14:00 +0200)] 
JCLOUDS-457: Use random vault names in live tests

Now the live tests are not conditioned by the current state of the
account used.

4 years agoRenamed FalseIfVaultNotEmpty to be more generic. deleteVault should return false...
Roman C. Coedo [Sat, 31 May 2014 09:58:19 +0000 (11:58 +0200)] 
Renamed FalseIfVaultNotEmpty to be more generic. deleteVault should return false on any IllegalArgumentException.

4 years agoJCLOUDS-546: Remove Javadoc @author annotations
Andrew Gaul [Sun, 8 Jun 2014 04:11:47 +0000 (21:11 -0700)] 
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//'