Skip to content

Commit

Permalink
Merge branch 'main' into 160425-restore-dataset-selection
Browse files Browse the repository at this point in the history
  • Loading branch information
tonyghiani authored Jul 19, 2023
2 parents d97e26c + 5bc6faa commit f736edf
Show file tree
Hide file tree
Showing 14 changed files with 177 additions and 196 deletions.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Binary file modified docs/user/alerting/images/rule-flyout-action-details.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/user/alerting/images/rule-flyout-action-variables.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Elastic License
* 2.0; you may not use this file except in compliance with the Elastic License
* 2.0.
*/

import url from 'url';
import { synthtrace } from '../../../../synthtrace';
import { opbeans } from '../../../fixtures/synthtrace/opbeans';

const start = '2021-10-10T00:00:00.000Z';
const end = '2021-10-10T00:15:00.000Z';

const dependencyOperationHref = url.format({
pathname: '/app/apm/dependencies/operation',
query: {
dependencyName: 'postgresql',
spanName: 'SELECT * FROM product',
environment: 'ENVIRONMENT_ALL',
rangeFrom: start,
rangeTo: end,
},
});

describe('Dependency operation', () => {
before(() => {
synthtrace.index(
opbeans({
from: new Date(start).getTime(),
to: new Date(end).getTime(),
})
);
});

after(() => {
synthtrace.clean();
});

beforeEach(() => {
cy.loginAsViewerUser();
});

it('opens the action menu popup when clicking the investigate button', () => {
cy.visitKibana(dependencyOperationHref);
cy.getByTestSubj('apmActionMenuButtonInvestigateButton').click();
cy.getByTestSubj('apmActionMenuInvestigateButtonPopup');
});
});
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Elastic License
* 2.0; you may not use this file except in compliance with the Elastic License
* 2.0.
*/

import url from 'url';
import { synthtrace } from '../../../../synthtrace';
import { generateMobileData } from './generate_data';

const start = '2021-10-10T00:00:00.000Z';
const end = '2021-10-10T00:15:00.000Z';

const mobileTransactionDetailsPageHref = url.format({
pathname: '/app/apm/mobile-services/synth-android/transactions/view',
query: {
rangeFrom: start,
rangeTo: end,
transactionName: 'Start View - View Appearing',
},
});

describe('Mobile transaction details page', () => {
before(() => {
synthtrace.index(
generateMobileData({
from: new Date(start).getTime(),
to: new Date(end).getTime(),
})
);
});

beforeEach(() => {
cy.loginAsViewerUser();
});

after(() => {
synthtrace.clean();
});

it('opens the action menu popup when clicking the investigate button', () => {
cy.visitKibana(mobileTransactionDetailsPageHref);
cy.getByTestSubj('apmActionMenuButtonInvestigateButton').click();
cy.getByTestSubj('apmActionMenuInvestigateButtonPopup');
});
});
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Elastic License
* 2.0; you may not use this file except in compliance with the Elastic License
* 2.0.
*/

import url from 'url';
import { synthtrace } from '../../../../synthtrace';
import { opbeans } from '../../../fixtures/synthtrace/opbeans';

const start = '2021-10-10T00:00:00.000Z';
const end = '2021-10-10T00:15:00.000Z';

const traceExplorerHref = url.format({
pathname: '/app/apm/traces/explorer',
query: {
environment: 'ENVIRONMENT_ALL',
rangeFrom: start,
rangeTo: end,
},
});

