Commit Graph
23801 Commits
Author SHA1 Message Date
Dominik Schmidt ac2f0944ef fix(search): pass order_by through the grpc service and cache key
The grpc layer rebuilt the searcher request field by field and dropped
order_by; the response cache also ignored it, so differently sorted
searches collided on the same cache entry.

(cherry picked from commit 97626bb26bd4fe8cdb74c19b519b2230c492681c)
2026-09-08 00:34:04 +02:00
Dominik Schmidt 79e616da3a feat(search): native order_by sorting in the opensearch backend
Name is analyzed (lowercaseKeyword) and therefore a text field, which
OpenSearch refuses to sort on without fielddata; enable it in the index
template. The keyword tokenizer emits one term per document, so the
fielddata cache stays small. The schema version has not shipped yet, so
no reindex is needed.

(cherry picked from commit f1d0e7b773b170b119dbd59fa176d656237bed96)
2026-09-08 00:26:03 +02:00
Dominik Schmidt 55b89d02d4 feat(search): native order_by sorting in the bleve backend
(cherry picked from commit 66a0755ad69a6a1af07e0b8335b08d63793777ce)
2026-09-08 00:25:48 +02:00
Dominik Schmidt eb6df66d13 feat(search): merge per-space results in order_by order
The fan-out passes order_by through to each engine query; the merge
re-sorts the combined matches with CompareMatches and keeps the score
as tiebreaker (and as the sole criterion when no order_by is given).

(cherry picked from commit 66af40fc34fd9daffc028ab06f83f7ade8a360d1)
2026-09-08 00:25:37 +02:00
Dominik Schmidt 641aa74a1e feat(search): allow sorting by any scalar hit field
Sortable is every field that is indexed as a scalar and carried on the
match entity: name, size, lastModifiedDateTime, mimeType and the scalar
facet fields (photo.*, audio.*, image.*, location.*, ...). Both sets
are derived by reflection, so new facet fields become sortable
automatically. Multivalued fields (tags), bare facets and internal
index fields are rejected with invalidRequest at the graph layer.
CompareMatches provides the merge comparator for the service layer.

(cherry picked from commit bd32795194cf3945e8416ede496a147ce8d6cb5c)
2026-09-08 00:25:28 +02:00
Dominik Schmidt da6809a2cb feat(graph): accept sortProperties on search requests
Validated against the sortable-field whitelist (name, size,
lastModifiedDateTime, photo.takenDateTime) and forwarded to the search
service as order_by. Also fixes the stub search service's IndexSpace
signature (streaming response) so the suite builds again.

