[
https://issues.apache.org/jira/browse/HADOOP-20007?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Jose Luis López updated HADOOP-20007:
-------------------------------------
Description:
HBase, Hive, Spark, Ozone and Knox compile against hadoop-auth's filters and
{{HttpServer2}}. HADOOP-19912 moves Hadoop to Jetty 12 on the ee8 environment
so that this API keeps {{javax.servlet}} and downstream projects need not
rebuild. That promise should be enforced by a test, not left to review.
h3. Changes
New {{TestDownstreamServletCompatibility}} in hadoop-common, which:
* checks reflectively that the public and protected signatures of that API name
only {{javax.servlet}} types, with no {{jakarta.servlet}} and no
{{org.eclipse.jetty}};
* runs a downstream-style filter and servlet on an {{HttpServer2}} and checks
the response.
New tests in {{TestHttpServer}} pin behaviour a Jetty upgrade could change
silently:
* a redirect's {{Location}} is absolute;
* {{/static}} lists no directory;
* paths with an empty segment, an encoded percent or an encoded backslash reach
the servlet;
* {{/logs}} keeps its admin check when {{hadoop.log.dir}} is missing.
{{HttpServer2}} sets {{relativeRedirectAllowed}} to false explicitly. That is
Jetty 9.4's default, so nothing changes today; Jetty 12's default is true.
The tests pass on trunk (Jetty 9.4), and HADOOP-19972 must keep them green. It
is expected to fail on the day the jakarta move (HADOOP-19395) reaches this
API, which belongs to a major release.
was:
HBase, Hive, Spark, Ozone and Knox compile against hadoop-auth's filters and
{{HttpServer2}}. HADOOP-19912 moves Hadoop to Jetty 12 on the ee8 environment
so that this API keeps {{javax.servlet}} and downstream projects need not
rebuild. That promise should be enforced by a test, not left to review.
h3. Changes
New {{TestDownstreamServletCompatibility}} in hadoop-common, which:
* checks reflectively that the public and protected signatures of that API name
only {{javax.servlet}} types, with no {{jakarta.servlet}} and no
{{org.eclipse.jetty}};
* runs a downstream-style filter and servlet on an {{HttpServer2}} and checks
the response.
The test passes on trunk (Jetty 9.4), and HADOOP-19972 must keep it green. It
is expected to fail on the day the jakarta move (HADOOP-19395) reaches this
API, which belongs to a major release.
Summary: Add tests for the javax.servlet contract and HTTP behaviour
offered to downstream projects (was: Add a test for the javax.servlet contract
offered to downstream projects)
> Add tests for the javax.servlet contract and HTTP behaviour offered to
> downstream projects
> ------------------------------------------------------------------------------------------
>
> Key: HADOOP-20007
> URL: https://issues.apache.org/jira/browse/HADOOP-20007
> Project: Hadoop Common
> Issue Type: Sub-task
> Components: common, test
> Reporter: Jose Luis López
> Priority: Minor
>
> HBase, Hive, Spark, Ozone and Knox compile against hadoop-auth's filters and
> {{HttpServer2}}. HADOOP-19912 moves Hadoop to Jetty 12 on the ee8 environment
> so that this API keeps {{javax.servlet}} and downstream projects need not
> rebuild. That promise should be enforced by a test, not left to review.
> h3. Changes
> New {{TestDownstreamServletCompatibility}} in hadoop-common, which:
> * checks reflectively that the public and protected signatures of that API
> name only {{javax.servlet}} types, with no {{jakarta.servlet}} and no
> {{org.eclipse.jetty}};
> * runs a downstream-style filter and servlet on an {{HttpServer2}} and checks
> the response.
> New tests in {{TestHttpServer}} pin behaviour a Jetty upgrade could change
> silently:
> * a redirect's {{Location}} is absolute;
> * {{/static}} lists no directory;
> * paths with an empty segment, an encoded percent or an encoded backslash
> reach the servlet;
> * {{/logs}} keeps its admin check when {{hadoop.log.dir}} is missing.
> {{HttpServer2}} sets {{relativeRedirectAllowed}} to false explicitly. That is
> Jetty 9.4's default, so nothing changes today; Jetty 12's default is true.
> The tests pass on trunk (Jetty 9.4), and HADOOP-19972 must keep them green.
> It is expected to fail on the day the jakarta move (HADOOP-19395) reaches
> this API, which belongs to a major release.
--
This message was sent by Atlassian Jira
(v10.3.26#10030026)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]