Skip to content

perf(ios): add lifecycle-safe runner sequence tracer for hot interaction loops #669

@thymikee

Description

@thymikee

What to build

Add a narrow runner sequence tracer that batches a small, explicit hot-loop interaction family into one lifecycle-tracked request.

This is not a migration of all commands to a batch protocol. The first slice should prove the shape with a limited command set where ordering and result semantics are clear, such as repeated coordinate gestures or one existing series-style interaction. The sequence must use command IDs and lifecycle status so lost responses remain observable and commands are not replayed after the runner reports accepted, started, completed, or failed.

Performance target: repeated hot interactions should reduce daemon-to-runner round trips from N requests to one request for the supported sequence, while retaining lifecycle diagnostics and bounded response retention.

Acceptance criteria

  • A narrow allowlist of sequenceable iOS runner interactions is defined explicitly; unsupported commands fail with a clear error or continue using the existing single-command path.
  • The sequence request is tracked by command ID and exposes lifecycle status in the runner journal.
  • Sequence execution preserves ordering and stops or reports failure deterministically when one step fails.
  • Lost-response recovery uses lifecycle status and does not replay an observed mutating sequence.
  • Response retention stays bounded and does not retain large snapshot/screenshot-like payloads.
  • Focused tests cover completed, failed, in-flight, and lost-response recovery behavior for the sequence command.
  • iOS simulator validation demonstrates fewer runner requests for the supported hot loop and no behavior regression compared with issuing the commands individually.

Blocked by

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions