aboutsummaryrefslogtreecommitdiffstats
path: root/searchlib/src/tests/attribute/bitvector/bitvector_test.cpp
diff options
context:
space:
mode:
authorGeir Storli <geirst@yahooinc.com>2024-01-22 13:45:32 +0000
committerGeir Storli <geirst@yahooinc.com>2024-01-24 09:56:58 +0000
commit233da25510548e8a1033e1bbf0a506135ea85b42 (patch)
tree309838b1750e6c45c155098f539ada45f916bc96 /searchlib/src/tests/attribute/bitvector/bitvector_test.cpp
parent2a43344d217ab065425e880cd35be54542423ce8 (diff)
Support IDocidWithWeightPostingStore for more attribute data types.
This includes array types (in addition to weighted set) and all integer types. This change also aligns the blueprint and iterator implementations used for WeightedSetTerm and InTerm, making the performance of WeightedSetTerm more similar to InTerm. In particular an attribute with "rank: filter" uses a more optimal search iterator for WeightedSetTerm.
Diffstat (limited to 'searchlib/src/tests/attribute/bitvector/bitvector_test.cpp')
-rw-r--r--searchlib/src/tests/attribute/bitvector/bitvector_test.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/searchlib/src/tests/attribute/bitvector/bitvector_test.cpp b/searchlib/src/tests/attribute/bitvector/bitvector_test.cpp
index f612bdda87f..6e479e1d9db 100644
--- a/searchlib/src/tests/attribute/bitvector/bitvector_test.cpp
+++ b/searchlib/src/tests/attribute/bitvector/bitvector_test.cpp
@@ -430,7 +430,8 @@ BitVectorTest::test(BasicType bt, CollectionType ct, const vespalib::string &pre
sc = getSearch<VectorType>(tv, filter);
checkSearch(v, std::move(sc), 2, 1022, 205, !filter, true);
const auto* dww = v->as_docid_with_weight_posting_store();
- if (dww != nullptr) {
+ if ((dww != nullptr) && (bt == BasicType::STRING)) {
+ // This way of doing lookup is only supported by string attributes.
auto lres = dww->lookup(getSearchStr<VectorType>(), dww->get_dictionary_snapshot());
using DWSI = search::queryeval::DocidWithWeightSearchIterator;
TermFieldMatchData md;