Open
Conversation
… execution. Added '--exclude-wl' to entity store to filter out watchlists and '--privmon-wl' to org data for privileged user monitoring watchlist synctesting scenario
Contributor
There was a problem hiding this comment.
Pull request overview
Adds new CLI flags to adjust which integrations/maintainers are included during “quick” test-data generation, with the goal of improving flexibility around watchlist-related data.
Changes:
org_data: introduces--privmon-wlflag and attempts to pass it into the quick generator.entity_store: introduces--exclude-wlto omit watchlists during--quickruns; temporarily removes the Watchlist choice from the interactive prompt.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 4 comments.
| File | Description |
|---|---|
src/commands/org_data/index.ts |
Adds --privmon-wl option and forwards it to the quick org data generator; updates quick command description. |
src/commands/entity_store/index.ts |
Adds --exclude-wl option for quick maintainer generation; comments out Watchlist in interactive maintainer selection. |
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
| @@ -140,50 +135,27 @@ export const entityStoreCommands: CommandModule = { | |||
| ) | |||
| .option('--space <space>', 'Kibana space ID', 'default') | |||
| .option('--quick', 'Run all maintainers for 10000 entities without prompts') | |||
There was a problem hiding this comment.
The --quick help text says it will "Run all maintainers" but the behavior can now exclude watchlists via --exclude-wl, and (via config) could diverge further from "all" in the future. Consider updating the --quick description to reflect that it runs the configured quick-default maintainers (with optional exclusions) to avoid misleading CLI help.
Suggested change
| .option('--quick', 'Run all maintainers for 10000 entities without prompts') | |
| .option( | |
| '--quick', | |
| 'Run quick-default maintainers for 10000 entities without prompts (respects --exclude-wl and maintainer config)', | |
| ) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Updated organization data generation to support a specialised watchlist mode for testing privileged users prebuilt watchlist sync 🔥
Additionally, refactors how entity maintainer options are managed and improves flexibility for both quick and manual data generation commands. It introduces a new configuration array for maintainers, simplifies option handling, and adds new CLI flags to control which maintainers are included in quick runs.
Entity Maintainer Options Refactor:
ENTITY_MAINTAINERS_CONFIGarray of objects inconstants.tsto define maintainer keys, labels, default checked status, quick inclusion, and exclusion behavior, replacing hardcoded lists throughout the codebase.entity_storecommand to useENTITY_MAINTAINERS_CONFIGfor both quick and manual maintainer selection, ensuring consistent and centralized configuration. [1] [2]New CLI Options and Behavior:
--exclude-wlflag to theentity_storequick command, allowing users to exclude watchlist maintainers from quick runs. The filtering logic now respects theexcludeOnQuickproperty from the config.--privmon-wloption to theorg_dataquick command to enable Privileged User Monitoring watchlist integrations, passing this option through to the handler.Commands Usage
Normal Path
yarn start org-data-quickyarn start generate-entity-maintainers-data --quickTesting Privmon Sync Path
yarn start org-data-quick --privmon-wlyarn start generate-entity-maintainers-data --quick --exclude-wl