-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
 Post subject: OSCache hiberate query cache
PostPosted: Tue Jul 10, 2007 11:14 pm 
Newbie

Joined: Mon Jul 09, 2007 9:32 am
Posts: 17
Code:
[com.opensymphony.oscache.base.algorithm.AbstractConcurrentReadCache] - [oscache] Exception persisting sql: select ticket0_.ticketId as ticketId1_, ticket0_.ticketType as ticketType1_, ticket0_.active as active1_ from TICKET ticket0_ where ticket0_.peopleId = ? and ticket0_.active=0; parameters: 1, ; named parameters: {}.org.hibernate.cache.StandardQueryCache
com.opensymphony.oscache.base.persistence.CachePersistenceException: Unable to write 'c:\myapp\cache\application\sql__select_ticket0__ticketId_as_ticketId1_,_ticket0__ticketType_as_ticketType1_,_ticket0__active_as_active1__from_TICKET_ticket0__where_ticket0__peopleId_=_?_and_ticket0__active=0__parameters__1,___named_parameters__{}_org_hibernate_cache_StandardQueryCache.cache' in the cache. Exception: java.io.FileNotFoundException, Message: c:\myapp\cache\application\sql__select_ticket0__ticketId_as_ticketId1_,_ticket0__ticketType_as_ticketType1_,_ticket0__active_as_active1__from_TICKET_ticket0__where_ticket0__peopleId_=_?_and_ticket0__active=0__parameters__1,___named_parameters__{}_org_hibernate_cache_StandardQueryCache.cache (The filename, directory name, or volume label syntax is incorrect)
   at com.opensymphony.oscache.plugins.diskpersistence.AbstractDiskPersistenceListener.store(AbstractDiskPersistenceListener.java:350)
   at com.opensymphony.oscache.plugins.diskpersistence.AbstractDiskPersistenceListener.store(AbstractDiskPersistenceListener.java:238)
   at com.opensymphony.oscache.base.algorithm.AbstractConcurrentReadCache.persistStore(AbstractConcurrentReadCache.java:1091)
   at com.opensymphony.oscache.base.algorithm.AbstractConcurrentReadCache.put(AbstractConcurrentReadCache.java:1570)
   at com.opensymphony.oscache.base.algorithm.AbstractConcurrentReadCache.put(AbstractConcurrentReadCache.java:866)
   at com.opensymphony.oscache.base.Cache.putInCache(Cache.java:570)
   at com.opensymphony.oscache.base.Cache.putInCache(Cache.java:535)
   at com.opensymphony.oscache.general.GeneralCacheAdministrator.putInCache(GeneralCacheAdministrator.java:241)
   at com.opensymphony.oscache.general.GeneralCacheAdministrator.putInCache(GeneralCacheAdministrator.java:251)
   at org.hibernate.cache.OSCache.put(OSCache.java:56)
   at org.hibernate.cache.StandardQueryCache.put(StandardQueryCache.java:87)
   at org.hibernate.loader.Loader.putResultInQueryCache(Loader.java:2194)
   at org.hibernate.loader.Loader.listUsingQueryCache(Loader.java:2138)
   at org.hibernate.loader.Loader.list(Loader.java:2096)
   at org.hibernate.loader.hql.QueryLoader.list(QueryLoader.java:378)
   at org.hibernate.hql.ast.QueryTranslatorImpl.list(QueryTranslatorImpl.java:338)
   at org.hibernate.engine.query.HQLQueryPlan.performList(HQLQueryPlan.java:172)
   at org.hibernate.impl.SessionImpl.listFilter(SessionImpl.java:1477)
   at org.hibernate.impl.CollectionFilterImpl.list(CollectionFilterImpl.java:51)
   at service.Main.filterCollection(Main.java:67)
   at service.Main.main(Main.java:56)


I am using OSCache, hibernate query cache, I got this exception. Obviously, the file name is too long for Windows. Any ideas how to fix it ?

Thanks.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jul 11, 2007 5:34 am 
Regular
Regular

Joined: Fri Dec 17, 2004 10:38 am
Posts: 54
you can disable disk persistance in oscache (do not know is this possible in OSCache)
or fix
Code:
private String toString(Object key) {
        return String.valueOf(key) + '.' + regionName;
}

in org.hibernate.cache.OSCache to generate shorter cache key value


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.