Skip to content

Telemetry request interceptors ignore configured priority #8418

Description

@ThunderKhan

Summary

TelemetryRequestInterceptorRegistry documents support for a priority value on telemetry request interceptors, where a higher priority should have more weight than a lower one.

However, getInterceptors() currently returns applicable interceptors in registration order and does not sort them by priority.

As a result, the execution order of telemetry request interceptors is determined by plugin registration order rather than the configured interceptor priority.

Expected vs Current Behavior

Expected: Applicable telemetry request interceptors should be returned in descending priority order, consistent with other priority-based registries in Open MCT. Interceptors without an explicit priority should use the default priority.

Current: Applicable telemetry request interceptors are returned in registration order regardless of their configured priority.

Steps to Reproduce

  1. Create three telemetry request interceptors with priorities -1000, no explicit priority, and 1000.
  2. Register them in the following order: -1000, default, 1000.
  3. Call TelemetryRequestInterceptorRegistry.getInterceptors().
  4. Observe that the returned order matches registration order (-1000, default, 1000) instead of descending priority order (1000, default, -1000).

Environment

  • Open MCT Version: 4.3.1
  • Deployment Type: local development
  • OS: Windows 10
  • Browser: Brave / Chromium 152

Impact Check List

  • Data loss or misrepresented data?
  • Regression? Did this used to work or has it always been broken?
  • Is there a workaround available?
  • Does this impact a critical component?
  • Is this just a visual bug with no functional impact?
  • Does this block the execution of e2e tests?
  • Does this have an impact on Performance?

Additional Information

TelemetryRequestInterceptor.js already contains a TODO indicating that interceptors should be sorted by priority.

The existing object InterceptorRegistry implements analogous behavior by:

  • treating an unspecified interceptor priority as 0
  • sorting higher numeric priorities before lower priorities

A regression unit test can reproduce the issue and verify the expected ordering behavior.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions