New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
JCLOUDS-1590: Promote glacier to core #127
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The Glacier client can create, delete, read, and list vaults.
… code for clarity.
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//'
…eturn false on any IllegalArgumentException.
Now the live tests are not conditioned by the current state of the account used.
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.
Also ensure that we close the InputStream.
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.
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.
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.
Now the Glacier client supports initiateMultipartUpload and uploadPart operations.
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.
Now the Glacier client supports completeMultipartUpload and i abortMultipartUpload operations.
Use these annotations to initialize before every test. BeforeTest and AfterTest initialize once before a single test in this suite.
Added listParts and listMultipartUploads operations to the Glacier client.
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.
Now the Glacier client supports the initiateJob operation.
The binder classes were making unnecessary checks. They have been cleaned up.
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.
Now Glacier client supports the describeJob operation.
Now the Glacier client supports the listJobs operation.
Now the Glacier client can retrieve data.
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.
It is currently throwing UnsupportedOperationException exception.
Found via error-prone.
Not yet implemented.
Enable for Glacier.
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).
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.
This can cause thread visibility issues. Found via error-prone.
- from 2.2.0-SNAPSHOST to 2.2.0-SNAPSHOT
This project, the aws-lab version of Apache JClouds, share the exact build instructions as the primary Apache JClouds project with all its modules. Apache JClouds is shifting its strategy in handling OSGi configuration. Instead of using the Maven Bundle Plugin, a wrapper of the BND plugin, the BND plugin gets used directly. - Remove the OSGi configuration from each module. The configuration gets served to the BND through dedicated configuration / bnd files. - Onboard bnd-configuration files, one per module. Ignore bnd files in rat plugin
The JClouds project module upgrades the okhttp server library and related dependencies such as mockwebserver from 2.2.0 to 3.14.9. The vendor switched the groupId declaration from com.squareup.okhttp to com.squareup.okhttp3. Adjust imports and api calls for newer okhttp vers
This addresses a critical CVE: https://logging.apache.org/log4j/2.x/security.html
…moved' into promoted-glacier
nacx
approved these changes
Dec 17, 2021
apis/glacier/pom.xml
Outdated
Comment on lines
45
to
70
<repositories> | ||
<repository> | ||
<id>apache-snapshots</id> | ||
<url>https://repository.apache.org/content/repositories/snapshots</url> | ||
<releases> | ||
<enabled>false</enabled> | ||
</releases> | ||
<snapshots> | ||
<enabled>true</enabled> | ||
</snapshots> | ||
</repository> | ||
</repositories> | ||
|
||
<!-- For modernizer, which depends on jclouds-resources snapshot. --> | ||
<pluginRepositories> | ||
<pluginRepository> | ||
<id>apache-snapshots</id> | ||
<url>https://repository.apache.org/content/repositories/snapshots</url> | ||
<releases> | ||
<enabled>false</enabled> | ||
</releases> | ||
<snapshots> | ||
<enabled>true</enabled> | ||
</snapshots> | ||
</pluginRepository> | ||
</pluginRepositories> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should probably remove this from here and just inherit these settings?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
gaul
force-pushed
the
promoted-glacier
branch
from
December 17, 2021 15:11
eec9385
to
3bbb0b4
Compare
nacx
approved these changes
Dec 17, 2021
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.