From 0559de6678b233da08ea2f532912ee9c61dff212 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Cau=C3=AA=20Marcondes?=
<55978943+cauemarcondes@users.noreply.github.com>
Date: Wed, 7 Aug 2024 09:11:49 +0100
Subject: [PATCH 01/44] [APM][ECO] Logs callout when logs.level is not
available (#189644)
closes https://github.com/elastic/kibana/issues/189731
- Adding dismiss button to APM section
- Adding logs callout
https://github.com/user-attachments/assets/902409de-7d9b-47bf-b57d-3cdb199301f0
- N/A popover
---
.../apm/common/entities/types.ts | 1 +
.../app/entities/logs/add_apm_callout.tsx | 84 ++++++++++------
.../entities/logs/logs_service_overview.tsx | 97 +++++++++++++++++--
.../table/get_service_columns.tsx | 18 +++-
.../shared/environment_badge/index.tsx | 2 +-
.../not_available_apm_metrics.tsx | 8 +-
.../not_available_environment.tsx | 6 +-
.../not_available_log_metrics.tsx | 53 ++++++++++
.../apm/public/utils/get_signal_type.ts | 2 +-
.../server/routes/entities/get_entities.ts | 12 ++-
.../entities/get_service_entity_summary.ts | 40 ++++++++
.../server/routes/entities/services/routes.ts | 32 ++++++
.../apm/server/routes/entities/types.ts | 2 +
.../utils/calculate_avg_metrics.test.ts | 6 ++
.../entities/utils/merge_entities.test.ts | 22 +++++
.../routes/entities/utils/merge_entities.ts | 2 +
16 files changed, 332 insertions(+), 55 deletions(-)
rename x-pack/plugins/observability_solution/apm/public/components/shared/{ => not_available_popover}/not_available_apm_metrics.tsx (81%)
rename x-pack/plugins/observability_solution/apm/public/components/shared/{ => not_available_popover}/not_available_environment.tsx (92%)
create mode 100644 x-pack/plugins/observability_solution/apm/public/components/shared/not_available_popover/not_available_log_metrics.tsx
create mode 100644 x-pack/plugins/observability_solution/apm/server/routes/entities/get_service_entity_summary.ts
diff --git a/x-pack/plugins/observability_solution/apm/common/entities/types.ts b/x-pack/plugins/observability_solution/apm/common/entities/types.ts
index f953fb5c593ed..bdca62bc66824 100644
--- a/x-pack/plugins/observability_solution/apm/common/entities/types.ts
+++ b/x-pack/plugins/observability_solution/apm/common/entities/types.ts
@@ -27,4 +27,5 @@ export interface EntityServiceListItem {
environments: string[];
serviceName: string;
agentName: AgentName;
+ hasLogMetrics: boolean;
}
diff --git a/x-pack/plugins/observability_solution/apm/public/components/app/entities/logs/add_apm_callout.tsx b/x-pack/plugins/observability_solution/apm/public/components/app/entities/logs/add_apm_callout.tsx
index c73526a5350c5..49856327dd703 100644
--- a/x-pack/plugins/observability_solution/apm/public/components/app/entities/logs/add_apm_callout.tsx
+++ b/x-pack/plugins/observability_solution/apm/public/components/app/entities/logs/add_apm_callout.tsx
@@ -16,6 +16,7 @@ import {
EuiTitle,
EuiButtonEmpty,
useEuiTheme,
+ EuiButtonIcon,
} from '@elastic/eui';
import { apmLight } from '@kbn/shared-svg';
import { FormattedMessage } from '@kbn/i18n-react';
@@ -23,7 +24,11 @@ import { useKibana } from '../../../../context/kibana_context/use_kibana';
import { ApmPluginStartDeps, ApmServices } from '../../../../plugin';
import { AddApmData } from '../../../shared/add_data_buttons/buttons';
-export function AddAPMCallOut() {
+interface Props {
+ onClose: () => void;
+}
+
+export function AddAPMCallOut({ onClose }: Props) {
const { euiTheme } = useEuiTheme();
const { services } = useKibana
-
+
-
-
+
+