Skip to content

Commit

Permalink
Set internal APIs as @internal
Browse files Browse the repository at this point in the history
  • Loading branch information
afharo committed Apr 29, 2021
1 parent 6bfec2e commit cc2e449
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 167 deletions.
165 changes: 1 addition & 164 deletions api_docs/telemetry.json
Original file line number Diff line number Diff line change
Expand Up @@ -359,170 +359,7 @@
},
"server": {
"classes": [],
"functions": [
{
"id": "def-server.getClusterUuids",
"type": "Function",
"children": [
{
"id": "def-server.getClusterUuids.$1",
"type": "Object",
"label": "{ esClient }",
"isRequired": true,
"signature": [
{
"pluginId": "telemetryCollectionManager",
"scope": "server",
"docId": "kibTelemetryCollectionManagerPluginApi",
"section": "def-server.StatsCollectionConfig",
"text": "StatsCollectionConfig"
}
],
"description": [],
"source": {
"path": "src/plugins/telemetry/server/telemetry_collection/get_cluster_stats.ts",
"lineNumber": 26
}
}
],
"signature": [
"({ esClient }: ",
{
"pluginId": "telemetryCollectionManager",
"scope": "server",
"docId": "kibTelemetryCollectionManagerPluginApi",
"section": "def-server.StatsCollectionConfig",
"text": "StatsCollectionConfig"
},
") => Promise<{ clusterUuid: string; }[]>"
],
"description": [
"\nGet the cluster uuids from the connected cluster."
],
"label": "getClusterUuids",
"source": {
"path": "src/plugins/telemetry/server/telemetry_collection/get_cluster_stats.ts",
"lineNumber": 26
},
"tags": [],
"returnComment": [],
"initialIsOpen": false
},
{
"id": "def-server.getLocalStats",
"type": "Function",
"children": [
{
"id": "def-server.getLocalStats.$1",
"type": "Array",
"label": "clustersDetails",
"isRequired": true,
"signature": [
{
"pluginId": "telemetryCollectionManager",
"scope": "server",
"docId": "kibTelemetryCollectionManagerPluginApi",
"section": "def-server.ClusterDetails",
"text": "ClusterDetails"
},
"[]"
],
"description": [],
"source": {
"path": "src/plugins/telemetry/server/telemetry_collection/get_local_stats.ts",
"lineNumber": 63
}
},
{
"id": "def-server.getLocalStats.$2",
"type": "Object",
"label": "config",
"isRequired": true,
"signature": [
{
"pluginId": "telemetryCollectionManager",
"scope": "server",
"docId": "kibTelemetryCollectionManagerPluginApi",
"section": "def-server.StatsCollectionConfig",
"text": "StatsCollectionConfig"
}
],
"description": [],
"source": {
"path": "src/plugins/telemetry/server/telemetry_collection/get_local_stats.ts",
"lineNumber": 64
}
},
{
"id": "def-server.getLocalStats.$3",
"type": "Object",
"label": "context",
"isRequired": true,
"signature": [
{
"pluginId": "telemetryCollectionManager",
"scope": "server",
"docId": "kibTelemetryCollectionManagerPluginApi",
"section": "def-server.StatsCollectionContext",
"text": "StatsCollectionContext"
}
],
"description": [],
"source": {
"path": "src/plugins/telemetry/server/telemetry_collection/get_local_stats.ts",
"lineNumber": 65
}
}
],
"signature": [
"(clustersDetails: ",
{
"pluginId": "telemetryCollectionManager",
"scope": "server",
"docId": "kibTelemetryCollectionManagerPluginApi",
"section": "def-server.ClusterDetails",
"text": "ClusterDetails"
},
"[], config: ",
{
"pluginId": "telemetryCollectionManager",
"scope": "server",
"docId": "kibTelemetryCollectionManagerPluginApi",
"section": "def-server.StatsCollectionConfig",
"text": "StatsCollectionConfig"
},
", context: ",
{
"pluginId": "telemetryCollectionManager",
"scope": "server",
"docId": "kibTelemetryCollectionManagerPluginApi",
"section": "def-server.StatsCollectionContext",
"text": "StatsCollectionContext"
},
") => Promise<{ timestamp: string; cluster_uuid: string; cluster_name: string; version: string; cluster_stats: Pick<{ nodes: { usage: { nodes: ",
{
"pluginId": "telemetry",
"scope": "server",
"docId": "kibTelemetryPluginApi",
"section": "def-server.NodeUsage",
"text": "NodeUsage"
},
"[]; }; count: ",
"ClusterNodeCount"
],
"description": [
"\nGet statistics for all products joined by Elasticsearch cluster."
],
"label": "getLocalStats",
"source": {
"path": "src/plugins/telemetry/server/telemetry_collection/get_local_stats.ts",
"lineNumber": 62
},
"tags": [],
"returnComment": [],
"initialIsOpen": false
}
],
"functions": [],
"interfaces": [
{
"id": "def-server.DataTelemetryBasePayload",
Expand Down
3 changes: 0 additions & 3 deletions api_docs/telemetry.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,6 @@ import telemetryObj from './telemetry.json';
### Start
<DocDefinitionList data={[telemetryObj.server.start]}/>

### Functions
<DocDefinitionList data={telemetryObj.server.functions}/>

### Interfaces
<DocDefinitionList data={telemetryObj.server.interfaces}/>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ export async function getClusterStats(esClient: ElasticsearchClient) {

/**
* Get the cluster uuids from the connected cluster.
* @internal only used externally by the X-Pack Telemetry extension
* @param esClient Scoped Elasticsearch client
*/
export const getClusterUuids: ClusterDetailsGetter = async ({ esClient }) => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ export type TelemetryLocalStats = ReturnType<typeof handleLocalStats>;

/**
* Get statistics for all products joined by Elasticsearch cluster.
* @internal only used externally by the X-Pack Telemetry extension
* @param clustersDetails uuids array of cluster uuid's
* @param config contains the usageCollection, callCluster (deprecated), the esClient and Saved Objects client scoped to the request or the internal repository, and the kibana request
* @param context contains logger and version (string)
Expand Down

0 comments on commit cc2e449

Please sign in to comment.