Skip to content

Adds filter to target specific cluster connections #95

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

sdseaton
Copy link
Contributor

@sdseaton sdseaton commented Apr 4, 2025

  • Adds attribute to Cluster model to indicate if cluster is active.
  • Adds filter option to KustoSchemaHandler Tasks to allow targeting specific cluster connections if a list of included connections is provided.

@Copilot Copilot AI review requested due to automatic review settings April 4, 2025 13:48
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR adds filtering functionality to target specific cluster connections by introducing a new boolean attribute in the Cluster model and a filtering method in the KustoSchemaHandler.

  • Adds an IsActive property to the Cluster model to denote active clusters.
  • Implements the FilterClusters method in KustoSchemaHandler to filter connections based on activity status or an explicit list of included connections.
  • Updates methods GenerateDiffMarkdown, Import, and Apply to utilize the new filtering logic.

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
KustoSchemaTools/Model/Cluster.cs Introduces a new property IsActive to mark clusters as active.
KustoSchemaTools/KustoSchemaHandler.cs Adds FilterClusters method and updates existing methods to filter connections.
Comments suppressed due to low confidence (1)

KustoSchemaTools/KustoSchemaHandler.cs:28

  • Consider adding test cases to verify the behavior of FilterClusters with various inputs, including cases with a null or empty includedConnections list and with explicit connection names.
public Clusters FilterClusters(Clusters clusters, List<string>? includedConnections)

Tip: Copilot code review supports C#, Go, Java, JavaScript, Markdown, Python, Ruby and TypeScript, with more languages coming soon. Learn more

@sdseaton sdseaton changed the title Adds filter to target specific cluster connectons Adds filter to target specific cluster connections Apr 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant