diff --git a/docs/development/core/server/kibana-plugin-core-server.coreconfigusagedata.elasticsearch.md b/docs/development/core/server/kibana-plugin-core-server.coreconfigusagedata.elasticsearch.md new file mode 100644 index 0000000000000..9382b68bac6fa --- /dev/null +++ b/docs/development/core/server/kibana-plugin-core-server.coreconfigusagedata.elasticsearch.md @@ -0,0 +1,33 @@ + + +[Home](./index.md) > [kibana-plugin-core-server](./kibana-plugin-core-server.md) > [CoreConfigUsageData](./kibana-plugin-core-server.coreconfigusagedata.md) > [elasticsearch](./kibana-plugin-core-server.coreconfigusagedata.elasticsearch.md) + +## CoreConfigUsageData.elasticsearch property + +Signature: + +```typescript +elasticsearch: { + sniffOnStart: boolean; + sniffIntervalMs?: number; + sniffOnConnectionFault: boolean; + numberOfHostsConfigured: number; + requestHeadersWhitelistConfigured: boolean; + customHeadersConfigured: boolean; + shardTimeoutMs: number; + requestTimeoutMs: number; + pingTimeoutMs: number; + logQueries: boolean; + ssl: { + verificationMode: 'none' | 'certificate' | 'full'; + certificateAuthoritiesConfigured: boolean; + certificateConfigured: boolean; + keyConfigured: boolean; + keystoreConfigured: boolean; + truststoreConfigured: boolean; + alwaysPresentCertificate: boolean; + }; + apiVersion: string; + healthCheckDelayMs: number; + }; +``` diff --git a/docs/development/core/server/kibana-plugin-core-server.coreconfigusagedata.http.md b/docs/development/core/server/kibana-plugin-core-server.coreconfigusagedata.http.md new file mode 100644 index 0000000000000..1cfbef4992e07 --- /dev/null +++ b/docs/development/core/server/kibana-plugin-core-server.coreconfigusagedata.http.md @@ -0,0 +1,40 @@ + + +[Home](./index.md) > [kibana-plugin-core-server](./kibana-plugin-core-server.md) > [CoreConfigUsageData](./kibana-plugin-core-server.coreconfigusagedata.md) > [http](./kibana-plugin-core-server.coreconfigusagedata.http.md) + +## CoreConfigUsageData.http property + +Signature: + +```typescript +http: { + basePathConfigured: boolean; + maxPayloadInBytes: number; + rewriteBasePath: boolean; + keepaliveTimeout: number; + socketTimeout: number; + compression: { + enabled: boolean; + referrerWhitelistConfigured: boolean; + }; + xsrf: { + disableProtection: boolean; + whitelistConfigured: boolean; + }; + requestId: { + allowFromAnyIp: boolean; + ipAllowlistConfigured: boolean; + }; + ssl: { + certificateAuthoritiesConfigured: boolean; + certificateConfigured: boolean; + cipherSuites: string[]; + keyConfigured: boolean; + keystoreConfigured: boolean; + truststoreConfigured: boolean; + redirectHttpFromPortConfigured: boolean; + supportedProtocols: string[]; + clientAuthentication: 'none' | 'optional' | 'required'; + }; + }; +``` diff --git a/docs/development/core/server/kibana-plugin-core-server.coreconfigusagedata.logging.md b/docs/development/core/server/kibana-plugin-core-server.coreconfigusagedata.logging.md new file mode 100644 index 0000000000000..53961b6169bd1 --- /dev/null +++ b/docs/development/core/server/kibana-plugin-core-server.coreconfigusagedata.logging.md @@ -0,0 +1,14 @@ + + +[Home](./index.md) > [kibana-plugin-core-server](./kibana-plugin-core-server.md) > [CoreConfigUsageData](./kibana-plugin-core-server.coreconfigusagedata.md) > [logging](./kibana-plugin-core-server.coreconfigusagedata.logging.md) + +## CoreConfigUsageData.logging property + +Signature: + +```typescript +logging: { + appendersTypesUsed: string[]; + loggersConfiguredCount: number; + }; +``` diff --git a/docs/development/core/server/kibana-plugin-core-server.coreconfigusagedata.md b/docs/development/core/server/kibana-plugin-core-server.coreconfigusagedata.md new file mode 100644 index 0000000000000..5af673c572945 --- /dev/null +++ b/docs/development/core/server/kibana-plugin-core-server.coreconfigusagedata.md @@ -0,0 +1,23 @@ + + +[Home](./index.md) > [kibana-plugin-core-server](./kibana-plugin-core-server.md) > [CoreConfigUsageData](./kibana-plugin-core-server.coreconfigusagedata.md) + +## CoreConfigUsageData interface + +Usage data on this cluster's configuration of Core features + +Signature: + +```typescript +export interface CoreConfigUsageData +``` + +## Properties + +| Property | Type | Description | +| --- | --- | --- | +| [elasticsearch](./kibana-plugin-core-server.coreconfigusagedata.elasticsearch.md) | {
sniffOnStart: boolean;
sniffIntervalMs?: number;
sniffOnConnectionFault: boolean;
numberOfHostsConfigured: number;
requestHeadersWhitelistConfigured: boolean;
customHeadersConfigured: boolean;
shardTimeoutMs: number;
requestTimeoutMs: number;
pingTimeoutMs: number;
logQueries: boolean;
ssl: {
verificationMode: 'none' | 'certificate' | 'full';
certificateAuthoritiesConfigured: boolean;
certificateConfigured: boolean;
keyConfigured: boolean;
keystoreConfigured: boolean;
truststoreConfigured: boolean;
alwaysPresentCertificate: boolean;
};
apiVersion: string;
healthCheckDelayMs: number;
} | | +| [http](./kibana-plugin-core-server.coreconfigusagedata.http.md) | {
basePathConfigured: boolean;
maxPayloadInBytes: number;
rewriteBasePath: boolean;
keepaliveTimeout: number;
socketTimeout: number;
compression: {
enabled: boolean;
referrerWhitelistConfigured: boolean;
};
xsrf: {
disableProtection: boolean;
whitelistConfigured: boolean;
};
requestId: {
allowFromAnyIp: boolean;
ipAllowlistConfigured: boolean;
};
ssl: {
certificateAuthoritiesConfigured: boolean;
certificateConfigured: boolean;
cipherSuites: string[];
keyConfigured: boolean;
keystoreConfigured: boolean;
truststoreConfigured: boolean;
redirectHttpFromPortConfigured: boolean;
supportedProtocols: string[];
clientAuthentication: 'none' | 'optional' | 'required';
};
} | | +| [logging](./kibana-plugin-core-server.coreconfigusagedata.logging.md) | {
appendersTypesUsed: string[];
loggersConfiguredCount: number;
} | | +| [savedObjects](./kibana-plugin-core-server.coreconfigusagedata.savedobjects.md) | {
maxImportPayloadBytes: number;
maxImportExportSizeBytes: number;
} | | + diff --git a/docs/development/core/server/kibana-plugin-core-server.coreconfigusagedata.savedobjects.md b/docs/development/core/server/kibana-plugin-core-server.coreconfigusagedata.savedobjects.md new file mode 100644 index 0000000000000..cfa02191947af --- /dev/null +++ b/docs/development/core/server/kibana-plugin-core-server.coreconfigusagedata.savedobjects.md @@ -0,0 +1,14 @@ + + +[Home](./index.md) > [kibana-plugin-core-server](./kibana-plugin-core-server.md) > [CoreConfigUsageData](./kibana-plugin-core-server.coreconfigusagedata.md) > [savedObjects](./kibana-plugin-core-server.coreconfigusagedata.savedobjects.md) + +## CoreConfigUsageData.savedObjects property + +Signature: + +```typescript +savedObjects: { + maxImportPayloadBytes: number; + maxImportExportSizeBytes: number; + }; +``` diff --git a/docs/development/core/server/kibana-plugin-core-server.coreenvironmentusagedata.md b/docs/development/core/server/kibana-plugin-core-server.coreenvironmentusagedata.md new file mode 100644 index 0000000000000..6b919c41622bd --- /dev/null +++ b/docs/development/core/server/kibana-plugin-core-server.coreenvironmentusagedata.md @@ -0,0 +1,20 @@ + + +[Home](./index.md) > [kibana-plugin-core-server](./kibana-plugin-core-server.md) > [CoreEnvironmentUsageData](./kibana-plugin-core-server.coreenvironmentusagedata.md) + +## CoreEnvironmentUsageData interface + +Usage data on this Kibana node's runtime environment. + +Signature: + +```typescript +export interface CoreEnvironmentUsageData +``` + +## Properties + +| Property | Type | Description | +| --- | --- | --- | +| [memory](./kibana-plugin-core-server.coreenvironmentusagedata.memory.md) | {
heapTotalBytes: number;
heapUsedBytes: number;
heapSizeLimit: number;
} | | + diff --git a/docs/development/core/server/kibana-plugin-core-server.coreenvironmentusagedata.memory.md b/docs/development/core/server/kibana-plugin-core-server.coreenvironmentusagedata.memory.md new file mode 100644 index 0000000000000..0d3cb6bc5282c --- /dev/null +++ b/docs/development/core/server/kibana-plugin-core-server.coreenvironmentusagedata.memory.md @@ -0,0 +1,15 @@ + + +[Home](./index.md) > [kibana-plugin-core-server](./kibana-plugin-core-server.md) > [CoreEnvironmentUsageData](./kibana-plugin-core-server.coreenvironmentusagedata.md) > [memory](./kibana-plugin-core-server.coreenvironmentusagedata.memory.md) + +## CoreEnvironmentUsageData.memory property + +Signature: + +```typescript +memory: { + heapTotalBytes: number; + heapUsedBytes: number; + heapSizeLimit: number; + }; +``` diff --git a/docs/development/core/server/kibana-plugin-core-server.coreservicesusagedata.md b/docs/development/core/server/kibana-plugin-core-server.coreservicesusagedata.md new file mode 100644 index 0000000000000..af315a3743f47 --- /dev/null +++ b/docs/development/core/server/kibana-plugin-core-server.coreservicesusagedata.md @@ -0,0 +1,20 @@ + + +[Home](./index.md) > [kibana-plugin-core-server](./kibana-plugin-core-server.md) > [CoreServicesUsageData](./kibana-plugin-core-server.coreservicesusagedata.md) + +## CoreServicesUsageData interface + +Usage data from Core services + +Signature: + +```typescript +export interface CoreServicesUsageData +``` + +## Properties + +| Property | Type | Description | +| --- | --- | --- | +| [savedObjects](./kibana-plugin-core-server.coreservicesusagedata.savedobjects.md) | {
indices: {
alias: string;
docsCount: number;
docsDeleted: number;
storeSizeBytes: number;
primaryStoreSizeBytes: number;
}[];
} | | + diff --git a/docs/development/core/server/kibana-plugin-core-server.coreservicesusagedata.savedobjects.md b/docs/development/core/server/kibana-plugin-core-server.coreservicesusagedata.savedobjects.md new file mode 100644 index 0000000000000..047c730501086 --- /dev/null +++ b/docs/development/core/server/kibana-plugin-core-server.coreservicesusagedata.savedobjects.md @@ -0,0 +1,19 @@ + + +[Home](./index.md) > [kibana-plugin-core-server](./kibana-plugin-core-server.md) > [CoreServicesUsageData](./kibana-plugin-core-server.coreservicesusagedata.md) > [savedObjects](./kibana-plugin-core-server.coreservicesusagedata.savedobjects.md) + +## CoreServicesUsageData.savedObjects property + +Signature: + +```typescript +savedObjects: { + indices: { + alias: string; + docsCount: number; + docsDeleted: number; + storeSizeBytes: number; + primaryStoreSizeBytes: number; + }[]; + }; +``` diff --git a/docs/development/core/server/kibana-plugin-core-server.md b/docs/development/core/server/kibana-plugin-core-server.md index be8b7c27495ad..b65c155705f27 100644 --- a/docs/development/core/server/kibana-plugin-core-server.md +++ b/docs/development/core/server/kibana-plugin-core-server.md @@ -67,6 +67,9 @@ The plugin integrates with the core system via lifecycle events: `setup` | [CapabilitiesSetup](./kibana-plugin-core-server.capabilitiessetup.md) | APIs to manage the [Capabilities](./kibana-plugin-core-server.capabilities.md) that will be used by the application.Plugins relying on capabilities to toggle some of their features should register them during the setup phase using the registerProvider method.Plugins having the responsibility to restrict capabilities depending on a given context should register their capabilities switcher using the registerSwitcher method.Refers to the methods documentation for complete description and examples. | | [CapabilitiesStart](./kibana-plugin-core-server.capabilitiesstart.md) | APIs to access the application [Capabilities](./kibana-plugin-core-server.capabilities.md). | | [ContextSetup](./kibana-plugin-core-server.contextsetup.md) | An object that handles registration of context providers and configuring handlers with context. | +| [CoreConfigUsageData](./kibana-plugin-core-server.coreconfigusagedata.md) | Usage data on this cluster's configuration of Core features | +| [CoreEnvironmentUsageData](./kibana-plugin-core-server.coreenvironmentusagedata.md) | Usage data on this Kibana node's runtime environment. | +| [CoreServicesUsageData](./kibana-plugin-core-server.coreservicesusagedata.md) | Usage data from Core services | | [CoreSetup](./kibana-plugin-core-server.coresetup.md) | Context passed to the plugins setup method. | | [CoreStart](./kibana-plugin-core-server.corestart.md) | Context passed to the plugins start method. | | [CoreStatus](./kibana-plugin-core-server.corestatus.md) | Status of core services. | diff --git a/src/core/server/core_usage_data/core_usage_data_service.mock.ts b/src/core/server/core_usage_data/core_usage_data_service.mock.ts index f59d172ef32f1..c443ce72f5ed7 100644 --- a/src/core/server/core_usage_data/core_usage_data_service.mock.ts +++ b/src/core/server/core_usage_data/core_usage_data_service.mock.ts @@ -117,10 +117,6 @@ const createStartContractMock = () => { heapTotalBytes: 1, heapUsedBytes: 1, }, - os: { - platform: 'darwin', - platformRelease: 'test', - }, }, services: { savedObjects: { @@ -128,7 +124,7 @@ const createStartContractMock = () => { { docsCount: 1, docsDeleted: 1, - name: 'test_index', + alias: 'test_index', primaryStoreSizeBytes: 1, storeSizeBytes: 1, }, diff --git a/src/core/server/core_usage_data/core_usage_data_service.test.ts b/src/core/server/core_usage_data/core_usage_data_service.test.ts index 716bc72f7992a..a664f6514e9c8 100644 --- a/src/core/server/core_usage_data/core_usage_data_service.test.ts +++ b/src/core/server/core_usage_data/core_usage_data_service.test.ts @@ -68,10 +68,38 @@ describe('CoreUsageDataService', () => { it('returns core metrics for default config', () => { const metrics = metricsServiceMock.createInternalSetupContract(); service.setup({ metrics }); + const elasticsearch = elasticsearchServiceMock.createStart(); + elasticsearch.client.asInternalUser.cat.indices.mockResolvedValueOnce({ + body: [ + { + name: '.kibana_task_manager_1', + 'docs.count': 10, + 'docs.deleted': 10, + 'store.size': 1000, + 'pri.store.size': 2000, + }, + ], + } as any); + elasticsearch.client.asInternalUser.cat.indices.mockResolvedValueOnce({ + body: [ + { + name: '.kibana_1', + 'docs.count': 20, + 'docs.deleted': 20, + 'store.size': 2000, + 'pri.store.size': 4000, + }, + ], + } as any); + const typeRegistry = savedObjectsServiceMock.createTypeRegistryMock(); + typeRegistry.getAllTypes.mockReturnValue([ + { name: 'type 1', indexPattern: '.kibana' }, + { name: 'type 2', indexPattern: '.kibana_task_manager' }, + ] as any); const { getCoreUsageData } = service.start({ - savedObjects: savedObjectsServiceMock.createInternalStartContract(), - elasticsearch: elasticsearchServiceMock.createStart(), + savedObjects: savedObjectsServiceMock.createInternalStartContract(typeRegistry), + elasticsearch, }); expect(getCoreUsageData()).resolves.toMatchInlineSnapshot(` Object { @@ -169,16 +197,25 @@ describe('CoreUsageDataService', () => { "heapTotalBytes": 1, "heapUsedBytes": 1, }, - "os": Object { - "distro": undefined, - "distroRelease": undefined, - "platform": "darwin", - "platformRelease": "test", - }, }, "services": Object { "savedObjects": Object { - "indices": Array [], + "indices": Array [ + Object { + "alias": ".kibana", + "docsCount": 10, + "docsDeleted": 10, + "primaryStoreSizeBytes": 2000, + "storeSizeBytes": 1000, + }, + Object { + "alias": ".kibana_task_manager", + "docsCount": 20, + "docsDeleted": 20, + "primaryStoreSizeBytes": 4000, + "storeSizeBytes": 2000, + }, + ], }, }, } diff --git a/src/core/server/core_usage_data/core_usage_data_service.ts b/src/core/server/core_usage_data/core_usage_data_service.ts index 3c98b828818a3..f729e23cb68bc 100644 --- a/src/core/server/core_usage_data/core_usage_data_service.ts +++ b/src/core/server/core_usage_data/core_usage_data_service.ts @@ -42,6 +42,24 @@ export interface StartDeps { elasticsearch: ElasticsearchServiceStart; } +/** + * Because users can configure their Saved Object to any arbitrary index name, + * we need to map customized index names back to a "standard" index name. + * + * e.g. If a user configures `kibana.index: .my_saved_objects` we want to the + * collected data to be grouped under `.kibana` not ".my_saved_objects". + * + * This is rather brittle, but the option to configure index names might go + * away completely anyway (see #60053). + * + * @param index The index name configured for this SO type + * @param kibanaConfigIndex The default kibana index as configured by the user + * with `kibana.index` + */ +const kibanaOrTaskManagerIndex = (index: string, kibanaConfigIndex: string) => { + return index === kibanaConfigIndex ? '.kibana' : '.kibana_task_manager'; +}; + export class CoreUsageDataService implements CoreService { private elasticsearchConfig?: ElasticsearchConfigType; private configService: CoreContext['configService']; @@ -67,32 +85,28 @@ export class CoreUsageDataService implements CoreService { - // TODO: Let the registry return `kibana.index` instead of reading - // the config value here. - const index = - savedObjects.getTypeRegistry().getIndex(type.name) || this.kibanaConfig!.index; + const index = type.indexPattern ?? this.kibanaConfig!.index; return index != null ? acc.add(index) : acc; }, new Set()) .values() - ).map((alias) => { + ).map((index) => { // The _cat/indices API returns the _index_ and doesn't return a way // to map back from the index to the alias. So we have to make an API // call for every alias return elasticsearch.client.asInternalUser.cat .indices({ - index: alias, + index, format: 'JSON', bytes: 'b', }) .then(({ body }) => { - const index = body[0]; + const stats = body[0]; return { - name: index.index, - alias, - docsCount: index['docs.count'], - docsDeleted: index['docs.deleted'], - storeSizeBytes: index['store.size'], - primaryStoreSizeBytes: index['pri.store.size'], + alias: kibanaOrTaskManagerIndex(index, this.kibanaConfig!.index), + docsCount: stats['docs.count'], + docsDeleted: stats['docs.deleted'], + storeSizeBytes: stats['store.size'], + primaryStoreSizeBytes: stats['pri.store.size'], }; }); }) @@ -207,12 +221,6 @@ export class CoreUsageDataService implements CoreService types + // so we have to disable eslint here and use {...}[] // eslint-disable-next-line @typescript-eslint/array-type indices: { - name: string; + alias: string; docsCount: number; docsDeleted: number; storeSizeBytes: number; @@ -54,12 +55,6 @@ export interface CoreEnvironmentUsageData { /** V8 heap size limit */ heapSizeLimit: number; }; - os: { - platform: string; - platformRelease: string; - distro?: string; - distroRelease?: string; - }; } /** diff --git a/src/core/server/saved_objects/saved_objects_service.mock.ts b/src/core/server/saved_objects/saved_objects_service.mock.ts index bd76658c21731..c56cdabf6e4cd 100644 --- a/src/core/server/saved_objects/saved_objects_service.mock.ts +++ b/src/core/server/saved_objects/saved_objects_service.mock.ts @@ -33,10 +33,11 @@ import { savedObjectsClientMock } from './service/saved_objects_client.mock'; import { typeRegistryMock } from './saved_objects_type_registry.mock'; import { migrationMocks } from './migrations/mocks'; import { ServiceStatusLevels } from '../status'; +import { ISavedObjectTypeRegistry } from './saved_objects_type_registry'; type SavedObjectsServiceContract = PublicMethodsOf; -const createStartContractMock = () => { +const createStartContractMock = (typeRegistry?: jest.Mocked) => { const startContrat: jest.Mocked = { getScopedClient: jest.fn(), createInternalRepository: jest.fn(), @@ -48,13 +49,15 @@ const createStartContractMock = () => { startContrat.getScopedClient.mockReturnValue(savedObjectsClientMock.create()); startContrat.createInternalRepository.mockReturnValue(savedObjectsRepositoryMock.create()); startContrat.createScopedRepository.mockReturnValue(savedObjectsRepositoryMock.create()); - startContrat.getTypeRegistry.mockReturnValue(typeRegistryMock.create()); + startContrat.getTypeRegistry.mockReturnValue(typeRegistry ?? typeRegistryMock.create()); return startContrat; }; -const createInternalStartContractMock = () => { - const internalStartContract: jest.Mocked = createStartContractMock(); +const createInternalStartContractMock = (typeRegistry?: jest.Mocked) => { + const internalStartContract: jest.Mocked = createStartContractMock( + typeRegistry + ); return internalStartContract; }; diff --git a/src/core/server/server.api.md b/src/core/server/server.api.md index f0f91c14f3220..6b4cecd0b0ec0 100644 --- a/src/core/server/server.api.md +++ b/src/core/server/server.api.md @@ -401,9 +401,108 @@ export interface ContextSetup { createContextContainer>(): IContextContainer; } +// Warning: (ae-missing-release-tag) "CoreConfigUsageData" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) +// +// @public +export interface CoreConfigUsageData { + // (undocumented) + elasticsearch: { + sniffOnStart: boolean; + sniffIntervalMs?: number; + sniffOnConnectionFault: boolean; + numberOfHostsConfigured: number; + requestHeadersWhitelistConfigured: boolean; + customHeadersConfigured: boolean; + shardTimeoutMs: number; + requestTimeoutMs: number; + pingTimeoutMs: number; + logQueries: boolean; + ssl: { + verificationMode: 'none' | 'certificate' | 'full'; + certificateAuthoritiesConfigured: boolean; + certificateConfigured: boolean; + keyConfigured: boolean; + keystoreConfigured: boolean; + truststoreConfigured: boolean; + alwaysPresentCertificate: boolean; + }; + apiVersion: string; + healthCheckDelayMs: number; + }; + // (undocumented) + http: { + basePathConfigured: boolean; + maxPayloadInBytes: number; + rewriteBasePath: boolean; + keepaliveTimeout: number; + socketTimeout: number; + compression: { + enabled: boolean; + referrerWhitelistConfigured: boolean; + }; + xsrf: { + disableProtection: boolean; + whitelistConfigured: boolean; + }; + requestId: { + allowFromAnyIp: boolean; + ipAllowlistConfigured: boolean; + }; + ssl: { + certificateAuthoritiesConfigured: boolean; + certificateConfigured: boolean; + cipherSuites: string[]; + keyConfigured: boolean; + keystoreConfigured: boolean; + truststoreConfigured: boolean; + redirectHttpFromPortConfigured: boolean; + supportedProtocols: string[]; + clientAuthentication: 'none' | 'optional' | 'required'; + }; + }; + // (undocumented) + logging: { + appendersTypesUsed: string[]; + loggersConfiguredCount: number; + }; + // (undocumented) + savedObjects: { + maxImportPayloadBytes: number; + maxImportExportSizeBytes: number; + }; +} + +// Warning: (ae-missing-release-tag) "CoreEnvironmentUsageData" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) +// +// @public +export interface CoreEnvironmentUsageData { + // (undocumented) + memory: { + heapTotalBytes: number; + heapUsedBytes: number; + heapSizeLimit: number; + }; +} + // @internal (undocumented) export type CoreId = symbol; +// Warning: (ae-missing-release-tag) "CoreServicesUsageData" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) +// +// @public +export interface CoreServicesUsageData { + // (undocumented) + savedObjects: { + indices: { + alias: string; + docsCount: number; + docsDeleted: number; + storeSizeBytes: number; + primaryStoreSizeBytes: number; + }[]; + }; +} + // @public export interface CoreSetup { // (undocumented) @@ -462,16 +561,10 @@ export interface CoreStatus { // @internal export interface CoreUsageData { - // Warning: (ae-forgotten-export) The symbol "CoreConfigUsageData" needs to be exported by the entry point index.d.ts - // // (undocumented) config: CoreConfigUsageData; - // Warning: (ae-forgotten-export) The symbol "CoreEnvironmentUsageData" needs to be exported by the entry point index.d.ts - // // (undocumented) environment: CoreEnvironmentUsageData; - // Warning: (ae-forgotten-export) The symbol "CoreServicesUsageData" needs to be exported by the entry point index.d.ts - // // (undocumented) services: CoreServicesUsageData; } diff --git a/src/plugins/kibana_usage_collection/server/collectors/core/core_usage_collector.ts b/src/plugins/kibana_usage_collection/server/collectors/core/core_usage_collector.ts index 129e547481d90..297baf016e9e6 100644 --- a/src/plugins/kibana_usage_collection/server/collectors/core/core_usage_collector.ts +++ b/src/plugins/kibana_usage_collection/server/collectors/core/core_usage_collector.ts @@ -100,12 +100,6 @@ export function getCoreUsageCollector( heapTotalBytes: { type: 'long' }, heapUsedBytes: { type: 'long' }, }, - os: { - distro: { type: 'keyword' }, - distroRelease: { type: 'keyword' }, - platform: { type: 'keyword' }, - platformRelease: { type: 'keyword' }, - }, }, services: { savedObjects: { @@ -114,7 +108,7 @@ export function getCoreUsageCollector( items: { docsCount: { type: 'long' }, docsDeleted: { type: 'long' }, - name: { type: 'text' }, + alias: { type: 'text' }, primaryStoreSizeBytes: { type: 'long' }, storeSizeBytes: { type: 'long' }, },