开发者

How to set the map task timeout?

I tried this

Configuration conf = new Configuration();
conf.set("mapred.task.timeout", "1000");
Job job = new Job(conf);

But I think it is not working. I am trying to set mapred.task.timeout to 1000 and in the map class I am giving a " Thread.sleep(2000开发者_如何学Python); " and expecting it to throw an exception. But it it running fine. Shouldn't this throw an exception?


That is an old, deprecated config setting. It may be that you need the newer equivalent, mapreduce.task.timeout. Also, call Configuration.setInt() instead.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