Skip to content

Commit

Permalink
use internal config to avoid modify the original one
Browse files Browse the repository at this point in the history
  • Loading branch information
Rong Ma committed Jun 27, 2024
1 parent a51f693 commit 5f1a4a8
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ object VeloxBackendSettings extends BackendSettingsApi {

val GLUTEN_VELOX_UDF_LIB_PATHS = getBackendConfigPrefix() + ".udfLibraryPaths"
val GLUTEN_VELOX_DRIVER_UDF_LIB_PATHS = getBackendConfigPrefix() + ".driver.udfLibraryPaths"
val GLUTEN_VELOX_INTERNAL_UDF_LIB_PATHS = getBackendConfigPrefix() + ".internal.udfLibraryPaths"

val MAXIMUM_BATCH_SIZE: Int = 32768

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -231,8 +231,9 @@ object UDFResolver extends Logging {

udfLibPaths match {
case Some(paths) =>
// Set resolved paths to the internal config to parse on native side.
sparkConf.set(
VeloxBackendSettings.GLUTEN_VELOX_UDF_LIB_PATHS,
VeloxBackendSettings.GLUTEN_VELOX_INTERNAL_UDF_LIB_PATHS,
getAllLibraries(sparkConf, isDriver, paths))
case None =>
}
Expand Down
2 changes: 1 addition & 1 deletion cpp/velox/config/VeloxConfig.h
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ const std::string kVeloxAsyncTimeoutOnTaskStopping =
const int32_t kVeloxAsyncTimeoutOnTaskStoppingDefault = 30000; // 30s

// udf
const std::string kVeloxUdfLibraryPaths = "spark.gluten.sql.columnar.backend.velox.udfLibraryPaths";
const std::string kVeloxUdfLibraryPaths = "spark.gluten.sql.columnar.backend.velox.internal.udfLibraryPaths";

// backtrace allocation
const std::string kBacktraceAllocation = "spark.gluten.backtrace.allocation";
Expand Down

0 comments on commit 5f1a4a8

Please sign in to comment.