-
Notifications
You must be signed in to change notification settings - Fork 2.8k
NIFI-5442 Get X-ProxyContextPath value from request attributes rather… #2908
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
Conversation
… than directly from headers.
Verified that the curl request in the ticket is no longer successful. |
In addition to verifying the |
@danfike I don't have an instance running right now which is set up with a proxy. I can run a remote debugger and verify an artificial proxy path in the response. What is an example of what you would expect the outcome to be? |
I can observe that passing a valid (whitelisted in nifi.properties: |
I actually also don't have an instance set up with a proxy either. I've just been directly poking a simple unsecured NiFi instance (without a proxy) using I guess I'd expect it to work like If I add I'd expect requests that use (I'd embed the full shell text illustrating this but I don't have that available at this moment). I poked around this issue a bit earlier today. I thought I tried exactly your fix (on top of 1.6.0 stable) and discovered that all message page renders were failing because of It looked to me like we'd need to add something to Line 805 in 46ce7aa Lines 52 to 53 in 46ce7aa
But I'm not sure. And perhaps there are other references to the message page that this wouldn't address. |
Ok, I think I understand. When I do a remote debug, the |
…e before displaying on message-page.jsp. Refactored shared code from CatchAllFilter to WebUtils.
Hi @danfike ; I was away from my computer for a few days but should have the fix for what you described. Please verify that the new commit does what you expect. Thanks. |
@alopresto I'm not able to validate right now, but @patwhitey2007 has agreed to take a look for me. |
I believe there are some other locations in the code that forward requests to This PR is not ready to be merged. |
…lter and subclass.
This PR is now ready for final review. |
Trying again to @mention Pat, whose ID I got wrong earlier, @mcg30005 |
Thanks very much @alopresto and @danfike, and apologies Dan, my bad with the id info. Andy, thanks again for looking at this, much appreciated. i will try to get a review in today. |
+1 |
+1 |
Thanks for the PR! I'm happy to help get this merged in. I tried out the proposed patch locally and it does address the issue in the case identified. However, I tried to run in some of the other context and the filter was not running as expected. Adding a dispatcher type of FORWARD on the |
Thanks Matt. Made the change locally and verifying before pushing. This seems to be a change in how the filters were invoked from the 2.3 spec, so thanks for identifying it. |
…ed unnecessary code from AccessResource.
@alopresto I'm a +1 with the addition of the most recent commit. I'll wait until tomorrow to merge it in just in case anyone else engaged here [@danfike @mcg30005] wants to check it out. |
Thanks again for the PR and reviews! This has been merged to master. |
Thanks a lot folks, much appreciated! |
… than directly from headers.
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:
For documentation related changes:
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.