Commit graph

110 commits

Author SHA1 Message Date
Peter
bc90140f8e
enable security plugin in basic (#35891)
enable security on file dataviz and import (ML plugin)

update unit tests

add api test coverage for security in basic

move audit logging to standard+ license level
2019-05-03 11:21:32 -07:00
Pete Harverson
3577c43d90
[ML] Edit queries in Metricbeat module to use event.dataset field (#35653) 2019-04-29 11:09:16 +01:00
Pete Harverson
43b9c7ad89
[ML] Adds Metricbeat System data recognizer module (#35580)
* [ML] Adds Metricbeat System data recognizer module

* [ML] Edit description of Metricbeat System module
2019-04-25 16:24:39 +01:00
Walter Rafelsberger
d316dca98a
[ML] Data Frame UI (#33427) 2019-04-23 16:46:52 +02:00
James Gowdy
c0edcbe9ab
[ML] Round value when using max model memory limit (#35223)
* [ML] Round value when using max model memory limit

* changing ceil to floor to avoid accidentally exceeding max mml
2019-04-17 16:00:35 +01:00
James Gowdy
3930c36898
ML] Fixes bug in module setup endpoint caused by PR 30935 (#34414)
* [ML] Fixes module setup endpoint

* tweaks endpoint to allow trailing slash
2019-04-03 12:42:59 +01:00
James Gowdy
2315ac1173
[ML] List data recognizer modules (#30935)
* [ML] [WIP] List data recognizer modules

* making module id optional

* sort modules

* removing list_module endpoint

* removing list_modules call

* listed modules include saveObjects

* adding tests
2019-04-02 17:23:56 +01:00
Walter Rafelsberger
2882d2853f
[ML] Fixes check to determine whether telemetry is enabled. (#33975) 2019-03-27 19:43:01 +01:00
Pete Harverson
0603f7a8db
[ML] Adds created_by field to auditbeat and APM data recognizer jobs (#33863) 2019-03-27 11:05:12 +00:00
Spencer
2e232c2e31
[@kbn/expect] "fork" expect.js into repo (#33761)
* [@kbn/expect] "fork" expect.js into repo

* [eslint] autofix references to expect.js

* [tslint] autofix all expect.js imports

* now that expect.js is in strict mode, avoid reassigning fn.length
2019-03-25 09:56:48 -07:00
Pete Harverson
5ff422d353
[ML] Skip invalid modules when data recognizer lists matches (#33703)
* [ML] Skip invalid modules when data recognizer lists matches

* [ML] Append error to data recognizer module load console logs
2019-03-22 16:45:01 +00:00
Pete Harverson
3581f1d54b
[ML] Fixes URL to get job stats when getting stats for all jobs (#33237) 2019-03-14 14:25:39 +00:00
Pete Harverson
a1a9511446
[ML] Edits data recognizer modules to use KQL in saved objects (#32766) 2019-03-08 16:35:20 +00:00
Melissa Alvarez
576c90ae8d
[ML] Add query bar to Anomaly Explorer for filtering of anomaly results for one or more influencers (#31763)
* wip: add autocomplete kueryFilterBar.update endpoints with query.

* Create indexPattern on job change. Value is autocompleted

* Mask unrelated swimlanes on filter apply

* Only show relevant viewBy swimlane

* reload viewBy swimlane when view By change is relevant to filter

* handle various query types when building filteredFields list

* remove deprecated code from old filter bar

* Show error callout when invalid filter syntax

* remove dependency on deprecated import var

* remove all left over apm dependencies

* persist filter on refresh

* Create initial filter bar placeholder dynamically

* add description text when filter active

* switch to relevant viewBy fieldname on filter

* recalculate placeholder on job change

* Create tests for all components

* View by dropdown only contains relevant fields for filter

* fix localization message noInfluencers component

* Move indexPattern to state and viewBy option filtering to utils

* remove unnecessary setState when setting viewBy for filter

* Use preloaded jobs from mlJobService to get influencers

* Only filter viewByOptions if valid field

* use kql and move to components dir

* move filter bar to public/components/
2019-03-05 15:07:30 -06:00
Walter Rafelsberger
46f7a350fe
[ML] Adds missing error handling to annotations request. (#32384)
- This adds more thorough error handling to retrieving annotations from the server to avoid breaking Anomaly Explorer when there's a problem retrieving annotations. The UI will silently fail and hide the annotations table if for whatever reasons annotations cannot be retrieved for the selected jobs (this could be permissions or setup related if e.g. the annotations feature index/aliases are not present). This is now the same behavior like in Single Metric Viewer. The browser console will still output an error message. This fixes an error scenario where Anomaly Explorer would fail to load if a user upgraded to 6.6 because the backend task wasn't run yet to create the annotation index/aliases.
- Disables annotations feature in Single Metric Viewer if annotations fail to load.
- Use componentDidUpdate and an update check instead of deprecated componentWillUpdate for updating the annotations table in jobs management.
2019-03-05 17:04:47 +01:00
Aleh Zasypkin
0835cd30ca
Introduce Elasticsearch service. (#28344) 2019-02-28 17:22:07 +02: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
James Gowdy
a28855a183
[ML] Fixing error when checking privileges for user with no ml_user role (#31429) 2019-02-18 18:37:14 +00:00
Pete Harverson
03b496e8cf
[ML] Fixes filter and icon for APM Data Recognizer module (#30820) 2019-02-13 17:24:43 +00:00
James Gowdy
2f4de7121c
[ML] Using eui icons in data recognizer modules (#30821) 2019-02-12 18:24:07 +00:00
Pete Harverson
0e5730c991
[ML] Removes non ECS apache, nginx and auditbeat data recognizer modules (#30537) 2019-02-11 12:21:21 +00:00
Walter Rafelsberger
e312daecfc
[ML] Fix Job Audit Messages filter. (#30490)
The way job audit messages were fetched didn't retrieve the expected results if there were deleted jobs with messages still present for these jobs.
This fix allows to specify a list of job IDs to filter the audit messages on. For the jobs list UI, the currently existing job IDs will be passed on to ignore messages from deleted jobs.
2019-02-08 15:13:17 +01:00
Pete Harverson
aed16cf27b
[ML] Fixes bucket spans and detector descriptions in ECS auditbeat modules (#30362) 2019-02-07 12:50:24 +00:00
Walter Rafelsberger
3d4dc093f3
[ML] Adds jest tests for annotation_service. (#30193)
This adds tests to `server/models/annotation_service`. The tests include a check if the `.key` attribute of an annotation is properly removed from an annotation before indexing it.
2019-02-06 14:43:04 +01:00
Walter Rafelsberger
0942332b0a
[ML] Remove key attribute from annotation before indexing. (#30183)
The UI adds a `key` attribute to annotation objects to store the letter used for labels in the chart and tables. When editing and saving an annotation that `key` could end up being saved to the annotations index. This isn't necesseary since the `key` attribute is just a dynamic label used within the UI. This fixes it by deleting an eventual `key` attribute from the annotations object before saving it to the index.
2019-02-06 11:23:29 +01:00
Sophie Chang
9ebddcc8a4 [ML] Update auditbeat modules for ECS (#29934)
* [ML] Initial commit for auditbeat hosts ECS

Rename fields for ECS
Rework dashboards due to bwc

* [ML] Further auditbeat tidy up and consistency changes

Custom urls should link to saved search, not discover
Ensure savedSearchId is used for visualizations
Ensure filter terms are consistent

TODO Decide if we should rename to auditd module
TODO Fix for new saved object format

* [ML] Refinements for auditbeat host module

Remove duplicated title from visState
Shrink panel heights in row 1

* [ML] Refinements to auditbeat module

Update module name from auditd to auditbeat
Add useMargins true for dashboards
Add filter to custom url for
   exists auditd.data.syscall
   not exists container.runtime
   event.module: auditd

* [ML] Initial commit for auditbeat_process_docker_ecs

Update for ECS using
  container.name (instead of container.id)
  container.runtime: docker
  process.executable
  event.module: auditd
  auditd.data.syscall exists

TODOs
Use auditd.message_type: syscall (instead of auditd.data.syscall)
Possibly combine with auditbeat hosts saved objects (depending on host.name being shared)
Possibly combine to single dashboard
Test against live auditbeat data collection
2019-02-05 19:06:25 +00:00
Walter Rafelsberger
fd8434a823
[ML] Fixes annotations integrity check. (#30102)
With security enabled, the internal user wouldn't have enough permissions to run the integrity check. This changes the check to use the currently logged in user. Also fixes some typos in messages.
2019-02-05 19:45:14 +01:00
Pete Harverson
d0f3b2a068
[ML] Fix filter params in HTTP Access job custom URLs (#30066) 2019-02-05 15:41:55 +00:00
James Gowdy
2850fd6735
[ML] Job deleting optimisations (#29848)
* [ML] Job deleting optimisations

* fixing force=true

* updating deleting jobs check
2019-02-05 12:29:01 +00:00
James Gowdy
fda6efed1a
[ML] Adding index migration warnings (#28938)
* [ML] Adding index migration warnings

* small refactor

* correctlng comment

* adding upgrade service to manage upgradeInProgress state

* removing missing function
2019-02-05 12:27:32 +00:00
Walter Rafelsberger
f2e3aff333
[ML] Adds an integrity check to creating, updating and deleting annotations. (#29969)
Adds an integrity check to make sure the required index and aliases are present before creating, updating or deleting annotations.
2019-02-05 10:14:45 +01:00
Pete Harverson
6afcc28c3b
[ML] Edits to labels in the Apache and Nginx ECS data recognizer modules (#29935) 2019-02-04 17:19:25 +00:00
Walter Rafelsberger
7966b2ff78
[ML] adds telemetry to ML (#29121)
Adds telemetry to collect the amount of indices created using File Data Visualizer.
2019-02-04 13:14:25 +01:00
Pete Harverson
0c86822e40
[ML] Automatically migrate saved objects created by data recognizer (#29736)
* [ML] Automatically migrate saved objects created by data recognizer

* [ML] Remove TODO from saved object import step
2019-01-31 19:54:22 +00:00
Sophie Chang
413d37d5ed [ML] Update http access modules for ECS (#29383)
* [ML] Initial commit for apache ecs module

* [ML] Update apache2 module for ECS

Rename following fields
event.module:apache
event.dataset:access
source.address
url.original
http.response.status_code
source.geo.location

Rationalise to only use one set of kibana saved objects for all http web access logs
Rename files from apache
Combined URL explorer into Count explorer dashboard as there was a lot of duplication
Add filter to custom url
Rename custom urls to Investigate Source IP and Status Code
Add chart to show overall event rate split by event.module - can tell if multiple datasets are included
Increase limit for top source ips from 5 to 50
Add created_by to custom setting for telemetry
Rename jobs and saved objects to include ecs tag

Tested side by side against v6 jobs

* [ML] Rename apache files from hyphen to underscores

* [ML] Further apache renames

Also change custom URLs to lower case to match "View series"
Change created_by to ml-module-apache-access

* [ML] Initial commit of nginx ml module

* [ML] Rename dashboard to generic explorer

* [ML] Further refinement for apache

Rename http_status_code to status_code_rate
Update custom url to use filters instead of lucene query bar

* [ML] Convert apache module to nginx

Copy files, keeping nginx logo
Multiple renames to nginx

* [ML] Make chart legend visible by default
2019-01-31 11:39:18 +00:00
Mike Côté
1b0f595f01
Add new "references" attribute to saved objects for relationships (#28199)
* Add new references attribute to saved objects

* Add dual support for dashboard export API

* Use new relationships API supporting legacy relationships extraction

* Code cleanup

* Fix style and CI error

* Add missing spaces test for findRelationships

* Convert collect_references_deep to typescript

* Add missing trailing commas

* Fix broken test by making saved object API consistently return references

* Fix broken api integration tests

* Add comment about the two TS types for saved object

* Only return title from the attributes returned in findRelationships

* Fix broken test

* Add missing security tests

* Drop filterTypes support

* Implement references to search, dashboard, visualization, graph

* Add index pattern migration to dashboards

* Add references mapping to dashboard mppings.json

* Remove findRelationships from repository and into it's own function / file

* Apply PR feedback pt1

* Fix some failing tests

* Remove error throwing in migrations

* Add references to edit saved object screen

* Pass types to findRelationships

* [ftr] restore snapshots from master, rely on migrations to add references

* [security] remove `find_relationships` action

* remove data set modifications

* [security/savedObjectsClient] remove _getAuthorizedTypes method

* fix security & spaces tests to consider references and migrationVersion

* Add space id prefixes to es_archiver/saved_objects/spaces/data.json

* Rename referenced attributes to have a suffix of RefName

* Fix length check in scenario references doesn't exist

* Add test for inject references to not be called when references array is empty or missing

* some code cleanup

* Make migrations run on machine learning data files, fix rollup filterPath for savedSearchRefName

* fix broken test

* Fix collector.js to include references in elasticsearch response

* code cleanup pt2

* add some more tests

* fix broken tests

* updated documentation on referencedBy option for saved object client find function

* Move visualization migrations into kibana plugin

* Update docs with better description on references

* Apply PR feedback

* Fix merge

* fix tests I broke adressing PR feedback

* PR feedback pt2
2019-01-30 15:53:03 -05:00
James Gowdy
ec607e26b9
[ML] Better handling of recognizer module manifest parsing errors (#29322) 2019-01-28 10:32:15 +00:00
James Gowdy
45b8ff99f0
[ML] Adding ability to override number of sample lines in File Data Visualizer (#29214)
* [ML] Adding ability to override number of sample lines in file data viz

* tiny tweak

* updating tests
2019-01-24 10:03:09 +00:00
Spencer
c052613962
[dashboard+gis] remove dark mode options (#29017)
* [dashboard+gis] remove dark mode options

* [reporting/extract] restore fixtures

* remove mentions of old `.theme-dark` class

* import panel styles from panel/_index.scss
2019-01-23 14:29:35 -08:00
James Gowdy
c91ec0d1ef
[ML] Adding privilege checks to File Data Visualizer (#29109)
* [ML] Adding privilege checks to File Data Visualizer

* fixing typo in comment
2019-01-22 17:07:53 +00:00
Pete Harverson
ed9a599b0d
[ML] Removes use of types from ES index and search calls (#28987) 2019-01-18 12:32:31 +00:00
Melissa Alvarez
7f8203715d
[ML] Add support to Data Visualizer for index patterns without a time field (#28511)
* Prevent docCount fetch and remove sidebar if no timeField set.

* Don't show metrics section if no metrics cards

* Add parens to conditional statement as per styleguide

* Don't create docCount card if not timeseries based
2019-01-14 12:31:46 -05:00
pavel06081991
19b84f0bc2
[ML] translate job validation messages (#28235)
[ML] translate job validation messages
2019-01-14 14:04:39 +03:00
pavel06081991
09ea8e35a3
[ML] translate models (#27888)
[ML] translate models
2019-01-14 12:24:30 +03:00
Nox911
2dfe4136b9 Translate ml -> server -> lib (#27974) 2019-01-08 11:13:17 +03:00
Pete Harverson
ef5e7a596e
[ML] Update REST endpoint calls to remove _xpack (#28069) 2019-01-04 16:48:05 +00:00
James Gowdy
0232b9b69e
[ML] Fix for audit message search size being 0 when jobs size is 0 (#27955) 2019-01-03 11:06:50 +00:00
Dimitris Athanasiou
b2f44622fe
[ML] Remove use of types in datafeeds (#27572)
This commit removes the use of types in datafeeds
and a few more places where it was possible.

Relates #26968
2019-01-02 09:34:38 +02:00
Walter Rafelsberger
7971b15cec
[ML] Fix audit messages. (#27575) 2018-12-21 10:59:52 +01:00
Pete Harverson
9b4a5a07d8
[ML] Handle removal of backend ml.enabled node attribute (#27604) 2018-12-21 09:13:30 +00:00