Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/master' into deprecate-kibana-…
Browse files Browse the repository at this point in the history
…index
  • Loading branch information
kobelb committed Nov 23, 2020
2 parents 9dc7532 + f4de383 commit 21f2e68
Show file tree
Hide file tree
Showing 601 changed files with 15,667 additions and 5,303 deletions.
2 changes: 1 addition & 1 deletion .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@
/x-pack/test/functional_basic/apps/transform/ @elastic/ml-ui

# Maps
/x-pack/plugins/maps/ @elastic/kibana-gis
#CC# /x-pack/plugins/maps/ @elastic/kibana-gis
/x-pack/test/api_integration/apis/maps/ @elastic/kibana-gis
/x-pack/test/functional/apps/maps/ @elastic/kibana-gis
/x-pack/test/functional/es_archives/maps/ @elastic/kibana-gis
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@

```typescript
getFieldAttrs: () => {
[x: string]: {
customLabel: string;
};
[x: string]: FieldAttrSet;
};
```
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ export declare class IndexPattern implements IIndexPattern
| [flattenHit](./kibana-plugin-plugins-data-public.indexpattern.flattenhit.md) | | <code>(hit: Record&lt;string, any&gt;, deep?: boolean) =&gt; Record&lt;string, any&gt;</code> | |
| [formatField](./kibana-plugin-plugins-data-public.indexpattern.formatfield.md) | | <code>FormatFieldFn</code> | |
| [formatHit](./kibana-plugin-plugins-data-public.indexpattern.formathit.md) | | <code>{</code><br/><code> (hit: Record&lt;string, any&gt;, type?: string): any;</code><br/><code> formatField: FormatFieldFn;</code><br/><code> }</code> | |
| [getFieldAttrs](./kibana-plugin-plugins-data-public.indexpattern.getfieldattrs.md) | | <code>() =&gt; {</code><br/><code> [x: string]: {</code><br/><code> customLabel: string;</code><br/><code> };</code><br/><code> }</code> | |
| [getFieldAttrs](./kibana-plugin-plugins-data-public.indexpattern.getfieldattrs.md) | | <code>() =&gt; {</code><br/><code> [x: string]: FieldAttrSet;</code><br/><code> }</code> | |
| [getOriginalSavedObjectBody](./kibana-plugin-plugins-data-public.indexpattern.getoriginalsavedobjectbody.md) | | <code>() =&gt; {</code><br/><code> fieldAttrs?: string &#124; undefined;</code><br/><code> title?: string &#124; undefined;</code><br/><code> timeFieldName?: string &#124; undefined;</code><br/><code> intervalName?: string &#124; undefined;</code><br/><code> fields?: string &#124; undefined;</code><br/><code> sourceFilters?: string &#124; undefined;</code><br/><code> fieldFormatMap?: string &#124; undefined;</code><br/><code> typeMeta?: string &#124; undefined;</code><br/><code> type?: string &#124; undefined;</code><br/><code> }</code> | Get last saved saved object fields |
| [id](./kibana-plugin-plugins-data-public.indexpattern.id.md) | | <code>string</code> | |
| [intervalName](./kibana-plugin-plugins-data-public.indexpattern.intervalname.md) | | <code>string &#124; undefined</code> | |
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [kibana-plugin-plugins-data-public](./kibana-plugin-plugins-data-public.md) &gt; [QueryStringInputProps](./kibana-plugin-plugins-data-public.querystringinputprops.md) &gt; [disableLanguageSwitcher](./kibana-plugin-plugins-data-public.querystringinputprops.disablelanguageswitcher.md)

## QueryStringInputProps.disableLanguageSwitcher property

<b>Signature:</b>

```typescript
disableLanguageSwitcher?: boolean;
```
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [kibana-plugin-plugins-data-public](./kibana-plugin-plugins-data-public.md) &gt; [QueryStringInputProps](./kibana-plugin-plugins-data-public.querystringinputprops.md) &gt; [iconType](./kibana-plugin-plugins-data-public.querystringinputprops.icontype.md)

## QueryStringInputProps.iconType property

<b>Signature:</b>

```typescript
iconType?: string;
```
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ export interface QueryStringInputProps
| [className](./kibana-plugin-plugins-data-public.querystringinputprops.classname.md) | <code>string</code> | |
| [dataTestSubj](./kibana-plugin-plugins-data-public.querystringinputprops.datatestsubj.md) | <code>string</code> | |
| [disableAutoFocus](./kibana-plugin-plugins-data-public.querystringinputprops.disableautofocus.md) | <code>boolean</code> | |
| [disableLanguageSwitcher](./kibana-plugin-plugins-data-public.querystringinputprops.disablelanguageswitcher.md) | <code>boolean</code> | |
| [iconType](./kibana-plugin-plugins-data-public.querystringinputprops.icontype.md) | <code>string</code> | |
| [indexPatterns](./kibana-plugin-plugins-data-public.querystringinputprops.indexpatterns.md) | <code>Array&lt;IIndexPattern &#124; string&gt;</code> | |
| [isInvalid](./kibana-plugin-plugins-data-public.querystringinputprops.isinvalid.md) | <code>boolean</code> | |
| [languageSwitcherPopoverAnchorPosition](./kibana-plugin-plugins-data-public.querystringinputprops.languageswitcherpopoveranchorposition.md) | <code>PopoverAnchorPosition</code> | |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@

```typescript
getFieldAttrs: () => {
[x: string]: {
customLabel: string;
};
[x: string]: FieldAttrSet;
};
```
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ export declare class IndexPattern implements IIndexPattern
| [flattenHit](./kibana-plugin-plugins-data-server.indexpattern.flattenhit.md) | | <code>(hit: Record&lt;string, any&gt;, deep?: boolean) =&gt; Record&lt;string, any&gt;</code> | |
| [formatField](./kibana-plugin-plugins-data-server.indexpattern.formatfield.md) | | <code>FormatFieldFn</code> | |
| [formatHit](./kibana-plugin-plugins-data-server.indexpattern.formathit.md) | | <code>{</code><br/><code> (hit: Record&lt;string, any&gt;, type?: string): any;</code><br/><code> formatField: FormatFieldFn;</code><br/><code> }</code> | |
| [getFieldAttrs](./kibana-plugin-plugins-data-server.indexpattern.getfieldattrs.md) | | <code>() =&gt; {</code><br/><code> [x: string]: {</code><br/><code> customLabel: string;</code><br/><code> };</code><br/><code> }</code> | |
| [getFieldAttrs](./kibana-plugin-plugins-data-server.indexpattern.getfieldattrs.md) | | <code>() =&gt; {</code><br/><code> [x: string]: FieldAttrSet;</code><br/><code> }</code> | |
| [getOriginalSavedObjectBody](./kibana-plugin-plugins-data-server.indexpattern.getoriginalsavedobjectbody.md) | | <code>() =&gt; {</code><br/><code> fieldAttrs?: string &#124; undefined;</code><br/><code> title?: string &#124; undefined;</code><br/><code> timeFieldName?: string &#124; undefined;</code><br/><code> intervalName?: string &#124; undefined;</code><br/><code> fields?: string &#124; undefined;</code><br/><code> sourceFilters?: string &#124; undefined;</code><br/><code> fieldFormatMap?: string &#124; undefined;</code><br/><code> typeMeta?: string &#124; undefined;</code><br/><code> type?: string &#124; undefined;</code><br/><code> }</code> | Get last saved saved object fields |
| [id](./kibana-plugin-plugins-data-server.indexpattern.id.md) | | <code>string</code> | |
| [intervalName](./kibana-plugin-plugins-data-server.indexpattern.intervalname.md) | | <code>string &#124; undefined</code> | |
Expand Down
3 changes: 2 additions & 1 deletion docs/management/advanced-options.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -454,7 +454,8 @@ of buckets to try to represent.

[horizontal]
[[visualization-colormapping]]`visualization:colorMapping`::
Maps values to specified colors in visualizations.
**This setting is deprecated and will not be supported as of 8.0.**
Maps values to specific colors in *Visualize* charts and *TSVB*. This setting does not apply to *Lens*.

[[visualization-dimmingopacity]]`visualization:dimmingOpacity`::
The opacity of the chart items that are dimmed when highlighting another element
Expand Down
2 changes: 1 addition & 1 deletion docs/settings/alert-action-settings.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Alerts and actions are enabled by default in {kib}, but require you configure th

. <<using-kibana-with-security,Set up {kib} to work with {stack} {security-features}>>.
. <<configuring-tls-kib-es,Set up TLS encryption between {kib} and {es}>>.
. <<general-alert-action-settings,Specify a value for `xpack.encryptedSavedObjects.encryptionKey`>>.
. If you are using an *on-premises* Elastic Stack deployment, <<general-alert-action-settings,specify a value for `xpack.encryptedSavedObjects.encryptionKey`>>.

You can configure the following settings in the `kibana.yml` file.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -127,9 +127,10 @@ export class BookEmbeddableFactoryDefinition

private async unwrapMethod(savedObjectId: string): Promise<BookSavedObjectAttributes> {
const { savedObjectsClient } = await this.getStartServices();
const savedObject: SimpleSavedObject<BookSavedObjectAttributes> = await savedObjectsClient.get<
BookSavedObjectAttributes
>(this.type, savedObjectId);
const savedObject: SimpleSavedObject<BookSavedObjectAttributes> = await savedObjectsClient.get<BookSavedObjectAttributes>(
this.type,
savedObjectId
);
return { ...savedObject.attributes };
}

Expand Down Expand Up @@ -163,9 +164,9 @@ export class BookEmbeddableFactoryDefinition

private async getAttributeService() {
if (!this.attributeService) {
this.attributeService = (await this.getStartServices()).getAttributeService<
BookSavedObjectAttributes
>(this.type, {
this.attributeService = (
await this.getStartServices()
).getAttributeService<BookSavedObjectAttributes>(this.type, {
saveMethod: this.saveMethod.bind(this),
unwrapMethod: this.unwrapMethod.bind(this),
checkForDuplicateTitle: this.checkForDuplicateTitleMethod.bind(this),
Expand Down
10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@
"**/load-grunt-config/lodash": "^4.17.20",
"**/minimist": "^1.2.5",
"**/node-jose/node-forge": "^0.10.0",
"**/prismjs": "1.22.0",
"**/request": "^2.88.2",
"**/trim": "0.0.3",
"**/typescript": "4.0.2"
Expand Down Expand Up @@ -131,6 +132,7 @@
"@kbn/config-schema": "link:packages/kbn-config-schema",
"@kbn/i18n": "link:packages/kbn-i18n",
"@kbn/interpreter": "link:packages/kbn-interpreter",
"@kbn/legacy-logging": "link:packages/kbn-legacy-logging",
"@kbn/logging": "link:packages/kbn-logging",
"@kbn/monaco": "link:packages/kbn-monaco",
"@kbn/std": "link:packages/kbn-std",
Expand Down Expand Up @@ -419,7 +421,6 @@
"@types/cmd-shim": "^2.0.0",
"@types/color": "^3.0.0",
"@types/compression-webpack-plugin": "^2.0.2",
"@types/console-stamp": "^0.2.32",
"@types/cypress-cucumber-preprocessor": "^1.14.1",
"@types/cytoscape": "^3.14.0",
"@types/d3": "^3.5.43",
Expand Down Expand Up @@ -510,7 +511,7 @@
"@types/pdfmake": "^0.1.15",
"@types/pegjs": "^0.10.1",
"@types/pngjs": "^3.4.0",
"@types/prettier": "^2.0.2",
"@types/prettier": "^2.1.5",
"@types/pretty-ms": "^5.0.0",
"@types/prop-types": "^15.7.3",
"@types/proper-lockfile": "^3.0.1",
Expand Down Expand Up @@ -602,7 +603,6 @@
"clean-webpack-plugin": "^3.0.0",
"cmd-shim": "^2.1.0",
"compare-versions": "3.5.1",
"console-stamp": "^0.2.9",
"constate": "^1.3.2",
"copy-to-clipboard": "^3.0.8",
"copy-webpack-plugin": "^6.0.2",
Expand All @@ -627,7 +627,7 @@
"enzyme-adapter-utils": "^1.13.0",
"enzyme-to-json": "^3.4.4",
"eslint": "^6.8.0",
"eslint-config-prettier": "^6.11.0",
"eslint-config-prettier": "^6.15.0",
"eslint-import-resolver-node": "0.3.2",
"eslint-import-resolver-webpack": "0.11.1",
"eslint-module-utils": "2.5.0",
Expand Down Expand Up @@ -763,7 +763,7 @@
"postcss": "^7.0.32",
"postcss-loader": "^3.0.0",
"postcss-prefix-selector": "^1.7.2",
"prettier": "^2.1.1",
"prettier": "^2.2.0",
"pretty-ms": "5.0.0",
"proxyquire": "1.8.0",
"querystring": "^0.2.0",
Expand Down
1 change: 0 additions & 1 deletion packages/kbn-config/src/__mocks__/env.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ export function getEnvOptions(options: DeepPartial<EnvOptions> = {}): EnvOptions
configs: options.configs || [],
cliArgs: {
dev: true,
open: false,
quiet: false,
silent: false,
watch: false,
Expand Down
6 changes: 0 additions & 6 deletions packages/kbn-config/src/__snapshots__/env.test.ts.snap

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion packages/kbn-config/src/env.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ export interface CliArgs {
watch: boolean;
repl: boolean;
basePath: boolean;
open: boolean;
oss: boolean;
/** @deprecated use disableOptimizer to know if the @kbn/optimizer is disabled in development */
optimize?: boolean;
Expand Down
4 changes: 4 additions & 0 deletions packages/kbn-legacy-logging/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# @kbn/legacy-logging

This package contains the implementation of the legacy logging
system, based on `@hapi/good`
15 changes: 15 additions & 0 deletions packages/kbn-legacy-logging/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"name": "@kbn/legacy-logging",
"version": "1.0.0",
"private": true,
"license": "Apache-2.0",
"main": "./target/index.js",
"scripts": {
"build": "tsc",
"kbn:bootstrap": "yarn build",
"kbn:watch": "yarn build --watch"
},
"dependencies": {
"@kbn/std": "link:../kbn-std"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -18,20 +18,25 @@
*/

import _ from 'lodash';
import { getLoggerStream } from './log_reporter';
import { getLogReporter } from './log_reporter';
import { LegacyLoggingConfig } from './schema';

export default function loggingConfiguration(config) {
const events = config.get('logging.events');
/**
* Returns the `@hapi/good` plugin configuration to be used for the legacy logging
* @param config
*/
export function getLoggingConfiguration(config: LegacyLoggingConfig, opsInterval: number) {
const events = config.events;

if (config.get('logging.silent')) {
if (config.silent) {
_.defaults(events, {});
} else if (config.get('logging.quiet')) {
} else if (config.quiet) {
_.defaults(events, {
log: ['listening', 'error', 'fatal'],
request: ['error'],
error: '*',
});
} else if (config.get('logging.verbose')) {
} else if (config.verbose) {
_.defaults(events, {
log: '*',
ops: '*',
Expand All @@ -47,24 +52,24 @@ export default function loggingConfiguration(config) {
});
}

const loggerStream = getLoggerStream({
const loggerStream = getLogReporter({
config: {
json: config.get('logging.json'),
dest: config.get('logging.dest'),
timezone: config.get('logging.timezone'),
json: config.json,
dest: config.dest,
timezone: config.timezone,

// I'm adding the default here because if you add another filter
// using the commandline it will remove authorization. I want users
// to have to explicitly set --logging.filter.authorization=none or
// --logging.filter.cookie=none to have it show up in the logs.
filter: _.defaults(config.get('logging.filter'), {
filter: _.defaults(config.filter, {
authorization: 'remove',
cookie: 'remove',
}),
},
events: _.transform(
events,
function (filtered, val, key) {
function (filtered: Record<string, string>, val: string, key: string) {
// provide a string compatible way to remove events
if (val !== '!') filtered[key] = val;
},
Expand All @@ -74,7 +79,7 @@ export default function loggingConfiguration(config) {

const options = {
ops: {
interval: config.get('ops.interval'),
interval: opsInterval,
},
includes: {
request: ['headers', 'payload'],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,23 +17,9 @@
* under the License.
*/

import { ExprVisAPIEvents } from '../../../../visualizations/public';

export const createBrushHandler = (applyFilter: ExprVisAPIEvents['applyFilter']) => (
gte: string,
lte: string
) => {
return applyFilter({
timeFieldName: '*',
filters: [
{
range: {
'*': {
gte,
lte,
},
},
},
],
});
};
export { LegacyLoggingConfig, legacyLoggingConfigSchema } from './schema';
export { attachMetaData } from './metadata';
export { setupLoggingRotate } from './rotate';
export { setupLogging, reconfigureLogging } from './setup_logging';
export { getLoggingConfiguration } from './get_logging_config';
export { LegacyLoggingServer } from './legacy_logging_server';
Loading

0 comments on commit 21f2e68

Please sign in to comment.