Skip to content

Conversation

@rfellows
Copy link
Contributor

@rfellows rfellows commented Oct 6, 2025

Summary

NIFI-15051

Add Filter to Show Current Scope Controller Services Only

This PR introduces a filtering feature to the Controller Services listing page that allows users to view only the controller services defined in the current process group, filtering out inherited services from parent process groups.

Changes

User-Facing Features:

  • Added a "Show current scope only" checkbox filter with help tooltip on the Controller Services page
  • Filter only appears when viewing non-root process groups (hidden at root level)
  • Tooltip displays the current process group name (or ID if not readable)
  • Filter state defaults to unchecked, showing all services (current + inherited)

Technical Implementation:

  • Converted serviceState$ observable to signal-based state management using selectSignal()
  • Added showCurrentScopeOnly signal to track filter state
  • Implemented filteredControllerServices computed property for reactive filtering
  • Added shouldShowFilter computed property to conditionally display filter based on hierarchy
  • Updated module imports to include FormsModule, MatCheckboxModule, and NifiTooltipDirective

Testing:

  • Added comprehensive test suite with 16 tests covering:
    • Component initialization
    • Filter functionality (enabled/disabled states, edge cases)
    • Computed property behavior
    • Template integration and user interactions
    • Root process group handling
  • All tests passing ✅

Why This Change?

Users working in nested process groups often inherit many controller services from parent groups, making it difficult to identify which services are defined at the current scope. This filter provides a quick way to focus on locally-defined services while still allowing visibility into inherited services when needed.

@rfellows rfellows added hacktoberfest-accepted Hacktoberfest Accepted ui Pull requests for work relating to the user interface labels Oct 6, 2025
@joewitt
Copy link
Contributor

joewitt commented Oct 6, 2025

@rfellows you'll want to edit the commit message to NIFI-15051

@rfellows rfellows changed the title NIFI-1501 - Allow users to only show controller services for the current process group (scope) in the listing NIFI-15051 - Allow users to only show controller services for the current process group (scope) in the listing Oct 6, 2025
@scottyaslan
Copy link
Contributor

Reviewing...

Copy link
Contributor

@scottyaslan scottyaslan left a comment

Choose a reason for hiding this comment

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

Useful addition and thanks for running the prettier formatter!

@scottyaslan scottyaslan merged commit 6346a87 into apache:main Oct 6, 2025
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

hacktoberfest-accepted Hacktoberfest Accepted ui Pull requests for work relating to the user interface

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants