[
https://issues.apache.org/jira/browse/HADOOP-14978?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16218260#comment-16218260
]
liyunzhang commented on HADOOP-14978:
-------------------------------------
[~ajisakaa]: can you help view this issue?
It seems that RMWebApp use guice dependency to bind JAXBContextResolver.class.
But after jdk9, guice does not support jdk9 very
well([GUICE-ISSUE|https://github.com/google/guice/issues/1085]).
[this|https://github.com/google/guice/issues/1085] seems not fixed now. So now
how to bypass it?
{code}
public void setup() {
bind(JAXBContextResolver.class);
bind(RMWebServices.class);
bind(GenericExceptionHandler.class);
if (rm != null) {
bind(ResourceManager.class).toInstance(rm);
bind(RMContext.class).toInstance(rm.getRMContext());
bind(ApplicationACLsManager.class).toInstance(
rm.getApplicationACLsManager());
}
route("/", RmController.class);
route(pajoin("/nodes", NODE_STATE), RmController.class, "nodes");
route(pajoin("/apps", APP_STATE), RmController.class);
route("/cluster", RmController.class, "about");
route(pajoin("/app", APPLICATION_ID), RmController.class, "app");
route("/scheduler", RmController.class, "scheduler");
route(pajoin("/queue", QUEUE_NAME), RmController.class, "queue");
}
{code}
> [JDK9] Resource Manager failed to start after using hadoop pkg(built with
> jdk9)
> -------------------------------------------------------------------------------
>
> Key: HADOOP-14978
> URL: https://issues.apache.org/jira/browse/HADOOP-14978
> Project: Hadoop Common
> Issue Type: Bug
> Reporter: liyunzhang
>
> Using latest code(b406d8e) and following 2 patches
> https://issues.apache.org/jira/secure/attachment/12850964/HADOOP-12760.03.patch
> https://issues.apache.org/jira/secure/attachment/12879343/HDFS-11610.001.patch
> command: {code}mvn clean package -Pdist -DskipTests -Dmaven.javadoc.skip=True
> -Dtar {code}
> After building successfully with jdk9 and deploy to a cluster,NameNode and
> DataNode successfully start but ResourceManager and NodeManager failed to
> start.
> the exception I found in the
> $HADOOP_HOME/logs/hadoop-root-resourcemanager-xxx.log
> {code}
> Caused by: com.google.inject.ProvisionException: Unable to provision, see the
> following errors:
> 402
> 403 1) Error injecting constructor, java.lang.NoClassDefFoundError:
> javax/activation/DataSource
> 404 at org.apache.hadoop.yarn.server.resourcemanager.webapp.
> .<init>(JAXBContextResolver.java:41)
> 405 at
> org.apache.hadoop.yarn.server.resourcemanager.webapp.RMWebApp.setup(RMWebApp.java:50)
> 406 while locating
> org.apache.hadoop.yarn.server.resourcemanager.webapp.JAXBContextResolver
> 407
> 408 1 error
> {code}
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]