Commit Graph
582 Commits
Author SHA1 Message Date
Florian Schade 301a60e99b Merge pull request #4123 from fschade/search-extraction-retry
feat(search): retry extractions tika could not answer during a walk
2026-11-25 14:34:50 +01:00
Florian Schade b6a3e39f08 fix(search): count only extractions that reach tika in the walk 2026-11-25 14:02:20 +01:00
Florian Schade b7a169671d fix(search): probe tika version to tell a hanging tika from a slow file 2026-11-25 13:34:16 +01:00
Florian Schade 960ff63db3 fix(search): count extraction timeouts against the file, retry on 429 2026-11-25 13:21:45 +01:00
Florian Schade 12e7b86344 fix(search): retry only unreachable extractions and bound each attempt 2026-11-25 12:29:02 +01:00
Florian Schade debbeae2cb feat(search): retry extractions tika could not answer during a walk 2026-11-25 11:13:32 +01:00
Dominik Schmidt c3a08d88da fix(search): answer text on numeric and date fields the same on both engines
A text restriction on a numeric field reached the engines as is. bleve found nothing for size:>100 or size:50..500, OpenSearch failed the search with a number format exception. size=50 only matched on OpenSearch.

Both engines now read the value of such a restriction as a number and match it as a whole, with : and with =. Anything that is no number matches nothing, and so does text on a date field. size:>100 is not KQL, the range form is size>100; old iOS clients still send the colon form.

The field type comes from one table of all fields, built from the walk the mapping validation uses. It replaces the separate walk for numeric fields, which left out the parts of a location: location.altitude>1000 now matches, the parts are indexed as numbers next to the geopoint.

The parity suite covers >=, <=, combined ranges, number equality, the colon forms and the location parts.
2026-11-25 10:58:30 +01:00
Florian Schade cf5a087de2 fix(search): index files by name while tika is unreachable 2026-11-24 17:51:11 +01:00
Florian Schade 7577dbfd5d fix(search): cap and space the retries of unparsable files 2026-11-24 17:37:54 +01:00
Florian Schade 8dc18b7f1d refactor(search): drop UpsertItem and reuse the stat in UpdateMetadata 2026-11-24 16:44:45 +01:00
Florian Schade 23f890cd62 fix(search): index failed extractions by name and retry them 2026-11-24 16:23:29 +01:00
Florian Schade 6cfc198663 fix(search): keep existing index entries out of the upgrade reindex 2026-11-24 16:20:57 +01:00
Florian Schade 4e3d952c13 fix(search): keep tika out of tag updates and retry incomplete extractions 2026-11-24 14:12:19 +01:00
Florian Schade 9afb99f54a Merge pull request #4096 from fschade/feat-search-photo-props-numeric-ranges
feat(search): return photo metadata and allow ranges on numeric fields
2026-11-23 17:33:06 +01:00
Florian Schade 5fe4935e7f feat(search): return photo metadata and allow ranges on numeric fields 2026-11-23 15:47:15 +01:00
Florian Schade 4c25436e4e fix(search): descend into unchanged folders and skip failed uploads 2026-11-23 15:33:09 +01:00
Andre Duffeck 9200fac9b8 Merge pull request #4030 from opencloud-eu/fix/search-debouncer-double-run
fix(search): run the debounced work once when both timers fire
2026-11-18 10:28:04 +01:00
André Duffeck 2b77cb9a17 Bump reva to v3.0.1 2026-11-17 12:45:18 +01:00
Dominik Schmidt ca733e731f fix(search): run the debounced work once when both timers fire
Every pending space has a debounce timer and a timeout timer, and both
call the same work function. The function checked for a run in progress
before taking the mutex, so when both timers were due together, both
calls passed the check and the space was indexed twice at the same
time.

Take the mutex first and return when the work item is no longer the
pending one.

This is also what made "fires at the timeout even when continuously
debounced" flaky: its two timers are due about 50ms apart, which is
close enough on a busy CI runner.
2026-11-17 12:06:59 +01:00
Jörn Friedrich Dreyer a7b21848cf test(search): wait for the first debouncer run instead of sleeping
"doesn't trigger twice simultaneously" slept 100ms and assumed the
first run had started by then. On a busy CI runner the 50ms debounce
timer can fire later. The second Debounce then only resets the pending
timer, both calls collapse into one run and the count never reaches 2:

  [FAILED] Timed out after 2.001s.
  Expected <int>: 1 to equal <int>: 2

The run now blocks on a channel until the test releases it. We wait
for the first run to start, check that the second debounce does not
start another run while it is in progress, then release it and expect
the second run.

