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

[Fleet] always create agent upload write indices #155729

Merged
merged 3 commits into from
Apr 26, 2023

Conversation

juliaElastic
Copy link
Contributor

@juliaElastic juliaElastic commented Apr 25, 2023

Summary

Fixes #155483

Always create file upload write indices for elastic_agent package, so that Request diagnostics of a managed Fleet Server works before installing Elastic Agent package.

To verify:

  • Go to a fresh cloud deployment without Elastic Agent installed
  • Go to the managed Fleet Server and click Request Diagnostics on Agent Details
  • Expect the action to work
  • Check in Stack Management that the .fleet-files-agent-000001 index is created.

Verified on pr link that the agent write index is created before Elastic Agent package is installed:

https://kibana-pr-155729.kb.us-west2.gcp.elastic-cloud.com:9243/app/management/data/index_management/indices?includeHiddenIndices=true

image

image

Checklist

@juliaElastic juliaElastic added release_note:skip Skip the PR/issue when compiling release notes ci:cloud-deploy Create or update a Cloud deployment v8.8.0 labels Apr 25, 2023
@juliaElastic juliaElastic requested a review from a team as a code owner April 25, 2023 15:01
@juliaElastic juliaElastic self-assigned this Apr 25, 2023
@botelastic botelastic bot added the Team:Fleet Team label for Observability Data Collection Fleet team label Apr 25, 2023
@elasticmachine
Copy link
Contributor

Pinging @elastic/fleet (Team:Fleet)

@apmmachine
Copy link
Contributor

🤖 GitHub comments

Expand to view the GitHub comments

Just comment with:

  • /oblt-deploy : Deploy a Kibana instance using the Observability test environments.
  • run elasticsearch-ci/docs : Re-trigger the docs validation. (use unformatted text in the comment!)

@kibana-ci
Copy link
Collaborator

kibana-ci commented Apr 26, 2023

💚 Build Succeeded

Metrics [docs]

Unknown metric groups

ESLint disabled line counts

id before after diff
enterpriseSearch 17 19 +2
securitySolution 397 400 +3
total +5

Total ESLint disabled count

id before after diff
enterpriseSearch 18 20 +2
securitySolution 477 480 +3
total +5

History

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

cc @juliaElastic

@juliaElastic juliaElastic merged commit 636674c into elastic:main Apr 26, 2023
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Apr 26, 2023
## Summary

Fixes elastic#155483

Always create file upload write indices for elastic_agent package, so
that Request diagnostics of a managed Fleet Server works before
installing Elastic Agent package.

To verify:
- Go to a fresh cloud deployment without Elastic Agent installed
- Go to the managed Fleet Server and click Request Diagnostics on Agent
Details
- Expect the action to work
- Check in Stack Management that the `.fleet-files-agent-000001` index
is created.

Verified on pr link that the agent write index is created before Elastic
Agent package is installed:

https://kibana-pr-155729.kb.us-west2.gcp.elastic-cloud.com:9243/app/management/data/index_management/indices?includeHiddenIndices=true

<img width="777" alt="image"
src="https://user-images.githubusercontent.com/90178898/234502605-cd91bbc2-0938-41ef-8455-1700f139a3ee.png">
<img width="1538" alt="image"
src="https://user-images.githubusercontent.com/90178898/234502727-74e84a2a-3126-4346-8328-cdb10ed26b8f.png">

### Checklist

- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios

(cherry picked from commit 636674c)
@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 26, 2023
…5845)

# Backport

