* [APM] Fix anomalies not showing up on transaction charts
* Added API tests to check transaction groups charts for anomaly data
* Improve test names and assertions from PR feedback
* Updated the transaction groups chart API to make `environment` a
required param while making `uiFilters` optional
* updates the basic API tests for transaction_groups/charts with the
required `environment` param
* makes uiFIltersES default to [] on core setup and removes SetupUIFilters type
* fixes vertical shade
* - replaces uiFiltersES with esFilter & uiFilters and cleans up related code around these
- deduplicates the required environment in the transaction_groups/charts API
* updates basic apm_api_integration tests
* pr feedback
* updates api test snapshots with correct anomaly data
* removed environment query param from useTransactionCharts and ensures
it's included in uiFilters returned from useUrlParams
Co-authored-by: Oliver Gupte <olivergupte@gmail.com>
* adding cgroup fields
* calculate the memory based on the cgroup fields otherwise use the system fields
* updating script
* adding api tests
* using cgroup fields on service map
* addressing PR comment
* fixing unit test
* fixing test
* changing api tests to use snapshot
* removing inactive_files from calculation
* fixing test
* refactoring painless script
* addressing PR comment
* addressing pr comments
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
* add babel support for export type
* bump ts version to 3.9.3
* rebuild kbn-pm
* bump typescript-eslint
* fix error in security plugin UI
* check export as works
* fix app migration type
* use correct test subj attribute
* fix errors from the old PR
* embeddable is already passed in props
* explicitly define type of fetch
* add some types for viz
* fix fetch type p.2
* add null to allow spreading without type errors due to override
* add type guard to fix type error
* cast to any, since cannot assign unknown
* add timestamp to known types
* fix type error in fetch
* fix type error. id is always defined in attibutes
* declare a type
* move ts-ignore to the lines with errors
* declare tuple type explicitly
* mute type error. cannot assign unknown
* fix errors. id is always defined
* fix error type
* fix override errors. id is always defined
* fix error. extends any doesn't work anymore
* fix type error. type is always defined
* env doesn't always contain values
* fix type error
* cast to string
* add: logs is already declared in getNodeLogsUrl
* state is already passed in props
* fix some errors in timelion
* number of fragments is always defined
* 'absolute' is not just string, but value
* TEMP: option is always defined
* always true if cast to promise manually
* both props are always defined
* explicitly define returned SO type
* workaround type
* bump tslib to be compatible with ts v3.9
* test private property
* rebuild kbn-pm
* Fix ts errors for beats management
* Fix type inference broken by the TS 3.9 upgrade
* Fix ingest manager saved object attributes typings
* Fix TS errors in cross_cluster_replication and index_management.
* Fix TS error in Watcher.
* roll back colorRange wrong type
* fix security plugin types
* TypeScript 3.9 fixes for APM
* Fix ColorRange types.
* fix actions & alerts errors. ByGidi
* fix lists error
* More APM fixes
* Remove paramaterization from `removeEmpty in agent config SettingsPage component (it's only used there and doesn't need to be parameterized.)
* Add option chain for case in registerTransactionDurationAlertType
* Cast `overallValue` in transform_metrics_chart
* Use more specific type for custom link filters
* Add more option chaining for local UI filters buckets response
* Remove unused parameters from routes
* Fix getProjection type parameter
* Use destructuring in serviceNodesLocalFiltersRoute to hide `never` error
* Revert `UnionToIntersection` change in `AggregationResponseMap`
Fixes#67804.
* fix platform type error
* Fix visualizations types.
* Fix data plugin types.
* bump TS version to 3.9.5
* Fix telemetry TS errors
* Fix dashboard code
* Adding Canvas Fixes for TS 3.9
* Fix case and security_solution types
* roll back to the old export syntax. new one might cause problems in api-extractor
* update docs
* Fix timelion code
* Fix meta
* Fix types
* fix type errors om ingest_manager
* bump babel deps
* enable private props & methods syntax
* update kbn-pm dist
* whitelist 0BSD license
* use @babel/plugin-proposal-private-methods in default set as well
* disable new babel plugins
* Revert "disable new babel plugins"
This reverts commit 04d959431d.
* cleanup security_solution types
* Fixes type error for newer TypeScript
* update docs
Co-authored-by: Nicolas Chaulet <nicolas.chaulet@elastic.co>
Co-authored-by: Felix Stürmer <stuermer@weltenwort.de>
Co-authored-by: CJ Cenizal <cj@cenizal.com>
Co-authored-by: Larry Gregory <larry.gregory@elastic.co>
Co-authored-by: Nathan L Smith <smith@nlsmith.com>
Co-authored-by: Walter Rafelsberger <walter@elastic.co>
Co-authored-by: Luke Elmers <luke.elmers@elastic.co>
Co-authored-by: Alejandro Fernández Haro <alejandro.haro@elastic.co>
Co-authored-by: Tim Roes <tim.roes@elastic.co>
Co-authored-by: Clint Andrew Hall <clint.hall@elastic.co>
Co-authored-by: Patryk Kopycinski <contact@patrykkopycinski.com>
Co-authored-by: FrankHassanabad <frank.hassanabad@elastic.co>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
* migrate files from legacy path to new plugin path
* update file paths to reflect migrated files
* move minimal legacy client files back to legacy path in order to run kibana
* Completes the full cutover to the new kibana platform removing all shims and legacy adapters.
* Adds APM to ignored list for casing check.
* - moves public/utils/pickKeys.ts to common/utils/pick_keys.ts
- exposes getTraceUrl as a plugin static export of apm/public and updates import in infra
- fixes FeaturesPluginSetup import in apm/public app
- renames get_apm_index_pattern_titles -> get_apm_index_pattern_title
- getApmIndexPatternTitle is now a synchronous getter function
- removes unused comments and xpack.apm.apmForESDescription i18n translations
* Moves automatic index pattern saved object creation from
plugin start to when the Home screen first renders
* removed unnecessary legacy css imports
* fixed ci issues by:
- moving readOnly badge, and help extension setup to occure only
when apm app is mounted
- registering saved object types
- also moved createStaticIndexPattern from a react useEffect on the
APM home screen to when the app is mounted
Remove the getCytoscapeElements function.
On the server:
* Replace `source` with `sourceData`, `destination` with `targetData`, `source.id` with `source`, and `destination.id` with `target`.
* Return a single array as an `elements` property instead of `nodes` and `connections`
* Map all of the items data to be inside of a `data` object
* Replace SERVICE_AGENT_NAME with AGENT_NAME
* Add some missing constants
On the client:
* Remove getCytoscapeElements
* Move all presentation-specific data transformation to use the original attributes in the place where they're needed
* Remove `href` since it wasn't being used
* Move BetaBadge to its own file
* Move cytoscapeDivStyle to cytoscapeOptions
* Fix storybook to work with new data formats
* Closes @56832 Migrates uses of the saved objects client to the internal
and context scoped clients exposed in the new platform core setup
* moves apm server, common, and typings dirs to the new plugin directory
* fixes path imports and type errors
* fixes some lint errors
* fixes CI failure. Use internal saved objects client like before.
* uses the context-scoped saved objects client for saving runtime APM indices,
and uses the internal saved objects client when creating apm index
pattern, so that any user who navigates to apm can trigger it
* fixes the type check error by updating import paths
* renamed files and directories to snake_case to pass scripts/check_file_casing
* rebase fixes and commit filename case changes
* moves get_indices_privileges.ts out of legacy path
* [APM]: Inferred types for aggregations
Previously, aggregations returned by the ESClient were 'any' by default, and the return type had to be explicitly defined by the consumer to get any type safety. This leads to both type duplication and errors because of wrong assumptions.
This change infers the aggregation return type from the parameters passed to ESClient.search.
* Fix idx error
* Safeguard against querying against non-existing indices in functional tests
* Improve metric typings
* Automatically infer params from function arguments
* Remove unnecessary type hints
* [APM] Closes#69301 by adding CPU/Memory graphs back to java-specific
metrics, modifying java metrics chart labels, and adding thread count
max line to chart.
* [APM] update i18n unused translation
* [APM] add filter to exclude non-existent memory chart data
* [APM] Adds global service environment filter to all applicable pages and APIs via uiFilters pattern.
* [APM] addressed some PR feedback:
- removed useUiFilters custom hook, derives memoized uiFilters from urlParams with useMemo and use the obj ref in dependency array
- modified the layout of environments filter to use EuiFlex components
- added 'Select environment' label to seperator, changed capitalization to 'Not defined' option
- set services table set column widths to 40%,20% for first 2 cols, and added space to comma separated list of environments
- added tests for generating environment es filters
* [APM] rename getUiFilters -> useUiFilters since it's based on useMemo
* Creates new java metrics endpoint
* Creates per-chart fetcher and index for per-agent metrics, with valid types
* Restructures client-side metrics charts to use new metrics endpoint, removes old unused code
* Adds i18n in the server for metrics charts
* Adds java metrics thread count chart
* Removes hard-coded agent name for metrics fetch
* General clean-up
* Writes new snapshots for es fieldname constants
* Small clean up for metrics based on PR review
* Makes agentName required for metrics charts
* Adds metrics transform test
* Uses casting to solve type problem with Hapi req.query
* Fixes functional test for required query param
* Simplify metric chart types
* Renames MetricsKeys to MetricSeriesKeys
* Rename transformDataToChart and a few other cleanups
* Fixes test and changes 0 B to just 0 in bytes unit y axes
* Improves byte format handling and adds test
* Removes unnecessary import
* More refactoring of the byte formatters and some extra tests to cover null and NaN cases
* Uses unmemoized version of byte formatter factory to prevent unnecessary function caching
* [APM] ECS changes
* Remove ambient types for idx
* Update `observer.listening`
* Added type safety to property config
* More ECS updates
* Juan fixes for ECS
* Adds available memory stats (in percent) to metrics server response
* Updates UI memory charts for new data
* Updates memory chart metrics to be usage (average and max), removes other unused metrics
* Review feedback addressed, small refactors
* Updates memory chart tests
* Service detail page refactor with TS conversions
* Adds error group list back to the service details page tabs
* Fixes after rebasing upstream master
* Adds integrations menu and flyouts, with no-transaction ML job creation and lookup
* WIP adds memory usage chart with fake data
* Adds error group distribution chart to metrics tab
* Metrics "memory" chart data flow from server to chart
* Server side query and transform set up for cpu charts
* CPU charts created
* Review feedback and watcher flyout
* Server tests added, broken tests fixed
* Review feedback
* Fixes up type problems
* Converts metric key paths to constants
* Fixes error group type issue after rebasing from master
* Makes transaction type filterable on transactions list tab
* Review feedback
* Chart formatting tweaks and fixes
* Fixes y-axis ticks for GB chart
* Restores machine learning annotations with some test fixes
* Continued styling and other review based changes
* More review fixes and cleanup
* Updated chartGroupProps -> hoverXHandlers
* Removes "type" column from transaction list table
* Re-centers around using urlParams
* Fixes panel item references in service integrations menu
* Serves default transaction type from /transactions route
* Reverts tooltip series ordering change
* Adds a clarification note about route config
* Makes it possible to request transaction chart data without specifying type
* Fixes empty series problem for memory chart
* Fixes tests
* Review feedback
* Fixes after rebase
* Replaces boolean casted array#find with array#some