You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@zeppelin.apache.org by GitBox <gi...@apache.org> on 2021/10/19 06:56:52 UTC

[GitHub] [zeppelin] Reamer commented on a change in pull request #4258: [ZEPPELIN-5567] add Logging to LdapRealm on login Error

Reamer commented on a change in pull request #4258:
URL: https://github.com/apache/zeppelin/pull/4258#discussion_r731548534



##########
File path: zeppelin-server/src/main/java/org/apache/zeppelin/realm/LdapRealm.java
##########
@@ -206,7 +206,12 @@ public LdapRealm() {
   @Override
   protected AuthenticationInfo doGetAuthenticationInfo(AuthenticationToken token)
       throws org.apache.shiro.authc.AuthenticationException {
-    return super.doGetAuthenticationInfo(token);
+    try{
+      return super.doGetAuthenticationInfo(token);
+    }catch (Exception e){

Review comment:
       Thanks for your pull request.
   - Please catch only the `AuthenticationException`.
   - Add a whitespace after `try`, in front of `catch` and after `Exception e)`.
   - Use the following logger method, which avoids unnecessary string concatenation. http://www.slf4j.org/api/org/slf4j/Logger.html#warn(java.lang.String,java.lang.Object...)




-- 
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: dev-unsubscribe@zeppelin.apache.org

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