This will backport the following commits from `main` to `8.7`:
- [[Fleet] always create agent upload write indices
(#155729)](#155729)

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

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

<!--BACKPORT [{"author":{"name":"Julia
Bardi","email":"90178898+juliaElastic@users.noreply.github.com"},"sourceCommit":{"committedDate":"2023-04-26T08:44:42Z","message":"[Fleet]
always create agent upload write indices (#155729)\n\n##
Summary\r\n\r\nFixes
https://github.com/elastic/kibana/issues/155483\r\n\r\nAlways create
file upload write indices for elastic_agent package, so\r\nthat Request
diagnostics of a managed Fleet Server works before\r\ninstalling Elastic
Agent package.\r\n\r\nTo verify:\r\n- Go to a fresh cloud deployment
without Elastic Agent installed\r\n- Go to the managed Fleet Server and
click Request Diagnostics on Agent\r\nDetails\r\n- Expect the action to
work\r\n- Check in Stack Management that the `.fleet-files-agent-000001`
index\r\nis created.\r\n\r\nVerified on pr link that the agent write
index is created before Elastic\r\nAgent package is
installed:\r\n\r\n\r\nhttps://kibana-pr-155729.kb.us-west2.gcp.elastic-cloud.com:9243/app/management/data/index_management/indices?includeHiddenIndices=true\r\n\r\n<img
width=\"777\"
alt=\"image\"\r\nsrc=\"https://user-images.githubusercontent.com/90178898/234502605-cd91bbc2-0938-41ef-8455-1700f139a3ee.png\">\r\n<img
width=\"1538\"
alt=\"image\"\r\nsrc=\"https://user-images.githubusercontent.com/90178898/234502727-74e84a2a-3126-4346-8328-cdb10ed26b8f.png\">\r\n\r\n\r\n\r\n###
Checklist\r\n\r\n- [x] [Unit or
functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere
updated or added to match the most common
scenarios","sha":"636674c2137bc38017f7a085f70b87d6a362308e","branchLabelMapping":{"^v8.8.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","Team:Fleet","ci:cloud-deploy","v8.8.0","v8.7.2"],"number":155729,"url":"https://github.com/elastic/kibana/pull/155729","mergeCommit":{"message":"[Fleet]
always create agent upload write indices (#155729)\n\n##
Summary\r\n\r\nFixes
https://github.com/elastic/kibana/issues/155483\r\n\r\nAlways create
file upload write indices for elastic_agent package, so\r\nthat Request
diagnostics of a managed Fleet Server works before\r\ninstalling Elastic
Agent package.\r\n\r\nTo verify:\r\n- Go to a fresh cloud deployment
without Elastic Agent installed\r\n- Go to the managed Fleet Server and
click Request Diagnostics on Agent\r\nDetails\r\n- Expect the action to
work\r\n- Check in Stack Management that the `.fleet-files-agent-000001`
index\r\nis created.\r\n\r\nVerified on pr link that the agent write
index is created before Elastic\r\nAgent package is
installed:\r\n\r\n\r\nhttps://kibana-pr-155729.kb.us-west2.gcp.elastic-cloud.com:9243/app/management/data/index_management/indices?includeHiddenIndices=true\r\n\r\n<img
width=\"777\"
alt=\"image\"\r\nsrc=\"https://user-images.githubusercontent.com/90178898/234502605-cd91bbc2-0938-41ef-8455-1700f139a3ee.png\">\r\n<img
width=\"1538\"
alt=\"image\"\r\nsrc=\"https://user-images.githubusercontent.com/90178898/234502727-74e84a2a-3126-4346-8328-cdb10ed26b8f.png\">\r\n\r\n\r\n\r\n###
Checklist\r\n\r\n- [x] [Unit or
functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere
updated or added to match the most common
scenarios","sha":"636674c2137bc38017f7a085f70b87d6a362308e"}},"sourceBranch":"main","suggestedTargetBranches":["8.7"],"targetPullRequestStates":[{"branch":"main","label":"v8.8.0","labelRegex":"^v8.8.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/155729","number":155729,"mergeCommit":{"message":"[Fleet]
always create agent upload write indices (#155729)\n\n##
Summary\r\n\r\nFixes
https://github.com/elastic/kibana/issues/155483\r\n\r\nAlways create
file upload write indices for elastic_agent package, so\r\nthat Request
diagnostics of a managed Fleet Server works before\r\ninstalling Elastic
Agent package.\r\n\r\nTo verify:\r\n- Go to a fresh cloud deployment
without Elastic Agent installed\r\n- Go to the managed Fleet Server and
click Request Diagnostics on Agent\r\nDetails\r\n- Expect the action to
work\r\n- Check in Stack Management that the `.fleet-files-agent-000001`
index\r\nis created.\r\n\r\nVerified on pr link that the agent write
index is created before Elastic\r\nAgent package is
installed:\r\n\r\n\r\nhttps://kibana-pr-155729.kb.us-west2.gcp.elastic-cloud.com:9243/app/management/data/index_management/indices?includeHiddenIndices=true\r\n\r\n<img
width=\"777\"
alt=\"image\"\r\nsrc=\"https://user-images.githubusercontent.com/90178898/234502605-cd91bbc2-0938-41ef-8455-1700f139a3ee.png\">\r\n<img
width=\"1538\"
alt=\"image\"\r\nsrc=\"https://user-images.githubusercontent.com/90178898/234502727-74e84a2a-3126-4346-8328-cdb10ed26b8f.png\">\r\n\r\n\r\n\r\n###
Checklist\r\n\r\n- [x] [Unit or
functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere
updated or added to match the most common
scenarios","sha":"636674c2137bc38017f7a085f70b87d6a362308e"}},{"branch":"8.7","label":"v8.7.2","labelRegex":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->

Co-authored-by: Julia Bardi <90178898+juliaElastic@users.noreply.github.com>
jloleysens added a commit to jloleysens/kibana that referenced this pull request Apr 26, 2023
* main: (1294 commits)
  [SecuritySolution] Refactor security packages (elastic#155365)
  [Discover] Show "Temporary" badge for ad-hoc data views in Alerts flyout (elastic#155717)
  [RAM] Conditional actions feedback on pr review (elastic#155804)
  [Files] Adds bulk delete method (elastic#155628)
  [Lens] Use proper way to generate absolute short URL (elastic#155512)
  [Guided onboarding] Use Kibana features to grant access (elastic#155065)
  [Index Management] Fix duped mock (elastic#155844)
  [Lens] Enhance visualization modifier popup with layer palette (elastic#155280)
  Fix flaky combobox tests on role management screen (elastic#155711)
  [Infrastructure UI] Create InventoryViewsService and InventoryViewsClient (elastic#155126)
  [Fleet] always create agent upload write indices (elastic#155729)
  [Fleet] [Cloud Security Posture] Add CloudFormation agent install method (elastic#155045)
  Add tech preview label for search applications (elastic#155649)
  [ML] AIOps: Stabilize flaky functional tests. (elastic#155710)
  [ES UI Shared] Migrate JsonEditor to monaco (elastic#155610)
  [Security Solution] Fixes security_solution storybooks always rendering in a flyout (elastic#155814)
  [Synthetics] Make error popover disappear `onMouseLeave` of metric item card (elastic#155800)
  Remove Exploratory View components from Observability (elastic#155629)
  [Discover] Remove redundant "Filter was added" toast (elastic#155645)
  [RAM][Security Solution][Alerts] Support the ability to trigger a rule action per alert generated (elastic#153611) (elastic#155384)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ci:cloud-deploy Create or update a Cloud deployment release_note:skip Skip the PR/issue when compiling release notes Team:Fleet Team label for Observability Data Collection Fleet team v8.7.1 v8.7.2 v8.8.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Fleet]: Agent diagnostics failed for Hosted fleet server under Diagnostics tab.
6 participants