Skip to content

Commit

Permalink
[APM] Read body from indicesStats in upload-telemetry-data (#72732)
Browse files Browse the repository at this point in the history
add for transport request too
  • Loading branch information
smith authored Jul 26, 2020
1 parent ff9f06b commit 55f55bf
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions x-pack/plugins/apm/scripts/upload-telemetry-data/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -87,13 +87,15 @@ async function uploadData() {
return client.search(body as any).then((res) => res.body);
},
indicesStats: (body) => {
return client.indices.stats(body as any);
return client.indices.stats(body as any).then((res) => res.body);
},
transportRequest: ((params) => {
return client.transport.request({
method: params.method,
path: params.path,
});
return client.transport
.request({
method: params.method,
path: params.path,
})
.then((res) => res.body);
}) as CollectTelemetryParams['transportRequest'],
},
});
Expand Down

0 comments on commit 55f55bf

Please sign in to comment.