describe('Trace Explorer', () => {
before(() => {
synthtrace.index(
opbeans({
from: new Date(start).getTime(),
to: new Date(end).getTime(),
})
);

cy.updateAdvancedSettings({
'observability:apmTraceExplorerTab': true,
});
});

after(() => {
synthtrace.clean();
});

beforeEach(() => {
cy.loginAsViewerUser();
});

it('opens the action menu popup when clicking the investigate button', () => {
cy.visitKibana(traceExplorerHref);
cy.getByTestSubj('apmActionMenuButtonInvestigateButton').click();
cy.getByTestSubj('apmActionMenuInvestigateButtonPopup');
});
});
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,9 @@ describe('Transaction action menu', () => {
apmRouter,
infraLocators,
infraLinksAvailable: false,
rangeFrom: 'now-24h',
rangeTo: 'now',
environment: 'ENVIRONMENT_ALL',
})
).toEqual([
[
Expand Down Expand Up @@ -124,6 +127,9 @@ describe('Transaction action menu', () => {
apmRouter,
infraLocators,
infraLinksAvailable: true,
rangeFrom: 'now-24h',
rangeTo: 'now',
environment: 'ENVIRONMENT_ALL',
})
).toEqual([
[
Expand Down Expand Up @@ -205,6 +211,9 @@ describe('Transaction action menu', () => {
apmRouter,
infraLocators,
infraLinksAvailable: true,
rangeFrom: 'now-24h',
rangeTo: 'now',
environment: 'ENVIRONMENT_ALL',
})
).toEqual([
[
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import moment from 'moment';
import url from 'url';
import type { InfraLocators } from '@kbn/infra-plugin/common/locators';
import type { ProfilingLocators } from '@kbn/profiling-plugin/public';
import { Environment } from '../../../../common/environment_rt';
import type { Transaction } from '../../../../typings/es_schemas/ui/transaction';
import { getDiscoverHref } from '../links/discover_links/discover_link';
import { getDiscoverQuery } from '../links/discover_links/discover_transaction_link';
Expand Down Expand Up @@ -40,6 +41,9 @@ export const getSections = ({
infraLocators,
infraLinksAvailable,
profilingLocators,
rangeFrom,
rangeTo,
environment,
}: {
transaction?: Transaction;
basePath: IBasePath;
Expand All @@ -48,6 +52,9 @@ export const getSections = ({
infraLocators: InfraLocators;
infraLinksAvailable: boolean;
profilingLocators?: ProfilingLocators;
rangeFrom: string;
rangeTo: string;
environment: Environment;
}) => {
if (!transaction) return [];
const hostName = transaction.host?.hostname;
Expand All @@ -58,12 +65,6 @@ export const getSections = ({
const time = Math.round(transaction.timestamp.us / 1000);
const infraMetricsQuery = getInfraMetricsQuery(transaction);

const routeParams = apmRouter.getParams(
'/services/{serviceName}/transactions/view',
location
);
const { rangeFrom, rangeTo, environment } = routeParams.query;

const uptimeLink = url.format({
pathname: basePath.prepend('/app/uptime'),
search: `?${fromQuery(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ import { ProfilingLocators } from '@kbn/profiling-plugin/public';
import React, { useState } from 'react';
import { useLocation } from 'react-router-dom';
import useAsync from 'react-use/lib/useAsync';
import { useAnyOfApmParams } from '../../../hooks/use_apm_params';
import { ApmFeatureFlagName } from '../../../../common/apm_feature_flags';
import { Transaction } from '../../../../typings/es_schemas/ui/transaction';
import { useApmPluginContext } from '../../../context/apm_plugin/use_apm_plugin_context';
Expand Down Expand Up @@ -115,6 +116,15 @@ function ActionMenuSections({
ApmFeatureFlagName.InfraUiAvailable
);

const {
query: { rangeFrom, rangeTo, environment },
} = useAnyOfApmParams(
'/services/{serviceName}/transactions/view',
'/mobile-services/{serviceName}/transactions/view',
'/traces/explorer/waterfall',
'/dependencies/operation'
);

const sections = getSections({
transaction,
basePath: core.http.basePath,
Expand All @@ -123,6 +133,9 @@ function ActionMenuSections({
infraLocators: locators,
infraLinksAvailable,
profilingLocators,
rangeFrom,
rangeTo,
environment,
});

const externalMenuItems = useAsync(() => {
Expand Down Expand Up @@ -153,7 +166,7 @@ function ActionMenuSections({
}

return (
<div>
<div data-test-subj="apmActionMenuInvestigateButtonPopup">
{sections.map((section, idx) => {
const isLastSection = idx !== sections.length - 1;
return (
Expand Down
63 changes: 0 additions & 63 deletions x-pack/plugins/translations/translations/fr-FR.json
Original file line number Diff line number Diff line change
Expand Up @@ -27281,7 +27281,6 @@
"xpack.observability_onboarding.configureLogs.serviceName": "Nom de service",
"xpack.observability_onboarding.configureLogs.serviceName.helper": "Nom du service à partir duquel vos données sont collectées.",
"xpack.observability_onboarding.configureLogs.serviceName.placeholder": "Donner un nom à votre service",
"xpack.observability_onboarding.configureLogs.title": "Transmettre des fichiers log à Elastic",
"xpack.observability_onboarding.exploreOtherIntegrations": "Explorer d’autres intégrations",
"xpack.observability_onboarding.fetcher.error.status": "Erreur",
"xpack.observability_onboarding.fetcher.error.title": "Erreur lors de la récupération des ressources",
Expand All @@ -27298,7 +27297,6 @@
"xpack.observability_onboarding.installElasticAgent.installStep.choosePlatform.linux": "Linux",
"xpack.observability_onboarding.installElasticAgent.installStep.choosePlatform.macOS": "MacOS",
"xpack.observability_onboarding.installElasticAgent.installStep.choosePlatform.windows": "Windows",
"xpack.observability_onboarding.installElasticAgent.installStep.description": "Sélectionnez une plateforme et exécutez la commande pour l’installer dans votre terminal, enregistrez puis démarrez Elastic Agent. Faites ceci pour chaque hôte. Pour d’autres plateformes, consultez notre page des téléchargements. Consulter les exigences d’hébergement et les autres options d’installation.",
"xpack.observability_onboarding.installElasticAgent.installStep.title": "Installation d'Elastic Agent",
"xpack.observability_onboarding.installElasticAgent.progress.eaConfig.incompleteTitle": "Configurer l'agent",
"xpack.observability_onboarding.installElasticAgent.progress.eaConfig.loadingTitle": "Téléchargement de la configuration Elastic Agent",
Expand All @@ -27317,7 +27315,6 @@
"xpack.observability_onboarding.installElasticAgent.progress.logsIngest.completedTitle": "Les logs sont en cours de transfert.",
"xpack.observability_onboarding.installElasticAgent.progress.logsIngest.incompleteTitle": "Recherche de logs transférés",
"xpack.observability_onboarding.installElasticAgent.progress.logsIngest.loadingTitle": "En attente du transfert des logs",
"xpack.observability_onboarding.installElasticAgent.title": "Installer l’agent de transfert pour collecter des données",
"xpack.observability_onboarding.selectLogs.chooseType": "Quels logs voulez-vous collecter ?",
"xpack.observability_onboarding.selectLogs.httpEndpointLogs": "Point de terminaison HTTP",
"xpack.observability_onboarding.selectLogs.httpEndpointLogs.description": "Collecter des données JSON du port HTTP à l’écoute.",
Expand All @@ -27332,12 +27329,9 @@
"xpack.observability_onboarding.selectLogs.useOwnShipper": "Obtenir une clé d’API",
"xpack.observability_onboarding.selectLogs.useOwnShipper.description": "Utilisez votre propre agent de transfert pour collecter des données de logs en générant une clé d’API.",
"xpack.observability_onboarding.steps.back": "Retour",
"xpack.observability_onboarding.steps.configureLogs": "Configurer les logs",
"xpack.observability_onboarding.steps.continue": "Continuer",
"xpack.observability_onboarding.steps.exploreLogs": "Explorer les logs",
"xpack.observability_onboarding.steps.inspect": "Inspecter",
"xpack.observability_onboarding.steps.installShipper": "Installer l’agent de transfert",
"xpack.observability_onboarding.steps.selectLogs": "Sélectionner les logs",
"xpack.observability_onboarding.title.collectCustomLogs": "Collectez des logs personnalisés",
"xpack.observability.apmEnableContinuousRollupsDescription": "{betaLabel} Lorsque les cumuls continus sont activés, l'interface utilisateur sélectionne des indicateurs ayant la résolution appropriée. Sur des plages temporelles plus larges, des indicateurs de résolution inférieure sont utilisés, ce qui améliore les temps de chargement.",
"xpack.observability.apmEnableServiceMetricsDescription": "{betaLabel} Permet l'utilisation d'indicateurs de transaction de service. Il s'agit d'indicateurs à faible cardinalité qui peuvent être utilisés par certaines vues, comme l'inventaire de service, pour accélérer le chargement.",
Expand Down Expand Up @@ -40130,11 +40124,7 @@
"devTools.badge.readOnly.tooltip": "Enregistrement impossible",
"devTools.breadcrumb.homeLabel": "Outils de développement",
"devTools.devToolsTitle": "Outils de développement",
"eventAnnotation.annotationList.add": "Ajouter une annotation",
"eventAnnotation.content.name": "Groupe d'annotations",
"eventAnnotation.edit.back": "Retour",
"eventAnnotation.edit.cancel": "Annuler",
"eventAnnotation.edit.save": "Enregistrer le groupe d'annotations",
"eventAnnotation.eventAnnotationGroup.metadata.name": "Groupes d’annotations",
"eventAnnotation.eventAnnotationGroup.savedObjectFinder.emptyCTA": "Créer un calque d’annotations",
"eventAnnotation.eventAnnotationGroup.savedObjectFinder.emptyPromptDescription": "Il n’y a actuellement aucune annotation disponible à sélectionner depuis la bibliothèque. Créez un nouveau calque pour ajouter des annotations.",
Expand All @@ -40151,14 +40141,6 @@
"eventAnnotation.group.args.annotationConfigs.ignoreGlobalFilters.help": "Basculer pour ignorer les filtres globaux pour l'annotation",
"eventAnnotation.group.args.annotationGroups": "Groupe d'annotations",
"eventAnnotation.group.description": "Groupe d'annotations d'événement",
"eventAnnotation.groupEditor.addAnnotation": "Annotations",
"eventAnnotation.groupEditor.dataView": "Vue de données",
"eventAnnotation.groupEditor.description": "Description",
"eventAnnotation.groupEditor.details": "Détails",
"eventAnnotation.groupEditor.optional": "Facultatif",
"eventAnnotation.groupEditor.title": "Titre",
"eventAnnotation.groupEditor.titleRequired": "Un titre est requis.",
"eventAnnotation.groupEditorFlyout.title": "Modifier le groupe d'annotations",
"eventAnnotation.listingViewTitle": "Groupes d'annotations",
"eventAnnotation.manualAnnotation.args.color": "Couleur de la ligne",
"eventAnnotation.manualAnnotation.args.icon": "Icône facultative utilisée pour les lignes d'annotation",
Expand Down Expand Up @@ -40190,51 +40172,6 @@
"eventAnnotation.rangeAnnotation.args.label": "Nom de l'annotation",
"eventAnnotation.rangeAnnotation.args.time": "Horodatage de l'annotation",
"eventAnnotation.rangeAnnotation.description": "Configurer l'annotation manuelle",
"eventAnnotation.tableList.dataView": "Vue de données",
"eventAnnotation.tableList.emptyPrompt.body": "Vous pouvez créer et enregistrer des annotations afin de les utiliser dans plusieurs visualisations de l’éditeur de visualisation Lens.",
"eventAnnotation.tableList.emptyPrompt.cta": "Créer une nouvelle annotation dans Lens",
"eventAnnotation.tableList.emptyPrompt.title": "Créer votre première annotation dans Lens",
"eventAnnotation.tableList.entityName": "groupe d'annotations",
"eventAnnotation.tableList.entityNamePlural": "groupes d'annotations",
"eventAnnotation.tableList.listTitle": "Bibliothèque d’annotations",
"eventAnnotation.xyChart.annotation.hide": "Masquer l’annotation",
"eventAnnotation.xyChart.annotation.manual": "Date statique",
"eventAnnotation.xyChart.annotation.query": "Requête personnalisée",
"eventAnnotation.xyChart.annotation.queryField": "Champ de date cible",
"eventAnnotation.xyChart.annotation.queryInput": "Requête sur les annotations",
"eventAnnotation.xyChart.annotation.tooltip": "Afficher les champs supplémentaires",
"eventAnnotation.xyChart.annotation.tooltip.addField": "Ajouter un champ",
"eventAnnotation.xyChart.annotation.tooltip.deleteButtonLabel": "Supprimer",
"eventAnnotation.xyChart.annotation.tooltip.noFields": "Aucune sélection",
"eventAnnotation.xyChart.annotationDate": "Date de l’annotation",
"eventAnnotation.xyChart.annotationDate.from": "De",
"eventAnnotation.xyChart.annotationDate.placementType": "Type de placement",
"eventAnnotation.xyChart.annotationDate.to": "À",
"eventAnnotation.xyChart.appearance": "Apparence",
"eventAnnotation.xyChart.applyAsRange": "Appliquer en tant que plage",
"eventAnnotation.xyChart.defaultAnnotationLabel": "Événement",
"eventAnnotation.xyChart.defaultRangeAnnotationLabel": "Plage d'événements",
"eventAnnotation.xyChart.fillStyle": "Remplir",
"eventAnnotation.xyChart.fillStyle.inside": "Intérieur",
"eventAnnotation.xyChart.fillStyle.outside": "Extérieur",
"eventAnnotation.xyChart.iconSelect.alertIconLabel": "Alerte",
"eventAnnotation.xyChart.iconSelect.asteriskIconLabel": "Astérisque",
"eventAnnotation.xyChart.iconSelect.bellIconLabel": "Cloche",
"eventAnnotation.xyChart.iconSelect.boltIconLabel": "Éclair",
"eventAnnotation.xyChart.iconSelect.bugIconLabel": "Bug",
"eventAnnotation.xyChart.iconSelect.circleIconLabel": "Cercle",
"eventAnnotation.xyChart.iconSelect.commentIconLabel": "Commentaire",
"eventAnnotation.xyChart.iconSelect.flagIconLabel": "Drapeau",
"eventAnnotation.xyChart.iconSelect.heartLabel": "Cœur",
"eventAnnotation.xyChart.iconSelect.mapMarkerLabel": "Repère",
"eventAnnotation.xyChart.iconSelect.mapPinLabel": "Punaise",
"eventAnnotation.xyChart.iconSelect.starFilledLabel": "Étoile remplie",
"eventAnnotation.xyChart.iconSelect.starLabel": "Étoile",
"eventAnnotation.xyChart.iconSelect.tagIconLabel": "Balise",
"eventAnnotation.xyChart.iconSelect.triangleIconLabel": "Triangle",
"eventAnnotation.xyChart.lineColor.label": "Couleur",
"eventAnnotation.xyChart.placement": "Placement",
"eventAnnotation.xyChart.tooltip": "Infobulle",
"expandableFlyout.previewSection.backButton": "Retour",
"expandableFlyout.previewSection.closeButton": "Fermer",
"expressionHeatmap.function.args.addTooltipHelpText": "Afficher l'infobulle au survol",
Expand Down
Loading

0 comments on commit f736edf

Please sign in to comment.