0
0
Commit Graph

1384 Commits

Author SHA1 Message Date
Marty Schoch
c351931701 Merge branch 'slavikm-master4' 2016-11-28 15:00:48 -05:00
Marty Schoch
c927e124dd Merge branch 'master' of https://github.com/slavikm/bleve into slavikm-master4 2016-11-28 14:03:35 -05:00
slavikm
75c8c0e2b1 Revert the nil protection which is not needed 2016-11-23 09:26:07 -08:00
slavikm
20b847f04e Added protection again nil Boost 2016-11-22 13:04:36 -08:00
slavikm
a4c94e440e Added missing boost getters 2016-11-22 12:50:08 -08:00
Marty Schoch
58fe9b9562 Merge pull request #502 from pmezard/fix-docidreader-next-doc
index: DocIDReader.Next() returns nil when done not io.EOF
2016-11-20 13:16:35 -05:00
Patrick Mezard
c81fd6fdb0 index: DocIDReader.Next() returns nil when done not io.EOF 2016-11-20 19:05:35 +01:00
Marty Schoch
3da28dfbc1 Merge pull request #499 from mschoch/498
add support for parsing BoolFieldQuery from JSON
2016-11-16 11:50:44 -05:00
Marty Schoch
d372602f3c add support for parsing BoolFieldQuery from JSON
presence of the "bool" key triggers parsing as a BoolFieldQuery
fixes #498
2016-11-15 10:29:11 -05:00
slavikm
187d6013df Make sure getters follow the Go convention 2016-11-14 15:30:07 -08:00
slavikm
339ddbe0fa Added getters to boost and field query interfaces 2016-11-14 14:02:43 -08:00
Silvan Jegen
1a6a4c493b Check locations in the phrase searcher as well 2016-11-08 20:05:36 +01:00
Silvan Jegen
33e2432fc6 Initialize the return value as late as possible 2016-11-08 20:05:36 +01:00
Silvan Jegen
3dd363afaa Don't search the same term twice
We have searched for the first term in the phrase query already so we
can skip it. Before doing so we have to add the location of the first
term.
2016-11-08 20:05:04 +01:00
Silvan Jegen
d87b4f88bf Refactor phrase searching
Reduce nesting by using early continues.
2016-11-08 20:04:28 +01:00
Marty Schoch
bcaea084c5 Merge pull request #496 from mschoch/fix495
fix date facets when using MultiSearch
2016-11-04 15:06:57 -04:00
Marty Schoch
8e2159cbe4 Merge pull request #494 from steveyen/MB-21474
simplified MultiSearch requires that indexes honor context deadlines
2016-11-04 15:06:47 -04:00
Marty Schoch
647bfd10ad fix date facets when using MultiSearch
changed date parsing to NOT update internal state of the date
range object (avoids races)

second, when marshaling a facet date range, we now use the
string version, if the time.Time is zero and the string version
is not ""
2016-11-04 14:02:01 -04:00
Steve Yen
dc2b6cd656 simplified MultiSearch requires that indexes honor context deadlines
MultiSearch previously had its own timeout checking.  This commit
removes that timeout checking, so that now MultiSearch instead depends
upon the bleve.Index implementations to perform their own context
deadline/timeout checking.