(cherry picked from commit 9aa6a3492de3468da7a8480a3b9ef5748cee1f5d)
(cherry picked from commit 35a6cad8ea6a7890bdc0bc98c7ac97bdcbf477cc)
2026-09-08 00:25:02 +02:00
Dominik Schmidt 43f6efe403 feat(search): add sortProperties plumbing (libregraph model, proto order_by)
(cherry picked from commit 1b748fb757e2dde5b3cd1beaa543be4266342590)
2026-09-08 00:18:57 +02:00
Dominik Schmidt dfe5fdbb26 feat(search): metric objects, aggregationFilterToken and report parity
Migrate the graph search query to metricDefinition/searchMetric and the
@libre.graph prefixes. Add the aggregationFilterToken round-trip: encode
terms/range/or tokens on the response, pass aggregationFilters 1:1 to the
search service, decode them and force exact case-sensitive matches in both
backends. Map the WebDAV-report facets onto search hits: tags, video,
motionPhoto, livePhoto, allowedValues (from the space permission set),
me.following (favorite), webUrl (private link, shared helper) and
thumbnails via opt-in $expand.
2026-09-07 23:25:31 +02:00
Dominik Schmidt 5a92245286 chore(search): regenerate libre-graph-api-go and search protos
Regenerate the vendored libre-graph-api-go from the feat/search spec
(metricDefinition/searchMetric, @libre.graph.subAggregations,
aggregationFilterToken) and add aggregation_filters plus the
permissionsActionsAllowedValues entity field to the search protos.
2026-09-07 23:25:31 +02:00
Dominik Schmidt 07c7389104 Merge remote-tracking branch 'origin/main' into feat/graph-search-query 2026-09-07 23:20:22 +02:00
Dominik Schmidt d6c6b6fd0d Merge pull request #3481 from opencloud-eu/fix/proxy-signed-url-methods
fix(proxy): restrict JWT signed urls to the allowed HTTP methods
2026-09-07 16:13:40 +02:00
Dominik Schmidt 7f7a938c3f fix(proxy): restrict JWT signed urls to the allowed HTTP methods
The legacy OC-Signature path already rejects methods outside
PRE_SIGNED_URL_ALLOWED_HTTP_METHODS, the JWT path did not. A leaked
signed download url could be used for PUT, DELETE, MOVE or PROPFIND
as the signing user for the lifetime of the signature.
2026-09-07 13:00:09 +02:00
Dominik Schmidt 81536bbd0e Merge pull request #3471 from opencloud-eu/feat/graph-expand-thumbnails
feat(graph): expand thumbnails on driveItems
2026-09-07 12:50:53 +02:00
Jörn Friedrich Dreyer be226ebb4c Merge pull request #3478 from opencloud-eu/reva-bump-main-20260907
[full-ci] chore: bump reva to latest main
2026-09-07 12:48:12 +02:00
Dominik Schmidt c2b37668e4 chore: bump reva to latest main 2026-09-07 09:33:59 +02:00
opencloudeu 4b7c6908f0 [tx] updated from transifex 2026-09-06 23:16:18 +00:00
Dominik Schmidt 6231a870d5 feat(graph): expand thumbnails on driveItems
$expand=thumbnails was only honored by sharedByMe and sharedWithMe. The
driveItem stat, the children listing and the root children listing now
honor it as well, so a client that lists a folder learns which items have
a preview instead of guessing from the mime type.

