Skip to content

Commit

Permalink
[SPARK-17710][FOLLOW UP] Add comments to state why 'Utils.classForNam…
Browse files Browse the repository at this point in the history
…e' is not used

## What changes were proposed in this pull request?
Add comments.

## How was this patch tested?
Build passed.

Author: Weiqing Yang <[email protected]>

Closes #15776 from weiqingy/SPARK-17710.
  • Loading branch information
weiqingy authored and rxin committed Nov 5, 2016
1 parent 0f7c9e8 commit 8a9ca19
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions core/src/main/scala/org/apache/spark/util/Utils.scala
Original file line number Diff line number Diff line change
Expand Up @@ -2539,6 +2539,8 @@ private[util] object CallerContext extends Logging {
val callerContextSupported: Boolean = {
SparkHadoopUtil.get.conf.getBoolean("hadoop.caller.context.enabled", false) && {
try {
// `Utils.classForName` will make `ReplSuite` fail with `ClassCircularityError` in
// master Maven build, so do not use it before resolving SPARK-17714.
// scalastyle:off classforname
Class.forName("org.apache.hadoop.ipc.CallerContext")
Class.forName("org.apache.hadoop.ipc.CallerContext$Builder")
Expand Down Expand Up @@ -2604,6 +2606,8 @@ private[spark] class CallerContext(
def setCurrentContext(): Unit = {
if (CallerContext.callerContextSupported) {
try {
// `Utils.classForName` will make `ReplSuite` fail with `ClassCircularityError` in
// master Maven build, so do not use it before resolving SPARK-17714.
// scalastyle:off classforname
val callerContext = Class.forName("org.apache.hadoop.ipc.CallerContext")
val builder = Class.forName("org.apache.hadoop.ipc.CallerContext$Builder")
Expand Down

0 comments on commit 8a9ca19

Please sign in to comment.