Skip to content

Conversation

@trixpan
Copy link
Contributor

@trixpan trixpan commented Jul 18, 2017

Thank you for submitting a contribution to Apache NiFi.

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 NIFI-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 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 nifi-assembly?
  • If applicable, have you updated the NOTICE file, including the main NOTICE file found under nifi-assembly?
  • If adding new Properties, have you added .displayName in addition to .name (programmatic access) for each of the new properties?

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.

Copy link
Contributor

@pvillard31 pvillard31 left a comment

Choose a reason for hiding this comment

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

Hey @trixpan. Just had a quick look and left two comments.

);
// Check if Username is set and populate the proxy accordingly
if (ctx.getProperty(PROXY_USERNAME).evaluateAttributeExpressions(flowFile).isSet()) {
proxy.setUserPasswd(ctx.getProperty(PROXY_USERNAME).evaluateAttributeExpressions(flowFile).getValue(), ctx.getProperty(PROXY_PASSWORD).evaluateAttributeExpressions(flowFile).getValue());
Copy link
Contributor

Choose a reason for hiding this comment

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

[WARNING] src/main/java/org/apache/nifi/processors/standard/util/SFTPTransfer.java[445] (sizes) LineLength: Line is longer than 200 characters (found 206).

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Hmmm... missed that one. Will fix.

.defaultValue("true")
.required(true)
.build();
public static final PropertyDescriptor PROXY_HOST = new PropertyDescriptor.Builder()
Copy link
Contributor

Choose a reason for hiding this comment

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

I'm wondering if, since FileTransfer is only used for FTP and SFTP, it would make sens to move the proxy-related properties to FileTransfer instead of duplicating code. I believe, as far as I can see, that we could use the existing properties in FTPTransfer for SFTPTransfer as well with HTTP Proxy and SOCK proxy. Thoughts?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@pvillard31 I saw that and considered it but ended up adopting the current approach due to my view that I prefer not supporting SOCKS ... Don't get me wrong, I appreciate the reason why SOCKS exists but most processors are only able to support HTTP so I rather provide... consistency (I know I have been sounding repetitive lately... 😄 )

Since FTP already supports SOCKS I reckon we can leave it there, but for SFTP I rather not add it at all.

Let me know if you agree and I will adjust accordingly.

Copy link
Contributor

Choose a reason for hiding this comment

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

I honestly don't have any opinion on this subject but I agree that if we do not add SOCKS option to SFTP processors, then it's OK to have the corresponding properties in SFTPTransfer.

Copy link
Contributor

Choose a reason for hiding this comment

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

Hi,
We would really like to see that the development goes into the direction that SOCKS Proxy with authentication will also be available.
In many bigger companies it is a basic requirement and for us it is not possible to provide those parameters through the -D Options as mentioned in this comment: https://community.hortonworks.com/questions/30339/how-to-configure-proxy-server-details-with-user-an.html
As JSCH offers all the possibilities and a reference implementation it should be possible to integrate it and broaden the functionality of Nifi and thus make it more attractive to companies.
Please feel free to discuss my opinion.
Best regards

ijokarumawak pushed a commit to ijokarumawak/nifi that referenced this pull request May 16, 2018
This closes apache#2018.

Signed-off-by: Koji Kawamura <ijokarumawak@apache.org>
@ijokarumawak
Copy link
Member

@trixpan Since this PR is really close to get merged, but got inactive, and I have another PR tackling the same theme, I have merged your commit into my PR in #2704. SOCKS proxy support is also added there. When #2704 is merged successfully after being reviewed, this PR will be closed, too.

I hope continuing work at #2704 would be fine for you. Please let me know if not the case.

@trixpan @pvillard31 @jugi92 would you please take a look on #2704 and post any feedback there, thanks!

ijokarumawak pushed a commit to ijokarumawak/nifi that referenced this pull request May 16, 2018
This closes apache#2018.

Signed-off-by: Koji Kawamura <ijokarumawak@apache.org>
ijokarumawak pushed a commit to ijokarumawak/nifi that referenced this pull request May 17, 2018
This closes apache#2018.

Signed-off-by: Koji Kawamura <ijokarumawak@apache.org>
ijokarumawak pushed a commit to ijokarumawak/nifi that referenced this pull request May 17, 2018
This closes apache#2018.

Signed-off-by: Koji Kawamura <ijokarumawak@apache.org>
ijokarumawak pushed a commit to ijokarumawak/nifi that referenced this pull request May 17, 2018
This closes apache#2018.

Signed-off-by: Koji Kawamura <ijokarumawak@apache.org>
@asfgit asfgit closed this in 2834fa4 May 20, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants