kibana/x-pack/plugins/observability
Maryam Saeidi 41e54e7208
[AO] Save group information in AAD for the new threshold rule (#164087)
Closes #161758

## Summary

In this PR, I am saving the groupings information for the new threshold
in AAD in a similar format as the security team does, you can check the
format in the following screenshots. (Please check this
[RFC](https://docs.google.com/document/d/1DlykydM8Hk7-VAPOcuoUXp0L_qSi2jCZabJkPdO44tQ/edit#heading=h.2b1v1tr0ep8m)
for more information)

### Alert as data document


![image](ce4d5000-3799-4dd7-9a04-d012f1cc5aca)

### Groupings action variable


![image](5a4aaff1-b9c5-44e8-86e5-9fa397b6af62)

### Alert table


![image](cfe1aaf1-475c-4d04-8726-b064c0905d55)

It is also possible to search based on these new variables:


f07b39c2-52e8-4f50-b713-577da7ab1c42
2023-10-02 15:42:35 +02:00
..
.storybook fix all violations 2022-04-16 01:37:30 -05:00
common [Profiling] New settings to control CO2 calculation (#166637) 2023-09-30 02:25:55 -07:00
dev_docs Add detail in docs for histogram indicator type (#163905) 2023-08-15 19:31:57 -04:00
docs/openapi/slo feat(slo): limit perPage in find api (#167185) 2023-09-28 09:20:33 -04:00
public [RAM][Maintenance Window] Add maintenance window solution selection. (#166781) 2023-10-02 09:20:53 +01:00
scripts Update E2E setup for Exploratory View app (#154166) 2023-03-31 21:08:49 +02:00
server [AO] Save group information in AAD for the new threshold rule (#164087) 2023-10-02 15:42:35 +02:00
typings [Profiling] Add Universal Profiling to O11y overview and Setup guide (#165092) 2023-09-18 01:16:55 -07:00
jest.config.js [jest] update config files to get coverage per plugin (#111299) 2021-09-09 08:14:56 +02:00
kibana.jsonc [Drift] Enable chat globally + A/B test for pages where the chat was available before (#167069) 2023-10-01 16:07:11 +02:00
README.md feat(slo): remove feature flag (#152834) 2023-03-08 12:45:05 -07:00
tsconfig.json [RAM][Maintenance Window] Add maintenance window solution selection. (#166781) 2023-10-02 09:20:53 +01:00

Observability plugin

This plugin provides shared components and services for use across observability solutions, as well as the observability landing page UI.

Rules, Alerts, and Cases

In order to have alert data indexed you'll need to enable writing in the Rule Registry plugin:

xpack.ruleRegistry.write.enabled: true

When this is set to true, your alerts should show on the alerts page.

Shared navigation

The Observability plugin maintains a navigation registry for Observability solutions, and exposes a shared page template component. Please refer to the docs in the component directory for more information on registering your solution's navigation structure, and rendering the navigation via the shared component.

Exploratory view component

A shared component for visualizing observability data types via lens embeddable. For further details.

Unit testing

Note: Run the following commands from kibana/x-pack/plugins/observability.

Run unit tests

npx jest --watch

Update snapshots

npx jest --updateSnapshot

Coverage

HTML coverage report can be found in target/coverage/jest after tests have run.

open target/coverage/jest/index.html

API integration testing

API tests are separated in two suites:

  • a basic license test suite
  • a trial license test suite (the equivalent of gold+)

This requires separate test servers and test runners.

Basic

# Start server
node scripts/functional_tests_server --config x-pack/test/observability_api_integration/basic/config.ts

# Run tests
node scripts/functional_test_runner --config x-pack/test/observability_api_integration/basic/config.ts

The API tests for "basic" are located in x-pack/test/observability_api_integration/basic/tests.

Trial

# Start server
node scripts/functional_tests_server --config x-pack/test/observability_api_integration/trial/config.ts

# Run tests
node scripts/functional_test_runner --config x-pack/test/observability_api_integration/trial/config.ts

The API tests for "trial" are located in x-pack/test/observability_api_integration/trial/tests.

API test tips

  • For debugging access Elasticsearch on http://localhost:9220` (elastic/changeme)
  • To update snapshots append --updateSnapshots to the functional_test_runner command