Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: microsoft/ApplicationInsights-node.js
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 2.2.0
Choose a base ref
...
head repository: microsoft/ApplicationInsights-node.js
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 2.2.1
Choose a head ref
  • 15 commits
  • 79 files changed
  • 5 contributors

Commits on Jan 14, 2022

  1. Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    1be9b92 View commit details

Commits on Jan 24, 2022

  1. Add path to http dependency when host is missing (#885)

    * Add path to http dependency when host is missing
    
    * Add test for http dependency without a host
    
    Co-authored-by: Foysal Mohammed <m.foysal@kainos.com>
    MohammedFoysal and Foysal Mohammed authored Jan 24, 2022

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    38b2430 View commit details
  2. Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    8d2f43a View commit details
  3. Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    7682993 View commit details

Commits on Jan 28, 2022

  1. Update deprecated dependencies (#893)

    * Update deprecated dependencies
    
    * Clean before running tests
    
    * Update api version
    
    * Use api 1.0.1 to avoid issues with OTel core
    hectorhdzg authored Jan 28, 2022

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    d1d2a5c View commit details
  2. build(deps): bump node-fetch from 2.6.6 to 2.6.7 (#894)

    Bumps [node-fetch](https://github.com/node-fetch/node-fetch) from 2.6.6 to 2.6.7.
    - [Release notes](https://github.com/node-fetch/node-fetch/releases)
    - [Commits](node-fetch/node-fetch@v2.6.6...v2.6.7)
    
    ---
    updated-dependencies:
    - dependency-name: node-fetch
      dependency-type: indirect
    ...
    
    Signed-off-by: dependabot[bot] <support@github.com>
    
    Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
    dependabot[bot] authored Jan 28, 2022

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    5f3e1ca View commit details

Commits on Feb 2, 2022

  1. Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    70143b0 View commit details
  2. Ignore github files in npm package (#895)

    Co-authored-by: Hector Hernandez <39923391+hectorhdzg@users.noreply.github.com>
    orgads and hectorhdzg authored Feb 2, 2022

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    db69fa5 View commit details
  3. Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    11651f5 View commit details
  4. 2.2.1 release (#900)

    * 2.2.1 release
    
    * Updated constant
    hectorhdzg authored Feb 2, 2022

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    a160abb View commit details

Commits on Feb 7, 2022

  1. Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    d03bc8c View commit details

Commits on Feb 8, 2022

  1. Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    6a10cd5 View commit details
  2. Add eslint validation (#905)

    * Add eslint validation
    
    * Fix
    
    * Update dependencies
    
    * Run only on node 14
    
    * WIP
    hectorhdzg authored Feb 8, 2022

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    2763731 View commit details

Commits on Feb 10, 2022

  1. Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    48f1281 View commit details

Commits on Feb 15, 2022

  1. Statsbeat do not count failed request when throttle (#911)

    * Statsbeat do not count failed request when throttle
    
    * Fix responde code for throttling
    
    * Add new status code handling
    hectorhdzg authored Feb 15, 2022

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    811975d View commit details
Showing with 6,535 additions and 560 deletions.
  1. +3 −0 .eslintignore
  2. +41 −0 .eslintrc
  3. +9 −0 .github/codeql/codeql-config.yml
  4. +72 −0 .github/workflows/codeql-analysis.yml
  5. +1 −0 .github/workflows/node.js.yml
  6. +1 −0 .npmignore
  7. +2 −0 .travis.yml
  8. +11 −3 AutoCollection/AsyncHooksScopeManager.ts
  9. +0 −1 AutoCollection/Console.ts
  10. +36 −34 AutoCollection/CorrelationContextManager.ts
  11. +1 −6 AutoCollection/Exceptions.ts
  12. +7 −7 AutoCollection/HttpDependencies.ts
  13. +31 −8 AutoCollection/HttpDependencyParser.ts
  14. +7 −3 AutoCollection/HttpRequestParser.ts
  15. +6 −6 AutoCollection/HttpRequests.ts
  16. +4 −4 AutoCollection/NativePerformance.ts
  17. +9 −9 AutoCollection/Performance.ts
  18. +12 −12 AutoCollection/PreAggregatedMetrics.ts
  19. +55 −54 AutoCollection/Statsbeat.ts
  20. +1 −1 AutoCollection/diagnostic-channel/Azure/EventHub.ts
  21. +11 −5 AutoCollection/diagnostic-channel/SpanParser.ts
  22. +10 −11 AutoCollection/diagnostic-channel/azure-coretracing.sub.ts
  23. +12 −12 AutoCollection/diagnostic-channel/bunyan.sub.ts
  24. +8 −10 AutoCollection/diagnostic-channel/console.sub.ts
  25. +0 −1 AutoCollection/diagnostic-channel/initialization.ts
  26. +9 −11 AutoCollection/diagnostic-channel/mongodb.sub.ts
  27. +8 −10 AutoCollection/diagnostic-channel/mysql.sub.ts
  28. +8 −10 AutoCollection/diagnostic-channel/postgres.sub.ts
  29. +8 −10 AutoCollection/diagnostic-channel/redis.sub.ts
  30. +8 −10 AutoCollection/diagnostic-channel/winston.sub.ts
  31. +1 −1 Bootstrap/DataModel.ts
  32. +2 −2 Bootstrap/Default.ts
  33. +2 −2 Bootstrap/DiagnosticLogger.ts
  34. +9 −9 Declarations/Constants.ts
  35. +1 −1 Declarations/Contracts/Generated/AvailabilityData.ts
  36. +2 −2 Declarations/Contracts/Generated/ContextTagKeys.ts
  37. +1 −1 Declarations/Contracts/Generated/Data.ts
  38. +1 −1 Declarations/Contracts/Generated/DataPoint.ts
  39. +1 −1 Declarations/Contracts/Generated/Envelope.ts
  40. +1 −1 Declarations/Contracts/Generated/EventData.ts
  41. +3 −3 Declarations/Contracts/Generated/ExceptionData.ts
  42. +1 −1 Declarations/Contracts/Generated/ExceptionDetails.ts
  43. +2 −2 Declarations/Contracts/Generated/MessageData.ts
  44. +2 −2 Declarations/Contracts/Generated/MetricData.ts
  45. +1 −1 Declarations/Contracts/Generated/PageViewData.ts
  46. +1 −1 Declarations/Contracts/Generated/RemoteDependencyData.ts
  47. +1 −1 Declarations/Contracts/Generated/RequestData.ts
  48. +1 −1 Declarations/Contracts/QuickPulseTypes/DocumentQuickPulse.ts
  49. +1 −1 Declarations/Contracts/TelemetryTypes/TelemetryType.ts
  50. +1 −1 Declarations/Contracts/TelemetryTypes/TraceTelemetry.ts
  51. +11 −11 Declarations/Interfaces.ts
  52. +1 −1 Declarations/Metrics/AggregatedMetricDimensions.ts
  53. +0 −1 Library/AuthorizationHandler.ts
  54. +5 −5 Library/AzureVirtualMachine.ts
  55. +1 −1 Library/Channel.ts
  56. +9 −9 Library/Config.ts
  57. +14 −14 Library/CorrelationIdManager.ts
  58. +22 −19 Library/EnvelopeFactory.ts
  59. +5 −3 Library/FileAccessControl.ts
  60. +2 −2 Library/InternalAzureLogger.ts
  61. +1 −1 Library/JsonConfig.ts
  62. +1 −1 Library/NodeClient.ts
  63. +4 −4 Library/QuickPulseEnvelopeFactory.ts
  64. +7 −7 Library/QuickPulseSender.ts
  65. +6 −3 Library/QuickPulseStateManager.ts
  66. +24 −18 Library/Sender.ts
  67. +1 −1 Library/TelemetryClient.ts
  68. +17 −15 Library/Util.ts
  69. +5 −5 TelemetryProcessors/PreAggregatedMetricsTelemetryProcessor.ts
  70. +23 −23 Tests/AutoCollection/CorrelationContextManager.tests.ts
  71. +20 −0 Tests/AutoCollection/HttpDependencyParser.tests.ts
  72. +1 −1 Tests/AutoCollection/SpanParser.tests.ts
  73. +1 −1 Tests/AutoCollection/azure-coretracing.tests.ts
  74. +2 −2 Tests/FunctionalTests/TestApp/package.json
  75. +21 −0 Tests/Library/EnvelopeFactoryTests.ts
  76. +36 −1 Tests/Library/QuickPulseStateManager.tests.ts
  77. +3 −2 Tests/Library/Sender.tests.ts
  78. +5,847 −126 package-lock.json
  79. +19 −10 package.json
3 changes: 3 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
**/*.js
/out
/Tests
41 changes: 41 additions & 0 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
{
"env": {
"browser": true,
"es2021": true
},
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/recommended",
"plugin:security/recommended"
],
"plugins": [
"security"
],
"rules": {
"quotes": ["warn", "double"], // Enabled for auto fixing
"prefer-const": "off",
"prefer-spread": "off",
"no-var": "off",
"no-extra-boolean-cast": "off",
"prefer-rest-params": "off",
"no-case-declarations": "off",
"no-prototype-builtins": "off",
"no-useless-escape": "off", // Suppressing Error -- need to Review Later
"no-trailing-spaces": [ "warn", { "skipBlankLines": true }],// Enabled for auto fixing
"no-const-assign": "error",
"comma-dangle": [ "error", "never" ], // Enabled for auto fixing
"security/detect-object-injection": "off", // Suppress Warning -- need to Review Later
"@typescript-eslint/ban-types": "off",
"@typescript-eslint/no-unused-vars": [ "warn", { "vars": "all", "args": "none", "argsIgnorePattern": "^_", "ignoreRestSiblings": true } ],
"@typescript-eslint/triple-slash-reference": "off",
"@typescript-eslint/no-inferrable-types": "off",
"@typescript-eslint/no-this-alias": "off",
"@typescript-eslint/no-explicit-any": "off",
"@typescript-eslint/no-empty-function": "off",
"@typescript-eslint/no-empty-interface": "off",
"@typescript-eslint/no-var-requires": "off",
"@typescript-eslint/explicit-module-boundary-types": "off",
"@typescript-eslint/no-extra-semi": "error", // Enabled for auto fixing
"@typescript-eslint/no-non-null-assertion": "error"
}
}
9 changes: 9 additions & 0 deletions .github/codeql/codeql-config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
name: "CodeQL config"

queries:
- uses: security-and-quality

paths-ignore:
- '**/Tests/'
- '**/Schema/'
- '**/out/'
72 changes: 72 additions & 0 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
# For most projects, this workflow file will not need changing; you simply need
# to commit it to your repository.
#
# You may wish to alter this file to override the set of languages analyzed,
# or to provide custom queries or build logic.
#
# ******** NOTE ********
# We have attempted to detect the languages in your repository. Please check
# the `language` matrix defined below to confirm you have the correct set of
# supported CodeQL languages.
#
name: "CodeQL"

on:
push:
branches: [ master ]
pull_request:
# The branches below must be a subset of the branches above
branches: [ master ]
schedule:
- cron: '17 15 * * 2'

jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write

strategy:
fail-fast: false
matrix:
language: [ 'javascript' ]
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python' ]
# Learn more:
# https://docs.github.com/en/free-pro-team@latest/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#changing-the-languages-that-are-analyzed

steps:
- name: Checkout repository
uses: actions/checkout@v2

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
with:
languages: ${{ matrix.language }}
config-file: ./.github/codeql/codeql-config.yml
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.
# queries: ./path/to/local/query, your-org/your-repo/queries@main

# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v1

# ℹ️ Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl

# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
# and modify them (or add more) to build your code if your project
# uses a compiled language

#- run: |
# make bootstrap
# make release

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
1 change: 1 addition & 0 deletions .github/workflows/node.js.yml
Original file line number Diff line number Diff line change
@@ -24,4 +24,5 @@ jobs:
node-version: ${{ matrix.node-version }}
- run: npm ci
- run: npm run build --if-present
- run: if [[ ${{ matrix.node-version }} == 14 ]]; then npm run lint; fi;
- run: npm test
1 change: 1 addition & 0 deletions .npmignore
Original file line number Diff line number Diff line change
@@ -7,6 +7,7 @@ obj
*.sln
*.njsproj
.vscode/
.github

# Ignore test files
Tests
2 changes: 2 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -17,6 +17,8 @@ before_install:
- npm uninstall applicationinsights-native-metrics --save-dev
- if [ "$TRAVIS_EXTENDED_METRICS" = "true" ]; then npm install applicationinsights-native-metrics --save-optional || true; fi
script:
- npm clean
# Build and test
- npm test
# Run funcs for LTS releases (currently 6, 8, 10) + current release (12)
- if [ "$TRAVIS_NODE_VERSION" = "12" ]; then npm run functionaltest; fi
14 changes: 11 additions & 3 deletions AutoCollection/AsyncHooksScopeManager.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { SpanContext } from "@opentelemetry/api";
import { Span } from "@opentelemetry/tracing";
import { Span } from "@opentelemetry/sdk-trace-base";

import { CorrelationContextManager, CorrelationContext } from "./CorrelationContextManager"
import { EventEmitter } from "events";
@@ -55,12 +55,20 @@ export class OpenTelemetryScopeManagerWrapper {

private static _spanToContext(span: Span, parentSpanId?: string, name?: string): CorrelationContext {
const spanContext = span.spanContext ? span.spanContext() : (<any>span).context(); // context is available in OT API <v0.19.0
const _parentId = parentSpanId ? `|${spanContext.traceId}.${parentSpanId}.` : spanContext.traceId;
const context: SpanContext = {
...span.spanContext(),
traceFlags: span.spanContext().traceFlags
};
const correlationContext = CorrelationContextManager.spanToContextObject(context, _parentId, name)
let parentId = parentSpanId ? `|${spanContext.traceId}.${parentSpanId}.` : spanContext.traceId;
const aiContext = CorrelationContextManager.getCurrentContext();
if (aiContext) {
context.traceId = aiContext.operation.id;
// If parent is no available use current context
if (!parentSpanId) {
parentId = aiContext.operation.parentId;
}
}
const correlationContext = CorrelationContextManager.spanToContextObject(context, parentId, name)
return correlationContext;
}
}
1 change: 0 additions & 1 deletion AutoCollection/Console.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import TelemetryClient = require("../Library/TelemetryClient");
import Logging = require("../Library/Logging");

import * as DiagChannel from "./diagnostic-channel/initialization";

70 changes: 36 additions & 34 deletions AutoCollection/CorrelationContextManager.ts
Original file line number Diff line number Diff line change
@@ -11,6 +11,7 @@ import Traceparent = require("../Library/Traceparent");
import Tracestate = require("../Library/Tracestate");
import HttpRequestParser = require("./HttpRequestParser");
import { SpanContext } from "@opentelemetry/api";
import { Span } from "@opentelemetry/sdk-trace-base";

export interface CustomProperties {
/**
@@ -52,7 +53,7 @@ export class CorrelationContextManager {
private static forceClsHooked: boolean = undefined; // true: use cls-hooked, false: use cls, undefined: choose based on node version
private static session: cls.Namespace;
private static cls: typeof cls;
private static CONTEXT_NAME = "ApplicationInsights-Context"
private static CONTEXT_NAME = "ApplicationInsights-Context";

/**
* Provides the current Context.
@@ -93,7 +94,7 @@ export class CorrelationContextManager {
return null;
}

public static spanToContextObject(spanContext: SpanContext, parentId?: string, name?: string) {
public static spanToContextObject(spanContext: SpanContext, parentId?: string, name?: string): CorrelationContext {
const traceContext = new Traceparent();
traceContext.traceId = spanContext.traceId;
traceContext.spanId = spanContext.spanId;
@@ -158,9 +159,9 @@ export class CorrelationContextManager {

if (typeof this.cls === "undefined") {
if ((CorrelationContextManager.forceClsHooked === true) || (CorrelationContextManager.forceClsHooked === undefined && CorrelationContextManager.shouldUseClsHooked())) {
this.cls = require('cls-hooked');
this.cls = require("cls-hooked");
} else {
this.cls = require('continuation-local-storage');
this.cls = require("continuation-local-storage");
}
}

@@ -174,45 +175,46 @@ export class CorrelationContextManager {
this.enabled = true;
}

public static startOperation(context: azureFunctionsTypes.Context | (http.IncomingMessage | azureFunctionsTypes.HttpRequest) | SpanContext, request?: azureFunctionsTypes.HttpRequest | string): CorrelationContext | null {
const traceContext = context && (context as azureFunctionsTypes.Context).traceContext || null;
const spanContext = context && (context as SpanContext).traceId
? context as SpanContext
: null;
const headers = context && (context as http.IncomingMessage | azureFunctionsTypes.HttpRequest).headers;
/**
* Create new correlation context.
*/
public static startOperation(
input: azureFunctionsTypes.Context | (http.IncomingMessage | azureFunctionsTypes.HttpRequest) | SpanContext | Span,
request?: azureFunctionsTypes.HttpRequest | string)
: CorrelationContext | null {
const traceContext = input && (input as azureFunctionsTypes.Context).traceContext || null;
const span = input && (input as Span).spanContext ? input as Span : null;
const spanContext = input && (input as SpanContext).traceId ? input as SpanContext : null;
const headers = input && (input as http.IncomingMessage | azureFunctionsTypes.HttpRequest).headers;

// OpenTelemetry Span
if (span) {
return this.spanToContextObject(span.spanContext(), span.parentSpanId, span.name);
}

// OpenTelemetry SpanContext
if (spanContext) {
const traceparent = new Traceparent(`00-${spanContext.traceId}-${spanContext.spanId}-01`);
const tracestate = new Tracestate(spanContext.traceState ? spanContext.traceState.serialize() : null);
const correlationContext = CorrelationContextManager.generateContextObject(
spanContext.traceId,
`|${spanContext.traceId}.${spanContext.spanId}.`,
typeof request === "string" ? request : "",
undefined,
traceparent,
tracestate,
);
return correlationContext;
return this.spanToContextObject(spanContext, `|${spanContext.traceId}.${spanContext.spanId}.`, typeof request === "string" ? request : "");
}

// AzFunction TraceContext available
// AzFunction TraceContext
if (traceContext) {
let traceparent = null;
let tracestate = null;
if ( (request as azureFunctionsTypes.HttpRequest).headers ) {
if( (request as azureFunctionsTypes.HttpRequest).headers.traceparent ) {
if ((request as azureFunctionsTypes.HttpRequest).headers) {
if ((request as azureFunctionsTypes.HttpRequest).headers.traceparent) {
traceparent = new Traceparent((request as azureFunctionsTypes.HttpRequest).headers.traceparent);
} else if ( (request as azureFunctionsTypes.HttpRequest).headers["request-id"] ) {
} else if ((request as azureFunctionsTypes.HttpRequest).headers["request-id"]) {
traceparent = new Traceparent(null, (request as azureFunctionsTypes.HttpRequest).headers["request-id"]);
}
if( (request as azureFunctionsTypes.HttpRequest).headers.tracestate ) {
if ((request as azureFunctionsTypes.HttpRequest).headers.tracestate) {
tracestate = new Tracestate((request as azureFunctionsTypes.HttpRequest).headers.tracestate);
}
}
if( !traceparent ) {
if (!traceparent) {
traceparent = new Traceparent(traceContext.traceparent);
}
if( !tracestate ) {
if (!tracestate) {
tracestate = new Tracestate(traceContext.tracestate);
}
const parser = typeof request === "object"
@@ -226,7 +228,7 @@ export class CorrelationContextManager {
: parser.getOperationName({}),
parser && parser.getCorrelationContextHeader() || undefined,
traceparent,
tracestate,
tracestate
);

return correlationContext;
@@ -235,15 +237,15 @@ export class CorrelationContextManager {
// No TraceContext available, parse as http.IncomingMessage
if (headers) {
const traceparent = new Traceparent(headers.traceparent ? headers.traceparent.toString() : null);
const tracestate = new Tracestate(headers.tracestate? headers.tracestate.toString() : null);
const parser = new HttpRequestParser(context as http.IncomingMessage | azureFunctionsTypes.HttpRequest);
const tracestate = new Tracestate(headers.tracestate ? headers.tracestate.toString() : null);
const parser = new HttpRequestParser(input as http.IncomingMessage | azureFunctionsTypes.HttpRequest);
const correlationContext = CorrelationContextManager.generateContextObject(
traceparent.traceId,
traceparent.parentId,
parser.getOperationName({}),
parser.getCorrelationContextHeader(),
traceparent,
tracestate,
tracestate
);

return correlationContext;
@@ -266,7 +268,7 @@ export class CorrelationContextManager {
public static reset() {
if (CorrelationContextManager.hasEverEnabled) {
CorrelationContextManager.session = null;
CorrelationContextManager.session = this.cls.createNamespace('AI-CLS-Session');
CorrelationContextManager.session = this.cls.createNamespace("AI-CLS-Session");
}
}

@@ -350,4 +352,4 @@ class CustomPropertiesImpl implements PrivateCustomProperties {
}
this.props.push({ key: prop, value: val });
}
}
}
7 changes: 1 addition & 6 deletions AutoCollection/Exceptions.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,6 @@
import http = require("http");

import Contracts = require("../Declarations/Contracts");
import TelemetryClient = require("../Library/TelemetryClient");
import Sender = require("../Library/Sender");
import Queue = require("../Library/Channel");
import Util = require("../Library/Util");


class AutoCollectExceptions {

@@ -41,7 +37,6 @@ class AutoCollectExceptions {
public enable(isEnabled: boolean) {
if (isEnabled) {
this._isInitialized = true;
var self = this;
if (!this._exceptionListenerHandle) {
// For scenarios like Promise.reject(), an error won't be passed to the handle. Create a placeholder
// error for these scenarios.
Loading