2011/11/30 Josep García <jgar...@isigma.es>:
> If I pass in a dynamic context name, like in validatorManager.validate(this,
> "my-validation"), the AnnotationActionValidator calls its method
> getValidators:
>
>     public synchronized List<Validator> getValidators(Class clazz, String
> context, String method) {
>         final String validatorKey = buildValidatorKey(clazz);
>
>         if (validatorCache.containsKey(validatorKey)) {
>             if (FileManager.isReloadingConfigs()) {
>                 validatorCache.put(validatorKey,
> buildValidatorConfigs(clazz, context, true, null));
>             }
>         } else {
>             validatorCache.put(validatorKey, buildValidatorConfigs(clazz,
> context, false, null));
>         }
>
>         // get the set of validator configs
>         List<ValidatorConfig> cfgs = validatorCache.get(validatorKey);
>
> and if reload is false, it will not find the file
> MyAction-my-validation-validation.xml: the validatorKey is based on the
> clazz name, and not on the context.
> :-(

Hm... it should work, did you try to debug ?


Regards
-- 
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/
Warszawa JUG conference - Confitura http://confitura.pl/

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org

Reply via email to