diff --git a/src/main/java/eu/cloudscale/showcase/db/dao/hibernate/impl/ItemDaoImpl.java b/src/main/java/eu/cloudscale/showcase/db/dao/hibernate/impl/ItemDaoImpl.java
index d6525c4..cefc318 100755
--- a/src/main/java/eu/cloudscale/showcase/db/dao/hibernate/impl/ItemDaoImpl.java
+++ b/src/main/java/eu/cloudscale/showcase/db/dao/hibernate/impl/ItemDaoImpl.java
@@ -59,13 +59,13 @@ public class ItemDaoImpl extends DaoImpl<IItem> implements IItemDao
return (List<IItem>) q.list();
}
- public static APLCache<IItem> findItemByIdCache = new APLCache<>("ItemDaoImpl.findItemById");
+ public static APLCache<IItem> findByIdCache = new APLCache<>("ItemDaoImpl.findById");
@SuppressWarnings( "unused" )
@Override
public IItem findById(int id)
{
- return findItemByIdCache.computeIfAbsent(Thread.currentThread(), new Object[]{id}, () -> {
+ return findByIdCache.computeIfAbsent(Thread.currentThread(), new Object[]{id}, () -> {
String hql = "SELECT I, A FROM Item I, Author A WHERE I.IId = :itemId AND A.AId = I.author.AId";
Query q = getCurrentSession().createQuery( hql );
q.setParameter( "itemId", id );
diff --git a/src/main/java/eu/cloudscale/showcase/db/dao/hibernate/impl/ShoppingCartDaoImpl.java b/src/main/java/eu/cloudscale/showcase/db/dao/hibernate/impl/ShoppingCartDaoImpl.java
index e5e3dc9..3facd16 100755
--- a/src/main/java/eu/cloudscale/showcase/db/dao/hibernate/impl/ShoppingCartDaoImpl.java
+++ b/src/main/java/eu/cloudscale/showcase/db/dao/hibernate/impl/ShoppingCartDaoImpl.java
@@ -38,14 +38,14 @@ public class ShoppingCartDaoImpl extends DaoImpl<IShoppingCart> implements IShop
super(sessionFactory);
}
-public static APLCache<IShoppingCart> findShoppingCartByIdCache = new APLCache<>("ShoppingCartDaoImpl.findShoppingCartById");
+public static APLCache<IShoppingCart> findByIdCache = new APLCache<>("ShoppingCartDaoImpl.findById");
@SuppressWarnings( "rawtypes" )
@Override
// @Transactional(readOnly=true)
public IShoppingCart findById(Integer shoppingId)
{
- return findShoppingCartByIdCache.computeIfAbsent(Thread.currentThread(), new Object[]{shoppingId}, () -> {
+ return findByIdCache.computeIfAbsent(Thread.currentThread(), new Object[]{shoppingId}, () -> {
Session session = getCurrentSession();
String hql = "SELECT SC FROM ShoppingCart as SC WHERE SC.scId = :scId";