Aug 27th, 2010, 03:44 PM
a benign bug in tokenrepository impls?
in both InMemoryTokenRepositoryImpl and JdbcTokenRepositoryImpl, for the #updateToken() method, a new Date() is created rather than using the lastUsed that is passed in (which in the PersistentTokenBasedRememberMeServices is a new Date() defined 2 lines earlier).
I'm working on creating a custom implementation of the PersistentTokenRepository interface, and since there is absolutely no JavaDoc on the interface methods, I've been looking at the source of the implementations to determine what they are supposed to do. Should I be using the lastUsed Date that is passed in or also ignore it and create a new Date() object?
Aug 28th, 2010, 07:59 AM
As you say, it shouldn't matter since they are effectively the same. There's probably no good reason why the date needs to be passed into the update method.