Is it possible to run several map task in one JVM?

前端 未结 4 1507
小鲜肉
小鲜肉 2021-01-21 10:07

I want to share large in memory static data(RAM lucene index) for my map tasks in Hadoop? Is there way for several map/reduce tasks to share same JVM?

4条回答
  •  南方客
    南方客 (楼主)
    2021-01-21 10:38

    In $HADOOP_HOME/conf/mapred-site.xml add the follow property

    
        mapred.job.reuse.jvm.num.tasks
        #
    
    

    The # can be set to a number to specify how many times the JVM is to be reused (default is 1), or set to -1 for no limit on the reuse amount.

提交回复
热议问题