Hi there,
we're trying to replicate the Yarn tutorial from
http://hadoop.apache.org/docs/stable/hadoop-yarn/hadoop-yarn-site/WritingYarnApplications.html.
It actually needed some modification to run on CDH4.3. It crashes as
follows:
13/12/02 17:09:36 WARN util.NativeCodeLoader: Unable to load
native-hadoop library for your platform... using builtin-java classes
where applicable
Exception in thread "main" java.lang.RuntimeException:
java.lang.NoSuchFieldException: versionID
at org.apache.hadoop.ipc.RPC.getProtocolVersion(RPC.java:171)
at
org.apache.hadoop.ipc.WritableRpcEngine$Invocation.<init>(WritableRpcEngine.java:111)
at
org.apache.hadoop.ipc.WritableRpcEngine$Invoker.invoke(WritableRpcEngine.java:225)
at com.sun.proxy.$Proxy6.getNewApplication(Unknown Source)
at
ch.unibe.scg.yarn.ApplicationMaster.launch(ApplicationMaster.java:58)
at ch.unibe.scg.yarn.ApplicationMaster.main(ApplicationMaster.java:112)
Caused by: java.lang.NoSuchFieldException: versionID
at java.lang.Class.getField(Class.java:1579)
at org.apache.hadoop.ipc.RPC.getProtocolVersion(RPC.java:167)
... 5 more
Here's our code, up to the point where it crashes.
// mostly stolen from
http://hadoop.apache.org/docs/stable/hadoop-yarn/hadoop-yarn-site/WritingYarnApplications.html
Configuration conf = new Configuration();
conf.addResource(new Path(CONF_FILE_PATH));
YarnConfiguration yarnConf = new YarnConfiguration(conf);
InetSocketAddress rmAddress = NetUtils.createSocketAddr(
yarnConf.get(YarnConfiguration.RM_ADDRESS,
YarnConfiguration.DEFAULT_RM_ADDRESS));
Configuration appsManagerServerConf = new Configuration(conf);
ClientRMProtocol applicationsManager =
RPC.getProxy(ClientRMProtocol.class, 1L, rmAddress, appsManagerServerConf);
GetNewApplicationRequest request =
Records.newRecord(GetNewApplicationRequest.class);
GetNewApplicationResponse response =
applicationsManager.getNewApplication(request);
The last line there triggers the above exception. Any hints?
Cheers,
Boris Spasojević - Борис Спасојевић
*Research assistant*
Software Composition Group <http://scg.unibe.ch>
Institute of Computer Science and Applied Mathematics
<http://www.iam.unibe.ch>
University of Bern <http://www.unibe.ch>
email: [email protected] <mailto:[email protected]>
office phone: +41 (0)31 511 7636
mobile: +41 (0)76 66 88 175
webpage: http://scg.unibe.ch/staff/Boris-Spasojevic