0
0
Commit Graph

1183 Commits

Author SHA1 Message Date
Steve Yen
2d72b542c0 optimize upside-down FieldDict reader with prealloc'ed objects
As part of this commit, there's also a newly added
Dictionaryrow.parseDictionaryK() helper method.
2016-10-12 09:18:58 -07:00
Marty Schoch
d026a44230 Merge pull request #474 from steveyen/simplify-AddLocation
simplify TermLocationMap.AddLocation()
2016-10-12 14:20:50 +02:00
Marty Schoch
bddc064069 Merge pull request #471 from steveyen/remove-extra-indirection-LevenshteinDistance
removed extra level of pointer indirection from LevenshteinDistance()'s params
2016-10-12 14:05:34 +02:00
Marty Schoch
4160fb296f Merge pull request #470 from daschl/sigma
Address special unicode sigma at end of term when lowercasing.
2016-10-12 14:03:17 +02:00
Marty Schoch
483f06ef5b Merge pull request #467 from steveyen/optimize-disjunction-searcher-shrink-children
optimize disjunction searcher to trim child searchers array earlier
2016-10-12 14:00:19 +02:00
Marty Schoch
b76cbc805e Merge pull request #465 from steveyen/cleanup-when-PrefixSearcher-error
close resources when we encounter an error on PrefixSearcher initialization
2016-10-12 13:39:28 +02:00
Marty Schoch
4e16818656 Merge pull request #464 from steveyen/check-FieldDictPrefix-err
check for error when prefix searcher starts a FieldDictPrefix reader
2016-10-12 13:36:04 +02:00
Marty Schoch
155827aeef Merge pull request #462 from steveyen/master
log slow queries only when Config.SlowSearchLogThreshold > 0
2016-10-12 13:34:15 +02:00
Steve Yen
e72c8be353 simplify TermLocationMap.AddLocation() 2016-10-11 12:15:28 -07:00
Steve Yen
b6c97ddbfe removed extra ptr indirection from LevenshteinDistance 2016-10-11 08:49:10 -07:00
Michael Nitschinger
7e656dad32 Address special unicode sigma at end of term when lowercasing.
Σ maps to σ, except at the end of a word where it maps to ς.
This is the only conditional (contextual) but language-independent
mapping in unicode.
2016-10-11 12:37:08 +02:00
Marty Schoch
586c6ee1a3 Merge pull request #469 from daschl/optim-lowercase
Skip already lowercased runes on transformation.
2016-10-11 12:12:21 +02:00
Michael Nitschinger
ff35d75aa4 Skip already lowercased runes on transformation.
The LowerCaseFilter works on the original slice to avoid allocations,
so skipping already lowercased runes avoids unnecessary work.

benchmark                      old ns/op     new ns/op     delta
BenchmarkLowerCaseFilter-8     1302          815           -37.40%
2016-10-11 12:03:26 +02:00
Steve Yen
3f588cd4ae optimize disjunction searcher to trim child searchers array earlier
Disjunction searchers are used heavily by higher-level searchers, like
prefix searchers.  In that case, a disjunction searcher might have
many thousands of child searchers.

