You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by "mridulm (via GitHub)" <gi...@apache.org> on 2023/07/01 03:34:38 UTC

[GitHub] [spark] mridulm commented on a diff in pull request #41806: [SPARK-44242] Improve Max Heap not set check

mridulm commented on code in PR #41806:
URL: https://github.com/apache/spark/pull/41806#discussion_r1248432874


##########
launcher/src/main/java/org/apache/spark/launcher/SparkSubmitCommandBuilder.java:
##########
@@ -311,11 +311,17 @@ private List<String> buildSparkSubmitCommand(Map<String, String> env)
   }
 
   private void checkJavaOptions(String javaOptions) {
-    if (!isEmpty(javaOptions) && javaOptions.contains("Xmx")) {
-      String msg = String.format("Not allowed to specify max heap(Xmx) memory settings through " +
-        "java options (was %s). Use the corresponding --driver-memory or " +
-        "spark.driver.memory configuration instead.", javaOptions);
-      throw new IllegalArgumentException(msg);
+    System.out.println(javaOptions);
+
+    if (!isEmpty(javaOptions)) {
+      for (String javaOption: javaOptions.split(" ")) {

Review Comment:
   Perfect @LuciferYang  !



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org