mcgilman opened a new pull request, #11144: URL: https://github.com/apache/nifi/pull/11144
## Summary Adds context menu support to the connector canvas, providing right-click actions for both the canvas background and individual components. Also extends the component state infrastructure to support connector-specific API endpoints. ### Context Menu - **Canvas background**: Refresh (Ctrl/Cmd+R) and Leave group (Escape) with keyboard shortcuts - **Components**: Enter group (process groups), View data provenance, View state (stateful processors), and Center in view - Menu items are conditionally shown based on component type, selection state, and user permissions - Fixed the context menu template's `@for` tracking expression to use `track item.text || $index` instead of `track item`, preventing DOM element recreation during change detection cycles ### View Data Provenance - Added `navigateToProvenanceForComponent` action and effect to navigate to `/provenance` with back-navigation state linking back to the connector canvas ### View State (Processors) - Added "View state" menu item for stateful processors (requires `persistsState === true` and read/write permissions) - Extended `ComponentStateRequest` and `ComponentStateState` with an optional `connectorId` field - Added connector-specific methods to `ComponentStateService` (`getConnectorComponentState`, `clearConnectorComponentState`, `clearConnectorComponentStateEntry`) - Updated `ComponentStateEffects` to route API calls through connector endpoints when `connectorId` is present, while preserving existing behavior for non-connector contexts - `canClear` logic checks processor run status and active thread count ### Tests - Comprehensive tests for all context menu conditions (component types, permissions, selection states) - Tests for action dispatch methods (`refreshAction`, `enterGroupAction`, `viewDataProvenanceAction`, `viewProcessorStateAction`) - Tests for `canClear` logic (stopped, running, active threads) - Effect tests for provenance navigation with back-navigation state -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
