NIFI-4444:

- Ensure the /nifi-api/controller redirection filter executes before matching.

This closes # 2358.

Signed-off-by: Andy LoPresto <alopresto.apache@gmail.com>
This commit is contained in:
Matt Gilman 2017-12-21 14:54:09 -05:00 committed by Andy LoPresto
parent 482f371958
commit b7c9c88f9f
No known key found for this signature in database
GPG Key ID: 6EC293152D90B61D
1 changed files with 2 additions and 0 deletions

View File

@ -21,6 +21,7 @@ import org.apache.nifi.web.api.SiteToSiteResource;
import javax.ws.rs.container.ContainerRequestContext; import javax.ws.rs.container.ContainerRequestContext;
import javax.ws.rs.container.ContainerRequestFilter; import javax.ws.rs.container.ContainerRequestFilter;
import javax.ws.rs.container.PreMatching;
import javax.ws.rs.core.UriBuilder; import javax.ws.rs.core.UriBuilder;
import javax.ws.rs.core.UriInfo; import javax.ws.rs.core.UriInfo;
import java.io.IOException; import java.io.IOException;
@ -29,6 +30,7 @@ import java.net.URI;
/** /**
* This filter provides backward compatibility for Resource URI changes. * This filter provides backward compatibility for Resource URI changes.
*/ */
@PreMatching
public class RedirectResourceFilter implements ContainerRequestFilter { public class RedirectResourceFilter implements ContainerRequestFilter {
/** /**