70 Commits

Author SHA1 Message Date
Harpreet Sangar
1128f7f9dd
Merge join conditions of embedded filter_by and query filter_by (#1935)
* Move joins related functions into `Join` class.

* Add `Join::merge_join_conditions`.

* Handle join condition merge in a complex embedded filter.

* Add test case and comments.

* Fix if condition.
2024-09-06 16:39:11 +05:30
Harpreet Sangar
08c0a087a1 Support nested join. 2024-01-02 14:14:21 +05:30
Harpreet Sangar
4bd1619cd6 Parse nested reference include_fields. 2023-12-27 10:34:36 +05:30
krunal
7126aa8024 fix open quotes search query bug 2023-12-21 17:39:59 +05:30
Harpreet Sangar
35fc560ed9 Move get_reference_collection_names out of StringUtils. 2023-07-21 11:30:20 +05:30
Harpreet Sangar
0334f5e534 Include/Exclude reference fields. 2023-07-14 17:32:26 +05:30
Kishore Nallan
7515e733db Move range facet parsing to cpp file. 2023-05-03 13:47:30 +05:30
Kishore Nallan
8ebe92dbe2 Fix bug in range facet string parsing. 2023-05-03 11:37:27 +05:30
Harpreet Sangar
b1ef695461 Reference include_fields. 2023-02-09 11:50:58 +05:30
Kishore Nallan
b8b9fb20b3 Merge branch 'v0.24-nested' into v0.25
# Conflicts:
#	include/collection.h
#	src/collection.cpp
#	src/collection_manager.cpp
#	test/collection_faceting_test.cpp
2023-01-03 09:42:21 +05:30
Kishore Nallan
1a66a25e2f Enable slow searches logging by default (30s cutoff) 2023-01-02 18:53:36 +05:30
Krunal Gandhi
2e8ad0f7c3
Range faceting (#823)
* facet range base commit

* ammending range checks to strictly abide to range, ignoring outliers

* range facet query parsing and results

* Making facet processing generic for both
range and non-range facets

* Adding facet parsing tests and bug fixes

* Adding range facet search tests and some refactoring

* Refactoring and adding more tests for seach. adding Range should be continuous check

* Refactoring the code

* making test case asserts more verbose

Co-authored-by: Kishore Nallan <kishorenc@gmail.com>
2022-12-14 15:49:14 +05:30
Kishore Nallan
6dc2df2376 Don't trim when splitting POST body. 2022-12-08 13:09:58 +05:30
Harpreet Sangar
9651c1abdf
Add Tokenize test. (#756)
* Add Tokenize test.

* Add Tokenize test case.

* Review changes.
2022-10-18 12:07:39 +05:30
Harpreet Sangar
f75cbca920
Filter query (#737)
* Implement advance filter query parser.

* Remove `exclude_filters`.

* Review changes

* Implement do_filtering2

* Use updated implementation

* Pass failing tests.

* Handle special characters in value.

* Add space around  in embedded filters

* Update tokenize

* Rename to `recursive_filtering`

* Deconstruct filter tree.

* Remove separating space requirement for operators

* Fix rebase errors.

* Undo filter override change

* Format changes

* Pass StaticFilteringMultipleRuleMatch

* Undo formatting changes

* Pass DynamicFilteringMultipleRuleMatch

* Review changes.

* Add filter_query guard.
2022-10-11 11:21:20 +05:30
Kishore Nallan
7b59f10d46 Fix float validation to handle scientific notation. 2022-10-06 11:46:47 +05:30
Kishore Nallan
11d157463c Fix unicode character boundary highlighting. 2022-07-28 17:59:16 +05:30
Kishore Nallan
b3b591d9dd Option to log requests. 2022-04-27 16:53:15 +05:30
Kishore Nallan
66cb71039f Do drop tokens at a global level. 2022-03-23 18:53:48 +05:30
Kishore Nallan
87e8e7b0ce Fix match contains edge case on overrides. 2022-03-01 13:34:48 +05:30
Kishore Nallan
ba91e69c04 Proper error in API response when GET query > 4K chars. 2021-10-27 21:20:31 +05:30
Kishore Nallan
6da39ff51c Expose write stats. 2021-10-02 18:54:30 +05:30
Kishore Nallan
947a5019d9 Handle override with synonyms. 2021-10-02 08:07:08 +05:30
Kishore Nallan
35409f8493 Batched background indexer.
Enables write parallelism across collections.
2021-07-31 21:44:06 +05:30
Kishore Nallan
56d3a26cc5 Imporve prefix searching on ko locale. 2021-05-31 19:47:12 +05:30
Kishore Nallan
b817e615cb Ensure floating point precision is correct when faceted. 2021-05-21 19:01:39 +05:30
Kishore Nallan
999a62b64c Support use of backticks for wrapping string filter value. 2021-05-09 15:55:48 +05:30
Kishore Nallan
1d1712f391 Refactor tokenizer to use index, skip and separate logic. 2021-04-16 17:55:52 +05:30
kishorenc
b9f3829b43 Refactor query string parsing to not use regexp. 2021-03-03 19:47:02 +05:30
kishorenc
11c41804e5 Handle bad data gracefully. 2021-02-20 12:49:41 +05:30
kishorenc
e5c3cddfcc Log hash of key also when logging key prefix. 2021-02-19 13:11:35 +05:30
kishorenc
6997e35f72 Combine various token operations in a single flow.
Splitting, normalizing etc. are now done in a single loop.
2020-11-17 20:10:34 +05:30
kishorenc
6c1455bc2f Return matched tokens in highlight response structure.
Also, allows customization of the highlighting tag used (default being the mark tag).
2020-11-17 20:10:34 +05:30
Kishore Nallan
a692553909 Support single document upsert. 2020-10-22 19:02:06 +05:30
Kishore Nallan
60d4e9bf5a Support upsert during import. 2020-10-10 18:09:17 +05:30
kishorenc
13fd927944 Fix crash when an int32 field is filtered with an int64 value. 2020-09-07 19:23:11 +05:30
kishorenc
80a3e0fb87 Throttle imports.
Ensure that other queries are not blocked when an import is in progress.
2020-08-18 18:32:19 +05:30
kishorenc
0cdd58e86c Validate group limit & other numerical parameters of search. 2020-06-30 15:58:32 +05:30
kishorenc
ba80f06001 Generate whole key without relying on seed based generation. 2020-06-25 17:09:07 +05:30
kishorenc
f1d0f279c7 Support for pinning and hiding hits during query time. 2020-05-21 12:46:51 +05:30
kishorenc
1395d74d48 Manage scoped search API keys. 2020-04-30 14:21:39 +05:30
kishorenc
29b4225461 API Key management. 2020-04-27 21:43:24 +05:30
kishorenc
75a1fe1e1d Use hashmap for storing routes instead of an array.
The use of array index makes rolling updates tricky since requests might be forwarded to an instance running an older/newer version having a different route index.
2020-03-26 14:08:06 +05:30
kishorenc
df08df5d96 Exit cleanly from raft service on validation errors. 2020-03-17 07:43:22 +05:30
kishorenc
31e9e4719a Compute stats on all facet values regardless of facet query. 2020-03-01 21:18:45 +05:30
kishorenc
67c2169b88 Fixed an issue with facet query containing multiple tokens. 2020-02-18 20:30:15 +05:30
kishorenc
dfbe3888d8 Refactor facet search to use hash based mapping.
Also fixed a bug where filter fields marked as facets were being searched only verbatim.
2020-02-16 17:41:17 +05:30
kishorenc
457bbcf467 Ensure strings with both ASCII and non-ASCII entities are indexed properly.
Earlier, such strings were being indexed only partially in certain cases.
2019-10-03 19:22:29 +05:30
Kishore Nallan
c1b9501351 Lay foundations for overriding search results. 2019-08-10 19:46:37 +05:30
Kishore Nallan
ad72f36dd6 Address valgrind warnings. 2018-09-04 16:44:38 +05:30