Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update the log warning of UDF compiler #5157

Merged
merged 3 commits into from
Apr 13, 2022
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,14 @@ object RapidsPluginUtils extends Logging {
logWarning("RAPIDS Accelerator is disabled, to enable GPU " +
s"support set `${RapidsConf.SQL_ENABLED}` to true.")
}

if (conf.isUdfCompilerEnabled) {
logWarning("RAPIDS UDF compiler is enabled, to disable it " +
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We might want to link to our FAQ https://nvidia.github.io/spark-rapids/docs/FAQ.html#automatic-translation-of-scala-udfs-to-apache-spark-operations . Without such context it's not clear for the user why she is warned about this setting. What makes it different from other switches we don't draw attention to? Looks like we consider it bleeding edge (experimental, unstable, evolving), and the wording for the warning should make it clear. E.g.

Experimental RAPIDS UDF compiler is enabled, in case of related failures disable it by ...

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done!

s"set `${RapidsConf.UDF_COMPILER_ENABLED}` to false.")
} else {
logWarning("RAPIDS UDF compiler is disabled, to enable it " +
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1 to @jlowe's comment #5157 (comment) .

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done!

s"set `${RapidsConf.UDF_COMPILER_ENABLED}` to true.")
}
}

def fixupConfigs(conf: SparkConf): Unit = {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2019-2021, NVIDIA CORPORATION.
* Copyright (c) 2019-2022, NVIDIA CORPORATION.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand All @@ -25,8 +25,6 @@ import org.apache.spark.sql.catalyst.rules.Rule

class Plugin extends (SparkSessionExtensions => Unit) with Logging {
override def apply(extensions: SparkSessionExtensions): Unit = {
logWarning("Installing rapids UDF compiler extensions to Spark. The compiler is disabled" +
s" by default. To enable it, set `spark.rapids.sql.udfCompiler.enabled` to true")
extensions.injectResolutionRule(logicalPlanRules)
}

Expand Down