[APM] "Backends" naming (#110523)

* renaming backends to dependencies

* changing name on service maps
This commit is contained in:
Cauê Marcondes 2021-09-01 00:01:10 -04:00 committed by GitHub
parent 5b6588d8cb
commit 31057f7215
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
11 changed files with 30 additions and 25 deletions

View file

@ -14,9 +14,9 @@ import {
import { environmentQuery } from './utils/environment_query';
export const kueryBarPlaceholder = i18n.translate(
'xpack.apm.backends.kueryBarPlaceholder',
'xpack.apm.dependencies.kueryBarPlaceholder',
{
defaultMessage: `Search backend metrics (e.g. span.destination.service.resource:elasticsearch)`,
defaultMessage: `Search dependency metrics (e.g. span.destination.service.resource:elasticsearch)`,
}
);

View file

@ -74,6 +74,10 @@ describe('Service Overview', () => {
cy.contains('Service Map');
// Waits until the agent request is finished to check the tab.
cy.wait('@agentRequest');
cy.contains('Dependencies').should('not.exist');
cy.get('.euiTabs .euiTab__content').then((elements) => {
elements.map((index, element) => {
expect(element.innerText).to.not.equal('Dependencies');
});
});
});
});

View file

@ -18,7 +18,7 @@ import { useApmParams } from '../../../hooks/use_apm_params';
import { useApmRouter } from '../../../hooks/use_apm_router';
import { SearchBar } from '../../shared/search_bar';
import { BackendLatencyChart } from './backend_latency_chart';
import { BackendInventoryTitle } from '../../routing/home';
import { DependenciesInventoryTitle } from '../../routing/home';
import { BackendDetailDependenciesTable } from './backend_detail_dependencies_table';
import { BackendThroughputChart } from './backend_throughput_chart';
import { BackendFailedTransactionRateChart } from './backend_error_rate_chart';
@ -39,7 +39,7 @@ export function BackendDetailOverview() {
useBreadcrumb([
{
title: BackendInventoryTitle,
title: DependenciesInventoryTitle,
href: apmRouter.link('/backends', {
query: { rangeFrom, rangeTo, environment, kuery },
}),

View file

@ -98,9 +98,9 @@ export function BackendInventoryDependenciesTable() {
dependencies={dependencies}
title={null}
nameColumnTitle={i18n.translate(
'xpack.apm.backendInventory.dependenciesTableColumnBackend',
'xpack.apm.backendInventory.dependencyTableColumn',
{
defaultMessage: 'Backend',
defaultMessage: 'Dependency',
}
)}
status={status}

View file

@ -85,8 +85,8 @@ export function BackendContents({
});
}}
>
{i18n.translate('xpack.apm.serviceMap.backendDetailsButtonText', {
defaultMessage: 'Backend Details',
{i18n.translate('xpack.apm.serviceMap.dependencyDetailsButtonText', {
defaultMessage: 'Dependency Details',
})}
</EuiButton>
</EuiFlexItem>

View file

@ -14,12 +14,12 @@ const { Backend, ExternalsList, Resource, Service } = composeStories(stories);
describe('Popover', () => {
describe('with backend data', () => {
it('renders a backend link', async () => {
it('renders a dependency link', async () => {
render(<Backend />);
await waitFor(() => {
expect(
screen.getByRole('link', { name: /backend details/i })
screen.getByRole('link', { name: /Dependency Details/i })
).toBeInTheDocument();
});
});

View file

@ -125,13 +125,13 @@ export function ServiceOverviewDependenciesTable({
title={i18n.translate(
'xpack.apm.serviceOverview.dependenciesTableTitle',
{
defaultMessage: 'Downstream services and backends',
defaultMessage: 'Dependencies',
}
)}
nameColumnTitle={i18n.translate(
'xpack.apm.serviceOverview.dependenciesTableColumnBackend',
'xpack.apm.serviceOverview.dependenciesTableColumn',
{
defaultMessage: 'Backend',
defaultMessage: 'Dependency',
}
)}
status={status}

View file

@ -45,10 +45,10 @@ export const ServiceInventoryTitle = i18n.translate(
}
);
export const BackendInventoryTitle = i18n.translate(
'xpack.apm.views.backendInventory.title',
export const DependenciesInventoryTitle = i18n.translate(
'xpack.apm.views.dependenciesInventory.title',
{
defaultMessage: 'Backends',
defaultMessage: 'Dependencies',
}
);
@ -114,7 +114,7 @@ export const home = {
},
page({
path: '/',
title: BackendInventoryTitle,
title: DependenciesInventoryTitle,
element: <BackendInventory />,
}),
],

View file

@ -93,9 +93,12 @@ const serviceMapTitle = i18n.translate('xpack.apm.navigation.serviceMapTitle', {
defaultMessage: 'Service Map',
});
const backendsTitle = i18n.translate('xpack.apm.navigation.backendsTitle', {
defaultMessage: 'Backends',
});
const dependenciesTitle = i18n.translate(
'xpack.apm.navigation.dependenciesTitle',
{
defaultMessage: 'Dependencies',
}
);
export class ApmPlugin implements Plugin<ApmPluginSetup, ApmPluginStart> {
constructor(
@ -126,7 +129,7 @@ export class ApmPlugin implements Plugin<ApmPluginSetup, ApmPluginStart> {
{ label: servicesTitle, app: 'apm', path: '/services' },
{ label: tracesTitle, app: 'apm', path: '/traces' },
{
label: backendsTitle,
label: dependenciesTitle,
app: 'apm',
path: '/backends',
isNewFeature: true,
@ -270,7 +273,7 @@ export class ApmPlugin implements Plugin<ApmPluginSetup, ApmPluginStart> {
{ id: 'services', title: servicesTitle, path: '/services' },
{ id: 'traces', title: tracesTitle, path: '/traces' },
{ id: 'service-map', title: serviceMapTitle, path: '/service-map' },
{ id: 'backends', title: backendsTitle, path: '/backends' },
{ id: 'backends', title: dependenciesTitle, path: '/backends' },
],
async mount(appMountParameters: AppMountParameters<unknown>) {

View file

@ -5657,7 +5657,6 @@
"xpack.apm.serviceNodeMetrics.unidentifiedServiceNodesWarningTitle": "JVM を特定できませんでした",
"xpack.apm.serviceNodeNameMissing": " (空) ",
"xpack.apm.serviceOveriew.errorsTableOccurrences": "{occurrencesCount} occ.",
"xpack.apm.serviceOverview.dependenciesTableColumnBackend": "バックエンド",
"xpack.apm.serviceOverview.dependenciesTableTitle": "依存関係",
"xpack.apm.serviceOverview.errorsTableColumnLastSeen": "前回の認識",
"xpack.apm.serviceOverview.errorsTableColumnName": "名前",

View file

@ -5685,7 +5685,6 @@
"xpack.apm.serviceNodeMetrics.unidentifiedServiceNodesWarningTitle": "找不到 JVM",
"xpack.apm.serviceNodeNameMissing": "(空)",
"xpack.apm.serviceOveriew.errorsTableOccurrences": "{occurrencesCount} 次",
"xpack.apm.serviceOverview.dependenciesTableColumnBackend": "后端",
"xpack.apm.serviceOverview.dependenciesTableTitle": "依赖项",
"xpack.apm.serviceOverview.errorsTableColumnLastSeen": "最后看到时间",
"xpack.apm.serviceOverview.errorsTableColumnName": "名称",