Fixes#166773
## Summary
Fixes a bug where panels are not showing descriptions from library
items.
Changes the panel to use the `embeddable.getDescription` method for
retrieving the description. This is necessary since by-reference panels
can store descriptions in the saved object. `getDescription` will check
for a description in the saved object attributes, but the panel
description will still take precedence. This is very similar to how we
get the panel title.
## Summary
- Combines the `endpoint` and `mocked_data` tests suites so that they
run from the same cypress configuration/run buildkite setup
- Moved test files from the `endpoint/` and `mocked_data/` directories
into new sub-directories that more closely describe the set of tests
they contain
- The `security_solution/package.json` file was updated so that the
following `scripts` will now output a warning indicating that command is
no longer valid:
- `cypress:dw:endpoint`
- `cypress:dw:endpoint:run`
- `cypress:dw:endpoint:open`
The following npm/yarn commands remain available for running tests
locally:
```shell
yarn --cwd=x-pack/plugins/security_solution cypress:dw:open
```
```shell
yarn --cwd=x-pack/plugins/security_solution cypress:dw:run
```
New test file struncture:
<img width="415" alt="image"
src="0cb4bc76-b434-4219-b73e-508645201a81">
closes https://github.com/elastic/kibana/issues/164995
closes https://github.com/elastic/kibana/issues/165618
closes https://github.com/elastic/kibana/issues/166596
## 📝 Summary
### Observability Log Explorer Locators:
This PR adds 2 new customized locators to the Observability log explorer
profile. At the moment we implemented:
1- Single dataset selector locator
2- All dataset selector locator
With more locators to come in the future depending on the use cases.
### Log Explorer Locators:
We also added a log explorer locator that navigates to discover, this
can be used in case the **Observability Log Explorer** plugin is
disabled.
### Logs Onboarding:
The PR also replaces the temp navigation to the default discover we
implemented for[ 8.10
here](https://github.com/elastic/kibana/pull/163218) with the above new
Observability Log Explorer locators.
### APM:
After [disabling infra plugin in serverless
projects](https://github.com/elastic/kibana/pull/165289), APM links to
infra locators in serverless have been replaced to use the above
locators.
### Observability Landing Page:
The landing page now redirects to the Log Explorer if `logs-*-*` has
data in it, otherwise the flow continues as before.
### Necessary Refactoring:
To avoid the circular dependency between `ObservabilityLogExplorer` &
`ObservabilityOnboarding` after each one using the other's locator and
importing the necessary types, I moved the type definition for all
locators in the `deeplinks` package.
## ✅ Testing
- Onboarding Wizard in Serverless and Stateful
1. Navigate to the onboarding flow `/app/observabilityOnboarding/`
2. Choose either System logs or Stream log files
3. Go through the onboarding wizard
4. Click the Explore logs button at the end
5. You should be redirected to observability log explorer with the
integration and dataset preselected.
- APM links in Serverless
1. Navigate to APM and click on the logs links as shown in the Demos
below
2. All links should navigate to Observability Log Explorer with the
queries set in the search bar.
## 🎥 Demos
- APM Serverless
7161364e-333f-4ac4-87d5-7f1ffec699b3
- APM Stateful
058c9587-b766-4d4f-a73d-50fd381be4bb
- Onboarding Serverless
ee1cab42-f91c-4558-aa5f-4fa7e8963427
- Onboarding Stateful
a376a12b-499b-4488-a75a-d06e81f8e21d
- Observability Landing Page
c1c084ca-b1b1-4c4b-a4e6-ae8e157dcf57
---------
Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Marco Antonio Ghiani <marcoantonio.ghiani@elastic.co>
Co-authored-by: Marco Antonio Ghiani <marcoantonio.ghiani01@gmail.com>
**Problem:** Several headings in the release notes use title case (Example: "Bug Fixes"). Elastic uses sentence case for headings.
**Solution:** Update release note headings to use sentence case.
## Summary
- Moves the Serverless Endpoint Management tests from
`x-pack/test_serverless/functional/test_suites/security/cypress` to
`x-pack/plugins/security_solution/public/management/cypress` along with
its set of supporting `screens` and `task`'s
- This work is in preparation for enabling tests to be run in a
serverless environment
> ❗❗ NOTE
> Tests for serverless are not currently running. The kibana core team
is working on providing serverless users that have serverless security
roles assigned to them for testing. Also, an effort in underway to also
use a tagging approach to define which existing tests should run in
serverless.
---------
Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
## Summary
We try to reuse existing FTR services for serverless test as much as
possible. Most of the services are deployment agnostic, however some
won't work on serverless and we add its own serverless implementation.
Currently we import all the services from api integration tests directly
into the serverless services. The same with functional ones. This PR
loads the minimum required services for api integration and functional
tests respectively.
This way we can control which services are deployment agnostic and
explicitly remove any of it when we decide to have its own
implementation for serverless.
- Move logic to fetch the TopN functions to
'profiling-data-access-plugin'
- Create new TopN functions embeddable
- Refactor Universal profiling page on APM adding Tabs (Flamegraph | Top
10 functions)
- Create a new API on APM to fetch Top functions
<img width="1605" alt="Screenshot 2023-09-08 at 11 14 13"
src="76fc7bf3-094b-438b-99b8-3cab01539eb4">
<img width="1615" alt="Screenshot 2023-09-08 at 11 14 20"
src="c4d3e97a-eee0-4829-8d6f-545f9c844b18">
---------
Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Joseph Crail <joseph.crail@elastic.co>
Towards https://github.com/elastic/response-ops-team/issues/130
## Summary
This implements the third of 3 SLIs described in
https://github.com/elastic/response-ops-team/issues/130 - the histogram
for tracking task overdue time in seconds. We bucket up to 30 minutes.
This implementation is slightly different than what was originally
described for this SLI, which was number of overdue tasks. We changed to
track a histogram of number of seconds overdue because this will provide
a better metric against which to set an SLO.
## To Verify
Run Kibana and create some alerting rules. Navigate to
https://localhost:5601/api/task_manager/metrics?reset=false and you
should see that the new metric under `task_overdue.value`. There should
be an overall task delay histogram and a histogram for each task type,
with groupings for the alerting and action task types
---------
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
closes https://github.com/elastic/kibana/issues/166247
## 📝 Summary
This PR changes the display of datasets in the dataset selector so that
we only show the dataset name and not the whole index pattern.
ex:
- `logs-foo-*` ➡️ `foo`
- `logs-bar-*` ➡️ `bar`
## ✅ Testing
1. Navigate to the observability log explorer
2. Click the dataset selector and choose Uncategorized
3. Observe how the datasets are represented
## 🎥 Demo
8a6a1212-46d5-4ceb-bf38-cf13d1b3e555
Closes#166748
## Summary
This PR fixes an issue with the error state - when there is a successful
request after a failed request the error state was still visible.
### Before
0cb15cab-dc7c-48ad-b080-179f0444284d
### After
e765b5e9-d213-45da-968f-257955b1f4b0
## Summary
Fixes a problem on the flyout ui (the black line on the right). I dont
think that this line is useful. Vertical scrolling works fine.
**Before**
<img width="1435" alt="image"
src="56868893-2aad-4118-a5c6-245b1111b735">
**Now**
<img width="1356" alt="image"
src="0f2d0e87-d60d-4507-8d68-accc0ba840ed">
## Summary
This fixes the icon and category being missing for top level search
results for Serverless Search pages.
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
## Summary
- introduces tags for [Defend Workflows] cypress tests (similarly to
https://github.com/elastic/kibana/pull/162698)
- adds scripts to Security Solution:
- `cypress:dw:serverless:open` and `:run`
- `cypress:dw:endpoint:serverless:open` and `:run`
- adds CI jobs to run these scripts
- so far most of the expected tests got both `@serverless` and
`@brokenInServerless` tests, because of other issues to be solved,
- one test is able to run against serverless:
`x-pack/plugins/security_solution/public/management/cypress/e2e/mocked_data/policy_details.cy.ts`
Closes#161367
## Summary
This PR changes the metadata error callout to re-fetch the metadata
instead of reloading the whole page. As the components are now used also
in the asset details view refreshing the flyout won't be needed - as
also it won't help the user if we fetch other data again when the
metadata is missing. The current logic will make the request to the
metadata again in case of an error. This way the other content will stay
the same as we don't need to reload the whole flyout/tab in case the
metadata request fails
## Testing
I couldn't find a good way to 'fake' the error happening only once ( and
getting a result after the refetch) I did 2 things trying to simulate
the behavior (not ideal but it's fine for checking the cases)
1. Change the [metadata endpoint
name](https://github.com/elastic/kibana/blob/main/x-pack/plugins/infra/public/components/asset_details/hooks/use_metadata.ts/#L32C8-L32C8)
(to metadataaa for example) to cause 404 error (or comment the parameter
to get 500)
- Check the error callout
fbf833c7-2f94-4027-bf58-3dbc8d95a090
2. Change the metadata hook to send an error initially and to get the
actual metadata error value when the re-fetch is triggered:
<img width="808" alt="fake_error"
src="b81c3c98-d957-4c0b-8f2e-676c26a0e916">
d65f5c3e-9d81-4fec-a0bf-338ef50ca7db
## 📓 Summary
Closes#165222
This work intends to avoid the registration of the log view saved object
(`type: "infrastructure-monitoring-log-view"`) and the related endpoint
to update a persisted log view.
To achieve it, the `xpack.logs_shared.savedObjects.logView.enabled`
configuration is introduced, which is configurable only in a serverless
environment and defaults to `true` for the stateful Kibana version to
keep the existing behaviour unchanged.
To also guarantee the normal functioning of the consumers of the
`<LogStream />` component in a serverless environment, we now set an
internal view using the default configuration that will be used as a
fallback when skipping the persisted log view lookup.
## 🧪 Testing
### Normal behaviour
When Kibana is used as always, we want to keep the current behaviour and
retrieve the persisted log view if exists or default to an internally
defined one.
- Launch the Kibana dev environment with `yarn start`
- Navigate to APM/Fleet/Enterprise Search logs
- Verify all the usages of the `<LogStream />` component work correctly
retrieving the internal views set during the setup lifecycle of the
related plugin. This means the LogStream should render the appropriate
columns set for the default log view or apply the custom ones defined
with an internal log view.
### Serverless behaviour
When Kibana is used in serverless mode, we want to skip the lookup for
the log view saved object and directly retrieve the log view from the
internally defined ones.
- Launch the Kibana dev environment with `yarn serverless-oblt`
- Navigate to APM/Fleet/Enterprise Search logs
- Verify all the usages of the `<LogStream />` component work correctly
retrieving the internal views set during the setup lifecycle of the
related plugin.
---------
Co-authored-by: Marco Antonio Ghiani <marcoantonio.ghiani@elastic.co>
## Summary
This PR fixes#166476 by fixing a bug where you can't repeat a variable
twice in the equation. This PR changes the code that converts the
variables from `A` to `params.A` by changing a `replace` to a
`replaceAll`.
The work around would be to duplicate the aggregation that needs to be
repeated so it has a unique variable name.
### 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
---------
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
closes https://github.com/elastic/kibana/issues/162944
## Summary
This PR adds the Kubernetes Overview section to the Host Detail view.
**Old view**
<img width="778" alt="image"
src="2c6c3341-7aa3-48e4-a5d5-e9580b2e2c13">
**New view**
<img width="778" alt="image"
src="357ef56d-b783-41ed-8d7f-e9a3369d13b0">
There was some reog in the formulas folder too, separating nginx and
kubernetes from hosts formulas.
### How to test
- Start a local Kibana pointing to a oblt cluster
- Navigate to `Infrastructure` > `Hosts`
- Click on a `gke` host to navigate to the detail view