Make Bloom size configurable without system properties

* BloomUriUniqFilter.java
    make bloom size configurable via bean properties
    change implementing class to BloomFilter64bit (given growing prevalance of 64bit JVMs and larger heaps)
* BloomUriUniqFilterTest.java
    update test for property-set sizing
* BloomFilter64bit.java
    improve comment
This commit is contained in:
gojomo
2009-11-16 22:42:18 +00:00
parent 69bedb8240
commit 9059395617
3 changed files with 50 additions and 54 deletions
@@ -52,7 +52,10 @@ implements UriUniqFilter.CrawlUriReceiver {
protected void setUp() throws Exception {
super.setUp();
this.filter = new BloomUriUniqFilter(2000,24);
this.filter = new BloomUriUniqFilter();
this.filter.setExpectedInserts(2000);
this.filter.setHashCount(24);
this.filter.afterPropertiesSet();
this.filter.setDestination(this);
}