Nullkeyreturnedforcacheoperation(maybeyouareusingnamedparamsonclasseswithoutdebug
2024-03-12 09:12阅读:
Null key returned for cache operation (maybe you are using named
params on classes without debug info?) Builder(解决Null key returned
for cache operation)
@Cacheable(cacheNames = 'demoCache', key = '#id')
User getUserById(Integer id);
解决: key = '#id' 改成: key = ''_' + #id'
@Cacheable(cacheNames = 'demoCache', key = ''_' +
#id')
User getUserById(Integer id);
解决: key = '#id'
