qian created SPARK-39526:
----------------------------
Summary: Remove no-null conditional statements in
SparkSubmitCommandBuilder#isThriftServer
Key: SPARK-39526
URL: https://issues.apache.org/jira/browse/SPARK-39526
Project: Spark
Issue Type: Improvement
Components: Spark Core
Affects Versions: 3.3.0
Reporter: qian
{code:java}
private boolean isThriftServer(String mainClass) {
return (mainClass != null &&
mainClass.equals("org.apache.spark.sql.hive.thriftserver.HiveThriftServer2"));
} {code}
No scenario that *mainClass* is null, because already have defensive code.
{code:java}
if (isExample && !isSpecialCommand) {
checkArgument(mainClass != null, "Missing example class name.");
}
if (mainClass != null) {
args.add(parser.CLASS);
args.add(mainClass);
} {code}
--
This message was sent by Atlassian Jira
(v8.20.7#820007)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]