accumulo-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sven Hodapp <>
Subject IntersectingIterator and Ranges
Date Wed, 18 Nov 2015 12:08:32 GMT
Hello together,

Currently I'm using Accumulo 1.7 (currently single a node) with the IntersectingIterator.
The current index schema for the IntersectingIterator looks like this, for example:

    key1 : term1 : doc1
    key1 : term2 : doc1
    key2 : term3 : doc1

I've noticed that I can't intersect terms which are in distinct key-ranges.
Is that a correct behavior, or I'm doing something wrong?

Extract of my code (Scala) as example:

    val bs = conn.createBatchScanner(tableName, authorizations, numQueryThreads)
    val terms = List(new Text("term1"), new Text("term2")).toArray

    val ii = new IteratorSetting(priority, name, iteratorClass)
    IntersectingIterator.setColumnFamilies(ii, terms)

    bs.setRanges(Collections.singleton(new Range()))  // all ranges

    for (entry <- bs.asScala.take(100)) yield {

This will yield "doc1" as expected.

But if I'll choose the terms like this:

    // ...
    val terms = List(new Text("term1"), new Text("term3")).toArray
    // ...

It will yield "null" but I would expect here also "doc1".
I've also tried this with setting a list of Range.exact,
but I'll get also "null".

I'm doing something wrong?

Thank you in advance!


Sven Hodapp, M.Sc.,
Fraunhofer Institute for Algorithms and Scientific Computing SCAI,
Department of Bioinformatics
Schloss Birlinghoven, 53754 Sankt Augustin, Germany

View raw message