@Service
public class CmsSiteFlowCacheImpl implements CmsSiteFlowCache, DisposableBean {
private Logger log = LoggerFactory.getLogger(CmsSiteFlowCacheImpl.class);
public void flow(CmsSite site, String ip, String sessionId, String page, String referer) {
CmsSiteFlow cmsSiteFlow = create(site, ip, sessionId, page, referer);
FlowBean flowBean = new FlowBean(cmsSiteFlow.getAccessDate(), sessionId, page);
if(cache.get(flowBean) == null){
CmsSiteFlow bean = null;
try {
bean = manager.findUniqueByProperties(site.getId(), cmsSiteFlow.getAccessDate(),
sessionId, page);
} catch (HibernateException e) {
cache.remove(flowBean);