无法在Cosmos中使用自定义Mapreduce jar文件

无法在Cosmos中使用自定义Mapreduce jar文件,mapreduce,fiware,fiware-cosmos,Mapreduce,Fiware,Fiware Cosmos,我创建了自己的Mapreduce jar文件,并在Cosmos中使用HDFSshell命令成功地进行了测试。下一步是在新集群中测试同一个jar,所以我将它上传到 ,转到我的主文件夹(用户/my.username) 当我尝试使用下面的curl post开始Mapreduce作业时 curl -X POST "http://computing.cosmos.lab.fiware.org:12000/tidoop/v1/user/my.username/jobs" -d '{"jar":"dt.jar

我创建了自己的Mapreduce jar文件,并在Cosmos中使用HDFSshell命令成功地进行了测试。下一步是在新集群中测试同一个jar,所以我将它上传到 ,转到我的主文件夹(用户/my.username)

当我尝试使用下面的curl post开始Mapreduce作业时

curl -X POST "http://computing.cosmos.lab.fiware.org:12000/tidoop/v1/user/my.username/jobs" -d '{"jar":"dt.jar","class_name":"DistanceTest","lib_jars":"dt.jar","input":"input","output":"output"}' -H "Content-Type: application/json" -H "X-Auth-Token: xxxxxxxxxxxxxxxxxxx"
我得到:

{“成功”:“错误”,“错误”:255}


我为jar尝试了不同的路径值,得到了相同的结果。我是否必须将我的jar上传到其他地方,还是缺少一些必要的步骤?

代码中有一个bug,已经在FIWARE Lab的全局实例中修复

我已经测试过这个:

$ curl -X POST "http://computing.cosmos.lab.fiware.org:12000/tidoop/v1/user/myuser/jobs" -d '{"jar":"mrjars/hadoop-mapreduce-examples.jar","class_name":"wordcount","lib_jars":"mrjars/hadoop-mapreduce-examples.jar","input":"testdir","output":"outputdir"}' -H "Content-Type: application/json" -H "X-Auth-Token: mytoken"
{"success":"true","job_id": "job_1460639183882_0016"}
在本例中,请注意,
mrjars/hadoop-mapreduce-examples.jar
hdfs:///user/myuser
。始终在此操作中使用相对路径

$ curl -X GET "http://storage.cosmos.lab.fiware.org:14000/webhdfs/v1/user/myuser/mrjars?op=liststatus&user.name=myuser" -H "X-Auth-Token: mytoken"
{"FileStatuses":{"FileStatus":[{"pathSuffix":"hadoop-mapreduce-examples.jar","type":"FILE","length":270283,"owner":"myuser","group":"myuser","permission":"644","accessTime":1464702215233,"modificationTime":1464702215479,"blockSize":134217728,"replication":3}]}}
结果是:

$ curl -X GET "http://storage.cosmos.lab.fiware.org:14000/webhdfs/v1/user/myuser/outputdir?op=liststatus&user.name=myuser" -H "X-Auth-Token: mytoken"
{"FileStatuses":{"FileStatus":[{"pathSuffix":"_SUCCESS","type":"FILE","length":0,"owner":"myuser","group":"myuser","permission":"644","accessTime":1464706333691,"modificationTime":1464706333706,"blockSize":134217728,"replication":3},{"pathSuffix":"part-r-00000","type":"FILE","length":128,"owner":"myuser","group":"myuser","permission":"644","accessTime":1464706333264,"modificationTime":1464706333460,"blockSize":134217728,"replication":3}]}}
我将尽快将修复上传到GitHub中的Cosmos repo。

这次,我得到
{“成功”:“错误”,“错误”:1}
。新旧集群之间是否存在Hadoop版本的差异,或者我是否遗漏了什么?是jar文件和我用于测试的示例输入。