incubator-bval-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mben...@apache.org
Subject svn commit: r1148846 - /incubator/bval/sandbox/lang3-work/bval-jsr303-dynamic/provider/src/main/java/org/apache/bval/jsr303/dynamic/NestedValidator.java
Date Wed, 20 Jul 2011 16:54:13 GMT
Author: mbenson
Date: Wed Jul 20 16:54:12 2011
New Revision: 1148846

URL: http://svn.apache.org/viewvc?rev=1148846&view=rev
Log:
add logging message when NestedValidator cannot find nested validation metadata

Modified:
    incubator/bval/sandbox/lang3-work/bval-jsr303-dynamic/provider/src/main/java/org/apache/bval/jsr303/dynamic/NestedValidator.java

Modified: incubator/bval/sandbox/lang3-work/bval-jsr303-dynamic/provider/src/main/java/org/apache/bval/jsr303/dynamic/NestedValidator.java
URL: http://svn.apache.org/viewvc/incubator/bval/sandbox/lang3-work/bval-jsr303-dynamic/provider/src/main/java/org/apache/bval/jsr303/dynamic/NestedValidator.java?rev=1148846&r1=1148845&r2=1148846&view=diff
==============================================================================
--- incubator/bval/sandbox/lang3-work/bval-jsr303-dynamic/provider/src/main/java/org/apache/bval/jsr303/dynamic/NestedValidator.java
(original)
+++ incubator/bval/sandbox/lang3-work/bval-jsr303-dynamic/provider/src/main/java/org/apache/bval/jsr303/dynamic/NestedValidator.java
Wed Jul 20 16:54:12 2011
@@ -36,6 +36,8 @@ import org.apache.bval.util.PropertyAcce
 import org.apache.commons.lang3.ObjectUtils;
 import org.apache.commons.lang3.StringUtils;
 import org.apache.commons.lang3.Validate;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 /**
  * {@code Validator} implementation to handle validations in a given context. This extension
is only applicable because
@@ -145,6 +147,7 @@ public class NestedValidator extends Dyn
     private Object rootBean;
     private DynamicMetaBean rootMetaBean;
     private String path;
+    private final Logger log = LoggerFactory.getLogger(getClass());
     
     /**
      * Create a new NestedValidator instance.
@@ -226,7 +229,7 @@ public class NestedValidator extends Dyn
                 }
                 return result;
             } catch (UnknownPropertyException e) {
-
+                log.warn("Could not get nested validation metadata, falling back to non-nested
metadata instead", e);
             }
         }
         return super.createContext(metaBean, object, objectClass, groups);



Mime
View raw message