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

[Security Solutions][Endpoint] Use id instead of identifier to get fleet artifact #154810

Conversation

dasansol92
Copy link
Contributor

@dasansol92 dasansol92 commented Apr 12, 2023

Summary

Get fleet artifacts by artifact.id instead of by artifact.identifier before pushing them to the endpoint manifest.

@dasansol92 dasansol92 added release_note:skip Skip the PR/issue when compiling release notes Team:Defend Workflows “EDR Workflows” sub-team of Security Solution v8.7.1 labels Apr 12, 2023
@dasansol92
Copy link
Contributor Author

@elasticmachine merge upstream

@dasansol92 dasansol92 marked this pull request as ready for review April 12, 2023 14:34
@dasansol92 dasansol92 requested a review from a team as a code owner April 12, 2023 14:35
@elasticmachine
Copy link
Contributor

Pinging @elastic/security-defend-workflows (Team:Defend Workflows)

Copy link
Contributor

@paul-tavares paul-tavares left a comment

Choose a reason for hiding this comment

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

Seems good. Only question is: would we be able to add a test for this (cypress/FTR)?

@dasansol92
Copy link
Contributor Author

@paul-tavares Sure, we have an FTR suite that checks artifacts generation. Will increase the scope to cover that use case.

@kibana-ci
Copy link
Collaborator

💚 Build Succeeded

Metrics [docs]

Unknown metric groups

ESLint disabled line counts

id before after diff
securitySolution 433 436 +3

Total ESLint disabled count

id before after diff
securitySolution 512 515 +3

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

@kevinlog
Copy link
Contributor

checked it out tried it, LGTM.

I added different artifacts across 2 policies and they were generated correctly and Policy responses were always successful

image

@dasansol92 dasansol92 added release_note:fix and removed release_note:skip Skip the PR/issue when compiling release notes labels Apr 12, 2023
@dasansol92 dasansol92 merged commit fbe0243 into elastic:main Apr 12, 2023
22 checks passed
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Apr 12, 2023
…eet artifact (elastic#154810)

## Summary

Get fleet artifacts by `artifact.id` instead of by `artifact.identifier`
before pushing them to the endpoint manifest.

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
(cherry picked from commit fbe0243)
@kibanamachine
Copy link
Contributor

💚 All backports created successfully

Status Branch Result
8.7

Note: Successful backport PRs will be merged automatically after passing CI.

Questions ?

Please refer to the Backport tool documentation

kibanamachine added a commit that referenced this pull request Apr 12, 2023
…get fleet artifact (#154810) (#154837)

# Backport

This will backport the following commits from `main` to `8.7`:
- [[Security Solutions][Endpoint] Use id instead of identifier to get
fleet artifact (#154810)](#154810)

<!--- Backport version: 8.9.7 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sqren/backport)

<!--BACKPORT [{"author":{"name":"David
Sánchez","email":"david.sanchezsoler@elastic.co"},"sourceCommit":{"committedDate":"2023-04-12T15:54:21Z","message":"[Security
Solutions][Endpoint] Use id instead of identifier to get fleet artifact
(#154810)\n\n## Summary\r\n\r\nGet fleet artifacts by `artifact.id`
instead of by `artifact.identifier`\r\nbefore pushing them to the
endpoint manifest.\r\n\r\nCo-authored-by: Kibana Machine
<42973632+kibanamachine@users.noreply.github.com>","sha":"fbe024306c37bd87d9c2d4a1bab45b89fb148e77","branchLabelMapping":{"^v8.8.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:fix","Team:Defend
Workflows","v8.8.0","v8.7.1"],"number":154810,"url":"#154810
Solutions][Endpoint] Use id instead of identifier to get fleet artifact
(#154810)\n\n## Summary\r\n\r\nGet fleet artifacts by `artifact.id`
instead of by `artifact.identifier`\r\nbefore pushing them to the
endpoint manifest.\r\n\r\nCo-authored-by: Kibana Machine
<42973632+kibanamachine@users.noreply.github.com>","sha":"fbe024306c37bd87d9c2d4a1bab45b89fb148e77"}},"sourceBranch":"main","suggestedTargetBranches":["8.7"],"targetPullRequestStates":[{"branch":"main","label":"v8.8.0","labelRegex":"^v8.8.0$","isSourceBranch":true,"state":"MERGED","url":"#154810
Solutions][Endpoint] Use id instead of identifier to get fleet artifact
(#154810)\n\n## Summary\r\n\r\nGet fleet artifacts by `artifact.id`
instead of by `artifact.identifier`\r\nbefore pushing them to the
endpoint manifest.\r\n\r\nCo-authored-by: Kibana Machine
<42973632+kibanamachine@users.noreply.github.com>","sha":"fbe024306c37bd87d9c2d4a1bab45b89fb148e77"}},{"branch":"8.7","label":"v8.7.1","labelRegex":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->

Co-authored-by: David Sánchez <david.sanchezsoler@elastic.co>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release_note:fix Team:Defend Workflows “EDR Workflows” sub-team of Security Solution v8.7.1 v8.8.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants