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
TEIIDSB 211 spring data s3 #267
TEIIDSB 211 spring data s3 #267
Conversation
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.
Looking good. I think we can go ahead and implement the encryption logic as well.
The encryption configuration property should default to AES256 - it should probably be renamed sseAlgorithm. Similarly encryptionKey should be re-named sseKey.
In S3VirtualFile s3Client.getObject(summary.getBucketName(), summary.getKey()); - can take a GetObjectRequest instead. If the key is set, you can then set that and the algorithm there.
In the existing implementation that's only on getFile. It must happen automatically on save on the server side.
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.
Once this commited are we going to remove the current amazon-s3
or not?
data/s3/src/main/java/org/teiid/spring/data/s3/S3Configuration.java
Outdated
Show resolved
Hide resolved
Like the getObject method takes a getObjectRequest, likewise the putObject also takes a putObjectRequest where we can set the key and corresponding algorithm! I've added the functionality at both the places! |
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.
Great. It makes more sense for it to be symmetrical.
data/s3/src/main/java/org/teiid/spring/data/s3/S3Configuration.java
Outdated
Show resolved
Hide resolved
@shawkins I spent the day pretty much figuring out how to test using mockito. In the testGetFiles(), I was getting this error: Also, this error might show up because:
Can you help me, what I'm doing wrong? And also, see that If I've structured the test well or it is supposed to be some other way? |
d3cbe3b
to
f389a24
Compare
I've figured out the problem. I think it's good now. Suggest changes if any!! |
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.
lgtm
@aditya300899 were there any additional commits that you were going to make, such as minor cleanups of the tests like removing Assert.assertTrue(true), etc.? I can also do that with the porting to WildFly if you haven't already made those changes. |
I thought maybe you'd have more suggestions later, thus did not commit. Also, I was to think about the code coverage of a test by using some support in IntelliJ! I would do this later now.
|
No description provided.