Skip to content

Commit

Permalink
Merge branch 'master' of github.com:elastic/kibana into securiy-solut…
Browse files Browse the repository at this point in the history
…ion-search-strategy
  • Loading branch information
XavierM committed Aug 22, 2020
2 parents 1a38f1e + f7cfcea commit 63cde69
Show file tree
Hide file tree
Showing 569 changed files with 42,455 additions and 44,775 deletions.
2 changes: 1 addition & 1 deletion .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ target
# package overrides
/packages/eslint-config-kibana
/packages/kbn-interpreter/src/common/lib/grammar.js
/packages/kbn-plugin-generator/sao_template/template
/packages/kbn-plugin-generator/template
/packages/kbn-pm/dist
/packages/kbn-test/src/functional_test_runner/__tests__/fixtures/
/packages/kbn-test/src/functional_test_runner/lib/config/__tests__/fixtures/
Expand Down
1 change: 0 additions & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -604,7 +604,6 @@ module.exports = {
{
files: [
'.eslintrc.js',
'packages/kbn-plugin-generator/**/*.js',
'packages/kbn-eslint-import-resolver-kibana/**/*.js',
'packages/kbn-eslint-plugin-eslint/**/*',
'x-pack/gulpfile.js',
Expand Down
9 changes: 0 additions & 9 deletions .telemetryrc.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,4 @@
[
{
"output": "src/plugins/telemetry/schema/legacy_oss_plugins.json",
"root": "src/legacy/core_plugins/",
"exclude": [
"src/legacy/core_plugins/testbed",
"src/legacy/core_plugins/elasticsearch",
"src/legacy/core_plugins/tests_bundle"
]
},
{
"output": "src/plugins/telemetry/schema/oss_plugins.json",
"root": "src/plugins/",
Expand Down
4 changes: 2 additions & 2 deletions docs/developer/architecture/code-exploration.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -426,9 +426,9 @@ You can test that the Frozen badge, phase filtering, and lifecycle information i
Index Management by running this series of requests in Console:
- {kib-repo}blob/{branch}/x-pack/plugins/index_management[indexManagement]
- {kib-repo}blob/{branch}/x-pack/plugins/index_management/README.md[indexManagement]
WARNING: Missing README.
Create a data stream using Console and you'll be able to view it in the UI:
- {kib-repo}blob/{branch}/x-pack/plugins/infra/README.md[infra]
Expand Down
2 changes: 1 addition & 1 deletion docs/developer/contributing/development-tests.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ root)
|`yarn test:jest_integration -t regexp [test path]`

|Mocha
|`src/**/__tests__/**/*.js` `!src/**/public/__tests__/*.js``packages/kbn-datemath/test/**/*.js` `packages/kbn-dev-utils/src/**/__tests__/**/*.js` `tasks/**/__tests__/**/*.js`
|`src/**/__tests__/**/*.js` `!src/**/public/__tests__/*.js` `packages/kbn-dev-utils/src/**/__tests__/**/*.js` `tasks/**/__tests__/**/*.js`
|`node scripts/mocha --grep=regexp [test path]`

|Functional
Expand Down
2 changes: 2 additions & 0 deletions docs/development/core/server/kibana-plugin-core-server.md
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@ The plugin integrates with the core system via lifecycle events: `setup`<!-- -->
| [SavedObjectMigrationMap](./kibana-plugin-core-server.savedobjectmigrationmap.md) | A map of [migration functions](./kibana-plugin-core-server.savedobjectmigrationfn.md) to be used for a given type. The map's keys must be valid semver versions.<!-- -->For a given document, only migrations with a higher version number than that of the document will be applied. Migrations are executed in order, starting from the lowest version and ending with the highest one. |
| [SavedObjectReference](./kibana-plugin-core-server.savedobjectreference.md) | A reference to another saved object. |
| [SavedObjectsAddToNamespacesOptions](./kibana-plugin-core-server.savedobjectsaddtonamespacesoptions.md) | |
| [SavedObjectsAddToNamespacesResponse](./kibana-plugin-core-server.savedobjectsaddtonamespacesresponse.md) | |
| [SavedObjectsBaseOptions](./kibana-plugin-core-server.savedobjectsbaseoptions.md) | |
| [SavedObjectsBulkCreateObject](./kibana-plugin-core-server.savedobjectsbulkcreateobject.md) | |
| [SavedObjectsBulkGetObject](./kibana-plugin-core-server.savedobjectsbulkgetobject.md) | |
Expand All @@ -167,6 +168,7 @@ The plugin integrates with the core system via lifecycle events: `setup`<!-- -->
| [SavedObjectsCreateOptions](./kibana-plugin-core-server.savedobjectscreateoptions.md) | |
| [SavedObjectsDeleteByNamespaceOptions](./kibana-plugin-core-server.savedobjectsdeletebynamespaceoptions.md) | |
| [SavedObjectsDeleteFromNamespacesOptions](./kibana-plugin-core-server.savedobjectsdeletefromnamespacesoptions.md) | |
| [SavedObjectsDeleteFromNamespacesResponse](./kibana-plugin-core-server.savedobjectsdeletefromnamespacesresponse.md) | |
| [SavedObjectsDeleteOptions](./kibana-plugin-core-server.savedobjectsdeleteoptions.md) | |
| [SavedObjectsExportOptions](./kibana-plugin-core-server.savedobjectsexportoptions.md) | Options controlling the export operation. |
| [SavedObjectsExportResultDetails](./kibana-plugin-core-server.savedobjectsexportresultdetails.md) | Structure of the export result details entry |
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [kibana-plugin-core-server](./kibana-plugin-core-server.md) &gt; [SavedObjectsAddToNamespacesResponse](./kibana-plugin-core-server.savedobjectsaddtonamespacesresponse.md)

## SavedObjectsAddToNamespacesResponse interface


<b>Signature:</b>

```typescript
export interface SavedObjectsAddToNamespacesResponse
```

## Properties

| Property | Type | Description |
| --- | --- | --- |
| [namespaces](./kibana-plugin-core-server.savedobjectsaddtonamespacesresponse.namespaces.md) | <code>string[]</code> | The namespaces the object exists in after this operation is complete. |

Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [kibana-plugin-core-server](./kibana-plugin-core-server.md) &gt; [SavedObjectsAddToNamespacesResponse](./kibana-plugin-core-server.savedobjectsaddtonamespacesresponse.md) &gt; [namespaces](./kibana-plugin-core-server.savedobjectsaddtonamespacesresponse.namespaces.md)

## SavedObjectsAddToNamespacesResponse.namespaces property

The namespaces the object exists in after this operation is complete.

<b>Signature:</b>

```typescript
namespaces: string[];
```
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Adds namespaces to a SavedObject
<b>Signature:</b>

```typescript
addToNamespaces(type: string, id: string, namespaces: string[], options?: SavedObjectsAddToNamespacesOptions): Promise<{}>;
addToNamespaces(type: string, id: string, namespaces: string[], options?: SavedObjectsAddToNamespacesOptions): Promise<SavedObjectsAddToNamespacesResponse>;
```

## Parameters
Expand All @@ -23,5 +23,5 @@ addToNamespaces(type: string, id: string, namespaces: string[], options?: SavedO

<b>Returns:</b>

`Promise<{}>`
`Promise<SavedObjectsAddToNamespacesResponse>`

Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Removes namespaces from a SavedObject
<b>Signature:</b>

```typescript
deleteFromNamespaces(type: string, id: string, namespaces: string[], options?: SavedObjectsDeleteFromNamespacesOptions): Promise<{}>;
deleteFromNamespaces(type: string, id: string, namespaces: string[], options?: SavedObjectsDeleteFromNamespacesOptions): Promise<SavedObjectsDeleteFromNamespacesResponse>;
```

## Parameters
Expand All @@ -23,5 +23,5 @@ deleteFromNamespaces(type: string, id: string, namespaces: string[], options?: S

<b>Returns:</b>

`Promise<{}>`
`Promise<SavedObjectsDeleteFromNamespacesResponse>`

Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [kibana-plugin-core-server](./kibana-plugin-core-server.md) &gt; [SavedObjectsDeleteFromNamespacesResponse](./kibana-plugin-core-server.savedobjectsdeletefromnamespacesresponse.md)

## SavedObjectsDeleteFromNamespacesResponse interface


<b>Signature:</b>

```typescript
export interface SavedObjectsDeleteFromNamespacesResponse
```

## Properties

| Property | Type | Description |
| --- | --- | --- |
| [namespaces](./kibana-plugin-core-server.savedobjectsdeletefromnamespacesresponse.namespaces.md) | <code>string[]</code> | The namespaces the object exists in after this operation is complete. An empty array indicates the object was deleted. |

Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [kibana-plugin-core-server](./kibana-plugin-core-server.md) &gt; [SavedObjectsDeleteFromNamespacesResponse](./kibana-plugin-core-server.savedobjectsdeletefromnamespacesresponse.md) &gt; [namespaces](./kibana-plugin-core-server.savedobjectsdeletefromnamespacesresponse.namespaces.md)

## SavedObjectsDeleteFromNamespacesResponse.namespaces property

The namespaces the object exists in after this operation is complete. An empty array indicates the object was deleted.

<b>Signature:</b>

```typescript
namespaces: string[];
```
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Adds one or more namespaces to a given multi-namespace saved object. This method
<b>Signature:</b>

```typescript
addToNamespaces(type: string, id: string, namespaces: string[], options?: SavedObjectsAddToNamespacesOptions): Promise<{}>;
addToNamespaces(type: string, id: string, namespaces: string[], options?: SavedObjectsAddToNamespacesOptions): Promise<SavedObjectsAddToNamespacesResponse>;
```

## Parameters
Expand All @@ -23,5 +23,5 @@ addToNamespaces(type: string, id: string, namespaces: string[], options?: SavedO

<b>Returns:</b>

`Promise<{}>`
`Promise<SavedObjectsAddToNamespacesResponse>`

Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Removes one or more namespaces from a given multi-namespace saved object. If no
<b>Signature:</b>

```typescript
deleteFromNamespaces(type: string, id: string, namespaces: string[], options?: SavedObjectsDeleteFromNamespacesOptions): Promise<{}>;
deleteFromNamespaces(type: string, id: string, namespaces: string[], options?: SavedObjectsDeleteFromNamespacesOptions): Promise<SavedObjectsDeleteFromNamespacesResponse>;
```

## Parameters
Expand All @@ -23,5 +23,5 @@ deleteFromNamespaces(type: string, id: string, namespaces: string[], options?: S

<b>Returns:</b>

`Promise<{}>`
`Promise<SavedObjectsDeleteFromNamespacesResponse>`

Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@
<b>Signature:</b>

```typescript
export declare type FieldFormatsGetConfigFn = <T = any>(key: string, defaultOverride?: T) => T;
export declare type FieldFormatsGetConfigFn = GetConfigFn;
```
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,13 @@

## getSearchParamsFromRequest() function


<b>Signature:</b>

```typescript
export declare function getSearchParamsFromRequest(searchRequest: SearchRequest, dependencies: {
injectedMetadata: CoreStart['injectedMetadata'];
uiSettings: IUiSettingsClient;
esShardTimeout: number;
getConfig: GetConfigFn;
}): ISearchRequestParams;
```

Expand All @@ -18,7 +19,7 @@ export declare function getSearchParamsFromRequest(searchRequest: SearchRequest,
| Parameter | Type | Description |
| --- | --- | --- |
| searchRequest | <code>SearchRequest</code> | |
| dependencies | <code>{</code><br/><code> injectedMetadata: CoreStart['injectedMetadata'];</code><br/><code> uiSettings: IUiSettingsClient;</code><br/><code>}</code> | |
| dependencies | <code>{</code><br/><code> esShardTimeout: number;</code><br/><code> getConfig: GetConfigFn;</code><br/><code>}</code> | |

<b>Returns:</b>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@
<b>Signature:</b>

```typescript
export declare type FieldFormatsGetConfigFn = <T = any>(key: string, defaultOverride?: T) => T;
export declare type FieldFormatsGetConfigFn = GetConfigFn;
```
2 changes: 1 addition & 1 deletion docs/management/watcher-ui/index.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ The following example walks you through creating a threshold alert. The alert
is triggered when the maximum total CPU usage on a machine goes above a
certain percentage. The example uses https://www.elastic.co/products/beats/metricbeat[Metricbeat]
to collect metrics from your systems and services.
{metricbeat-ref}/metricbeat-installation.html[Learn more] on how to install
{metricbeat-ref}/metricbeat-installation-configuration.html[Learn more] on how to install
and get started with Metricbeat.

[float]
Expand Down
2 changes: 1 addition & 1 deletion docs/user/monitoring/monitoring-metricbeat.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ For more information, see {ref}/monitoring-settings.html[Monitoring settings in
and {ref}/cluster-update-settings.html[Cluster update settings].
--

. {metricbeat-ref}/metricbeat-installation.html[Install {metricbeat}] on the
. {metricbeat-ref}/metricbeat-installation-configuration.html[Install {metricbeat}] on the
same server as {kib}.

. Enable the {kib} {xpack} module in {metricbeat}. +
Expand Down
10 changes: 3 additions & 7 deletions examples/embeddable_examples/public/book/book_embeddable.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ import {
EmbeddableOutput,
SavedObjectEmbeddableInput,
ReferenceOrValueEmbeddable,
Container,
} from '../../../../src/plugins/embeddable/public';
import { BookSavedObjectAttributes } from '../../common';
import { BookEmbeddableComponent } from './book_component';
Expand Down Expand Up @@ -104,16 +103,13 @@ export class BookEmbeddable extends Embeddable<BookEmbeddableInput, BookEmbeddab
};

getInputAsValueType = async (): Promise<BookByValueInput> => {
const input =
this.getRoot() && (this.getRoot() as Container).getInput().panels[this.id].explicitInput
? ((this.getRoot() as Container).getInput().panels[this.id]
.explicitInput as BookEmbeddableInput)
: this.input;
const input = this.attributeService.getExplicitInputFromEmbeddable(this);
return this.attributeService.getInputAsValueType(input);
};

getInputAsRefType = async (): Promise<BookByReferenceInput> => {
return this.attributeService.getInputAsRefType(this.input, { showSaveModal: true });
const input = this.attributeService.getExplicitInputFromEmbeddable(this);
return this.attributeService.getInputAsRefType(input, { showSaveModal: true });
};

public render(node: HTMLElement) {
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@
"@elastic/datemath": "5.0.3",
"@elastic/elasticsearch": "7.9.0-rc.2",
"@elastic/ems-client": "7.9.3",
"@elastic/eui": "27.4.0",
"@elastic/eui": "27.4.1",
"@elastic/filesaver": "1.1.2",
"@elastic/good": "8.1.1-kibana2",
"@elastic/numeral": "^2.5.0",
Expand Down
4 changes: 0 additions & 4 deletions packages/elastic-datemath/.babelrc

This file was deleted.

4 changes: 0 additions & 4 deletions packages/elastic-datemath/.npmignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,2 @@
/src
/test
/tsconfig.json
/.babelrc
/yarn.lock
/__tests__
8 changes: 4 additions & 4 deletions packages/elastic-datemath/__tests__/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@
* under the License.
*/

import dateMath from '../src';
import moment from 'moment';
import sinon from 'sinon';
import expect from '@kbn/expect';
const dateMath = require('../index');
const moment = require('moment');
const sinon = require('sinon');
const expect = require('@kbn/expect');

/**
* Require a new instance of the moment library, bypassing the require cache.
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
* under the License.
*/

import moment from 'moment';
const moment = require('moment');

const unitsMap = {
ms: { weight: 1, type: 'fixed', base: 1 },
Expand Down Expand Up @@ -151,7 +151,7 @@ function parseDateMath(mathString, time, roundUp) {
return dateTime;
}

export default {
module.exports = {
parse: parse,
unitsMap: Object.freeze(unitsMap),
units: Object.freeze(units),
Expand Down
18 changes: 2 additions & 16 deletions packages/elastic-datemath/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,8 @@
"version": "5.0.3",
"description": "elasticsearch datemath parser, used in kibana",
"license": "Apache-2.0",
"main": "target/index.js",
"typings": "target/index.d.ts",
"scripts": {
"build": "babel src --out-dir target --copy-files",
"kbn:bootstrap": "yarn build --quiet",
"kbn:watch": "yarn build --watch"
},
"devDependencies": {
"@babel/cli": "^7.10.5",
"@babel/preset-env": "^7.11.0",
"babel-plugin-add-module-exports": "^1.0.2",
"moment": "^2.24.0"
},
"dependencies": {
"tslib": "^2.0.0"
},
"main": "index.js",
"typings": "index.d.ts",
"peerDependencies": {
"moment": "^2.24.0"
}
Expand Down
8 changes: 2 additions & 6 deletions packages/elastic-datemath/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,6 @@
{
"extends": "../../tsconfig.json",
"compilerOptions": {
"declaration": true,
"outDir": "./target"
},
"include": [
"./src/**/*.ts"
]
"index.d.ts"
],
}
1 change: 0 additions & 1 deletion packages/elastic-datemath/yarn.lock

This file was deleted.

Loading

0 comments on commit 63cde69

Please sign in to comment.