Skip to content

feat(dgw): search Active Directory Console logs - #2150

Open
irvingouj@Devolutions (irvingoujAtDevolution) wants to merge 2 commits into
masterfrom
feat/recording-search-all-slogs
Open

irvingouj@Devolutions (irvingoujAtDevolution) wants to merge 2 commits into
masterfrom
feat/recording-search-all-slogs

Conversation

@irvingoujAtDevolution

Copy link
Copy Markdown
Contributor

Search read only the .slog files listed under artifacts in recording.json. Active Directory Console pushes its log as a recording, listed under files, so none of its logs, stored ones included, could be found.

Search now reads the .slog files under files too, before those under artifacts, in the order the manifest and the pull ZIP use. A name listed in both sections is searched once, so a cursor still resumes at a single place. Other file types under files, such as .webm, and unsafe names are still skipped.

api/jrec/search.intent.md states the new rules.

🤖 Generated with Claude Code

Active Directory Console pushes its log as a recording, so it sits
under `files` in `recording.json`, where search does not look.

The search intent now covers the `.slog` files listed under `files`
as well as under `artifacts`, `files` first, and defers choosing
other file types.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Search read only the `.slog` files listed under `artifacts` in
`recording.json`. Active Directory Console pushes its log as a
recording, listed under `files`, so none of its logs, stored ones
included, could be found.

Search now reads the `.slog` files under `files` too, before those
under `artifacts`, in the order the manifest and the pull ZIP use. A
name listed in both sections is searched once, so a cursor still
resumes at a single place. Other file types under `files`, such as
`.webm`, and unsafe names are still skipped.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Copilot AI balanced review requested due to automatic review settings October 23, 2026 22:47
@irvingoujAtDevolution

Copy link
Copy Markdown
Contributor Author

Lines changed, against master:

Added Removed
Production code 17 8
Tests 23 11
Other (intent file) 5 4

The behaviour change is read_recording_logs in search.rs; the rest of the production lines are doc comments.

#2114 copies the old search doc ("Only the files listed under artifacts …") into the OpenAPI document and the clients, so whichever of the two merges second regenerates them.

Note

LLM-assisted content (no human feedback).

@irvingoujAtDevolution

Copy link
Copy Markdown
Contributor Author

Intent drafts: handoff

The interview read devolutions-gateway/src/api/jrec/search.intent.md at 0467406c7 (master with cursor paging), and an intent review of the first draft added three more rounds.

Provenance

Levels: 1 = my words verbatim, 2 = my words tidied, 3 = agent wording I adopted, 4 = agent fill-in, not intent.

# Commitment as written My words (if tidied) Level
1 Search covers the .slog files listed in recording.json, under files as well as under artifacts. "To keep it backward compatiable, with the exception of Active Directory logging, which is pushed as a recording instead of artifacts, we extend the search to all content that is .slog, no matter it is an artifact or it is a file"; the review split it into a rule and a reason and dropped "every", which the safe-name rule falsified: "I agree" 3
2 files is searched so that Active Directory Console logs, which are pushed as recordings, are searchable, the ones already stored included, with no change to how they are pushed. Same answer as 1; the reason "backward compatible" named no party, so the review spelled it out: "I agree" 3
3 Within a recording, the .slog files listed under files are searched first, then those listed under artifacts, by convention, in the order recording.json lists them and a recording pull zips them. "file first"; "no reason, done by convention, in sync with order in manifest and zipping" 2
4 Any other line is matched case-insensitively against its raw text, so that any kind of log, present or future, can be searched. The existing reason, "artifact" widened to "log" since logs under files are searched too: "I agree" 3
5 Choosing which file types to search, such as .cast besides .slog, is wanted later; the request shape must not preclude it either. "choosing which file kinds to search is a wanted later"; of two readings, log kinds or file types: "2" 2

Left out on purpose

  • A .slog added under files while the cursor is inside an artifact of the same recording is not searched by that paging run. No current producer writes a .slog under both sections of one recording.
  • A manifest without files, or with a files entry missing fileName: Gateway always writes both, so search keeps reading the first and skips the second, as a pull does.
  • Access: §Access already makes the search scope the only check for any content, Active Directory Console logs included.
  • Choosing by log kind, such as only Active Directory Console logs: not committed.
  • Anchors: the file has none while tests cite its sections by heading; that predates this change and goes in a pull request of its own.
  • AD pushing an artifact-only session, and a separate endpoint to push any .slog: not part of this change.

Placement

All in devolutions-gateway/src/api/jrec/search.intent.md: 1 to 3 in §What is searched, 4 in its matching rules, 5 in §Later.

Pending experiments

None.

Note

Human-tuned, LLM-assisted content.

@github-actions

Copy link
Copy Markdown

Let maintainers know that an action is required on their side

  • Add the label release-required Please cut a new release (Devolutions Gateway, Devolutions Agent, Jetsocat, PowerShell module) when you request a maintainer to cut a new release (Devolutions Gateway, Devolutions Agent, Jetsocat, PowerShell module)

  • Add the label release-blocker Follow-up is required before cutting a new release if a follow-up is required before cutting a new release

  • Add the label publish-required Please publish libraries (`Devolutions.Gateway.Utils`, OpenAPI clients, etc) when you request a maintainer to publish libraries (Devolutions.Gateway.Utils, OpenAPI clients, etc.)

  • Add the label publish-blocker Follow-up is required before publishing libraries if a follow-up is required before publishing libraries

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

The focused change retains existing filtering and deduplication, adds regression coverage, and has no identified blocking issues.

No open issues 🎉

What changed in this PR

This PR extends recording search to include Active Directory Console .slog logs, including existing recordings, without changing how they are uploaded.

Changes:

  • Search manifest files before artifacts, deduplicating names while retaining filename safety and file-type filtering.
  • Update regression tests for expanded results, pagination order, and duplicate log entries.
  • Document the expanded search scope and ordering in the search intent.
File Description
testsuite/​tests/​cli/​dgw/​recording_search.rs Updates expected results and pagination to include recorded logs.
devolutions-gateway/​src/​api/​jrec/​search.rs Adds manifest files to log discovery and tests cross-section deduplication.
devolutions-gateway/​src/​api/​jrec/​search.intent.md Defines the expanded search scope and file ordering.

Review effort: Balanced

This branch has not been deployed

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

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants