You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hive.apache.org by "Stamatis Zampetakis (Jira)" <ji...@apache.org> on 2022/09/23 13:26:00 UTC

[jira] [Commented] (HIVE-26557) AbstractMethodError when running TestWebHCatE2e

    [ https://issues.apache.org/jira/browse/HIVE-26557?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17608742#comment-17608742 ] 

Stamatis Zampetakis commented on HIVE-26557:
--------------------------------------------

AbstractMethodError is thrown when the application tries to call an abstract method. 

In this case {{UriBuilder#uri}} is an abstract method so we need an implementation of this. This method (with String parameter) is from version 2.0 of JAX-RS specification and comes from the following dependency:

{noformat}
<rs-api.version>2.0.1</rs-api.version>
...
<dependency>
      <groupId>javax.ws.rs</groupId>
      <artifactId>javax.ws.rs-api</artifactId>
      <version>${rs-api.version}</version>
</dependency>
{noformat}

JAX-RS is just the API so in order to run it needs an actual implementation.

In this case the implementation that is used is Jersey version 1.19 but the latter only implements JAX-RS 1.x and not JAX-RS 2.x thus leading to the exception in the description.

Given that there is no code actively using the JAX-RS 2.x API we can drop the respective dependency and fallback to JAX-RS 1.x (jsr311-api) which comes transitively from Jersey 1.19.

It makes sense to update both the API and Jersey implementation but it is significantly more work and out of the scope of this ticket.

> AbstractMethodError when running TestWebHCatE2e
> -----------------------------------------------
>
>                 Key: HIVE-26557
>                 URL: https://issues.apache.org/jira/browse/HIVE-26557
>             Project: Hive
>          Issue Type: Sub-task
>          Components: HCatalog, Tests
>            Reporter: Stamatis Zampetakis
>            Priority: Major
>
> {code:bash}
> mvn test -Dtest=TestWebHCatE2e
> {code}
> {noformat}
> java.lang.AbstractMethodError: javax.ws.rs.core.UriBuilder.uri(Ljava/lang/String;)Ljavax/ws/rs/core/UriBuilder;
>         at javax.ws.rs.core.UriBuilder.fromUri(UriBuilder.java:119) ~[javax.ws.rs-api-2.0.1.jar:2.0.1]
>         at com.sun.jersey.spi.container.servlet.ServletContainer.service(ServletContainer.java:669) ~[jersey-servlet-1.19.jar:1.19]
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:790) ~[javax.servlet-api-3.1.0.jar:3.1.0]
>         at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:791) ~[jetty-servlet-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.servlet.ServletHandler$ChainEnd.doFilter(ServletHandler.java:1626) ~[jetty-servlet-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.apache.hive.hcatalog.templeton.Main$XFrameOptionsFilter.doFilter(Main.java:355) ~[classes/:?]
>         at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193) ~[jetty-servlet-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1601) ~[jetty-servlet-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.apache.hadoop.security.authentication.server.AuthenticationFilter.doFilter(AuthenticationFilter.java:650) ~[hadoop-auth-3.3.1.jar:?]
>         at org.apache.hadoop.security.authentication.server.ProxyUserAuthenticationFilter.doFilter(ProxyUserAuthenticationFilter.java:104) ~[hadoop-common-3.3.1.jar:?]
>         at org.apache.hadoop.security.authentication.server.AuthenticationFilter.doFilter(AuthenticationFilter.java:592) ~[hadoop-auth-3.3.1.jar:?]
>         at org.apache.hadoop.hdfs.web.AuthFilter.doFilter(AuthFilter.java:51) ~[hadoop-hdfs-3.3.1.jar:?]
>         at org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:193) ~[jetty-servlet-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1601) ~[jetty-servlet-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:548) ~[jetty-servlet-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:233) ~[jetty-server-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1435) ~[jetty-server-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:188) ~[jetty-server-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:501) ~[jetty-servlet-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:186) ~[jetty-server-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1350) ~[jetty-server-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141) ~[jetty-server-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.server.handler.HandlerList.handle(HandlerList.java:59) ~[jetty-server-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127) ~[jetty-server-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.server.Server.handle(Server.java:516) ~[jetty-server-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.server.HttpChannel.lambda$handle$1(HttpChannel.java:388) ~[jetty-server-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.server.HttpChannel.dispatch(HttpChannel.java:633) ~[jetty-server-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:380) ~[jetty-server-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:277) ~[jetty-server-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311) ~[jetty-io-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:105) ~[jetty-io-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.io.ChannelEndPoint$1.run(ChannelEndPoint.java:104) ~[jetty-io-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:336) ~[jetty-runner-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:313) ~[jetty-runner-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:171) ~[jetty-runner-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.produce(EatWhatYouKill.java:135) ~[jetty-runner-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:882) [jetty-runner-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:1036) [jetty-runner-9.4.40.v20210413.jar:9.4.40.v20210413]
>         at java.lang.Thread.run(Thread.java:748) [?:1.8.0_261]
> {noformat}
> Every single test in the class throws the error above; clearly there is a classpath problem.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)