0
0
Commit Graph

725 Commits

Author SHA1 Message Date
Silvan Jegen
84c755cdb0 Add tests for fuzzy search 2015-12-20 17:00:46 +01:00
Marty Schoch
f7698f1f15 support match_all, match_none and docid queries via JSON
also fixed bug in docIDQuery execution which would cause not
matching the highest docID passed in if it was in fact a
valid ID
2015-12-16 14:53:14 -05:00
Marty Schoch
849b69c318 more enhancements to bleve_query 2015-12-16 14:52:33 -05:00
Marty Schoch
cf67fe2cbc fix major synchronization issue in the field_cache
The field cache is expected to be the authority on which field
names are identified by which identifier.  This code was
optimized for the most common case in which fields already
exist.  However, if we deterimine the field is missing with
the read lock (shared), we incorrectly immediately proceed
to create a new row with the write lock (exclusive).  The
problem is that multiple goroutines might have come to
the same conclusion, and they all proceed to add rows.  The two
choices were to do the whole operation with the write lock, or
recheck the value again with the write lock.  We have chosen
to repeat the check inside the write-lock, as this optimizes
for what we believe to be the most common case, in which most
fields will already exist.
2015-12-15 16:39:38 -05:00
Marty Schoch
84ec206fec add some tests for index names in results 2015-12-08 14:38:46 -05:00
Marty Schoch
d73beac3b9 search result hits now have a field with the name of the index
this allows you to figure out where a result actually came
from when using aliases
2015-12-08 13:55:04 -05:00
Marty Schoch
9d30e1c96b Merge branch 'master' into give_indexes_names 2015-12-08 11:56:53 -05:00
Marty Schoch
b4d4ee2fff fix incorrect results returned by phrase search
previously phrase searcher would not validate that consecutive
terms were actually occurring in the same array position

fixes #292
2015-12-06 15:55:00 -05:00
Marty Schoch
6e9da3bab7 allow running prefix queries through bleve_query command 2015-12-06 14:01:53 -05:00
Marty Schoch
aa7658bbb0 give indexes names, make stats available via expvar by default 2015-12-06 14:01:03 -05:00
Marty Schoch
a73a178923 fix incorrect prefix search behavior
avoids double incrementing of end term when reading term dict
fixes #293
2015-12-04 14:07:16 -05:00
Marty Schoch
699c86073a make existing integration tests work with firestorm 2015-12-01 12:29:56 -05:00
Marty Schoch
9777846206 Merge branch 'master' into firestorm 2015-11-30 15:02:46 -05:00
Marty Schoch
e472b3e807 add support for a "web" tokenizer/analyzer
The goal of the "web" tokenizer is to recognize web things like
- email addresses
- URLs
- twitter @handles and #hashtags

This implementation uses regexp exceptions.  There will most
likely be endless debate about the regular expressions. These
were chosein as "good enough for now".

There is also a "web" analyzer.  This is just the "standard"
analyzer, but using the "web" tokenizer instead of the "unicode"
one.  NOTE: after processing the exceptions, it still falls back
to the standard "unicode" one.

For many users, you can simply set your mapping's default analyzer
to be "web".

closes #269
2015-11-30 14:27:18 -05:00
Marty Schoch
6d851cfcc2 fix bug in warmup which led to docs being deleted 2015-11-30 10:18:14 -05:00
Marty Schoch
aa8d98f5fa include space after prefix in log output 2015-11-30 10:17:48 -05:00
Marty Schoch
68d8742826 correctly prefix internal rows with 'i' and print them in debug 2015-11-30 10:17:15 -05:00
Marty Schoch
17cfe8cff0 Merge branch 'master' into firestorm 2015-11-30 07:25:33 -05:00
Marty Schoch
b2ac05c6d0 support metrics through bleve query 2015-11-30 07:24:31 -05:00
Marty Schoch
c93de9734e fix issues identified by errcheck 2015-11-24 14:32:33 -05:00
Marty Schoch
bbef1980d8 Merge branch 'master' into firestorm 2015-11-24 13:04:36 -05:00
Marty Schoch
808f2c1e43 remove exceptions from errcheck 2015-11-24 12:52:46 -05:00
Marty Schoch
ff11f83842 properly handle errors inside metrics kvstore reporting 2015-11-24 12:52:03 -05:00
Marty Schoch
a707d44e0b Merge branch 'master' into firestorm 2015-11-24 09:44:47 -05:00
Marty Schoch
3729ac67ea remove bleve mapping from errcheck exclusion list 2015-11-23 12:40:50 -05:00
Steve Yen
2d4cd7a696 go fmt index_text.go 2015-11-23 09:28:09 -08:00
Steve Yen
19c43af6d4 typo in lookupPropertyPathPart() func name 2015-11-23 09:27:22 -08:00
Steve Yen
ab3188becb http/mapping subdir replaced by blevesearch/bleve-mapping-ui
The bleve mapping UI is now moved / replaced, and is available at...

   github.com/blevesearch/bleve-mapping-ui
