mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 01:38:56 -04:00
Migrate server-side Root
and Server
to packages (#144990)
## Summary Fix https://github.com/elastic/kibana/issues/144255 Create the `@kbn/core-root-server-internal` package, and move `Root`, `Server` and `bootstrap` to it. Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
This commit is contained in:
parent
32cf768f05
commit
a16c2ac56a
50 changed files with 280 additions and 33 deletions
1
.github/CODEOWNERS
vendored
1
.github/CODEOWNERS
vendored
|
@ -837,6 +837,7 @@ packages/core/rendering/core-rendering-browser-mocks @elastic/kibana-core
|
|||
packages/core/rendering/core-rendering-server-internal @elastic/kibana-core
|
||||
packages/core/rendering/core-rendering-server-mocks @elastic/kibana-core
|
||||
packages/core/root/core-root-browser-internal @elastic/kibana-core
|
||||
packages/core/root/core-root-server-internal @elastic/kibana-core
|
||||
packages/core/saved-objects/core-saved-objects-api-browser @elastic/kibana-core
|
||||
packages/core/saved-objects/core-saved-objects-api-server @elastic/kibana-core
|
||||
packages/core/saved-objects/core-saved-objects-api-server-internal @elastic/kibana-core
|
||||
|
|
|
@ -282,6 +282,7 @@
|
|||
"@kbn/core-rendering-server-internal": "link:bazel-bin/packages/core/rendering/core-rendering-server-internal",
|
||||
"@kbn/core-rendering-server-mocks": "link:bazel-bin/packages/core/rendering/core-rendering-server-mocks",
|
||||
"@kbn/core-root-browser-internal": "link:bazel-bin/packages/core/root/core-root-browser-internal",
|
||||
"@kbn/core-root-server-internal": "link:bazel-bin/packages/core/root/core-root-server-internal",
|
||||
"@kbn/core-saved-objects-api-browser": "link:bazel-bin/packages/core/saved-objects/core-saved-objects-api-browser",
|
||||
"@kbn/core-saved-objects-api-server": "link:bazel-bin/packages/core/saved-objects/core-saved-objects-api-server",
|
||||
"@kbn/core-saved-objects-api-server-internal": "link:bazel-bin/packages/core/saved-objects/core-saved-objects-api-server-internal",
|
||||
|
|
|
@ -147,6 +147,7 @@ filegroup(
|
|||
"//packages/core/rendering/core-rendering-server-internal:build",
|
||||
"//packages/core/rendering/core-rendering-server-mocks:build",
|
||||
"//packages/core/root/core-root-browser-internal:build",
|
||||
"//packages/core/root/core-root-server-internal:build",
|
||||
"//packages/core/saved-objects/core-saved-objects-api-browser:build",
|
||||
"//packages/core/saved-objects/core-saved-objects-api-server:build",
|
||||
"//packages/core/saved-objects/core-saved-objects-api-server-internal:build",
|
||||
|
@ -508,6 +509,7 @@ filegroup(
|
|||
"//packages/core/rendering/core-rendering-server-internal:build_types",
|
||||
"//packages/core/rendering/core-rendering-server-mocks:build_types",
|
||||
"//packages/core/root/core-root-browser-internal:build_types",
|
||||
"//packages/core/root/core-root-server-internal:build_types",
|
||||
"//packages/core/saved-objects/core-saved-objects-api-browser:build_types",
|
||||
"//packages/core/saved-objects/core-saved-objects-api-server:build_types",
|
||||
"//packages/core/saved-objects/core-saved-objects-api-server-internal:build_types",
|
||||
|
|
167
packages/core/root/core-root-server-internal/BUILD.bazel
Normal file
167
packages/core/root/core-root-server-internal/BUILD.bazel
Normal file
|
@ -0,0 +1,167 @@
|
|||
load("@npm//@bazel/typescript:index.bzl", "ts_config")
|
||||
load("@build_bazel_rules_nodejs//:index.bzl", "js_library")
|
||||
load("//src/dev/bazel:index.bzl", "jsts_transpiler", "pkg_npm", "pkg_npm_types", "ts_project")
|
||||
|
||||
PKG_DIRNAME = "core-root-server-internal"
|
||||
PKG_REQUIRE_NAME = "@kbn/core-root-server-internal"
|
||||
|
||||
SOURCE_FILES = glob(
|
||||
[
|
||||
"**/*.ts",
|
||||
],
|
||||
exclude = [
|
||||
"**/*.config.js",
|
||||
"**/*.mock.*",
|
||||
"**/*.test.*",
|
||||
"**/*.stories.*",
|
||||
"**/__snapshots__/**",
|
||||
"**/integration_tests/**",
|
||||
"**/mocks/**",
|
||||
"**/scripts/**",
|
||||
"**/storybook/**",
|
||||
"**/test_fixtures/**",
|
||||
"**/test_helpers/**",
|
||||
],
|
||||
)
|
||||
|
||||
SRCS = SOURCE_FILES
|
||||
|
||||
filegroup(
|
||||
name = "srcs",
|
||||
srcs = SRCS,
|
||||
)
|
||||
|
||||
NPM_MODULE_EXTRA_FILES = [
|
||||
"package.json",
|
||||
]
|
||||
|
||||
RUNTIME_DEPS = [
|
||||
"@npm//elastic-apm-node",
|
||||
"//packages/kbn-utils",
|
||||
"//packages/kbn-config",
|
||||
"//packages/kbn-ebt-tools",
|
||||
"//packages/core/doc-links/core-doc-links-server-internal",
|
||||
"//packages/core/logging/core-logging-server-internal",
|
||||
"//packages/core/config/core-config-server-internal",
|
||||
"//packages/core/node/core-node-server-internal",
|
||||
"//packages/core/analytics/core-analytics-server-internal",
|
||||
"//packages/core/environment/core-environment-server-internal",
|
||||
"//packages/core/execution-context/core-execution-context-server-internal",
|
||||
"//packages/core/preboot/core-preboot-server-internal",
|
||||
"//packages/core/http/core-http-context-server-internal",
|
||||
"//packages/core/http/core-http-server-internal",
|
||||
"//packages/core/elasticsearch/core-elasticsearch-server-internal",
|
||||
"//packages/core/metrics/core-metrics-server-internal",
|
||||
"//packages/core/capabilities/core-capabilities-server-internal",
|
||||
"//packages/core/saved-objects/core-saved-objects-base-server-internal",
|
||||
"//packages/core/saved-objects/core-saved-objects-server-internal",
|
||||
"//packages/core/i18n/core-i18n-server-internal",
|
||||
"//packages/core/deprecations/core-deprecations-server-internal",
|
||||
"//packages/core/usage-data/core-usage-data-server-internal",
|
||||
"//packages/core/status/core-status-server-internal",
|
||||
"//packages/core/ui-settings/core-ui-settings-server-internal",
|
||||
"//packages/core/http/core-http-request-handler-context-server-internal",
|
||||
"//packages/core/rendering/core-rendering-server-internal",
|
||||
"//packages/core/http/core-http-resources-server-internal",
|
||||
"//packages/core/plugins/core-plugins-server-internal",
|
||||
"//packages/core/apps/core-apps-server-internal",
|
||||
]
|
||||
|
||||
TYPES_DEPS = [
|
||||
"@npm//@types/node",
|
||||
"@npm//@types/jest",
|
||||
"@npm//elastic-apm-node",
|
||||
"//packages/kbn-utils:npm_module_types",
|
||||
"//packages/kbn-logging:npm_module_types",
|
||||
"//packages/kbn-config:npm_module_types",
|
||||
"//packages/kbn-ebt-tools:npm_module_types",
|
||||
"//packages/core/base/core-base-server-internal:npm_module_types",
|
||||
"//packages/core/doc-links/core-doc-links-server-internal:npm_module_types",
|
||||
"//packages/core/logging/core-logging-server-internal:npm_module_types",
|
||||
"//packages/core/config/core-config-server-internal:npm_module_types",
|
||||
"//packages/core/node/core-node-server-internal:npm_module_types",
|
||||
"//packages/core/analytics/core-analytics-server-internal:npm_module_types",
|
||||
"//packages/core/analytics/core-analytics-server:npm_module_types",
|
||||
"//packages/core/environment/core-environment-server-internal:npm_module_types",
|
||||
"//packages/core/execution-context/core-execution-context-server-internal:npm_module_types",
|
||||
"//packages/core/preboot/core-preboot-server-internal:npm_module_types",
|
||||
"//packages/core/http/core-http-context-server-internal:npm_module_types",
|
||||
"//packages/core/http/core-http-server-internal:npm_module_types",
|
||||
"//packages/core/elasticsearch/core-elasticsearch-server-internal:npm_module_types",
|
||||
"//packages/core/metrics/core-metrics-server-internal:npm_module_types",
|
||||
"//packages/core/capabilities/core-capabilities-server-internal:npm_module_types",
|
||||
"//packages/core/saved-objects/core-saved-objects-server:npm_module_types",
|
||||
"//packages/core/saved-objects/core-saved-objects-base-server-internal:npm_module_types",
|
||||
"//packages/core/saved-objects/core-saved-objects-server-internal:npm_module_types",
|
||||
"//packages/core/i18n/core-i18n-server-internal:npm_module_types",
|
||||
"//packages/core/deprecations/core-deprecations-server-internal:npm_module_types",
|
||||
"//packages/core/usage-data/core-usage-data-server-internal:npm_module_types",
|
||||
"//packages/core/status/core-status-server-internal:npm_module_types",
|
||||
"//packages/core/ui-settings/core-ui-settings-server-internal:npm_module_types",
|
||||
"//packages/core/http/core-http-request-handler-context-server-internal:npm_module_types",
|
||||
"//packages/core/http/core-http-request-handler-context-server:npm_module_types",
|
||||
"//packages/core/rendering/core-rendering-server-internal:npm_module_types",
|
||||
"//packages/core/http/core-http-resources-server-internal:npm_module_types",
|
||||
"//packages/core/lifecycle/core-lifecycle-server-internal:npm_module_types",
|
||||
"//packages/core/plugins/core-plugins-server-internal:npm_module_types",
|
||||
"//packages/core/apps/core-apps-server-internal:npm_module_types",
|
||||
]
|
||||
|
||||
jsts_transpiler(
|
||||
name = "target_node",
|
||||
srcs = SRCS,
|
||||
build_pkg_name = package_name(),
|
||||
)
|
||||
|
||||
ts_config(
|
||||
name = "tsconfig",
|
||||
src = "tsconfig.json",
|
||||
deps = [
|
||||
"//:tsconfig.base.json",
|
||||
"//:tsconfig.bazel.json",
|
||||
],
|
||||
)
|
||||
|
||||
ts_project(
|
||||
name = "tsc_types",
|
||||
args = ['--pretty'],
|
||||
srcs = SRCS,
|
||||
deps = TYPES_DEPS,
|
||||
declaration = True,
|
||||
emit_declaration_only = True,
|
||||
out_dir = "target_types",
|
||||
tsconfig = ":tsconfig",
|
||||
)
|
||||
|
||||
js_library(
|
||||
name = PKG_DIRNAME,
|
||||
srcs = NPM_MODULE_EXTRA_FILES,
|
||||
deps = RUNTIME_DEPS + [":target_node"],
|
||||
package_name = PKG_REQUIRE_NAME,
|
||||
visibility = ["//visibility:public"],
|
||||
)
|
||||
|
||||
js_library(
|
||||
name = "npm_module_types",
|
||||
srcs = NPM_MODULE_EXTRA_FILES,
|
||||
deps = RUNTIME_DEPS + [":target_node", ":tsc_types"],
|
||||
package_name = PKG_REQUIRE_NAME,
|
||||
visibility = ["//visibility:public"],
|
||||
)
|
||||
|
||||
pkg_npm(
|
||||
name = "npm_module",
|
||||
deps = [":" + PKG_DIRNAME],
|
||||
)
|
||||
|
||||
filegroup(
|
||||
name = "build",
|
||||
srcs = [":npm_module"],
|
||||
visibility = ["//visibility:public"],
|
||||
)
|
||||
|
||||
filegroup(
|
||||
name = "build_types",
|
||||
srcs = [":npm_module_types"],
|
||||
visibility = ["//visibility:public"],
|
||||
)
|
6
packages/core/root/core-root-server-internal/README.md
Normal file
6
packages/core/root/core-root-server-internal/README.md
Normal file
|
@ -0,0 +1,6 @@
|
|||
# @kbn/core-root-server-internal
|
||||
|
||||
This package exposes the root components required to start the Core system on the server side.
|
||||
- the `Root` class
|
||||
- the `Server` class
|
||||
- the `bootstap` function
|
9
packages/core/root/core-root-server-internal/index.ts
Normal file
9
packages/core/root/core-root-server-internal/index.ts
Normal file
|
@ -0,0 +1,9 @@
|
|||
/*
|
||||
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
|
||||
* or more contributor license agreements. Licensed under the Elastic License
|
||||
* 2.0 and the Server Side Public License, v 1; you may not use this file except
|
||||
* in compliance with, at your election, the Elastic License 2.0 or the Server
|
||||
* Side Public License, v 1.
|
||||
*/
|
||||
|
||||
export { Server, Root, bootstrap } from './src';
|
13
packages/core/root/core-root-server-internal/jest.config.js
Normal file
13
packages/core/root/core-root-server-internal/jest.config.js
Normal file
|
@ -0,0 +1,13 @@
|
|||
/*
|
||||
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
|
||||
* or more contributor license agreements. Licensed under the Elastic License
|
||||
* 2.0 and the Server Side Public License, v 1; you may not use this file except
|
||||
* in compliance with, at your election, the Elastic License 2.0 or the Server
|
||||
* Side Public License, v 1.
|
||||
*/
|
||||
|
||||
module.exports = {
|
||||
preset: '@kbn/test/jest_node',
|
||||
rootDir: '../../../..',
|
||||
roots: ['<rootDir>/packages/core/root/core-root-server-internal'],
|
||||
};
|
|
@ -0,0 +1,7 @@
|
|||
{
|
||||
"type": "shared-common",
|
||||
"id": "@kbn/core-root-server-internal",
|
||||
"owner": "@elastic/kibana-core",
|
||||
"runtimeDeps": [],
|
||||
"typeDeps": [],
|
||||
}
|
|
@ -0,0 +1,9 @@
|
|||
{
|
||||
"name": "@kbn/core-root-server-internal",
|
||||
"private": true,
|
||||
"version": "1.0.0",
|
||||
"main": "./target_node/index.js",
|
||||
"types": "./target_types/index.d.ts",
|
||||
"author": "Kibana Core",
|
||||
"license": "SSPL-1.0 OR Elastic License 2.0"
|
||||
}
|
11
packages/core/root/core-root-server-internal/src/index.ts
Normal file
11
packages/core/root/core-root-server-internal/src/index.ts
Normal file
|
@ -0,0 +1,11 @@
|
|||
/*
|
||||
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
|
||||
* or more contributor license agreements. Licensed under the Elastic License
|
||||
* 2.0 and the Server Side Public License, v 1; you may not use this file except
|
||||
* in compliance with, at your election, the Elastic License 2.0 or the Server
|
||||
* Side Public License, v 1.
|
||||
*/
|
||||
|
||||
export { Server } from './server';
|
||||
export { bootstrap } from './bootstrap';
|
||||
export { Root } from './root';
|
|
@ -16,7 +16,7 @@ import {
|
|||
distinctUntilChanged,
|
||||
} from 'rxjs/operators';
|
||||
import type { Logger, LoggerFactory } from '@kbn/logging';
|
||||
import { Env, RawConfigurationProvider } from '@kbn/config';
|
||||
import type { Env, RawConfigurationProvider } from '@kbn/config';
|
||||
import { LoggingConfigType, LoggingSystem } from '@kbn/core-logging-server-internal';
|
||||
import apm from 'elastic-apm-node';
|
||||
import { isEqual } from 'lodash';
|
|
@ -8,6 +8,7 @@
|
|||
|
||||
import apm from 'elastic-apm-node';
|
||||
import { config as pathConfig } from '@kbn/utils';
|
||||
import { reportPerformanceMetricEvent } from '@kbn/ebt-tools';
|
||||
import type { Logger, LoggerFactory } from '@kbn/logging';
|
||||
import { ConfigService, Env, RawConfigurationProvider } from '@kbn/config';
|
||||
import type { ServiceConfigDescriptor } from '@kbn/core-base-server-internal';
|
||||
|
@ -24,7 +25,6 @@ import {
|
|||
import { NodeService, nodeConfig } from '@kbn/core-node-server-internal';
|
||||
import { AnalyticsService } from '@kbn/core-analytics-server-internal';
|
||||
import type { AnalyticsServiceSetup, AnalyticsServiceStart } from '@kbn/core-analytics-server';
|
||||
import { reportPerformanceMetricEvent } from '@kbn/ebt-tools';
|
||||
import { EnvironmentService, pidConfig } from '@kbn/core-environment-server-internal';
|
||||
import {
|
||||
ExecutionContextService,
|
||||
|
@ -69,7 +69,7 @@ import type {
|
|||
import { RenderingService } from '@kbn/core-rendering-server-internal';
|
||||
|
||||
import { HttpResourcesService } from '@kbn/core-http-resources-server-internal';
|
||||
import {
|
||||
import type {
|
||||
InternalCorePreboot,
|
||||
InternalCoreSetup,
|
||||
InternalCoreStart,
|
15
packages/core/root/core-root-server-internal/tsconfig.json
Normal file
15
packages/core/root/core-root-server-internal/tsconfig.json
Normal file
|
@ -0,0 +1,15 @@
|
|||
{
|
||||
"extends": "../../../../tsconfig.bazel.json",
|
||||
"compilerOptions": {
|
||||
"declaration": true,
|
||||
"emitDeclarationOnly": true,
|
||||
"outDir": "target_types",
|
||||
"types": [
|
||||
"jest",
|
||||
"node"
|
||||
]
|
||||
},
|
||||
"include": [
|
||||
"**/*.ts",
|
||||
]
|
||||
}
|
|
@ -48,6 +48,8 @@ import type { RequestHandlerContext } from '@kbn/core-http-request-handler-conte
|
|||
import type { HttpResources } from '@kbn/core-http-resources-server';
|
||||
import type { PluginsServiceSetup, PluginsServiceStart } from '@kbn/core-plugins-server-internal';
|
||||
|
||||
export { bootstrap } from '@kbn/core-root-server-internal';
|
||||
|
||||
export type { PluginOpaqueId } from '@kbn/core-base-common';
|
||||
export type {
|
||||
CoreUsageStats,
|
||||
|
@ -65,8 +67,6 @@ export type {
|
|||
|
||||
export type { KibanaExecutionContext } from '@kbn/core-execution-context-common';
|
||||
export type { IExecutionContextContainer } from '@kbn/core-execution-context-server';
|
||||
|
||||
export { bootstrap } from './bootstrap';
|
||||
export type { Capabilities } from '@kbn/core-capabilities-common';
|
||||
export type {
|
||||
CapabilitiesProvider,
|
||||
|
|
|
@ -6,8 +6,8 @@
|
|||
* Side Public License, v 1.
|
||||
*/
|
||||
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
import * as kbnTestServer from '../../../test_helpers/kbn_server';
|
||||
import { Root } from '../../root';
|
||||
|
||||
describe('Core app routes', () => {
|
||||
let root: Root;
|
||||
|
|
|
@ -6,8 +6,8 @@
|
|||
* Side Public License, v 1.
|
||||
*/
|
||||
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
import * as kbnTestServer from '../../../test_helpers/kbn_server';
|
||||
import { Root } from '../../root';
|
||||
|
||||
describe('default route provider', () => {
|
||||
let esServer: kbnTestServer.TestElasticsearchUtils;
|
||||
|
|
|
@ -6,8 +6,8 @@
|
|||
* Side Public License, v 1.
|
||||
*/
|
||||
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
import * as kbnTestServer from '../../../test_helpers/kbn_server';
|
||||
import { Root } from '../../root';
|
||||
|
||||
describe('Platform assets', function () {
|
||||
let root: Root;
|
||||
|
|
|
@ -10,13 +10,13 @@ import { esTestConfig } from '@kbn/test';
|
|||
import * as http from 'http';
|
||||
import supertest from 'supertest';
|
||||
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
import {
|
||||
createRootWithCorePlugins,
|
||||
createTestServers,
|
||||
TestElasticsearchUtils,
|
||||
TestKibanaUtils,
|
||||
} from '../../../test_helpers/kbn_server';
|
||||
import { Root } from '../../root';
|
||||
|
||||
describe('elasticsearch clients', () => {
|
||||
let esServer: TestElasticsearchUtils;
|
||||
|
|
|
@ -14,7 +14,7 @@ import { getEnvOptions } from '@kbn/config-mocks';
|
|||
import type { ElasticsearchClient } from '@kbn/core-elasticsearch-server';
|
||||
import * as kbnTestServer from '../../../../test_helpers/kbn_server';
|
||||
import type { InternalCoreStart } from '@kbn/core-lifecycle-server-internal';
|
||||
import { Root } from '../../../root';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
|
||||
const kibanaVersion = Env.createDefault(REPO_ROOT, getEnvOptions()).packageInfo.version;
|
||||
const logFilePath = path.join(__dirname, '7.7.2_xpack_100k.log');
|
||||
|
|
|
@ -10,7 +10,7 @@ import Path from 'path';
|
|||
import fs from 'fs/promises';
|
||||
import type { ElasticsearchClient } from '@kbn/core-elasticsearch-server';
|
||||
import * as kbnTestServer from '../../../../test_helpers/kbn_server';
|
||||
import { Root } from '../../../root';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
|
||||
const logFilePath = Path.join(__dirname, '7_13_failed_action_tasks.log');
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@ import { REPO_ROOT } from '@kbn/utils';
|
|||
import { getEnvOptions } from '@kbn/config-mocks';
|
||||
import type { ElasticsearchClient } from '@kbn/core-elasticsearch-server';
|
||||
import * as kbnTestServer from '../../../../test_helpers/kbn_server';
|
||||
import { Root } from '../../../root';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
import { SearchTotalHits } from '@elastic/elasticsearch/lib/api/types';
|
||||
import { getMigrationDocLink } from './test_utils';
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@ import { REPO_ROOT } from '@kbn/utils';
|
|||
import { getEnvOptions } from '@kbn/config-mocks';
|
||||
import type { ElasticsearchClient } from '@kbn/core-elasticsearch-server';
|
||||
import * as kbnTestServer from '../../../../test_helpers/kbn_server';
|
||||
import type { Root } from '../../../root';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
|
||||
const logFilePath = Path.join(__dirname, '7_13_unknown_types.log');
|
||||
|
||||
|
|
|
@ -6,10 +6,10 @@
|
|||
* Side Public License, v 1.
|
||||
*/
|
||||
import type * as estypes from '@elastic/elasticsearch/lib/api/typesWithBodyKey';
|
||||
import { ElasticsearchClient } from '../../../..';
|
||||
import { InternalCoreStart } from '@kbn/core-lifecycle-server-internal';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
import type { ElasticsearchClient } from '../../../..';
|
||||
import * as kbnTestServer from '../../../../../test_helpers/kbn_server';
|
||||
import { Root } from '../../../../root';
|
||||
import {
|
||||
isWriteBlockException,
|
||||
isClusterShardLimitExceeded,
|
||||
|
|
|
@ -10,7 +10,7 @@ import Path from 'path';
|
|||
import fs from 'fs/promises';
|
||||
import JSON5 from 'json5';
|
||||
import * as kbnTestServer from '../../../../test_helpers/kbn_server';
|
||||
import { Root } from '../../../root';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
import type { ElasticsearchClient } from '@kbn/core-elasticsearch-server';
|
||||
import { Env } from '@kbn/config';
|
||||
import { REPO_ROOT } from '@kbn/utils';
|
||||
|
|
|
@ -11,7 +11,7 @@ import fs from 'fs/promises';
|
|||
import JSON5 from 'json5';
|
||||
import * as kbnTestServer from '../../../../test_helpers/kbn_server';
|
||||
import { retryAsync } from '@kbn/core-saved-objects-migration-server-mocks';
|
||||
import { Root } from '../../../root';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
|
||||
const logFilePath = Path.join(__dirname, 'batch_size_bytes_exceeds_es_content_length.log');
|
||||
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
|
||||
import type { ISavedObjectTypeRegistry } from '@kbn/core-saved-objects-server';
|
||||
import { getMigrationHash } from '@kbn/core-test-helpers-so-type-serializer';
|
||||
import { Root } from '../../../root';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
import * as kbnTestServer from '../../../../test_helpers/kbn_server';
|
||||
|
||||
describe('checking migration metadata changes on all registered SO types', () => {
|
||||
|
|
|
@ -11,7 +11,7 @@ import Fs from 'fs';
|
|||
import Util from 'util';
|
||||
import JSON5 from 'json5';
|
||||
import * as kbnTestServer from '../../../../test_helpers/kbn_server';
|
||||
import type { Root } from '../../../root';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
import { getMigrationDocLink } from './test_utils';
|
||||
|
||||
const migrationDocLink = getMigrationDocLink().resolveMigrationFailures;
|
||||
|
|
|
@ -10,7 +10,7 @@ import Path from 'path';
|
|||
import Fs from 'fs';
|
||||
import Util from 'util';
|
||||
import * as kbnTestServer from '../../../../test_helpers/kbn_server';
|
||||
import { Root } from '../../../root';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
import { getMigrationDocLink } from './test_utils';
|
||||
|
||||
const migrationDocLink = getMigrationDocLink().resolveMigrationFailures;
|
||||
|
|
|
@ -10,7 +10,7 @@ import Path from 'path';
|
|||
import Fs from 'fs';
|
||||
import Util from 'util';
|
||||
import * as kbnTestServer from '../../../../test_helpers/kbn_server';
|
||||
import { Root } from '../../../root';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
|
||||
const logFilePath = Path.join(__dirname, 'corrupt_outdated_docs.log');
|
||||
|
||||
|
|
|
@ -10,7 +10,7 @@ import Path from 'path';
|
|||
import fs from 'fs/promises';
|
||||
import JSON5 from 'json5';
|
||||
import * as kbnTestServer from '../../../../test_helpers/kbn_server';
|
||||
import { Root } from '../../../root';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
import type { ElasticsearchClient } from '@kbn/core-elasticsearch-server';
|
||||
import { LogRecord } from '@kbn/logging';
|
||||
import { getDocVersion } from './test_utils';
|
||||
|
|
|
@ -17,7 +17,7 @@ import { ElasticsearchClient } from '@kbn/core-elasticsearch-server';
|
|||
import type { SavedObjectsRawDoc } from '@kbn/core-saved-objects-server';
|
||||
import * as kbnTestServer from '../../../../test_helpers/kbn_server';
|
||||
import { InternalCoreStart } from '@kbn/core-lifecycle-server-internal';
|
||||
import { Root } from '../../../root';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
|
||||
const kibanaVersion = Env.createDefault(REPO_ROOT, getEnvOptions()).packageInfo.version;
|
||||
|
||||
|
|
|
@ -17,7 +17,7 @@ import type { SavedObjectsRawDoc } from '@kbn/core-saved-objects-server';
|
|||
import * as kbnTestServer from '../../../../test_helpers/kbn_server';
|
||||
import { ElasticsearchClient } from '@kbn/core-elasticsearch-server';
|
||||
import { InternalCoreStart } from '@kbn/core-lifecycle-server-internal';
|
||||
import { Root } from '../../../root';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
|
||||
const kibanaVersion = Env.createDefault(REPO_ROOT, getEnvOptions()).packageInfo.version;
|
||||
|
||||
|
|
|
@ -12,7 +12,7 @@ import { kibanaServerTestUser } from '@kbn/test';
|
|||
import { kibanaPackageJson as pkg } from '@kbn/utils';
|
||||
import * as kbnTestServer from '../../../../test_helpers/kbn_server';
|
||||
import type { ElasticsearchClient } from '@kbn/core-elasticsearch-server';
|
||||
import { Root } from '../../../root';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
|
||||
const LOG_FILE_PREFIX = 'migration_test_multiple_es_nodes';
|
||||
|
||||
|
|
|
@ -13,7 +13,7 @@ import { kibanaPackageJson as pkg } from '@kbn/utils';
|
|||
import type { SavedObjectsType } from '@kbn/core-saved-objects-server';
|
||||
import * as kbnTestServer from '../../../../test_helpers/kbn_server';
|
||||
import type { ElasticsearchClient } from '@kbn/core-elasticsearch-server';
|
||||
import type { Root } from '../../../root';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
|
||||
const LOG_FILE_PREFIX = 'migration_test_multiple_kibana_nodes';
|
||||
|
||||
|
|
|
@ -12,7 +12,7 @@ import Util from 'util';
|
|||
import { kibanaPackageJson as pkg } from '@kbn/utils';
|
||||
import * as kbnTestServer from '../../../../test_helpers/kbn_server';
|
||||
import type { ElasticsearchClient } from '@kbn/core-elasticsearch-server';
|
||||
import { Root } from '../../../root';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
|
||||
const logFilePath = Path.join(__dirname, 'outdated_docs.log');
|
||||
|
||||
|
|
|
@ -12,7 +12,7 @@ import Util from 'util';
|
|||
import { kibanaPackageJson as pkg } from '@kbn/utils';
|
||||
import * as kbnTestServer from '../../../../test_helpers/kbn_server';
|
||||
import type { ElasticsearchClient } from '@kbn/core-elasticsearch-server';
|
||||
import { Root } from '../../../root';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
import { deterministicallyRegenerateObjectId } from '@kbn/core-saved-objects-migration-server-internal';
|
||||
|
||||
const logFilePath = Path.join(__dirname, 'rewriting_id.log');
|
||||
|
|
|
@ -12,7 +12,7 @@ import JSON5 from 'json5';
|
|||
import { kibanaPackageJson as pkg } from '@kbn/utils';
|
||||
import { retryAsync } from '@kbn/core-saved-objects-migration-server-mocks';
|
||||
import * as kbnTestServer from '../../../../test_helpers/kbn_server';
|
||||
import { Root } from '../../../root';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
|
||||
const logFilePath = Path.join(__dirname, 'wait_for_migration_completion.log');
|
||||
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
|
||||
import { InternalCoreStart } from '@kbn/core-lifecycle-server-internal';
|
||||
import * as kbnTestServer from '../../../../../test_helpers/kbn_server';
|
||||
import { Root } from '../../../../root';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
|
||||
const { startES } = kbnTestServer.createTestServers({
|
||||
adjustTimeout: (t: number) => jest.setTimeout(t),
|
||||
|
|
|
@ -12,7 +12,7 @@ import { URL } from 'url';
|
|||
import type { SavedObject } from '@kbn/core-saved-objects-common';
|
||||
import type { ISavedObjectsRepository } from '@kbn/core-saved-objects-api-server';
|
||||
import type { InternalCoreSetup, InternalCoreStart } from '@kbn/core-lifecycle-server-internal';
|
||||
import { Root } from '../../../../root';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
import * as kbnTestServer from '../../../../../test_helpers/kbn_server';
|
||||
import {
|
||||
declareGetRoute,
|
||||
|
|
|
@ -16,7 +16,7 @@ import type { ISavedObjectsRepository } from '@kbn/core-saved-objects-api-server
|
|||
import type { SavedObjectsType } from '@kbn/core-saved-objects-server';
|
||||
import { getEnvOptions } from '@kbn/config-mocks';
|
||||
import type { InternalCoreSetup, InternalCoreStart } from '@kbn/core-lifecycle-server-internal';
|
||||
import { Root } from '../../../root';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
import * as kbnTestServer from '../../../../test_helpers/kbn_server';
|
||||
|
||||
const kibanaVersion = Env.createDefault(REPO_ROOT, getEnvOptions()).packageInfo.version;
|
||||
|
|
|
@ -22,7 +22,7 @@ import {
|
|||
import { CliArgs, Env } from '@kbn/config';
|
||||
|
||||
import type { InternalCoreSetup, InternalCoreStart } from '@kbn/core-lifecycle-server-internal';
|
||||
import { Root } from '../server/root';
|
||||
import { Root } from '@kbn/core-root-server-internal';
|
||||
|
||||
export type HttpMethod = 'delete' | 'get' | 'head' | 'post' | 'put' | 'patch';
|
||||
|
||||
|
|
|
@ -282,6 +282,8 @@
|
|||
"@kbn/core-rendering-server-mocks/*": ["packages/core/rendering/core-rendering-server-mocks/*"],
|
||||
"@kbn/core-root-browser-internal": ["packages/core/root/core-root-browser-internal"],
|
||||
"@kbn/core-root-browser-internal/*": ["packages/core/root/core-root-browser-internal/*"],
|
||||
"@kbn/core-root-server-internal": ["packages/core/root/core-root-server-internal"],
|
||||
"@kbn/core-root-server-internal/*": ["packages/core/root/core-root-server-internal/*"],
|
||||
"@kbn/core-saved-objects-api-browser": ["packages/core/saved-objects/core-saved-objects-api-browser"],
|
||||
"@kbn/core-saved-objects-api-browser/*": ["packages/core/saved-objects/core-saved-objects-api-browser/*"],
|
||||
"@kbn/core-saved-objects-api-server": ["packages/core/saved-objects/core-saved-objects-api-server"],
|
||||
|
|
|
@ -3294,6 +3294,10 @@
|
|||
version "0.0.0"
|
||||
uid ""
|
||||
|
||||
"@kbn/core-root-server-internal@link:bazel-bin/packages/core/root/core-root-server-internal":
|
||||
version "0.0.0"
|
||||
uid ""
|
||||
|
||||
"@kbn/core-saved-objects-api-browser@link:bazel-bin/packages/core/saved-objects/core-saved-objects-api-browser":
|
||||
version "0.0.0"
|
||||
uid ""
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue