gchm2010 / simple-spring-memcached

Automatically exported from code.google.com/p/simple-spring-memcached
MIT License
0 stars 0 forks source link

@CacheKeyMethod ignored in superclass #8

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
When A is a superclass of B, and A has an annotated method @CacheKeyMethod, 
then this method is ignored for B instance (and to toString() is used in place).

If I override the annotated method in B, and add the annotation, expected 
behavior is used.

It may be more appropriate that @CacheKeyMethod of superclasses is used when no 
@CacheKeyMethod is found in an object instance ? If not, @CacheKeyMethod 
javadoc may be modified to expose this behavior ?

Original issue reported on code.google.com by lalme...@gmail.com on 12 Sep 2012 at 12:49

GoogleCodeExporter commented 8 years ago
It will be easier and faster to just change the javadocs but it'll be too 
verbose and error prone when each subclass need to override (copy) the method 
annotated with @CacheKeyMethod from superclass. 
I'll change it. If there's no @CacheKeyMethod in class also superclasses will 
be checked before using the default toString().

Original comment by ragno...@gmail.com on 12 Sep 2012 at 3:01

GoogleCodeExporter commented 8 years ago
Code in trunk and artifact is available snapshot repository.
If you want to use it but don't want to relay on snapshot or compile SSM on 
your own, let me know and I'll describe how it's possible using version 3.0.2. 

Original comment by ragno...@gmail.com on 12 Sep 2012 at 3:52

GoogleCodeExporter commented 8 years ago

Original comment by ragno...@gmail.com on 18 Sep 2012 at 6:27

GoogleCodeExporter commented 8 years ago
Version 3.1.0 has been released and deployed to central maven repository.

Original comment by ragno...@gmail.com on 9 Oct 2012 at 6:00