Skip to content

Commit 14f47c3

Browse files
committed
Merge branch 'master' of github.com:elastic/kibana into dev/search-server-session-wip
# Conflicts: # src/plugins/data/public/search/search_interceptor.test.ts # src/plugins/data/public/search/search_interceptor.ts # x-pack/plugins/data_enhanced/public/search/search_interceptor.test.ts
2 parents 3fdef39 + 280ce7e commit 14f47c3

File tree

107 files changed

+2698
-653
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

107 files changed

+2698
-653
lines changed

docs/development/plugins/data/public/kibana-plugin-plugins-data-public.plugin.setup.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,15 @@
77
<b>Signature:</b>
88

99
```typescript
10-
setup(core: CoreSetup<DataStartDependencies, DataPublicPluginStart>, { expressions, uiActions, usageCollection }: DataSetupDependencies): DataPublicPluginSetup;
10+
setup(core: CoreSetup<DataStartDependencies, DataPublicPluginStart>, { bfetch, expressions, uiActions, usageCollection }: DataSetupDependencies): DataPublicPluginSetup;
1111
```
1212

1313
## Parameters
1414

1515
| Parameter | Type | Description |
1616
| --- | --- | --- |
1717
| core | <code>CoreSetup&lt;DataStartDependencies, DataPublicPluginStart&gt;</code> | |
18-
| { expressions, uiActions, usageCollection } | <code>DataSetupDependencies</code> | |
18+
| { bfetch, expressions, uiActions, usageCollection } | <code>DataSetupDependencies</code> | |
1919

2020
<b>Returns:</b>
2121

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
2+
3+
[Home](./index.md) &gt; [kibana-plugin-plugins-data-public](./kibana-plugin-plugins-data-public.md) &gt; [SearchInterceptorDeps](./kibana-plugin-plugins-data-public.searchinterceptordeps.md) &gt; [bfetch](./kibana-plugin-plugins-data-public.searchinterceptordeps.bfetch.md)
4+
5+
## SearchInterceptorDeps.bfetch property
6+
7+
<b>Signature:</b>
8+
9+
```typescript
10+
bfetch: BfetchPublicSetup;
11+
```

docs/development/plugins/data/public/kibana-plugin-plugins-data-public.searchinterceptordeps.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ export interface SearchInterceptorDeps
1414

1515
| Property | Type | Description |
1616
| --- | --- | --- |
17+
| [bfetch](./kibana-plugin-plugins-data-public.searchinterceptordeps.bfetch.md) | <code>BfetchPublicSetup</code> | |
1718
| [http](./kibana-plugin-plugins-data-public.searchinterceptordeps.http.md) | <code>CoreSetup['http']</code> | |
1819
| [session](./kibana-plugin-plugins-data-public.searchinterceptordeps.session.md) | <code>ISessionService</code> | |
1920
| [startServices](./kibana-plugin-plugins-data-public.searchinterceptordeps.startservices.md) | <code>Promise&lt;[CoreStart, any, unknown]&gt;</code> | |

docs/development/plugins/data/server/kibana-plugin-plugins-data-server.plugin.setup.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<b>Signature:</b>
88

