protected boolean loadFilters(final boolean cleanOnFail, boolean asynchronous)
   {
      if (!filtersSupported.get())
      {
         if (LOG.isWarnEnabled())
         {
            LOG.warn("The bloom filters are not supported therefore they cannot be reloaded");
         }
         return false;
      }
      filtersEnabled.set(false);
      this.filterPermissions = new BloomFilter<String>(bfProbability, bfElementNumber);
      this.filterOwner = new BloomFilter<String>(bfProbability, bfElementNumber);

      if (asynchronous)
      {
         new Thread(new Runnable()
         {
            public void run()
            {
               doLoadFilters(cleanOnFail);
            }
         }, "BloomFilter-Loader-" + dataContainer.getName()).start();

         return true;
      }
      else
      {
         return doLoadFilters(cleanOnFail);
      }
   }
protected boolean loadFilters ( final boolean cleanOnFail , boolean asynchronous ) { if ( ! filtersSupported . get ( ) ) { if ( LOG . isWarnEnabled ( ) ) { LOG . warn ( "The bloom filters are not supported therefore they cannot be reloaded" ) ; } return false ; } filtersEnabled . set ( false ) ; this . filterPermissions = new BloomFilter < String > ( bfProbability , bfElementNumber ) ; this . filterOwner = new BloomFilter < String > ( bfProbability , bfElementNumber ) ; if ( asynchronous ) { new Thread ( new Runnable ( ) { public void run ( ) { doLoadFilters ( cleanOnFail ) ; } } , "BloomFilter-Loader-" + dataContainer . getName ( ) ) . start ( ) ; return true ; } else { return doLoadFilters ( cleanOnFail ) ; } }
Loads the bloom filters
@param cleanOnFail clean everything if an error occurs
@param asynchronous make the bloom filters loading asynchronous
@return <code>true</code> if the filters could be loaded successfully, <code>false</code> otherwise.