Skip to content
Closed
Show file tree
Hide file tree
Changes from all 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 @@ -35,7 +35,7 @@
</File>
</Appenders>
<Loggers>
<Root level="INFO">
<Root level="DEBUG">
Copy link
Member Author

Choose a reason for hiding this comment

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

Debug message in CI for authz module can be turned on as most of its logs are at debug level and now it's less noisy.

<AppenderRef ref="stdout"/>
<AppenderRef ref="file"/>
</Root>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,11 +60,7 @@ object ReflectUtils {
}
} catch {
case e: Exception =>
val candidates =
(clz.getDeclaredFields ++ clz.getFields).map(_.getName).distinct.sorted
throw new RuntimeException(
s"Field $fieldName not in $clz [${candidates.mkString(",")}]",
e)
throw new RuntimeException(s"$clz does not have $fieldName field", e)
}
}

Expand Down Expand Up @@ -92,14 +88,8 @@ object ReflectUtils {
}
} catch {
case e: Exception =>
val candidates =
(clz.getDeclaredMethods ++ clz.getMethods)
.map(m => s"${m.getName}(${m.getParameterTypes.map(_.getName).mkString(", ")})")
.distinct.sorted
val argClassesNames = argClasses.map(_.getName)
throw new RuntimeException(
s"Method $methodName(${argClassesNames.mkString(", ")})" +
s" not found in $clz [${candidates.mkString(", ")}]",
s"$clz does not have $methodName${argClasses.map(_.getName).mkString("(", ", ", ")")}",
e)
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,10 +75,8 @@ class ReflectUtilsSuite extends AnyFunSuite {
"methodNotExists",
(classOf[String], "arg1"),
(classOf[String], "arg2"))
}("Method methodNotExists(java.lang.String, java.lang.String) not found " +
"in class org.apache.kyuubi.util.reflect.ObjectA$ " +
"[equals(java.lang.Object), field5(), field6(), getClass(), hashCode(), method5(), " +
"method6(), notify(), notifyAll(), toString(), wait(), wait(long), wait(long, int)]")
}("class org.apache.kyuubi.util.reflect.ObjectA$ does not have methodNotExists(" +
"java.lang.String, java.lang.String)")
}
}

Expand Down