-
Notifications
You must be signed in to change notification settings - Fork 8.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[APM] Profiling #91818
Merged
Merged
[APM] Profiling #91818
Changes from 16 commits
Commits
Show all changes
18 commits
Select commit
Hold shift + click to select a range
d77c2e9
Profiling API call
dgieselaar 771308f
Merge branch 'master' of github.com:elastic/kibana into profiling-poc
dgieselaar faaa683
Flamegraph
dgieselaar 7ef1e5e
Merge branch 'master' of github.com:elastic/kibana into profiling-poc
dgieselaar 5a1b62d
Timeline
dgieselaar ba004ee
Merge branch 'master' of github.com:elastic/kibana into profiling-poc
dgieselaar bcb566f
Merge branch 'master' of github.com:elastic/kibana into profiling-poc
dgieselaar 20ff20b
Select profile type
dgieselaar 3daacd4
Merge branch 'master' of github.com:elastic/kibana into profiling-poc
dgieselaar c1790ac
Instrument profiling es calls
dgieselaar 02342c2
Enable drilldown
dgieselaar b21065b
Highlighting + fqn + collapsing
dgieselaar bc98e82
Add heap profile support
dgieselaar 252aaa9
Updated snapshot
dgieselaar 4c8bf41
Merge branch 'master' of github.com:elastic/kibana into profiling-poc
dgieselaar 06377b3
Hidden feature flag
dgieselaar d03fe06
Merge branch 'master' of github.com:elastic/kibana into profiling-poc
dgieselaar 231b1cf
Merge branch 'master' of github.com:elastic/kibana into profiling-poc
dgieselaar File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
66 changes: 66 additions & 0 deletions
66
x-pack/plugins/apm/common/__snapshots__/elasticsearch_fieldnames.test.ts.snap
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,112 @@ | ||
/* | ||
* 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 { i18n } from '@kbn/i18n'; | ||
import { | ||
PROFILE_ALLOC_OBJECTS, | ||
PROFILE_ALLOC_SPACE, | ||
PROFILE_CPU_NS, | ||
PROFILE_INUSE_OBJECTS, | ||
PROFILE_INUSE_SPACE, | ||
PROFILE_SAMPLES_COUNT, | ||
PROFILE_WALL_US, | ||
} from './elasticsearch_fieldnames'; | ||
|
||
export enum ProfilingValueType { | ||
wallTime = 'wall_time', | ||
cpuTime = 'cpu_time', | ||
samples = 'samples', | ||
allocObjects = 'alloc_objects', | ||
allocSpace = 'alloc_space', | ||
inuseObjects = 'inuse_objects', | ||
inuseSpace = 'inuse_space', | ||
} | ||
|
||
export enum ProfilingValueTypeUnit { | ||
ns = 'ns', | ||
us = 'us', | ||
count = 'count', | ||
bytes = 'bytes', | ||
} | ||
|
||
export interface ProfileNode { | ||
id: string; | ||
label: string; | ||
fqn: string; | ||
value: number; | ||
children: string[]; | ||
} | ||
|
||
const config = { | ||
[ProfilingValueType.wallTime]: { | ||
unit: ProfilingValueTypeUnit.us, | ||
label: i18n.translate( | ||
'xpack.apm.serviceProfiling.valueTypeLabel.wallTime', | ||
{ | ||
defaultMessage: 'Wall', | ||
} | ||
), | ||
field: PROFILE_WALL_US, | ||
}, | ||
[ProfilingValueType.cpuTime]: { | ||
unit: ProfilingValueTypeUnit.ns, | ||
label: i18n.translate('xpack.apm.serviceProfiling.valueTypeLabel.cpuTime', { | ||
defaultMessage: 'On-CPU', | ||
}), | ||
field: PROFILE_CPU_NS, | ||
}, | ||
[ProfilingValueType.samples]: { | ||
unit: ProfilingValueTypeUnit.count, | ||
label: i18n.translate('xpack.apm.serviceProfiling.valueTypeLabel.samples', { | ||
defaultMessage: 'Samples', | ||
}), | ||
field: PROFILE_SAMPLES_COUNT, | ||
}, | ||
[ProfilingValueType.allocObjects]: { | ||
unit: ProfilingValueTypeUnit.count, | ||
label: i18n.translate( | ||
'xpack.apm.serviceProfiling.valueTypeLabel.allocObjects', | ||
{ | ||
defaultMessage: 'Alloc. objects', | ||
} | ||
), | ||
field: PROFILE_ALLOC_OBJECTS, | ||
}, | ||
[ProfilingValueType.allocSpace]: { | ||
unit: ProfilingValueTypeUnit.bytes, | ||
label: i18n.translate( | ||
'xpack.apm.serviceProfiling.valueTypeLabel.allocSpace', | ||
{ | ||
defaultMessage: 'Alloc. space', | ||
} | ||
), | ||
field: PROFILE_ALLOC_SPACE, | ||
}, | ||
[ProfilingValueType.inuseObjects]: { | ||
unit: ProfilingValueTypeUnit.count, | ||
label: i18n.translate( | ||
'xpack.apm.serviceProfiling.valueTypeLabel.inuseObjects', | ||
{ | ||
defaultMessage: 'In-use objects', | ||
} | ||
), | ||
field: PROFILE_INUSE_OBJECTS, | ||
}, | ||
[ProfilingValueType.inuseSpace]: { | ||
unit: ProfilingValueTypeUnit.bytes, | ||
label: i18n.translate( | ||
'xpack.apm.serviceProfiling.valueTypeLabel.inuseSpace', | ||
{ | ||
defaultMessage: 'In-use space', | ||
} | ||
), | ||
field: PROFILE_INUSE_SPACE, | ||
}, | ||
}; | ||
|
||
export const getValueTypeConfig = (type: ProfilingValueType) => { | ||
return config[type]; | ||
}; |
2 changes: 2 additions & 0 deletions
2
x-pack/plugins/apm/public/components/app/Home/__snapshots__/Home.test.tsx.snap
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.