2015-11-23 09:23:52 -08:00
Marty Schoch
fcf3980cea set GIT_BRANCH to TRAVIS_BRANCH 2015-11-23 11:10:55 -05:00
Marty Schoch
b5af97bc60 try TRAVIS_BRANCH 2015-11-23 11:01:57 -05:00
Marty Schoch
12273c369e try to fix confusing output 2015-11-23 09:39:43 -05:00
Marty Schoch
bd22b664c4 print branch name to output 2015-11-23 09:08:40 -05:00
Marty Schoch
89af187fb0 set branch to master to fix goveralls badge 2015-11-23 08:54:47 -05:00
Marty Schoch
16eecd50b4 Merge branch 'MachineShop-IOT-datetimefm' 2015-11-23 08:42:10 -05:00
Marty Schoch
97735ac2b6 set github issue number in testcase name 2015-11-23 08:41:34 -05:00
Mark Mindenhall
17d8391b2f Fixes datetime mapping from JSON, using DateTimeFieldMapping 2015-11-20 19:15:35 -07:00
Marty Schoch
a1ce44fcd4 Merge pull request #284 from pmezard/add-indexmapping-fieldanalyzer
mapping_index: add IndexMapping.FieldAnalyzer()
2015-11-19 12:55:27 -05:00
Marty Schoch
46534d79ea Merge pull request #285 from pmezard/phrase-queries-need-term-vectors
mapping_field: document IncludeTermVectors
2015-11-19 12:53:38 -05:00
Patrick Mezard
1591ed1839 mapping_field: document IncludeTermVectors
And mention it is required for phrase and match phrase queries to
succeed.

Fix #280
2015-11-19 15:38:16 +01:00
Patrick Mezard
ff41dfec3d mapping_index: add IndexMapping.FieldAnalyzer()
It returns the name of the analyzer used on a field, which can be passed
to IndexMapping.AnalyzeText().

Fix #282
2015-11-19 11:20:32 +01:00
Marty Schoch
7dd52a5463 Merge pull request #279 from pmezard/expose-row-attributes
row: expose TermFrequencyRow term and freq fields
2015-11-17 12:24:16 -05:00
Patrick Mezard
e85c9c542e row: expose TermFrequencyRow term and freq fields
Rows content is an implementation detail of bleve index and may change
in the future. That said, they also contains information valuable to
assess the quality of the index or understand its performances. So, as
long as we agree that type asserting rows should only be done if you
know what you are doing and are ready to deal with future changes, I see
no reason to hide the row fields from external packages.

Fix #268
2015-11-17 17:21:26 +01:00
Marty Schoch
236cc156c5 Merge pull request #277 from marksamman/patch-1
Update NumericRangeQuery comments
2015-11-12 22:40:36 +00:00
Mark Samman
b3a1e21c12 Update NumericRangeQuery comments 2015-11-12 22:16:10 +01:00
Marty Schoch
7b22332b06 Merge pull request #271 from pmezard/docid-query
query_docid: add DocIDQuery to filter by document identifiers
2015-11-12 15:52:36 +00:00
Marty Schoch
bfbc2a6244 Merge pull request #273 from pmezard/document-token-map
token_map: document it along with stop_token_filter
2015-11-12 15:40:40 +00:00
Marty Schoch
eee4482964 Merge pull request #272 from kevgs/boltdb_optimize
BoltDB wrapper nano optimization which makes code a bit prettier too
2015-11-12 15:39:37 +00:00
Patrick Mezard
ff03874f19 token_map: document it along with stop_token_filter 2015-11-05 14:07:54 +01:00
Kosov Eugene
45e670b99b BoltDB wrapper nano optimization which makes code a bit prettier too 2015-11-05 00:27:28 +03:00
Patrick Mezard
19230b2f8a searcher_docid: catch DocIDReader.Close() possible error 2015-11-04 19:24:01 +01:00