[jboss-user] [JBoss Cache] - Using JdbmCacheLoader
Eugeny Balakhonov
do-not-reply at jboss.com
Sun Mar 10 09:40:56 EDT 2013
Eugeny Balakhonov [https://community.jboss.org/people/c0ff75] created the discussion
"Using JdbmCacheLoader"
To view the discussion, visit: https://community.jboss.org/message/801763#801763
--------------------------------------------------------------
Hello!
I want to use JdbmCacheLoader in my configuration for a cache persistence. I have created simple config:
<?xml version="1.0" encoding="UTF-8"?>
<jbosscache xmlns:xsi=" http://www.w3.org/2001/XMLSchema-instance http://www.w3.org/2001/XMLSchema-instance"
xmlns="urn:jboss:jbosscache-core:config:3.2">
<loaders passivation="false" shared="false">
<loader
class="org.jboss.cache.loader.jdbm.JdbmCacheLoader"
async="false"
fetchPersistentState="true"
ignoreModifications="false"
purgeOnStartup="false">
<properties>
location=D:/cache/#data
</properties>
</loader>
</loaders>
</jbosscache>
But this isn't working:
1. After a first start of application I see two DB files created in the directory d:/cache/.
2. I don't use cache during application run: I just start it and stop immediately.
3. During a second start of application I see a lot of errors. JBoss cache can't read persistence database which were created during first start. Generic reason:
Caused by: jdbm.helper.WrappedRuntimeException: org.jboss.cache.loader.jdbm.JdbmFqnComparator
at jdbm.helper.DefaultSerializer.deserialize(DefaultSerializer.java:99)
at jdbm.recman.BaseRecordManager.fetch(BaseRecordManager.java:341)
at jdbm.recman.CacheRecordManager.fetch(CacheRecordManager.java:263)
at jdbm.recman.CacheRecordManager.fetch(CacheRecordManager.java:242)
at jdbm.btree.BTree.load(BTree.java:276)
at org.jboss.cache.loader.jdbm.JdbmCacheLoader.openDatabase(JdbmCacheLoader.java:186)
at org.jboss.cache.loader.jdbm.JdbmCacheLoader.start(JdbmCacheLoader.java:157)
at org.jboss.cache.loader.CacheLoaderManager.startCacheLoader(CacheLoaderManager.java:461)
4. If I change in my config file JdbmCacheLoader to FileCacheLoader then cache works fine.
Where is my error in the configuration? How to correctly use JdbmCacheLoader ?
Please help me by good advice ;)
Best regards,
Eugeny
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/801763#801763]
Start a new discussion in JBoss Cache at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2052]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20130310/626f8a63/attachment.html
More information about the jboss-user
mailing list