The thumbnails are set from the resource info the listing already has, so
a later preview check that needs more than the mime type has a single
place to sit. The two share listings carry driveItems only, they keep
matching on the mime type but share the url building.
2026-09-06 23:51:35 +02:00
opencloudeu 17003fe34b [tx] updated from transifex 2026-09-05 23:17:58 +00:00
Dominik Schmidt 2ce9faec5a Merge pull request #3444 from opencloud-eu/feat/driveitem-lock
graph: expose lockInfo on driveItems
2026-09-04 09:51:13 +02:00
opencloudeu f5696d40f8 [tx] updated from transifex 2026-09-03 23:17:09 +00:00
Dominik Schmidt 9a769b8019 build(deps): bump github.com/opencloud-eu/libre-graph-api-go to 45af3945a067 2026-09-03 16:02:43 +00:00
Dominik Schmidt bafbc88a40 graph: expose lockInfo on driveItems 2026-09-03 17:52:13 +02:00
Dominik Schmidt addb32812a Merge pull request #3438 from opencloud-eu/feat/driveitem-share-types
graph: expose @libre.graph.shareTypes on driveItems
2026-09-03 17:52:10 +02:00
Dominik Schmidt aa968ec898 graph: expose @libre.graph.shareTypes on driveItems 2026-09-03 16:59:29 +02:00
Dominik Schmidt 61037cc22f Merge pull request #3202 from opencloud-eu/feat/search-live-photo-facet
feat(search): live photo facet
2026-09-03 11:42:28 +02:00
Dominik Schmidt 71ca404695 feat(search): describe hits from shared spaces as remote items 2026-09-03 10:30:38 +02:00
Dominik Schmidt e38a735e20 test(search): pin aggregations in the parity suite 2026-09-03 10:30:38 +02:00
Dominik Schmidt b1393b504c fix(search): date range aggregations on opensearch, validate range bounds 2026-09-03 10:30:38 +02:00
Dominik Schmidt 504bdd5e7f fix(search): merge top-level metric aggregations across spaces
The cross-space merge only carried buckets, dropping metric results
(value/metricKind) from the per-space responses. Reduce metrics with
their kind's reducer, keyed by field and kind.
2026-09-03 10:30:38 +02:00
Dominik Schmidt 16ae504226 feat(search): support top-level metric aggregations on the bleve backend
Metric aggregations (sum/min/max/avg) only worked as sub-aggregations
under a terms bucket. Compute top-level metrics by folding the matched
hits through the existing accumulator and allow them through the graph
layer's numeric field validation.
2026-09-03 10:30:38 +02:00
Dominik Schmidt c16bdff872 feat(search): support date bounds in bleve range aggregations
Range aggregations parsed from/to with ParseFloat only, so date bounds on
datetime fields like photo.takenDateTime silently degraded to unbounded
numeric ranges. Detect date-formatted bounds (RFC3339 or YYYY-MM-DD),
switch the facet to bleve date ranges and read DateRanges from the facet
result. Malformed bounds in date mode are rejected.
2026-09-03 10:30:38 +02:00
Dominik Schmidt 9661f66fe8 feat(search): opensearch aggregations
Implements terms, range, metric and sub-aggregations for the OpenSearch backend
via a dedicated aggs builder, wiring them through the shared search service.
2026-09-03 10:30:38 +02:00
Dominik Schmidt dfb3893118 feat(search): graph search query endpoint with bleve aggregations
Adds the graph /v1beta1/search/query endpoint, the aggregation proto messages,
the service-layer aggregation forwarding/merging, and the recursive bleve
aggregation implementation (terms, range, metric, sub-aggregations).
2026-09-03 10:30:38 +02:00
Dominik Schmidt 0085478b79 chore(vendor): regenerate libre-graph-api-go with search query + aggregations
Rebased dschmidt/libre-graph-api feat/graph-search-full (PR #34) onto
opencloud-eu main and regenerated via the repo's woodpecker build-go recipe
(openapi-generator v7.23.0, --api-name-suffix Api).
2026-09-03 10:30:25 +02:00
Jörn Friedrich Dreyer 993265b64e Merge pull request #3445 from opencloud-eu/feat/graph-expand-children
feat: support $expand=children on the driveItem endpoint
2026-09-03 09:35:05 +02:00
Dominik Schmidt 5995938c34 chore(search): trim the live photo comments 2026-09-03 03:34:33 +02:00
Dominik Schmidt 0a4f3ed786 fix(search): keep livePhoto.contentId out of the search siblings 2026-09-03 03:34:33 +02:00
Dominik Schmidt a7214b3d73 fix(search): drop the live photo facet on an empty pairing id 2026-09-03 03:34:33 +02:00
Dominik Schmidt 81b0df1ad4 feat(search): live photo facet 2026-09-03 03:34:33 +02:00
Dominik Schmidt e6102c0405 Merge pull request #3200 from opencloud-eu/feat/search-motion-photo-facet
feat(search): motion photo facet
2026-09-03 03:34:29 +02:00
opencloudeu ab0b3c58f1 [tx] updated from transifex 2026-09-02 23:18:41 +00:00
Dominik Schmidt 3515594787 fix(search): keep the video facet on the file itself 2026-09-03 01:09:41 +02:00
Dominik Schmidt a8318fe03b refactor(search): take the motion photo video size from the video tika extracted 2026-09-03 00:32:07 +02:00
Dominik Schmidt 706aaf02f2 refactor(search): decide the motion photo from the file xmp and its extracted video 2026-09-03 00:32:06 +02:00
Dominik Schmidt 88f21d804b refactor(search): restore cs3 Retrieve, the download split had only one caller left 2026-09-03 00:31:40 +02:00
Dominik Schmidt 8aebf80124 refactor(search): confirm the motion photo video by type, not by name 2026-09-03 00:31:40 +02:00
Dominik Schmidt ae9fd595d9 chore(search): drop the dead legacy tika key 2026-09-03 00:31:40 +02:00
Dominik Schmidt 709962b616 feat(search): confirm the motion photo video via tika instead of reading bytes 2026-09-03 00:31:40 +02:00
Dominik Schmidt a2050d1fb9 feat(search): index and expose the motion photo facet 2026-09-03 00:31:40 +02:00
Dominik Schmidt 0f4b95b9ae feat(search): add RetrieveRange to the content retriever 2026-09-03 00:27:04 +02:00