1 2 Previous Next 20 Replies Latest reply on Feb 25, 2006 1:37 PM by smarlow Go to original post
      • 15. Re: random removing from Map (AOP-Cache)
        smarlow

        I'm using your cache configuration now and not seeing the problem. I did make one change that I would like you to make also.

        I took a shortcut and commented out the database loader config. Could you also try commenting out the following in your cache config file. If this worksaround the issue, I'll follow that path for reproducing (otherwise, I won't bother with a db).


        <!-- Start a comment before the cacheloader

        org.jboss.cache.loader.bdbje.BdbjeCacheLoader
        location=../bdbje
        /
        false
        false
        false
        true
        true

        end the comment after the block -->

        • 16. Re: random removing from Map (AOP-Cache)
          smarlow

          Hmm, last post didn't look so good.

          My cache config section for CacheLoaderCache looks like this

           <!--
           <attribute name="CacheLoaderClass">org.jboss.cache.loader.bdbje.BdbjeCacheLoader</attribute>
           <attribute name="CacheLoaderConfig" replace="false">location=../bdbje</attribute>
           <attribute name="CacheLoaderPreload">/</attribute>
           <attribute name="CacheLoaderShared">false</attribute>
           <attribute name="CacheLoaderPassivation">false</attribute>
           <attribute name="CacheLoaderAsynchronous">false</attribute>
           <attribute name="CacheLoaderFetchTransientState">true</attribute>
           <attribute name="CacheLoaderFetchPersistentState">true</attribute>
           -->
          


          • 17. Re: random removing from Map (AOP-Cache)
            shadowdz

            If I comment the section no exception is thrown.
            Try this config-section

            <attribute name="CacheLoaderClass">org.jboss.cache.loader.bdbje.BdbjeCacheLoader</attribute>
            <attribute name="CacheLoaderConfig" replace="false">location=../bdbje</attribute>
            <!--
             <attribute name="CacheLoaderPreload">/</attribute>
             <attribute name="CacheLoaderShared">false</attribute>
             <attribute name="CacheLoaderPassivation">false</attribute>
             <attribute name="CacheLoaderAsynchronous">false</attribute>
             <attribute name="CacheLoaderFetchTransientState">true</attribute>
             <attribute name="CacheLoaderFetchPersistentState">true</attribute>
            -->


            So it looks like something in the cacheloader is going wrong. I have used a JDBC-loader, too.

            If you must use a DB I have some changes for the class I post before:
            Replace:
            TestObject pojo = new TestObject();
            pojo.init();
            tx.begin();
            server.addObject("/pojo", pojo);
            pojo = server.find("/pojo"); // get ref to proxied object
            tx.commit();


            to:
            TestObject pojo = new TestObject();
            pojo.init();
            Object temp = server.find("/pojo"); // get ref to proxied object
            if (temp != null) {
             server.removeObject("/pojo");
            }
            tx.begin();
            server.addObject("/pojo", pojo);
            pojo = server.find("/pojo"); // get ref to proxied object
            tx.commit();


            • 18. Re: random removing from Map (AOP-Cache)
              smarlow

              Great news, I enabled the Sleepycat based classloader and can now reproduce the error.

              Can you create a jira for this and reference this forum thread?

              Thank you!

              • 19. Re: random removing from Map (AOP-Cache)
                shadowdz

                I've created one. Pleas let me know if you have an idea what's going wrong.

                • 20. Re: random removing from Map (AOP-Cache)
                  smarlow

                  It is not a real solution, but doing the remove operation outside of a transaction avoids the bug.

                  I'll keep working on this.

                  1 2 Previous Next