apache / apache/texera

Dashboard search accepts unknown sort values

Open
#8,147 1 comment 0 reactions 1 assignee Claimed by @carloea2 View on GitHub
Dominant language
Scala
Stars
314
Forks
187
Avg merge
1d 21h
Merged PRs (30d)
214

Description

### Feature Summary

Dashboard search silently accepts an unknown `orderBy` value and runs an unordered offset query. That can make pagination unstable instead of reporting invalid client input.

Before: an unknown sort value returns 200 without an order clause.
After: an unknown sort value returns 400, while documented sort values remain valid.

Reproduction evidence:

1. Start the local development backend from main.
2. Request `GET /api/dashboard/publicSearch?resourceType=workflow&orderBy=Bogus`.
3. Observe HTTP 200.
4. Request the endpoint with `orderBy=NameAsc` and observe HTTP 200.

Version and commit evidence:

1.3.0-incubating-SNAPSHOT (main)

**Commit Hash (Optional)**

98588bf2ab49aac65ebf002496eb057670e6fc07

**What browsers are you seeing the problem on?**

Not browser-specific.

**Relevant log output**

The invalid value falls through to an empty order field list, so the query runs without ordering.

### Proposed Solution or Design

After: an unknown sort value returns 400, while documented sort values remain valid.

### Affected Area

Workflow Engine (Amber)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.