[ 
https://issues.apache.org/jira/browse/HIVE-17292?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16127268#comment-16127268
 ] 

Peter Vary commented on HIVE-17292:
-----------------------------------

Actually checked the configuration of the standalone mode, and here is what I 
have found:
{code:title=data/conf/spark/standalone/hive-site.xml}
<property>
  <name>spark.master</name>
  <value>local-cluster[2,2,1024]</value>
</property>
{code}

This suggests, that we planned to use 2 executors with 2 cores each, but the 
{{SparkSessionImpl.getMemoryAndCores}} overrides this with configuration values 
we do not set in the conf.
{code:title=SparkSessionImpl}
  @Override
  public ObjectPair<Long, Integer> getMemoryAndCores() throws Exception {
[..]
    if (masterURL.startsWith("spark")) {
[..]
    } else {
      int coresPerExecutor = sparkConf.getInt("spark.executor.cores", 1);
      totalCores = numExecutors * coresPerExecutor;
    }
[..]
  }
{code}

Based on our conversation here and on HIVE-17291, I think the ideal solution 
would be to use the same logic for the "local.\*" master, as for the 
"spark.\*". This means that we have to regenerate many golden files, since we 
will change the result of the explains in the same way as for the 
TestMiniSparkOnYarnCliDriver.

If you agree [~lirui], I could provide a patch for it.

Thanks,
Peter

> Change TestMiniSparkOnYarnCliDriver test configuration to use the configured 
> cores
> ----------------------------------------------------------------------------------
>
>                 Key: HIVE-17292
>                 URL: https://issues.apache.org/jira/browse/HIVE-17292
>             Project: Hive
>          Issue Type: Sub-task
>          Components: Spark, Test
>    Affects Versions: 3.0.0
>            Reporter: Peter Vary
>            Assignee: Peter Vary
>         Attachments: HIVE-17292.1.patch, HIVE-17292.2.patch, 
> HIVE-17292.3.patch
>
>
> Currently the {{hive-site.xml}} for the {{TestMiniSparkOnYarnCliDriver}} test 
> defines 2 cores, and 2 executors, but only 1 is used, because the MiniCluster 
> does not allows the creation of the 3rd container.
> The FairScheduler uses 1GB increments for memory, but the containers would 
> like to use only 512MB. We should change the fairscheduler configuration to 
> use only the requested 512MB



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to