applicationinsights
Version:
Microsoft Application Insights module for Node.js
34 lines • 1.82 kB
JavaScript
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.
const api_1 = require("@opentelemetry/api");
const applicationinsights_1 = require("./applicationinsights");
class NodeClient extends applicationinsights_1.TelemetryClient {
/**
* Log RequestTelemetry from HTTP request and response. This method will log immediately without waiting for request completion
* and it requires duration parameter to be specified on NodeHttpRequestTelemetry object.
* Use trackNodeHttpRequest function to log the telemetry after request completion
* @param telemetry Object encapsulating incoming request, response and duration information
*/
trackNodeHttpRequestSync(telemetry) {
api_1.diag.warn("trackNodeHttpRequestSync is not implemented and is a no-op.");
}
/**
* Log RequestTelemetry from HTTP request and response. This method will `follow` the request to completion.
* Use trackNodeHttpRequestSync function to log telemetry immediately without waiting for request completion
* @param telemetry Object encapsulating incoming request and response information
*/
trackNodeHttpRequest(telemetry) {
api_1.diag.warn("trackNodeHttpRequest is not implemented and is a no-op.");
}
/**
* Log DependencyTelemetry from outgoing HTTP request. This method will instrument the outgoing request and append
* the specified headers and will log the telemetry when outgoing request is complete
* @param telemetry Object encapsulating outgoing request information
*/
trackNodeHttpDependency(telemetry) {
api_1.diag.warn("trackNodeHttpDependency is not implemented and is a no-op.");
}
}
module.exports = NodeClient;
//# sourceMappingURL=nodeClient.js.map
;