You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@calcite.apache.org by GitBox <gi...@apache.org> on 2022/12/17 03:01:18 UTC

[GitHub] [calcite] julianhyde commented on a diff in pull request #2919: [CALCITE-5298] CalciteSystemProperty calcite.test.dataset path check fails under Java Security Manager

julianhyde commented on code in PR #2919:
URL: https://github.com/apache/calcite/pull/2919#discussion_r1051297728


##########
core/src/main/java/org/apache/calcite/util/Util.java:
##########
@@ -1048,6 +1048,19 @@ public static String getStackTrace(Throwable t) {
     return sw.toString();
   }
 
+  /**
+   * Checks a RuntimeException for AccessControlException without importing JDK
+   * classes that are deprecated with the anticipated removal of Java security manager.
+   * Ignores the RuntimeException if it is an AccessControlException otherwise throws.
+   * @param e RuntimeException to check if it is an AccessControlException
+   */
+  @API(since = "1.33", status = API.Status.EXPERIMENTAL)
+  public static void ignoreAccessControlException(RuntimeException e) {

Review Comment:
   Can you re-order the javadoc so that it says what the method does in the first sentence.
   
   In the next paragraph explain how it does it.
   
   Put a blank line before \@param.



##########
core/src/main/java/org/apache/calcite/util/Util.java:
##########
@@ -1048,6 +1048,19 @@ public static String getStackTrace(Throwable t) {
     return sw.toString();
   }
 
+  /**
+   * Checks a RuntimeException for AccessControlException without importing JDK
+   * classes that are deprecated with the anticipated removal of Java security manager.
+   * Ignores the RuntimeException if it is an AccessControlException otherwise throws.
+   * @param e RuntimeException to check if it is an AccessControlException
+   */
+  @API(since = "1.33", status = API.Status.EXPERIMENTAL)
+  public static void ignoreAccessControlException(RuntimeException e) {

Review Comment:
   Is this issue tied to any particular JDK version? E.g. SecurityManager became deprecated in JDK x.x and is going to be removed in JDK y.y? If so it would be helpful to mention in this comment.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@calcite.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org