Skip to content

fix(users): Online Users 'All time' filter returns empty (#28145) [1.13]#28210

Merged
sonika-shah merged 1 commit into
1.13from
cherry-pick/28145-1.13
May 18, 2026
Merged

fix(users): Online Users 'All time' filter returns empty (#28145) [1.13]#28210
sonika-shah merged 1 commit into
1.13from
cherry-pick/28145-1.13

Conversation

@sonika-shah
Copy link
Copy Markdown
Collaborator

Cherry-pick of #28145 to 1.13.

Summary

Closes #27993 on the 1.13 release branch.

The /v1/users/online endpoint computed the SQL threshold as now - timeWindow*60*1000. When the UI sent timeWindow=0 for the All time dropdown option, the threshold collapsed to now, producing lastActivityTime > now — which matches zero rows. The page therefore rendered empty whenever a user selected All.

The fix skips the time predicate entirely when timeWindow <= 0, so the filter falls through to "all non-bot users".

Conflict resolution

UserResourceIT.java import block — kept both the existing SubjectCache/SubjectContext imports (already on 1.13) and the new HttpMethod/RequestOptions imports the new test needs.

Test plan

  • mvn -pl openmetadata-service,openmetadata-integration-tests -am test-compile passes locally
  • CI green
  • Manual: in the UI, open Settings → Members → Online Users, select All time — list populates

…28145)

The /v1/users/online endpoint computed `now - timeWindow*60*1000` for the
SQL threshold. When the UI sent `timeWindow=0` for the "All time" option,
the threshold collapsed to `now`, producing `lastActivityTime > now` —
which matched zero rows. Skip the time predicate entirely when
`timeWindow <= 0` so the filter falls through to "all non-bot users".

Reported via #27993.
@github-actions github-actions Bot added backend safe to test Add this label to run secure Github workflows on PRs labels May 18, 2026
@sonika-shah sonika-shah merged commit 30c62e0 into 1.13 May 18, 2026
17 of 34 checks passed
@sonika-shah sonika-shah deleted the cherry-pick/28145-1.13 branch May 18, 2026 05:17
@gitar-bot
Copy link
Copy Markdown

gitar-bot Bot commented May 18, 2026

Code Review ✅ Approved

Cherry-pick of the fix for the 'All time' online users filter, which now skips the time predicate when the window is zero to correctly return all non-bot users. No issues found.

Options

Display: compact → Showing less information.

Comment with these commands to change:

Compact
gitar display:verbose         

Was this helpful? React with 👍 / 👎 | Gitar

@github-actions
Copy link
Copy Markdown
Contributor

The Python checkstyle failed.

Please run make py_format and py_format_check in the root of your repository and commit the changes to this PR.
You can also use pre-commit to automate the Python code formatting.

You can install the pre-commit hooks with make install_test precommit_install.

@sonarqubecloud
Copy link
Copy Markdown

@github-actions
Copy link
Copy Markdown
Contributor

🔴 Playwright Results — 13 failure(s), 16 flaky

✅ 3756 passed · ❌ 13 failed · 🟡 16 flaky · ⏭️ 90 skipped

Shard Passed Failed Flaky Skipped
✅ Shard 1 290 0 0 4
🟡 Shard 2 710 0 4 7
🔴 Shard 3 705 13 2 12
🟡 Shard 4 730 0 5 24
✅ Shard 5 623 0 0 35
🟡 Shard 6 698 0 5 8

Genuine Failures (failed on all attempts)

Features/SearchSeparation/searchSeparationSuite.ts › live indexing produces searchable separation for all four facets (shard 3)
TypeError: (0 , _admin.createAdminApiContext) is not a function
Features/SearchSeparation/searchSeparationSuite.ts › live indexing produces searchable separation for all four facets (shard 3)
TypeError: (0 , _admin.createAdminApiContext) is not a function
Features/SearchSeparation/searchSeparationSuite.ts › live indexing produces searchable separation for all four facets (shard 3)
TypeError: (0 , _admin.createAdminApiContext) is not a function
Features/SearchSeparation/searchSeparationSuite.ts › live indexing produces searchable separation for all four facets (shard 3)
TypeError: (0 , _admin.createAdminApiContext) is not a function
Features/SearchSeparation/searchSeparationSuite.ts › live indexing produces searchable separation for all four facets (shard 3)
TypeError: (0 , _admin.createAdminApiContext) is not a function
Features/SearchSeparation/searchSeparationSuite.ts › live indexing produces searchable separation for all four facets (shard 3)
TypeError: (0 , _admin.createAdminApiContext) is not a function
Features/SearchSeparation/searchSeparationSuite.ts › live indexing produces searchable separation for all four facets (shard 3)
TypeError: (0 , _admin.createAdminApiContext) is not a function
Features/SearchSeparation/searchSeparationSuite.ts › live indexing produces searchable separation for all four facets (shard 3)
TypeError: (0 , _admin.createAdminApiContext) is not a function
Features/SearchSeparation/searchSeparationSuite.ts › live indexing produces searchable separation for all four facets (shard 3)
TypeError: (0 , _admin.createAdminApiContext) is not a function
Features/SearchSeparation/searchSeparationSuite.ts › live indexing produces searchable separation for all four facets (shard 3)
TypeError: (0 , _admin.createAdminApiContext) is not a function
Features/SearchSeparation/searchSeparationSuite.ts › live indexing produces searchable separation for all four facets (shard 3)
TypeError: (0 , _admin.createAdminApiContext) is not a function
Features/Tasks/TaskNavigation.spec.ts › clicking task notification while on entity task tab refreshes the task list (shard 3)
�[31mTest timeout of 180000ms exceeded.�[39m
Features/Tasks/TaskNavigation.spec.ts › two sessions: admin on Columns tab creates task, assignee sees refresh on notification click (shard 3)
�[31mTest timeout of 180000ms exceeded.�[39m
🟡 16 flaky test(s) (passed on retry)
  • Features/BulkEditEntity.spec.ts › Glossary (shard 2, 1 retry)
  • Features/ColumnBulkOperations.spec.ts › should keep latest search results when responses arrive out of order (shard 2, 1 retry)
  • Features/Glossary/GlossaryP3Tests.spec.ts › should handle multiple rapid API calls (shard 2, 1 retry)
  • Features/Glossary/GlossaryWorkflow.spec.ts › should start term as Draft when glossary has reviewers (shard 2, 1 retry)
  • Features/Permissions/GlossaryPermissions.spec.ts › Team-based permissions work correctly (shard 3, 1 retry)
  • Flow/PersonaFlow.spec.ts › Set default persona for team should work properly (shard 3, 1 retry)
  • Pages/DataContracts.spec.ts › Create Data Contract and validate for Store Procedure (shard 4, 1 retry)
  • Pages/DataContracts.spec.ts › Create Data Contract and validate for Api Collection (shard 4, 1 retry)
  • Pages/DataContractsSemanticRules.spec.ts › Validate Owner Rule Is_Set (shard 4, 1 retry)
  • Pages/Domains.spec.ts › Rename domain with owners and experts preserves assignments (shard 4, 1 retry)
  • Pages/Domains.spec.ts › Multiple consecutive domain renames preserve all associations (shard 4, 1 retry)
  • Pages/Lineage/DataAssetLineage.spec.ts › verify create lineage for entity - Dashboard (shard 6, 1 retry)
  • Pages/Lineage/LineageFilters.spec.ts › Verify lineage schema filter selection (shard 6, 1 retry)
  • Pages/Lineage/LineageRightPanel.spec.ts › Verify custom properties tab IS visible for supported type: searchIndex (shard 6, 1 retry)
  • Pages/ServiceEntity.spec.ts › Inactive Announcement create & delete (shard 6, 1 retry)
  • Pages/Users.spec.ts › Permissions for table details page for Data Consumer (shard 6, 1 retry)

📦 Download artifacts

How to debug locally
# Download playwright-test-results-<shard> artifact and unzip
npx playwright show-trace path/to/trace.zip    # view trace

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backend safe to test Add this label to run secure Github workflows on PRs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant