Commit graph

22916 commits

Author SHA1 Message Date
Aleh Zasypkin
0835cd30ca
Introduce Elasticsearch service. (#28344) 2019-02-28 17:22:07 +02:00
Aleh Zasypkin
b8c9d0afa0
Get rid of Handlebars support in i18n tools. (#32190) 2019-02-28 17:16:59 +02:00
Mikhail Shustov
5fc7addac5
Update jest to v24 (#31825)
* udpate jest, jest-cli, @types/jest to v24

* fix type error in kibana-i18n package

* return serivce explicitly to fix typings

* add explicit never

* suppress typings errors

* update jest versions in x-pack

* make tests in x-pack more robust and fix incompatibility

* suppress CallCluster mock typings

Mock interface doesn't match CallCluster. Requires
additional work

* x-pack. resolve other typing conflicts

* remove unused types/jest

* fix snapshots

* restore mocks after jest.spyOn

* remove outdated definitions for jest

* cleanup x-pack package.json and update @types/jest

* fix tests merged from master

* updated yarn.lock and log errors for scripts/type_check

* This commit fixes error in TS, which failed on parsing the file.

* suppress type errors from master

* jest-cli is devDep
2019-02-28 13:26:16 +01:00
Pete Harverson
f2acacb237
[ML] Fix formatting of values for time of day or week anomalies (#32134) 2019-02-28 09:32:32 +00:00
alakahakai
88c2b59c64
Add Kibana Home Tutorial for Filebeat zeek module (#31774)
* Add Kibana Home Tutorial for Filebeat zeek module
2019-02-27 21:39:21 -08:00
Joe Fleming
acd762d8ae Fix: don't initialize workpad from WorkpadApp (#32163)
Closes https://github.com/elastic/kibana/issues/32161

All the elements are loaded in the router, so loading the from the component just duplicates the work.

This is actually left-over code from before we had a router. Apparently I missed this lifecycle when adding the router, so it's been an issue in Canvas for quite some time now.

### Stats

Workpad | Previous load time | PR load time
-- | -- | -- 
Elastic{ON} Tour Dallas: Canvas v3 | 10 seconds | 7 seconds
Kibana Canvas - Your data, your way. | 32 seconds | 18 seconds

*Time from when the Canvas loading indicator goes away and the workpad app renders to when the loading indicator stops spinning*
2019-02-27 22:00:11 -06:00
spalger
7e1d565587 update kbn-pm build 2019-02-27 19:13:13 -08:00
Spencer
da38c346dd
[server/logging/tests] use --oss to load kibana faster and avoid timeouts (#32162) 2019-02-27 15:32:22 -08:00
Caroline Horn
75384404e8
[Bugfix] Remove bootstrap classes from Notifier (#31956) 2019-02-27 15:43:07 -05:00
nicknak
827e652351
Removes sinon from saved objects unit tests. (#32045)
* Removes sinon from saved objects unit tests.

* Uses mockResolvedValue for return values as promises.
2019-02-27 15:07:26 -05:00
Robert Monfera
0530dfb880
Usability: larger minimum element size (#32106) 2019-02-27 20:03:08 +01:00
Lukas Olson
d0fb7b8822
Move getIndexPattern service to visualize (#32060) 2019-02-27 11:51:07 -07:00
Alison Goryachev
6e77a7cb03
fix client validation for rollup index name (#32067)
* fix client validation for rollup index name

* remove wrapper object in constants file

* move support for "*" illegal character to common constants file
2019-02-27 13:08:37 -05:00
Aleh Zasypkin
2f62e6f1a5
Upgrade @babel/* dependencies. (#32031)
Co-authored-by: Tiago Costa <tiagoffcc@hotmail.com>
2019-02-27 19:27:40 +02:00
Chris Cowan
aeb5f7ba7a
Fixes #32022 - Fix table to display name instead of ID (#32051) 2019-02-27 07:38:35 -07:00
Joe Reuter
295de1ed7d
Fix pushed down chart on multi line horizontal legends (#31466) 2019-02-27 15:30:45 +01:00
Walter Rafelsberger
db700ffcef
[ML] Fixes restoring table interval selection from appState. (#32056)
Fixes a regression introduced in #31692. The table interval selection wasn't properly restored from `AppState` because of a mismatch in the expected object structure.
2019-02-27 12:26:51 +01:00
Tim Roes
9d77205191
Cleanup unused code (#32018) 2019-02-27 10:18:35 +01:00
Joe Fleming
2028fdf56e fix: bump max payload size up to 25MB (#31974)
default of 1MB is very easy to hit, so it's not hard to make Canvas fail
2019-02-27 09:33:57 +01:00
Jonathan Budzenski
1782f376a8 [build] final path length check for windows (#32076)
Windows has a maximum path length of 260 characters.  We're approaching this limit so this adds a build task to check for any path > 200 characters.

200 + C:/ + path + kibana = total.  Rough estimation.
2019-02-26 17:21:40 -08:00
Oliver Gupte
5949b004b0
[APM] Trunctating DB statements in span flyout (#31674)
* [APM] closes #18114 by trunctating db statements in span flyout by default but allowing toggle between preview and full content.

* Made component more tolerant of changes in props/children by checking for clipping on each update

* [APM] simplify component by enforcing the prop previewHeight is a number and use it for calculation
2019-02-26 16:34:32 -08:00
Tim Sullivan
87bd8913bd
[Reporting] Fix error handling in process request failed (#31861)
* [Reporting] Fix error handling in process request failed

- Callback param is a Puppeteer `Request` object, not Error

* unrelated prettier
2019-02-26 16:48:35 -07:00
Matt Bargar
f0f9dd025c
Update capitalization of KQL full name (#31631) 2019-02-26 16:44:58 -06:00
Eli Perelman
a639c86f93
Ensure legacy service names in core/server and core/public are consistent (#31732) 2019-02-26 14:09:06 -06:00
Joel Griffith
db2e92012b
Fixes data points on maps not showing up in reports (#31949)
* Fixes data points on maps not showing up in reports
2019-02-26 10:30:25 -08:00
Justin Kambic
c067a779b0
Switch uptime internationalization from i18n provider to context. (#31601) 2019-02-26 12:40:26 -05:00
Chris Cowan
32dbb82bf8
[Infra UI] Change waffle map node to button for accessibility (#31764)
* Fixes #28158 - Change waffle map node to button for accessibility

* intl-izing the aria-labels; changing size to eui
2019-02-26 10:09:44 -07:00
James Gowdy
f89faec278
[ML] Changing job wizard query to use match_all (#32008)
* [ML] Using job wizard query to use match_all

* adding query back in for data visualizer

* fixing typo
2019-02-26 16:51:17 +00:00
Jen Huang
50c7da3360
Fix common license checker issues (#31339)
* Fix hardcoded plugin name and license modes in common license checker

* Fix licensePreRoutingFactory scope issues

* PR feedback adjustments

* Use minimum license string instead of array of valid license
* Pass plugin name instead of ID for UX
* Return license status instead of `showLinks` and other flags
* Adjust factory closure for readability

* Fix test

* Additional PR feedback:

* Move license status constants to `/common`
* Internationalize plugin names that are passed to check license, and its error messages
* Remove `isAvailable` flag, change pre-routing logic to use `LICENSE_STATUS.VALID` instead
* Change constant `INACTIVE` to `EXPIRED`
* Convert check license test from mocha to jest

* Fix test
2019-02-26 08:29:47 -08:00
Søren Louv-Jansen
c68cc7890a
[APM] Improve license check (#31923)
* [APM] Improve license check

* Remove unneeded strings

* Add translations

* Use React.FunctionComponent

* Update copy
2019-02-26 17:09:34 +01:00
Jonathan Budzenski
e1339aa57c
[es] Fix ipv6 addresses used with angular connector (#29891) 2019-02-26 10:05:15 -06:00
Jonathan Budzenski
25e7b077c3
remove aws-sdk (#31002)
* rm aws-sdk

* remove references

* readd gitignore

* rm dlls/

* gitignore
2019-02-26 10:01:11 -06:00
Daniil Suleiman
7559941e26
[TSVB] Add option to stack globally or within series (#31417)
* Add a check for the same series metric

* Replace logic to the nodejs side

* Add 'Stack within series' option
2019-02-26 18:23:31 +03:00
Bill McConaghy
a382b49744
fixing issues with maximum documents and maximum size being set (#31998)
* fixing issues with maximum documents and maximum size being set

* removing defaults from ES policy load and removing unneeded propTypes

* fixing react warnings about controlled -> uncontrolled

* fixing tests

* more fixes for react controlled -> uncontrolled errors

* better fix for react warnings through empty default phases

* removing unused translation

* removing unnecessary async/awaits in onChange handlers
2019-02-26 10:23:11 -05:00
Alexey Antonov
9907f48e3b
Rollup support for TSVB (#28762)
* Added a feature of rollup search on the UI side

Signed-off-by: Alexey Antonov <alexwizp@gmail.com>

* Rollup Feature - initial commit

* Revert "Added a feature of rollup search on the UI side"

This reverts commit 9568b0970b16f5102f50b748bb4d691a8612c2c2.

# Conflicts:
#	src/legacy/core_plugins/metrics/public/components/index_pattern.js

* Remove the 'label' property from the search strategies

* Changed search by strategy from the last

* add single search request

* rollup_search_strategy add base implementation of isViable method

* rollup_search_strategy add base implementation of isViable method -fix

* Changed requests due to search request type

* refactoring of import Base classes / remove '../../../../../../

* remove extra await

* rollup_search_strategy. Refactoring of isRollupJobExists method

* remove question

* Add support of annotations and table data

* skeleton for adding Search Strategy restrictions

* Add rollup search capabilities

* apply search strategy for annotations request

* set fields capabilities for rollup strategy

* add timezone, interval into SearchCapabilities

* Add fields from capabilities

* add timezone, interval into SearchCapabilities

* fix default timezone

* Merging of two Rollup Jobs was removed

* move getFieldsForWildcard to searchStrategy

* Fix TSVB search requests should have a timeout

# Conflicts:
#	src/legacy/core_plugins/metrics/server/lib/vis_data/get_annotations.js
#	src/legacy/core_plugins/metrics/server/lib/vis_data/series/get_request_params.js

* Add unit test

* apply getEsShardTimeout for annorations/get_request_params,  series/get_request_params

* rename metrics -> tsvb

* search_strategies_register refactoring: move 'add' method from class

* Add merge rollup capabilities with fields

* Add merge rollup capabilities with fields - small fixes

* Add support of 'Everything' aggregation for Rollup Search

* Return back metrics plugin

* remove 'metrics' from the X-pack\rollup require

* Fix test cases

* fix broken test: fail: "apis InfraOps GraphQL Endpoints metrics should basically work"

* rollup search - split by terms is not working

* Add count metric

* /get_bucket_size.js. Add support of 'auto' interval, Add support of gte intervals  e.g.:  >=1m

* fix build_request_body test

* [Rollup] [Phase 1] Error handling - rollup search errors should be more user friendly

* [Rollup] [Phase 1] Table View - research the query to ES - sorting is not wokring

* Merge #26006 into rollup

# Conflicts:
#	src/legacy/core_plugins/metrics/server/lib/vis_data/annorations/build_request_body.js
#	src/legacy/core_plugins/metrics/server/lib/vis_data/get_annotations.js
#	src/legacy/core_plugins/metrics/server/lib/vis_data/get_series_data.js
#	src/legacy/core_plugins/metrics/server/lib/vis_data/get_table_data.js
#	src/legacy/core_plugins/metrics/server/lib/vis_data/request_processors/annotations/query.js
#	src/legacy/core_plugins/metrics/server/lib/vis_data/series/__tests__/build_request_body.js
#	src/legacy/core_plugins/metrics/server/lib/vis_data/series/build_request_body.js
#	src/legacy/core_plugins/metrics/server/lib/vis_data/series/get_request_params.js

* Add table view support

* fix broken build

* fix broken build

* [Rollup] [Phase 1] - write new tests  (rollup_search_request, rollup_search_strategy)

* [Rollup] [Phase 1] - write tests for rollup_search_capabilities

* Add test on default_search_capabilities, abstract_search_strategy, search_strategies_register

* Add test cases for search_requests folder

* [Rollup] [Phase 1] - write tests for rollup_search_strategy

* FIx broken build

* remove todo

* fix calculation of interval value for rollup search

* add unit tests

* Remove default exports

* fix PR comments

* fix calendar intervals
2019-02-26 18:08:57 +03:00
Tim Roes
416b41520b
Improve accessibility of sample data screen (#32004)
* Add better context to add/remove buttons for sample data

* Fix broken i18n id
2019-02-26 16:03:47 +01:00
Nathan Reese
946b7823f4
fix flaky input controls functional test (#31970) 2019-02-26 06:04:51 -07:00
Alison Goryachev
8fc9d90744
fix Platinum features link in license management (#31945)
* fix Platinum features link in license management

* move external license links to constants file
2019-02-26 08:01:22 -05:00
Ahmad Bamieh
c60d4ff675
remove 'Contract' from naming (#31888) 2019-02-26 14:21:11 +02:00
Alexey Antonov
9f4426b6b9
TSVB: Option to open links in new tab (#31906) 2019-02-26 14:53:29 +03:00
Thomas Neirynck
698e46dabc
[Maps] Show joined term metrics in tooltip (#31826) 2019-02-26 03:31:14 -05:00
Peter Pisljar
6eb1503af9
Fix/vislib click error (#31896) 2019-02-25 22:57:15 -08:00
Sébastien Loix
baf46c9079
[Rollup] Unit test for detail panel (#31690) 2019-02-26 06:35:10 +01:00
Thomas Neirynck
79a26aef36
Ensure any existing layers get cleared when previewing a new one (#31973) 2019-02-25 23:05:15 -05:00
Catherine Liu
a037874e4a
[Canvas] Fixes filter clearing on undo/redo (#31859)
* Added check to reset filters in 'setExpression'

* Removed filter reset from filter renderers' onDestroy handler

* Cleaned up setExpression

* Added TODO
2019-02-25 16:26:31 -07:00
Jonathan Budzenski
01c8627622
[es] scripts.inline -> scripts.source (#30457) 2019-02-25 16:34:47 -06:00
Chris Cowan
9fa9e083de
[Infra UI] Auto focus search bar when page mounts for accessibility (#31758)
* Fixes #28154 - Auto focus search bar when page mounts

* Adding check
2019-02-25 15:22:59 -07:00
Chris Cowan
99c11c50fb
Fixes #28155 - Changed EuiKeyPadMenuItem to EuiKeyPadMenuItemButton to support accessibility (#31860) 2019-02-25 15:21:26 -07:00
Clint Andrew Hall
dd633a37e4
Kill unnecessary re-renders in ElementWrapper (#31734)
## Summary (fixes #29700)

This is a small change that creates a huge impact on UI performance in Canvas.

As the mouse moves over a workpad, several parts of the state of the workpad, (the element hovered, the element moved if one is being held, etc) change.  These changes in state were causing every active Element to re-render in React.

In short, you may hover Element 10, but Elements 1-9 re-render because the state of the entire workpad changes.  This would happen even if the mouse were moved a single pixel.

By short-circuiting that re-render with a fast comparison, we prevent any Elements that are not affected from re-rendering... freeing up the main thread.  This performance impact intensifies as one adds Elements to the workpad.

Here is a performance shapshot before this change was made.  Notice the React tree reconciliation encompasses the entire 280ms.  This reflects a single state change flowing through all of the Elements on the workpad, (each orange "stalactite" descending downwards is an Element):

![screen shot 2019-02-21 at 11 49 48 am](https://user-images.githubusercontent.com/297604/53197762-76960380-35e0-11e9-9069-a30df5fd4b2f.png)

Here is a snapshot after.  That reconciliation now completes in 50ms or less:

![screen shot 2019-02-21 at 11 49 30 am](https://user-images.githubusercontent.com/297604/53197845-afce7380-35e0-11e9-8991-572462b441eb.png)

*This is not the end of this problem.*  There are many other opportunities to prevent re-rendering, and we need to focus on killing the need for the comparison in the first place.  @monfera and @w33ble will be instrumental in making these changes in the future... for now, though, this gets the job done.

### Checklist

Use ~~strikethroughs~~ to remove checklist items you don't feel are applicable to this PR.

- [x] This was checked for cross-browser compatibility, [including a check against IE11](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#cross-browser-compatibility)
- [ ] ~~Any text added follows [EUI's writing guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses sentence case text and includes [i18n support](https://github.com/elastic/kibana/blob/master/packages/kbn-i18n/README.md)~~
- [ ] ~~[Documentation](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#writing-documentation) was added for features that require explanation or tutorials~~
- [ ] ~~[Unit or functional tests](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#cross-browser-compatibility) were updated or added to match the most common scenarios~~
- [ ] ~~This was checked for [keyboard-only and screenreader accessibility](https://developer.mozilla.org/en-US/docs/Learn/Tools_and_testing/Cross_browser_testing/Accessibility#Accessibility_testing_checklist)~~

### For maintainers

- [x] This was checked for breaking API changes and was [labeled appropriately](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#release-notes-process)
- [ ] ~~This includes a feature addition or change that requires a release note and was [labeled appropriately](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#release-notes-process)~~
2019-02-25 15:58:43 -06:00
Nathan Reese
91477151e4
Add refreshConfig to embeddable container state (#31611)
* Add refreshConfig to embeddable container state

* TS fun
2019-02-25 14:18:05 -07:00