Because deadline/timeout checking is now handled by the bleve.Index
implementations, this change allows applications to provide richer
error and status results during timeouts.
2016-11-03 16:44:20 -07:00
Marty Schoch
a3f8953c9f Merge pull request #493 from mschoch/fix492
numeric range facet merging compare range values not pointers
2016-11-03 16:28:04 -04:00
Marty Schoch
e5ec831250 numeric range facet merging compare range values not pointers
fix #492
2016-11-03 15:48:46 -04:00
Marty Schoch
81c76f2a4a Merge pull request #490 from steveyen/master
optimize NewRegexpSearcher to return its disjunction searcher
2016-10-31 10:39:50 -04:00
Steve Yen
adc409e823 optimize NewRegexpSearcher to return its disjunction searcher
This minor optimization removes an unnecessary wrapper around the
disjunction searcher.
2016-10-27 13:16:41 -07:00
Marty Schoch
1bd6451581 Merge pull request #487 from steveyen/optimize-facets-builder
Minor facets builder optimizations
2016-10-26 14:14:25 -04:00
Marty Schoch
f45584bf54 Merge pull request #486 from robmccoll/feature/overridejsontag
adding override for "json" in struct tags, tests
2016-10-26 14:11:22 -04:00
Steve Yen
2a8237e8cc optimize FacetsBuilder with cached fields & avoid some allocs 2016-10-25 15:34:48 -07:00
Steve Yen
a941a0f318 simplify DocumentFieldTerms append() usage 2016-10-25 15:30:19 -07:00
rob mccoll
43b5b36a19 adding override for "json" in struct tags, tests 2016-10-25 10:42:40 -04:00
Marty Schoch
ef28c7f9e0 Merge pull request #485 from mschoch/mousetrap
vendor mousetrap
2016-10-24 14:29:45 -04:00
Marty Schoch
1061636c9d vendor mousetrap
our policy has been to vendor the libraries required for the
command-line portion of the bleve command-line tool.  this
included spf13/cobra etc, unfortunately we missed this library
as it is only required for windows users.
2016-10-24 13:54:29 -04:00
Marty Schoch
bc0758b98a Merge pull request #483 from robmccoll/patch-2
Doc: JSONable config, KVStore <-> KVStoreConstructor
2016-10-24 12:15:34 -04:00
Marty Schoch
aaa686869c Merge pull request #484 from mschoch/blevecheck
add the bleve check tool
2016-10-22 19:41:25 -04:00
Marty Schoch
9174872ba2 add the bleve check tool
bleve check was a consistency checking tool originally developed
as a part of cbft.  currently it checks that the term dictionary
counts match the number of postings for the term.  in the future
additional checks could be added.  this tool has been back
ported to bleve as we've now adopted a single common tool for
both cbft and bleve.
2016-10-22 06:11:50 -04:00
Marty Schoch
09fc57c5db Merge pull request #482 from steveyen/MB-21377
revert optimization that trims search-disjunction child searchers
2016-10-22 05:50:55 -04:00
Rob McColl
12c404aec0 Update kvstore.go 2016-10-19 10:31:00 -04:00
Rob McColl
87c7e9915e KVStoreConstructur doc 2016-10-19 10:28:44 -04:00
Rob McColl
414d21a541 Add comment about JSON serialization of kvconfig 2016-10-19 10:19:14 -04:00
Steve Yen
58c3b5c9b8 revert optimization that trims search-disjunction child searchers
This commit reverts a previous optimization attempt 3f588cd4a that
tried to trim or shrink the array of child searchers in a
search-disjunction.

Although I am not sure why at the moment, that optimization
incorrectly broke higher level boolean queries, but reverting so that
functionality is restored.
2016-10-18 14:38:34 -07:00
Marty Schoch
bfec4f23c0 Merge pull request #481 from robmccoll/patch-1
Fix NumDeletes doc copy/paste err s/Merge/Delete/g
2016-10-17 18:26:11 +01:00
Rob McColl
2b26218591 Fix NumDeletes doc copy/paste err s/Merge/Delete/g 2016-10-17 12:42:21 -04:00
Marty Schoch
77b79a2684 Merge pull request #466 from steveyen/optimize-fieldDict-reader-with-prealloc
Optimize upside-down's field dict reader with preallocated objects
2016-10-13 14:09:54 +02:00
Marty Schoch
5c7a2264a2 Merge pull request #473 from steveyen/reuse-incrementBytes-in-moss-kv-integration
reuse incrementBytes() in moss KV store integration
2016-10-13 14:03:46 +02:00
Marty Schoch
cee18d302e Merge pull request #475 from steveyen/phrase-searcher-simplifications-dry
some simplification / DRY for phrase searcher
2016-10-12 23:07:35 +02:00
Marty Schoch
ac02b206e5 Merge pull request #476 from steveyen/optimize-fuzzy-searcher-prefixTerm-loop
end fuzzy searcher prefixTerm construction loop early
2016-10-12 23:04:50 +02:00
Marty Schoch
8b409d7ab9 Merge pull request #477 from steveyen/fix-BleveQueryType-json-marshaling
fix BleveQueryTime json marshaling with double-quoting
2016-10-12 23:04:08 +02:00
Steve Yen
32e459f6b6 fix BleveQueryTime json marshaling with double-quoting
See also MB-21322 found by Mihir Kamdar.
2016-10-12 11:39:08 -07:00
Steve Yen
1a994ce2a7 end fuzzy searcher prefixTerm construction loop early 2016-10-12 09:51:36 -07:00
Steve Yen
6a38fa3719 go fmt 2016-10-12 09:39:43 -07:00
Steve Yen
62e6f1f648 reuse incrementBytes() in moss KV store integration
In this commit, I saw that there was a simple incrementBytes()
implementation elsewhere in bleve that seemed simpler than using the
big int package.

Edge case note: if the input bytes would overflow in incrementBytes(),
such as with an input of [0xff 0xff 0xff], it returns nil.  moss then
treats a nil endKeyExclusive iterator param as a logical
"higher-than-topmost" key, which produces the prefix iteration
behavior that we want for this edge situation.
2016-10-12 09:34:36 -07:00
Steve Yen
8230a7195f some simplification / DRY for phrase searcher 2016-10-12 09:26:31 -07:00