Skip to content
This repository has been archived by the owner on May 14, 2021. It is now read-only.

MINIFI-366: Adds S3ConfigurationCache. #90

Closed
wants to merge 1 commit into from
Closed

MINIFI-366: Adds S3ConfigurationCache. #90

wants to merge 1 commit into from

Conversation

jzonthemtn
Copy link
Contributor

This is my attempt at creating an implementation of a ConfigurationCache for S3. I'm happy to get any feedback on it. I tested it by enabling it and settings its properties in minifi-c2-context.xml and by hitting it via curl and MiNiFi's PullHttpChangeIngestor.

Thank you for submitting a contribution to Apache NiFi - MiNiFi.

In order to streamline the review of the contribution we ask you
to ensure the following steps have been taken:

For all changes:

  • Is there a JIRA ticket associated with this PR? Is it referenced
    in the commit message?

  • Does your PR title start with MINIFI-XXXX where XXXX is the JIRA number you are trying to resolve? Pay particular attention to the hyphen "-" character.

  • Has your PR been rebased against the latest commit within the target branch (typically master)?

  • Is your initial contribution a single, squashed commit?

For code changes:

  • Have you ensured that the full suite of tests is executed via mvn -Pcontrib-check clean install at the root nifi-minifi folder?
  • Have you written or updated unit tests to verify your changes?
  • If adding new dependencies to the code, are these dependencies licensed in a way that is compatible for inclusion under ASF 2.0?
  • If applicable, have you updated the LICENSE file, including the main LICENSE file under minifi-assembly?
  • If applicable, have you updated the NOTICE file, including the main NOTICE file found under minifi-assembly?

For documentation related changes:

  • Have you ensured that format looks appropriate for the output in which it is rendered?

Note:

Please ensure that once the PR is submitted, you check travis-ci for build issues and submit an update to your PR as soon as possible.

@apiri
Copy link
Member

apiri commented Oct 5, 2017

reviewing

Copy link
Member

@apiri apiri left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @jzonthemtn,

This is pretty slick. Was able to verify the functionality. I saw that there were a few places where TODOs were listed in terms of digging deeper into the thrown exceptions from AWS. Were you planning on tackling those as well and just forgot about them?

NOTICE looks good and no major qualms with any of the code work that is there. Certainly a nice bit of functionality.

@jzonthemtn
Copy link
Contributor Author

@apiri Thanks for reviewing. I think I must have forgot about leaving those TODOs in there. I will revisit them.

@jzonthemtn
Copy link
Contributor Author

I went back and looked at those TODOs. They were in the S3OutputStream class that I borrowed from Kafka which was borrowed from Hadoop. Since the TODOs mentioned things that are not critical to this functionality I removed them. If a multipart upload fails it throws an exception. I think it should be up to the caller of S3OutputStream to determine if they want to try again instead of the implementation doing it for them. (Maybe even exposed to the use as a configuration setting.) So if this is needed I think it might be best to make a new ticket for it to see the best way of going about it. Let me know what you think!

@apiri
Copy link
Member

apiri commented Nov 14, 2017

@jzonthemtn sorry I missed your comment follow up. let me refresh myself on this and we'll go from there.

@apiri
Copy link
Member

apiri commented Nov 17, 2017

@jzonthemtn Okay, your approach sounds good. Let's create a new ticket and capture that information and clean those items up for now.

Also, from an L&N perspective, are there any NOTICE considerations from the standpoint of including source from Hadoop/Kafka? I couldn't quite trace the path from the link to Hadoop, but seeing as how this would be a source inclusion, would be a consideration.

@jzonthemtn
Copy link
Contributor Author

I also could not find S3OutputStream in Hadoop. I went by the comment in the Kafka version that "The implementation has borrowed the general structure of Hadoop's implementation." So, I added a line to the NOTICE that says S3OutputStream was used from Kafka.

@apiri
Copy link
Member

apiri commented Nov 22, 2017

@jzonthemtn That works for me. Noticed there was a typo in the NOTICE but will correct on merge. Thanks for working through this with me!

@asfgit asfgit closed this in 61d1439 Nov 22, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
2 participants