This commit adds an optimization to close each child term searcher as
soon as a child searcher is finished and remove it from the
disjunction searcher's children.
2016-10-10 22:47:11 -07:00
Steve Yen
535b746b41 close resources when error on PrefixSearcher initialization 2016-10-10 17:29:59 -07:00
Steve Yen
2a022830f0 check FieldDictPrefix err result in prefix searcher 2016-10-10 15:35:54 -07:00
Steve Yen
21b3d592b8 log slow queries only when Config.SlowSearchLogThreshold > 0 2016-10-10 11:34:32 -07:00
Marty Schoch
de0c26718d Merge pull request #461 from bcampbell/master
Settle on default fuzziness of 1 (for now)
2016-10-04 08:36:02 -04:00
Ben Campbell
11f18333fb Settle on default fuzziness of 1 (for now)
see https://groups.google.com/d/msg/bleve/vkVxnLMlXow/5qM1jL0ZEgAJ
2016-10-04 15:00:50 +13:00
Marty Schoch
dfc78ca725 simplify, per gofmt -s recommendation 2016-10-02 12:14:53 -04:00
Marty Schoch
2f48d7fb02 fix misspellings 2016-10-02 12:11:15 -04:00
Marty Schoch
2dc2130633 additional golint cleanups 2016-10-02 12:00:01 -04:00
Marty Schoch
efb1ea7e64 fix golint comment 2016-10-02 11:56:37 -04:00
Marty Schoch
8e784c362b another golint suggestions 2016-10-02 11:54:04 -04:00
Marty Schoch
abeca559cd don't export unnecessary method 2016-10-02 11:50:58 -04:00
Marty Schoch
1b4ee737e0 more golint fixes 2016-10-02 11:46:27 -04:00
Marty Schoch
ce572091eb additional golint cleanups 2016-10-02 11:44:34 -04:00
Marty Schoch
ee6b698edb rename variable with _ 2016-10-02 11:32:46 -04:00
Marty Schoch
667371dbec more golint simplifications 2016-10-02 11:30:58 -04:00
Marty Schoch
c36eb74ead address some golint suggestions 2016-10-02 11:14:09 -04:00
Marty Schoch
f05dc237ab fix comment in wrong format 2016-10-02 11:10:05 -04:00
Marty Schoch
f3dc89699d address golint warnings 2016-10-02 10:47:40 -04:00
Marty Schoch
cd6b409971 fix code i carelessly broke 2016-10-02 10:39:20 -04:00
Marty Schoch
d4d3e7a043 address golint naming issues 2016-10-02 10:35:24 -04:00
Marty Schoch
3a276153a3 actually rename packages to singular, not just directory name 2016-10-02 10:29:39 -04:00
Marty Schoch
2332455bd2 nicer formatting of license header 2016-10-02 10:13:14 -04:00
Marty Schoch
c452804e3d Merge pull request #460 from mschoch/morename
BREAKING CHANGE - additional package renaming
2016-10-02 09:00:22 -04:00
Marty Schoch
6bf9dd59ab BREAKING CHANGE - additional package renaming
i recently learned that package names should also prefer the
singular form, not the plural form
2016-10-01 17:20:59 -04:00
Marty Schoch
43a421653c Merge pull request #455 from steveyen/fieldCache-reverse-mapping
field cache also tracks fieldIndex -> fieldName reverse mapping
2016-10-01 16:23:03 -04:00
Steve Yen
004e157963 field cache also tracks fieldIndex -> fieldName reverse mapping 2016-10-01 13:06:03 -07:00
Marty Schoch
ca4384e9b5 Merge pull request #459 from steveyen/termSearchersFinished
more careful Close()'ing and fix for termSearchersFinished stat
2016-09-30 21:23:39 -04:00
Steve Yen
c362ab302e fix tracking of termSearchersFinished stats 2016-09-30 16:11:30 -07:00
Steve Yen
a9cb8779c3 more careful Close()'ing and cleanup of searchers
From diagnosing a recent issue where the termSearchersFinished stats
were incorrectly tracked, I ended up scouring the Close() / cleanup
codepaths.

This change takes more care in Close()'ing child searchers, especially
in error situations.  This can be important to allow underlying
kvstore's to release resources.
2016-09-30 16:07:01 -07:00
Marty Schoch
30b5cb86d1 Merge pull request #458 from mschoch/metricswork
Metrics Work
2016-09-30 16:34:55 -04:00
Marty Schoch
caf5256f74 don't export internal timers from metrics kvstore 2016-09-30 15:52:16 -04:00
Marty Schoch
5515f57ad1 Merge pull request #457 from mschoch/packagenames
Shorten package names and stop using "_"
2016-09-30 15:46:45 -04:00
Marty Schoch
d7298a6e97 remove commented out section found by @steveyen code review 2016-09-30 12:36:52 -04:00
Marty Schoch
a2dd037cdb BREAKING CHANGE - rename fragment_formatters -> format 2016-09-30 12:36:48 -04:00
Marty Schoch
c487f29a46 BREAKING CHANGE - rename numeric_util to numeric 2016-09-30 12:36:43 -04:00
Marty Schoch
f90856b8d3 BREAKING CHANGE - rename upside_down to upsidedown 2016-09-30 12:36:38 -04:00