Skip to content
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

refactor: encourage the use of anonymous queries #280

Merged
merged 1 commit into from
Mar 2, 2022

Conversation

afiune
Copy link
Contributor

@afiune afiune commented Mar 2, 2022

Issue: N/A

Description:
The motivation of this change it to avoid making our users set the query
id twice, it makes no sense to allow them to configure a different query
id, especially not since the platform enforces that both, the query id and
the query text match.

Furthermore, we have introduced the concept of anonymous queries, such
queries are encouraged and should the default way that users create and
manage LQL queries.

This change updates all documentation and tests to avoid adding the
query id inside the query text.

Signed-off-by: Salim Afiune Maya afiune@lacework.net

Additional Info:
Updated integration tests and documentation.

The motivation of this change it to avoid making our users set the query
id twice, it makes no sense to allow them to configure a different query
id, especially not since the platform enforces that both, the query id and
the query text match.

Furthermore, we have introduced the concept of anonymous queries, such
queries are encouraged and should the default way that users create and
manage LQL queries.

This change updates all documentation and tests to avoid adding the
query id inside the query text.

Signed-off-by: Salim Afiune Maya <afiune@lacework.net>
@@ -176,4 +231,22 @@ var (
EVENT
}
}`

queryDeprecatedSyntaxWithID = `Lql_Terraform_Query {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I added one test to:

  1. show that this method has been deprecated and
  2. we still support it

Copy link
Contributor

@hazedav hazedav left a comment

Choose a reason for hiding this comment

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

@afiune afiune merged commit b7c2d4c into main Mar 2, 2022
@afiune afiune deleted the afiune/use-anonymous-queries branch March 2, 2022 15:52
@lacework-releng lacework-releng mentioned this pull request Mar 2, 2022
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.

3 participants