tezConfig, n, commonLocalResources); try { session.preWarm(prewarmVertex); } catch (IOException ie) { if (!isOnThread && ie.getMessage().contains("Interrupted while waiting")) {
tezConfig, n, commonLocalResources); try { session.preWarm(prewarmVertex); } catch (IOException ie) { if (!isOnThread && ie.getMessage().contains("Interrupted while waiting")) {
/** * API to help pre-allocate containers in session mode. In non-session mode * this is ignored. The pre-allocated containers may be re-used by subsequent * job DAGs to improve performance. * The preWarm vertex should be configured and setup exactly * like the other vertices in the job DAGs so that the pre-allocated containers * may be re-used by the subsequent DAGs to improve performance. * The processor for the preWarmVertex may be used to pre-warm the containers * by pre-loading classes etc. It should be short-running so that pre-warming * does not block real execution. Users can specify their custom processors or * use the PreWarmProcessor from the runtime library. * The parallelism of the preWarmVertex will determine the number of preWarmed * containers. * Pre-warming is best efforts and among other factors is limited by the free * resources on the cluster. * @param preWarmVertex * @throws TezException * @throws IOException */ @Unstable public synchronized void preWarm(PreWarmVertex preWarmVertex) throws TezException, IOException { preWarm(preWarmVertex, 0, TimeUnit.MILLISECONDS); }
tezClient.preWarm(PreWarmVertex.createConfigBuilder(tezConf).build());
preWarmVertex.setTaskLaunchCmdOpts(dag.getVertex("initialmap").getTaskLaunchCmdOpts()); tezSession.preWarm(preWarmVertex);
commonLocalResources); try { session.preWarm(prewarmVertex); } catch (IOException ie) { if (ie.getMessage().contains("Interrupted while waiting")) {