Assisted-by: Claude Code:claude-opus-5-5
Signed-off-by: Jörn Friedrich Dreyer <jfd@butonic.de>
2026-11-13 17:41:56 +01:00
Michael Barz 80d187eeb6 Merge pull request #3620 from jmrplens/fix-search-index-grpc-tls
fix(search): honor the gRPC client TLS mode in the index command
2026-11-12 11:03:34 +01:00
2435420f69 [full-ci] chore: bump reva to 2.52.2 (#3955)
* chore: bump reva to 2.52.2

* Merge pull request #42 from opencloud-eu/fix-web-theme-merge

fix(web): merge copies of the theme sources so themeDefaults is never mutated

* Merge pull request #43 from opencloud-eu/fix-search-trailing-not

fix(search): handle missing operands in the bleve compiler

* Merge pull request #44 from opencloud-eu/fix-search-highlight-escaping

fix(search): escape file content in OpenSearch highlights

---------

Co-authored-by: Ralf Haferkamp <r.haferkamp@opencloud.eu>
Co-authored-by: Florian Schade <f.schade@icloud.com>
2026-11-11 14:14:34 +01:00
André Duffeck 5bda7ddc9b Document the memory bleve needs for merging 2026-11-09 08:21:57 +01:00
André Duffeck a88477aa73 Write one bleve batch at a time
bleve keeps the analysis of a whole batch in memory until it is written, so
batches of spaces reindexed in parallel stacked up their memory.
2026-11-04 15:47:44 +01:00
André Duffeck 51b7c8b0d3 Bound the memory of bleve indexing batches
Push a batch at 16 MiB of document data or before a document would overflow
it. Reindexing large text files ran out of memory otherwise.
2026-11-04 15:47:33 +01:00
Andre Duffeck 12d8edb6e7 Merge pull request #3858 from aduffeck/kql-quote-escaping
Support doubled quotes in KQL values
2026-11-02 08:56:40 +01:00
Andre Duffeck 70fbc9fcb6 Merge pull request #3516 from opencloud-eu/fix/search-kql-path-normalization
fix(search): normalize KQL path once
2026-10-30 16:18:52 +01:00
Andre Duffeck 4118cd0b11 Merge pull request #3142 from opencloud-eu/fix/opensearch-bulk-item-errors
fix(search): report rejected documents when indexing to OpenSearch
2026-10-30 16:18:49 +01:00
Dominik Schmidt e1f313be98 fix(search): keep a leading wildcard in place of the KQL path prefix 2026-10-30 12:56:41 +01:00
Dominik Schmidt ff482878d3 fix(search): keep pushing a batch after a rejected bulk, join the errors 2026-10-30 11:53:45 +01:00
Dominik Schmidt 4a720c1a86 fix(search): resolve KQL path values like the scope path 2026-10-30 11:23:00 +01:00
Andre Duffeck b8cc9c6eb5 Merge pull request #3496 from opencloud-eu/fix/search-geopoint-range
fix(search): index resources with out-of-range coordinates without a geopoint
2026-10-30 11:08:31 +01:00
Dominik Schmidt 9a870295d9 perf(search): skip unchanged facet keys when storing metadata 2026-10-30 10:06:51 +01:00
André Duffeck ad834302be Remove facet metadata the indexer no longer extracts 2026-10-29 15:57:56 +01:00
André Duffeck fef2b7e3fa Support doubled quotes in KQL values
Fixes #3666
2026-10-29 10:00:59 +01:00
Viktor Scharf ae4970d92c chore: bump reva to 2.52.0 (#3820) 2026-10-27 12:46:43 +01:00
Dominik Schmidt da8d490982 test(search): port the batch specs to ginkgo 2026-10-27 10:57:27 +01:00
Dominik Schmidt ff6b17177e Apply suggestion from @dschmidt 2026-10-27 10:55:36 +01:00
Dominik Schmidt 8aef6c5c22 fix(search): print delete by query failures as json 2026-10-27 10:55:36 +01:00
Dominik Schmidt 29da827436 fix(search): report rejected documents when indexing to OpenSearch 2026-10-27 10:55:36 +01:00
André Duffeck 23c1fb67aa Skip extraction for directories before checking the size limit
That gets rid of confusing log messages like

```
2026-10-27T08:57:23+01:00 INF file exceeds content extraction size limit. skipping. Name=Admin ..."
```
2026-10-27 08:51:45 +01:00
Florian Schade 9d972f193e fix(search): expand is:favorite in place 2026-10-23 10:58:36 +02:00
Florian Schade a87aec0722 fix(search): strip the scope clause together with its boolean operator 2026-10-23 10:20:05 +02:00
Florian Schade 385062271d feat(search): turn the query filter into a template 2026-10-22 22:46:06 +02:00
Florian Schade 3fe11ea60a feat(search): configurable query filter 2026-10-22 20:05:31 +02:00
Dominik Schmidt 41bdc8ab76 fix(search): index a resource with out-of-range coordinates without a geopoint
Corrupt EXIF (latitude beyond 90, longitude beyond 180) made OpenSearch reject the whole document on the geo_point sibling while bleve indexed it at the pole. Both engines now skip the sibling and keep the location object; the parity suite pins it.
2026-10-15 15:50:51 +02:00
Dominik Schmidt f6a18209ef fix(search): normalize KQL path once
The trailing slash is trimmed in the normalizer instead of in each compiler; an empty path is the space root.
2026-10-15 15:50:48 +02:00
micbar 3662a94ca7 fix: nats checks were missing the configured auth 2026-10-14 17:45:44 +02:00
Andre Duffeck 8f2adf2138 Reindex disabled spaces once they get enabled again (#3579)
Spaces that are disabled while reindexing are skipped. They are now
remembered in a NATS KV bucket (including whether a forced rescan was
requested) and reindexed when the SpaceEnabled event comes in. The
entry is removed when the space gets deleted.
2026-10-05 14:28:58 +02:00
José M. Requena Plens 283bbe4ee3 docs(search): extend the --insecure note to 8.1.x [docs-only]
8.1.0 ships before this fix, so it still needs the flag too.
2026-10-04 23:34:06 +02:00