99
```typescript
10-
setup(core: CoreSetup<DataPluginStartDependencies, DataPluginStart>, { expressions, usageCollection }: DataPluginSetupDependencies): {
10+
setup(core: CoreSetup<DataPluginStartDependencies, DataPluginStart>, { bfetch, expressions, usageCollection }: DataPluginSetupDependencies): {
1111
__enhance: (enhancements: DataEnhancements) => void;
1212
search: ISearchSetup;
1313
fieldFormats: {
@@ -21,7 +21,7 @@ setup(core: CoreSetup<DataPluginStartDependencies, DataPluginStart>, { expressio
2121
| Parameter | Type | Description |
2222
| --- | --- | --- |
2323
| core | <code>CoreSetup&lt;DataPluginStartDependencies, DataPluginStart&gt;</code> | |
24-
| { expressions, usageCollection } | <code>DataPluginSetupDependencies</code> | |
24+
| { bfetch, expressions, usageCollection } | <code>DataPluginSetupDependencies</code> | |
2525

2626
<b>Returns:</b>
2727

packages/kbn-config/src/__mocks__/env.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,6 @@ export function getEnvOptions(options: DeepPartial<EnvOptions> = {}): EnvOptions
4242
runExamples: false,
4343
...(options.cliArgs || {}),
4444
},
45-
isDevClusterMaster:
46-
options.isDevClusterMaster !== undefined ? options.isDevClusterMaster : false,
45+
isDevCliParent: options.isDevCliParent !== undefined ? options.isDevCliParent : false,
4746
};
4847
}

packages/kbn-config/src/__snapshots__/env.test.ts.snap

Lines changed: 6 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/kbn-config/src/env.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ test('correctly creates default environment in dev mode.', () => {
4747
REPO_ROOT,
4848
getEnvOptions({
4949
configs: ['/test/cwd/config/kibana.yml'],
50-
isDevClusterMaster: true,
50+
isDevCliParent: true,
5151
})
5252
);
5353

packages/kbn-config/src/env.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ import { PackageInfo, EnvironmentMode } from './types';
2626
export interface EnvOptions {
2727
configs: string[];
2828
cliArgs: CliArgs;
29-
isDevClusterMaster: boolean;
29+
isDevCliParent: boolean;
3030
}
3131

3232
/** @internal */
@@ -101,10 +101,10 @@ export class Env {
101101
public readonly configs: readonly string[];
102102

103103
/**
104-
* Indicates that this Kibana instance is run as development Node Cluster master.
104+
* Indicates that this Kibana instance is running in the parent process of the dev cli.
105105
* @internal
106106
*/
107-
public readonly isDevClusterMaster: boolean;
107+
public readonly isDevCliParent: boolean;
108108

109109
/**
110110
* @internal
@@ -122,7 +122,7 @@ export class Env {
122122

123123
this.cliArgs = Object.freeze(options.cliArgs);
124124
this.configs = Object.freeze(options.configs);
125-
this.isDevClusterMaster = options.isDevClusterMaster;
125+
this.isDevCliParent = options.isDevCliParent;
126126

127127
const isDevMode = this.cliArgs.dev || this.cliArgs.envName === 'development';
128128
this.mode = Object.freeze<EnvironmentMode>({

packages/kbn-legacy-logging/src/log_format_string.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ const type = _.memoize((t: string) => {
5454
return color(t)(_.pad(t, 7).slice(0, 7));
5555
});
5656

57-
const workerType = process.env.kbnWorkerType ? `${type(process.env.kbnWorkerType)} ` : '';
57+
const prefix = process.env.isDevCliChild ? `${type('server')} ` : '';
5858

5959
export class KbnLoggerStringFormat extends BaseLogFormat {
6060
format(data: Record<string, any>) {
@@ -71,6 +71,6 @@ export class KbnLoggerStringFormat extends BaseLogFormat {
7171
return s + `[${color(t)(t)}]`;
7272
}, '');
7373

74-
return `${workerType}${type(data.type)} [${time}] ${tags} ${msg}`;
74+
return `${prefix}${type(data.type)} [${time}] ${tags} ${msg}`;
7575
}
7676
}

packages/kbn-legacy-logging/src/rotate/index.ts

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717
* under the License.
1818
*/
1919

20-
import { isMaster, isWorker } from 'cluster';
2120
import { Server } from '@hapi/hapi';
2221
import { LogRotator } from './log_rotator';
2322
import { LegacyLoggingConfig } from '../schema';
@@ -30,12 +29,6 @@ export async function setupLoggingRotate(server: Server, config: LegacyLoggingCo
3029
return;
3130
}
3231

33-
// We just want to start the logging rotate service once
34-
// and we choose to use the master (prod) or the worker server (dev)
35-
if (!isMaster && isWorker && process.env.kbnWorkerType !== 'server') {
36-
return;
37-
}
38-
3932
// We don't want to run logging rotate server if
4033
// we are not logging to a file
4134
if (config.dest === 'stdout') {

0 commit comments

Comments
 (0)