This forum is now a read-only archive. All commenting, posting, registration services have been turned off. Those needing community support and/or wanting to ask questions should refer to the Tag/Forum map, and to http://spring.io/questions for a curated list of stackoverflow tags that Pivotal engineers, and the community, monitor.

a benign bug in tokenrepository impls?

Aug 27th, 2010, 03:44 PM

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?