From 36ce8020e438d735179a49d23e882ae52499f5f2 Mon Sep 17 00:00:00 2001 From: chradek Date: Wed, 29 May 2019 14:08:37 -0700 Subject: [PATCH 01/11] Move Aborter into its own package --- rush.json | 19 -- sdk/core/aborter/.prettierrc.json | 6 + sdk/core/aborter/LICENSE | 21 ++ sdk/core/aborter/README.md | 42 +++ sdk/core/aborter/karma.conf.js | 109 ++++++++ sdk/core/aborter/mocha.reporter.config.json | 6 + sdk/core/aborter/package.json | 105 ++++++++ sdk/core/aborter/rollup.base.config.js | 112 ++++++++ sdk/core/aborter/rollup.config.js | 17 ++ sdk/core/aborter/rollup.test.config.js | 6 + sdk/core/aborter/src/aborter.ts | 284 ++++++++++++++++++++ sdk/core/aborter/test/aborter.spec.ts | 89 ++++++ sdk/core/aborter/tsconfig.json | 39 +++ 13 files changed, 836 insertions(+), 19 deletions(-) create mode 100644 sdk/core/aborter/.prettierrc.json create mode 100644 sdk/core/aborter/LICENSE create mode 100644 sdk/core/aborter/README.md create mode 100644 sdk/core/aborter/karma.conf.js create mode 100644 sdk/core/aborter/mocha.reporter.config.json create mode 100644 sdk/core/aborter/package.json create mode 100644 sdk/core/aborter/rollup.base.config.js create mode 100644 sdk/core/aborter/rollup.config.js create mode 100644 sdk/core/aborter/rollup.test.config.js create mode 100644 sdk/core/aborter/src/aborter.ts create mode 100644 sdk/core/aborter/test/aborter.spec.ts create mode 100644 sdk/core/aborter/tsconfig.json diff --git a/rush.json b/rush.json index 5304cd64c24f..a15f482f58c1 100644 --- a/rush.json +++ b/rush.json @@ -4,7 +4,6 @@ */ { "$schema": "https://developer.microsoft.com/json-schemas/rush/v5/rush.schema.json", - /** * (Required) This specifies the version of the Rush engine to be used in this repo. * Rush's "version selector" feature ensures that the globally installed tool will @@ -17,7 +16,6 @@ * correct error-underlining and tab-completion for editors such as VS Code. */ "rushVersion": "5.7.3", - /** * The next field selects which package manager should be installed and determines its version. * Rush installs its own local copy of the package manager to ensure that your build process @@ -27,10 +25,8 @@ * for details about these alternatives. */ "pnpmVersion": "3.2.0", - // "npmVersion": "4.5.0", // "yarnVersion": "1.9.4", - /** * Options that are only used when the PNPM package manager is selected */ @@ -46,7 +42,6 @@ * It is strongly recommended to set strictPeerDependencies=true. */ "strictPeerDependencies": true, - /** * Configures the strategy used to select versions during installation. * @@ -58,7 +53,6 @@ */ "resolutionStrategy": "fast" }, - /** * Older releases of the NodeJS engine may be missing features required by your system. * Other releases may have bugs. In particular, the "latest" version will not be a @@ -68,7 +62,6 @@ * for your repo. */ "nodeSupportedVersionRange": ">=8.0.0", - /** * If you would like the version specifiers for your dependencies to be consistent, then * uncomment this line. This is effectively similar to running "rush check" before any @@ -81,7 +74,6 @@ * section of the common-versions.json. */ "ensureConsistentVersions": true, - /** * Large monorepos can become intimidating for newcomers if project folder paths don't follow * a consistent and recognizable pattern. When the system allows nested folder trees, @@ -107,7 +99,6 @@ */ "projectFolderMinDepth": 3, "projectFolderMaxDepth": 3, - /** * This feature helps you to review and approve new packages before they are introduced * to your monorepo. For example, you may be concerned about licensing, code quality, @@ -143,7 +134,6 @@ // */ // // "ignoredNpmScopes": [ "@types" ] // }, - /** * If you use Git as your version control system, this section has some additional * optional features you can use. @@ -179,7 +169,6 @@ */ // "versionBumpCommitMessage": "Applying package updates. [skip-ci]" }, - "repository": { /** * The URL of this Git repository, used by "rush change" to determine the base branch for your PR. @@ -198,7 +187,6 @@ */ "url": "https://github.com/Azure/azure-sdk-for-js" }, - /** * Event hooks are customized script actions that Rush executes when specific events occur */ @@ -209,23 +197,19 @@ "preRushInstall": [ // "common/scripts/pre-rush-install.js" ], - /** * The list of shell commands to run after the Rush installation finishes */ "postRushInstall": [], - /** * The list of shell commands to run before the Rush build command starts */ "preRushBuild": [], - /** * The list of shell commands to run after the Rush build command finishes */ "postRushBuild": [] }, - /** * Installation variants allow you to maintain a parallel set of configuration files that can be * used to build the entire monorepo with an alternate set of dependencies. For example, suppose @@ -256,7 +240,6 @@ // "description": "Build this repo using the previous release of the SDK" // } ], - /** * Rush can collect anonymous telemetry about everyday developer activity such as * success/failure of installs, builds, and other operations. You can use this to identify @@ -266,12 +249,10 @@ * in the "eventHooks" section. */ // "telemetryEnabled": false, - /** * Allows creation of hotfix changes. This feature is experimental so it is disabled by default. */ // "hotfixChangeEnabled": false, - /** * (Required) This is the inventory of projects to be managed by Rush. * diff --git a/sdk/core/aborter/.prettierrc.json b/sdk/core/aborter/.prettierrc.json new file mode 100644 index 000000000000..766611669209 --- /dev/null +++ b/sdk/core/aborter/.prettierrc.json @@ -0,0 +1,6 @@ +{ + "tabWidth": 2, + "singleQuote": false, + "arrowParens": "always", + "printWidth": 100 +} diff --git a/sdk/core/aborter/LICENSE b/sdk/core/aborter/LICENSE new file mode 100644 index 000000000000..21071075c245 --- /dev/null +++ b/sdk/core/aborter/LICENSE @@ -0,0 +1,21 @@ + MIT License + + Copyright (c) Microsoft Corporation. All rights reserved. + + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to deal + in the Software without restriction, including without limitation the rights + to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in all + copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + SOFTWARE diff --git a/sdk/core/aborter/README.md b/sdk/core/aborter/README.md new file mode 100644 index 000000000000..4f42bbd2e91c --- /dev/null +++ b/sdk/core/aborter/README.md @@ -0,0 +1,42 @@ +# Aborter + +`Aborter` is used by the Azure SDK for JavaScript to abort pending work based on timeouts or other signals. `Aborter` is compatible with the `AbortSignal` used by the `fetch` API built into modern browsers. + +## Getting started + +``` +npm install @azure/core-aborter +``` + +```js +import { Aborter } from "@azure/core-aborter"; + +const signal = new Aborter(); +doAsyncWork({ abortSignal: signal }); + +// at some point later +signal.abort(); +``` + +### Aborting after a timeout + +```js +import { Aborter } from "@azure/core-aborter"; + +const signal = Aborter.timeout(1000); +doAsyncWork({ abortSignal: signal }); +``` + +### Aborting sub-tasks + +```js +import { Aborter } from "@azure/core-aborter"; + +const allTasksSignal = new Aborter(); + +const subTask1 = allTasksSignal.withValue("key1", "value1"); +const subtask2 = allTasksSignal.withValue("key2", "value2"); + +allTasksSignal.abort(); // aborts allTasksSignal, subTask1, subTask2 +subTask1.abort(); // aborts only subTask1 +``` diff --git a/sdk/core/aborter/karma.conf.js b/sdk/core/aborter/karma.conf.js new file mode 100644 index 000000000000..6bb1b3bef68e --- /dev/null +++ b/sdk/core/aborter/karma.conf.js @@ -0,0 +1,109 @@ +// https://github.com/karma-runner/karma-chrome-launcher +process.env.CHROME_BIN = require("puppeteer").executablePath(); +require("dotenv").config({ path: "../.env" }); + +module.exports = function(config) { + config.set({ + // base path that will be used to resolve all patterns (eg. files, exclude) + basePath: "./", + + // frameworks to use + // available frameworks: https://npmjs.org/browse/keyword/karma-adapter + frameworks: ["mocha"], + + plugins: [ + "karma-mocha", + "karma-mocha-reporter", + "karma-chrome-launcher", + "karma-edge-launcher", + "karma-firefox-launcher", + "karma-ie-launcher", + "karma-env-preprocessor", + "karma-coverage", + "karma-remap-coverage", + "karma-junit-reporter" + ], + + // list of files / patterns to load in the browser + files: ["test-browser/index.js"], + + // list of files / patterns to exclude + exclude: [], + + // preprocess matching files before serving them to the browser + // available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor + preprocessors: { + "**/*.js": ["env"] + // IMPORTANT: COMMENT following line if you want to debug in your browsers!! + // Preprocess source file to calculate code coverage, however this will make source file unreadable + // "test-browser/index.js": ["coverage"] + }, + + // test results reporter to use + // possible values: 'dots', 'progress' + // available reporters: https://npmjs.org/browse/keyword/karma-reporter + reporters: ["mocha", "coverage", "remap-coverage", "junit"], + + coverageReporter: { type: "in-memory" }, + + // Coverage report settings + remapCoverageReporter: { + "text-summary": null, // to show summary in console + html: "./coverage-browser", + cobertura: "./coverage-browser/cobertura-coverage.xml" + }, + + // Exclude coverage calculation for following files + remapOptions: { + exclude: /node_modules|tests/g + }, + + junitReporter: { + outputDir: "", // results will be saved as $outputDir/$browserName.xml + outputFile: "test-results.browser.xml", // if included, results will be saved as $outputDir/$browserName/$outputFile + suite: "", // suite will become the package name attribute in xml testsuite element + useBrowserName: false, // add browser name to report and classes names + nameFormatter: undefined, // function (browser, result) to customize the name attribute in xml testcase element + classNameFormatter: undefined, // function (browser, result) to customize the classname attribute in xml testcase element + properties: {} // key value pair of properties to add to the section of the report + }, + + // web server port + port: 9876, + + // enable / disable colors in the output (reporters and logs) + colors: true, + + // level of logging + // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG + logLevel: config.LOG_INFO, + + // enable / disable watching file and executing tests whenever any file changes + autoWatch: false, + + // start these browsers + // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher + // 'ChromeHeadless', 'Chrome', 'Firefox', 'Edge', 'IE' + browsers: ["ChromeHeadless"], + + // Continuous Integration mode + // if true, Karma captures browsers, runs the tests and exits + singleRun: false, + + // Concurrency level + // how many browser should be started simultaneous + concurrency: 1, + + browserNoActivityTimeout: 600000, + browserDisconnectTimeout: 10000, + browserDisconnectTolerance: 3, + + client: { + mocha: { + // change Karma's debug.html to the mocha web reporter + reporter: "html", + timeout: "600000" + } + } + }); +}; \ No newline at end of file diff --git a/sdk/core/aborter/mocha.reporter.config.json b/sdk/core/aborter/mocha.reporter.config.json new file mode 100644 index 000000000000..7da3cb7f0aa5 --- /dev/null +++ b/sdk/core/aborter/mocha.reporter.config.json @@ -0,0 +1,6 @@ +{ + "reporterEnabled": "spec, mocha-junit-reporter", + "mochaJunitReporterReporterOptions": { + "mochaFile": "test-results.xml" + } +} diff --git a/sdk/core/aborter/package.json b/sdk/core/aborter/package.json new file mode 100644 index 000000000000..16257db79f43 --- /dev/null +++ b/sdk/core/aborter/package.json @@ -0,0 +1,105 @@ +{ + "name": "@azure/core-aborter", + "version": "1.0.0", + "description": "Microsoft Azure SDK for JavaScript - Aborter", + "main": "./dist/index.js", + "module": "./dist-esm/src/aborter.js", + "browser": { + "./dist/index.js": "./browser/index.js" + }, + "scripts": { + "audit": "node ../../../common/scripts/rush-audit.js && rimraf node_modules package-lock.json && npm i --package-lock-only 2>&1 && npm audit", + "build:es6": "tsc -p tsconfig.json", + "build:nodebrowser": "rollup -c 2>&1", + "build:test": "rollup -c rollup.test.config.js 2>&1", + "build": "npm run build:es6 && npm run build:nodebrowser", + "check-format": "prettier --list-different --config .prettierrc.json \"src/**/*.ts\" \"test/**/*.ts\" \"*.{js,json}\"", + "clean": "rimraf dist dist-esm dist-test types temp browser/*.js* browser/*.zip statistics.html coverage coverage-browser .nyc_output *.tgz *.log test*.xml TEST*.xml", + "extract-api": "tsc -p . && api-extractor run --local", + "format": "prettier --write --config .prettierrc.json \"src/**/*.ts\" \"test/**/*.ts\" \"*.{js,json}\"", + "integration-test:browser": "echo skipped", + "integration-test:node": "echo skipped", + "integration-test": "npm run integration-test:node && npm run integration-test:browser", + "lint:fix": "echo skipped", + "lint": "echo skipped", + "pack": "npm pack 2>&1", + "prebuild": "npm run clean", + "pretest": "npm run build:test", + "test:browser": "karma start --single-run", + "test:node": "cross-env TS_NODE_COMPILER_OPTIONS=\"{\\\"module\\\": \\\"commonjs\\\"}\" mocha --require ts-node/register --require source-map-support/register --reporter mocha-multi-reporters --reporter-options configFile=mocha.reporter.config.json --full-trace --no-timeouts test/*.spec.ts", + "test": "npm run test:node && npm run test:browser", + "unit-test:browser": "npm run build && npm run test:browser", + "unit-test:node": "npm run build && npm run test:node", + "unit-test": "npm run unit-test:node && npm run unit-test:browser" + }, + "types": "./typings/src/aborter.d.ts", + "engine": { + "node": ">=6.0.0" + }, + "dependencies": { + "@azure/ms-rest-js": "^1.2.6", + "tslib": "^1.9.3" + }, + "devDependencies": { + "@microsoft/api-extractor": "^7.1.5", + "@types/mocha": "^5.2.5", + "@types/node": "^8.0.0", + "assert": "^1.4.1", + "cross-env": "^5.2.0", + "delay": "^4.2.0", + "karma": "^4.0.1", + "karma-chrome-launcher": "^2.2.0", + "karma-coverage": "^1.1.2", + "karma-edge-launcher": "^0.4.2", + "karma-env-preprocessor": "^0.1.1", + "karma-firefox-launcher": "^1.1.0", + "karma-ie-launcher": "^1.0.0", + "karma-junit-reporter": "^1.2.0", + "karma-mocha": "^1.3.0", + "karma-mocha-reporter": "^2.2.5", + "karma-remap-coverage": "^0.1.5", + "mocha": "^5.2.0", + "mocha-junit-reporter": "^1.18.0", + "mocha-multi-reporters": "^1.1.7", + "nyc": "^14.0.0", + "prettier": "^1.16.4", + "rimraf": "^2.6.2", + "rollup": "^1.0.0", + "rollup-plugin-commonjs": "^9.2.0", + "rollup-plugin-multi-entry": "^2.1.0", + "rollup-plugin-node-resolve": "^4.2.0", + "rollup-plugin-replace": "^2.1.0", + "rollup-plugin-sourcemaps": "^0.4.2", + "rollup-plugin-uglify": "^6.0.0", + "typescript": "^3.2.2" + }, + "files": [ + "browser/*.js*", + "dist/", + "dist-esm/src/", + "src/", + "typings/src", + "tsconfig.json" + ], + "repository": { + "type": "git", + "url": "git+https://github.com/Azure/azure-sdk-for-js.git" + }, + "keywords": [ + "Azure", + "Aborter", + "AbortSignal", + "Cancellation", + "Node.js", + "TypeScript", + "JavaScript", + "Browser" + ], + "author": "Microsoft Corporation", + "license": "MIT", + "bugs": { + "url": "https://github.com/Azure/azure-sdk-for-js/issues" + }, + "homepage": "https://github.com/Azure/azure-sdk-for-js#readme", + "sideEffects": false +} diff --git a/sdk/core/aborter/rollup.base.config.js b/sdk/core/aborter/rollup.base.config.js new file mode 100644 index 000000000000..42cbbf7e8405 --- /dev/null +++ b/sdk/core/aborter/rollup.base.config.js @@ -0,0 +1,112 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +import nodeResolve from "rollup-plugin-node-resolve"; +import multiEntry from "rollup-plugin-multi-entry"; +import cjs from "rollup-plugin-commonjs"; +import replace from "rollup-plugin-replace"; +import { uglify } from "rollup-plugin-uglify"; +import sourcemaps from "rollup-plugin-sourcemaps"; + +const pkg = require("./package.json"); +const depNames = Object.keys(pkg.dependencies); +const input = "./dist-esm/src/aborter.js"; +const production = process.env.NODE_ENV === "production"; + +export function nodeConfig(test = false) { + const externalNodeBuiltins = []; + const baseConfig = { + input: input, + external: depNames.concat(externalNodeBuiltins), + output: { file: "dist/index.js", format: "cjs", sourcemap: true }, + preserveSymlinks: false, + plugins: [ + sourcemaps(), + replace({ + delimiters: ["", ""], + values: { + // replace dynamic checks with if (true) since this is for node only. + // Allows rollup's dead code elimination to be more aggressive. + "if (isNode)": "if (true)" + } + }), + nodeResolve({ preferBuiltins: true, mainFields: ["module"] }), + cjs() + ] + }; + + if (test) { + // entry point is every test file + baseConfig.input = "dist-esm/test/**/*.spec.js"; + baseConfig.plugins.unshift(multiEntry({ exports: false })); + + // different output file + baseConfig.output.file = "dist-test/aborter.js"; + + // mark assert as external + baseConfig.external.push("assert"); + + baseConfig.context = "null"; + + baseConfig.onwarn = (warning) => { + console.error(`(!) ${warning.message}`); + }; + } else if (production) { + baseConfig.plugins.push(uglify()); + } + + return baseConfig; +} + +export function browserConfig(test = false) { + const baseConfig = { + input: input, + external: ["ms-rest-js"], + output: { + file: "browser/index.js", + format: "umd", + name: "Aborter", + sourcemap: true, + globals: { "ms-rest-js": "msRest" } + }, + preserveSymlinks: false, + plugins: [ + sourcemaps(), + replace( + // ms-rest-js is externalized so users must include it prior to using this bundle. + { + delimiters: ["", ""], + values: { + // replace dynamic checks with if (false) since this is for + // browser only. Rollup's dead code elimination will remove + // any code guarded by if (isNode) { ... } + "if (isNode)": "if (false)" + } + } + ), + nodeResolve({ + mainFields: ['module', 'browser'], + preferBuiltins: false + }), + cjs({ + namedExports: { + events: ["EventEmitter"], + assert: ["ok", "deepEqual", "equal", "fail", "deepStrictEqual", "notDeepEqual"] + } + }) + ] + }; + console.log('browser build'); + + if (test) { + console.log('yes test') + baseConfig.input = "dist-esm/test/**/*.spec.js"; + baseConfig.plugins.unshift(multiEntry({ exports: false })); + baseConfig.output.file = "test-browser/index.js"; + baseConfig.context = "null"; + } else if (production) { + baseConfig.plugins.push(uglify()); + } + + return baseConfig; +} diff --git a/sdk/core/aborter/rollup.config.js b/sdk/core/aborter/rollup.config.js new file mode 100644 index 000000000000..58ff3a947d7a --- /dev/null +++ b/sdk/core/aborter/rollup.config.js @@ -0,0 +1,17 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +import * as base from "./rollup.base.config"; + +const inputs = []; + +if (!process.env.ONLY_BROWSER) { + inputs.push(base.nodeConfig()); +} + +// Disable this until we are ready to run rollup for the browser. +if (!process.env.ONLY_NODE) { + inputs.push(base.browserConfig()); +} + +export default inputs; \ No newline at end of file diff --git a/sdk/core/aborter/rollup.test.config.js b/sdk/core/aborter/rollup.test.config.js new file mode 100644 index 000000000000..954f9d9e5a4f --- /dev/null +++ b/sdk/core/aborter/rollup.test.config.js @@ -0,0 +1,6 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +import * as base from "./rollup.base.config"; + +export default [base.nodeConfig(true), base.browserConfig(true)]; \ No newline at end of file diff --git a/sdk/core/aborter/src/aborter.ts b/sdk/core/aborter/src/aborter.ts new file mode 100644 index 000000000000..65bc069f2f95 --- /dev/null +++ b/sdk/core/aborter/src/aborter.ts @@ -0,0 +1,284 @@ +/// +/// + +import { AbortSignalLike, isNode } from "@azure/ms-rest-js"; + +/** + * An aborter instance implements AbortSignal interface, can abort HTTP requests. + * + * - Call Aborter.none to create a new Aborter instance without timeout. + * - Call Aborter.timeout() to create a new Aborter instance with timeout. + * + * For an existing instance aborter: + * - Call aborter.withTimeout() to create and return a child Aborter instance with timeout. + * - Call aborter.withValue(key, value) to create and return a child Aborter instance with key/value pair. + * - Call aborter.abort() to abort current instance and all children instances. + * - Call aborter.getValue(key) to search and get value with corresponding key from current aborter to all parents. + * + * @example + * // Abort without timeout + * await blockBlobClient.upload(Aborter.none, buf, buf.length); + * + * @example + * // Abort container create in 1000ms + * await blockBlobClient.upload(Aborter.timeout(1000), buf, buf.length); + * + * @example + * // Share aborter cross multiple operations in 30s + * // Upload the same data to 2 different data centers at the same time, abort another when any of them is finished + * const aborter = Aborter.timeout(30 * 1000); + * blockBlobClient1.upload(aborter, buf, buf.length).then(aborter.abort); + * blockBlobClient2.upload(aborter, buf, buf.length).then(aborter.abort); + * + * @example + * // Cascaded aborting + * // All operations can't take more than 30 seconds + * const aborter = Aborter.timeout(30 * 1000); + * + * // Following 2 operations can't take more than 25 seconds + * await blockBlobClient.upload(aborter.withTimeout(25 * 1000), buf, buf.length); + * await blockBlobClient.upload(aborter.withTimeout(25 * 1000), buf, buf.length); + * + * @export + * @class Aborter + * @implements {AbortSignalLike} + */ + +export class Aborter implements AbortSignalLike { + /** + * Status of whether aborted or not. + * + * @readonly + * @type {boolean} + * @memberof Aborter + */ + public get aborted(): boolean { + return this._aborted; + } + + /** + * Creates a new Aborter instance without timeout. + * + * @readonly + * @static + * @type {Aborter} + * @memberof Aborter + */ + public static get none(): Aborter { + return new Aborter(undefined, 0); + } + + /** + * Creates a new Aborter instance with timeout in milliseconds. + * Set parameter timeout to 0 will not create a timer. + * + * @static + * @param {number} {timeout} in milliseconds + * @returns {Aborter} + * @memberof Aborter + */ + public static timeout(timeout: number): Aborter { + return new Aborter(undefined, timeout); + } + + /** + * onabort event listener. + * + * @memberof Aborter + */ + public onabort?: (ev?: Event) => any; + + // tslint:disable-next-line:variable-name + private _aborted: boolean = false; + private timer?: any; + private readonly parent?: Aborter; + private readonly children: Aborter[] = []; // When child object calls dispose(), remove child from here + private readonly abortEventListeners: Array<(this: AbortSignalLike, ev?: any) => any> = []; + // Pipeline proxies need to use "abortSignal as Aborter" in order to access non AbortSignalLike methods + // immutable primitive types + private readonly key?: string; + private readonly value?: string | number | boolean | null; + // private disposed: boolean = false; + + /** + * Private constructor for internal usage, creates an instance of Aborter. + * + * @param {Aborter} [parent] Optional. Parent aborter. + * @param {number} [timeout=0] Optional. Timeout before abort in millisecond, 0 means no timeout. + * @param {string} [key] Optional. Immutable key in string. + * @param {(string | number | boolean | null)} [value] Optional. Immutable value. + * @memberof Aborter + */ + private constructor( + parent?: Aborter, + timeout: number = 0, + key?: string, + value?: string | number | boolean | null + ) { + this.parent = parent; + this.key = key; + this.value = value; + + if (timeout > 0) { + this.timer = setTimeout(() => { + this.abort.call(this); + }, timeout); + + // When called, the active Timeout object will not require the Node.js event loop + // to remain active. If there is no other activity keeping the event loop running, + // the process may exit before the Timeout object's callback is invoked. + if (this.timer && isNode) { + this.timer!.unref(); + } + } + } + + /** + * Create and return a new Aborter instance, which will be appended as a child node of current Aborter. + * Current Aborter instance becomes parent node of the new instance. When current or parent Aborter node + * triggers timeout event, all children nodes abort event will be triggered too. + * + * When timeout parameter (in millisecond) is larger than 0, the abort event will be triggered when timeout. + * Otherwise, call abort() method to manually abort. + * + * @param {number} {timeout} Timeout in millisecond. + * @returns {Aborter} The new Aborter instance created. + * @memberof Aborter + */ + public withTimeout(timeout: number): Aborter { + const childCancelContext = new Aborter(this, timeout); + this.children.push(childCancelContext); + return childCancelContext; + } + + /** + * Create and return a new Aborter instance, which will be appended as a child node of current Aborter. + * Current Aborter instance becomes parent node of the new instance. When current or parent Aborter node + * triggers timeout event, all children nodes abort event will be triggered too. + * + * Immutable key value pair will be set into the new created Aborter instance. + * Call getValue() to find out latest value with corresponding key in the chain of + * [current node] -> [parent node] and [grand parent node].... + * + * @param {string} key + * @param {(string | number | boolean | null)} [value] + * @returns {Aborter} + * @memberof Aborter + */ + public withValue(key: string, value?: string | number | boolean | null): Aborter { + const childCancelContext = new Aborter(this, 0, key, value); + this.children.push(childCancelContext); + return childCancelContext; + } + + /** + * Find out latest value with corresponding key in the chain of + * [current node] -> [parent node] -> [grand parent node] -> ... -> [root node]. + * + * If key is not found, undefined will be returned. + * + * @param {string} key + * @returns {(string | number | boolean | null | undefined)} + * @memberof Aborter + */ + public getValue(key: string): string | number | boolean | null | undefined { + for (let parent: Aborter | undefined = this; parent; parent = parent.parent) { + if (parent.key === key) { + return parent.value; + } + } + return undefined; + } + + /** + * Trigger abort event immediately, the onabort and all abort event listeners will be triggered. + * Will try to trigger abort event for all children Aborter nodes. + * + * - If there is a timeout, the timer will be cancelled. + * - If aborted is true, nothing will happen. + * + * @returns + * @memberof Aborter + */ + public abort() { + if (this.aborted) { + return; + } + this.cancelTimer(); + + if (this.onabort) { + this.onabort.call(this); + } + + this.abortEventListeners.forEach((listener) => { + listener.call(this); + }); + + this.children.forEach((child) => child.cancelByParent()); + + this._aborted = true; + } + + // public dispose() { + // if (this.disposed || this.aborted) { + // return; + // } + + // this.cancelTimer(); + + // // (parent)A <- B <- C(child), if B disposes, when A abort, C will not abort + // if (this.parent) { + // const index = this.parent.children.indexOf(this); + // if (index > -1) { + // this.parent.children.splice(index, 1); + // } + // } + + // this.disposed = true; + // } + + /** + * Added new "abort" event listener, only support "abort" event. + * + * @param {"abort"} _type Only support "abort" event + * @param {(this: AbortSignalLike, ev: any) => any} listener + * @memberof Aborter + */ + public addEventListener( + // tslint:disable-next-line:variable-name + _type: "abort", + listener: (this: AbortSignalLike, ev: any) => any + ): void { + this.abortEventListeners.push(listener); + } + + /** + * Remove "abort" event listener, only support "abort" event. + * + * @param {"abort"} _type Only support "abort" event + * @param {(this: AbortSignalLike, ev: any) => any} listener + * @memberof Aborter + */ + public removeEventListener( + // tslint:disable-next-line:variable-name + _type: "abort", + listener: (this: AbortSignalLike, ev: any) => any + ): void { + const index = this.abortEventListeners.indexOf(listener); + if (index > -1) { + this.abortEventListeners.splice(index, 1); + } + } + + private cancelByParent() { + // if (!this.disposed) { + this.abort(); + // } + } + + private cancelTimer() { + if (this.timer) { + clearTimeout(this.timer); + } + } +} \ No newline at end of file diff --git a/sdk/core/aborter/test/aborter.spec.ts b/sdk/core/aborter/test/aborter.spec.ts new file mode 100644 index 000000000000..8c608737c31e --- /dev/null +++ b/sdk/core/aborter/test/aborter.spec.ts @@ -0,0 +1,89 @@ +import * as assert from "assert"; +import delay from "delay"; +import { Aborter } from "../src/aborter"; + +describe("Aborter", () => { + async function doAsyncOperation( + aborter: Aborter, + runningTimeinMs: number = 100 + ): Promise { + await delay(runningTimeinMs); + if (aborter.aborted) { + throw new Error("Operation aborted"); + } + return 0; + } + + it("should set value and get value successfully", async () => { + const aborter = Aborter.none.withValue("mykey", "myvalue"); + assert.deepStrictEqual(aborter.getValue("mykey"), "myvalue"); + }); + + it("should get value from parent successfully", async () => { + const aborter = Aborter.none.withValue("parentkey", "parentvalue"); + const child = aborter.withValue("childkey", "childvalue"); + assert.deepStrictEqual(child.getValue("parentkey"), "parentvalue"); + }); + + it("should not abort without calling abort()", async () => { + await doAsyncOperation(Aborter.none); + }); + + it("should abort when calling abort() before request finishes", async () => { + const aborter = Aborter.none; + const response = doAsyncOperation(aborter); + aborter.abort(); + try { + await response; + assert.fail(); + } catch (err) {} + }); + + it("should not abort when calling abort() after request finishes", async () => { + const aborter = Aborter.none; + await doAsyncOperation(aborter); + aborter.abort(); + }); + + it("should abort after aborter timeout", async () => { + try { + await doAsyncOperation(Aborter.timeout(1)); + assert.fail(); + } catch (err) {} + }); + + it("should abort after parent aborter calls abort()", async () => { + try { + const aborter = Aborter.none; + const response = doAsyncOperation(aborter.withTimeout(10 * 60 * 1000)); + aborter.abort(); + await response; + assert.fail(); + } catch (err) {} + }); + + it("should abort after parent aborter timeout", async () => { + try { + const aborter = Aborter.timeout(1); + const response = doAsyncOperation(aborter.withTimeout(10 * 60 * 1000)); + await response; + assert.fail(); + } catch (err) {} + }); + + it("should invoke onabort callback when aborting", async () => { + let s = undefined; + try { + const aborter = Aborter.none; + aborter.onabort = () => { + s = "aborted"; + }; + const response = doAsyncOperation(aborter); + aborter.abort(); + await response; + assert.fail(); + } catch (err) { + assert.equal(s, "aborted"); + } + }); +}); \ No newline at end of file diff --git a/sdk/core/aborter/tsconfig.json b/sdk/core/aborter/tsconfig.json new file mode 100644 index 000000000000..12b5ff852eab --- /dev/null +++ b/sdk/core/aborter/tsconfig.json @@ -0,0 +1,39 @@ +{ + "compilerOptions": { + /* Basic Options */ + "target": "es5" /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017','ES2018' or 'ESNEXT'. */, + "module": "es6" /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', or 'ESNext'. */, + "lib": [] /* lib dependencies are triple-slash directives in lib/index.ts */, + "declaration": true /* Generates corresponding '.d.ts' file. */, + "declarationMap": true /* Generates a sourcemap for each corresponding '.d.ts' file. */, + "sourceMap": true /* Generates corresponding '.map' file. */, + "outDir": "./dist-esm" /* Redirect output structure to the directory. */, + "stripInternal": true /* Do not emit declarations for code with @internal annotation*/, + "declarationDir": "./typings" /* Output directory for generated declaration files.*/, + "importHelpers": true /* Import emit helpers from 'tslib'. */, + /* Strict Type-Checking Options */ + "strict": true /* Enable all strict type-checking options. */, + "noImplicitReturns": true /* Report error when not all code paths in function return a value. */, + /* Additional Checks */ + "noUnusedLocals": true /* Report errors on unused locals. */, + /* Module Resolution Options */ + "moduleResolution": "node" /* Specify module resolution strategy: 'node' (Node.js) or 'classic' (TypeScript pre-1.6). */, + "allowSyntheticDefaultImports": true /* Allow default imports from modules with no default export. This does not affect code emit, just typechecking. */, + "esModuleInterop": true /* Enables emit interoperability between CommonJS and ES Modules via creation of namespace objects for all imports. Implies 'allowSyntheticDefaultImports'. */, + /* Experimental Options */ + "forceConsistentCasingInFileNames": true, + /* Other options */ + "newLine": "LF" /* Use the specified end of line sequence to be used when emitting files: "crlf" (windows) or "lf" (unix).”*/, + "allowJs": false /* Don't allow JavaScript files to be compiled.*/ + }, + "compileOnSave": true, + "exclude": [ + "node_modules", + "./typings/**/*.d.ts", + "./samples/**/*.ts" + ], + "include": [ + "./src/**/*.ts", + "./test/**/*.ts" + ] +} From c94449b80b67459ff4e8b6bf96187eb7f3c6cf6d Mon Sep 17 00:00:00 2001 From: chradek Date: Wed, 29 May 2019 14:08:52 -0700 Subject: [PATCH 02/11] [core-aborter] add api-extractor config to Aborter package --- sdk/core/aborter/api-extractor.json | 30 +++++++++++++++++++++ sdk/core/aborter/review/core-aborter.api.md | 26 ++++++++++++++++++ 2 files changed, 56 insertions(+) create mode 100644 sdk/core/aborter/api-extractor.json create mode 100644 sdk/core/aborter/review/core-aborter.api.md diff --git a/sdk/core/aborter/api-extractor.json b/sdk/core/aborter/api-extractor.json new file mode 100644 index 000000000000..3044d1419f4e --- /dev/null +++ b/sdk/core/aborter/api-extractor.json @@ -0,0 +1,30 @@ +{ + "$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json", + "mainEntryPointFilePath": "typings/src/aborter.d.ts", + "docModel": { + "enabled": false + }, + "apiReport": { + "enabled": true, + "reportFolder": "./review" + }, + "dtsRollup": { + "enabled": true, + "publicTrimmedFilePath": "./typings/aborter.d.ts" + }, + "messages": { + "tsdocMessageReporting": { + "default": { + "logLevel": "none" + } + }, + "extractorMessageReporting": { + "ae-missing-release-tag": { + "logLevel": "none" + }, + "ae-unresolved-link": { + "logLevel": "none" + } + } + } +} diff --git a/sdk/core/aborter/review/core-aborter.api.md b/sdk/core/aborter/review/core-aborter.api.md new file mode 100644 index 000000000000..781579d7c2ab --- /dev/null +++ b/sdk/core/aborter/review/core-aborter.api.md @@ -0,0 +1,26 @@ +## API Report File for "@azure/core-aborter" + +> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). + +```ts + +import { AbortSignalLike } from '@azure/ms-rest-js'; + +// @public +export class Aborter implements AbortSignalLike { + abort(): void; + readonly aborted: boolean; + addEventListener(_type: "abort", listener: (this: AbortSignalLike, ev: any) => any): void; + getValue(key: string): string | number | boolean | null | undefined; + static readonly none: Aborter; + onabort?: (ev?: Event) => any; + removeEventListener(_type: "abort", listener: (this: AbortSignalLike, ev: any) => any): void; + static timeout(timeout: number): Aborter; + withTimeout(timeout: number): Aborter; + withValue(key: string, value?: string | number | boolean | null): Aborter; +} + + +// (No @packageDocumentation comment for this package) + +``` From f333d058bc402ac2d088c57a6ed83e1972e35024 Mon Sep 17 00:00:00 2001 From: chradek Date: Wed, 29 May 2019 14:33:26 -0700 Subject: [PATCH 03/11] [core-aborter] Update README.md and add known issue --- .docsettings.yml | 163 +++++++++++++++++++++---------------- sdk/core/aborter/README.md | 33 +++++++- 2 files changed, 122 insertions(+), 74 deletions(-) diff --git a/.docsettings.yml b/.docsettings.yml index 11e47565191b..e4ff4d21ee41 100644 --- a/.docsettings.yml +++ b/.docsettings.yml @@ -13,76 +13,97 @@ required_readme_sections: - ^Next steps$ - ^Contributing$ known_content_issues: - - ['README.md', '#1583'] - - ['sdk/template/template/README.md', '#1583'] - - ['sdk/applicationinsights/applicationinsights-query/README.md', '#1583'] - - ['sdk/batch/batch/README.md', '#1583'] - - ['sdk/cognitiveservices/cognitiveservices-anomalydetector/README.md', '#1583'] - - ['sdk/cognitiveservices/cognitiveservices-autosuggest/README.md', '#1583'] - - ['sdk/cognitiveservices/cognitiveservices-computervision/README.md', '#1583'] - - ['sdk/cognitiveservices/cognitiveservices-contentmoderator/README.md', '#1583'] - - ['sdk/cognitiveservices/cognitiveservices-customimagesearch/README.md', '#1583'] - - ['sdk/cognitiveservices/cognitiveservices-customsearch/README.md', '#1583'] - - ['sdk/cognitiveservices/cognitiveservices-customvision-prediction/README.md', '#1583'] - - ['sdk/cognitiveservices/cognitiveservices-customvision-training/README.md', '#1583'] - - ['sdk/cognitiveservices/cognitiveservices-entitysearch/README.md', '#1583'] - - ['sdk/cognitiveservices/cognitiveservices-face/README.md', '#1583'] - - ['sdk/cognitiveservices/cognitiveservices-imagesearch/README.md', '#1583'] - - ['sdk/cognitiveservices/cognitiveservices-localsearch/README.md', '#1583'] - - ['sdk/cognitiveservices/cognitiveservices-luis-authoring/README.md', '#1583'] - - ['sdk/cognitiveservices/cognitiveservices-luis-runtime/README.md', '#1583'] - - ['sdk/cognitiveservices/cognitiveservices-newssearch/README.md', '#1583'] - - ['sdk/cognitiveservices/cognitiveservices-qnamaker/README.md', '#1583'] - - ['sdk/cognitiveservices/cognitiveservices-spellcheck/README.md', '#1583'] - - ['sdk/cognitiveservices/cognitiveservices-textanalytics/README.md', '#1583'] - - ['sdk/cognitiveservices/cognitiveservices-videosearch/README.md', '#1583'] - - ['sdk/cognitiveservices/cognitiveservices-visualsearch/README.md', '#1583'] - - ['sdk/cognitiveservices/cognitiveservices-websearch/README.md', '#1583'] - - ['sdk/eventgrid/eventgrid/README.md', '#1583'] - - ['sdk/core/core-http/README.md', '#1583'] - - ['sdk/cosmosdb/cosmos/README.md', '#1583'] - - ['sdk/cosmosdb/cosmos/src/test/readme.md', '#1583'] - - ['sdk/cosmosdb/cosmos/samples/readme.md', '#1583'] - - ['sdk/cosmosdb/cosmos/samples/UserManagement/README.md', '#1583'] - - ['sdk/cosmosdb/cosmos/samples/TodoApp/readme.md', '#1583'] - - ['sdk/cosmosdb/cosmos/samples/ChangeFeed/README.md', '#1583'] - - ['sdk/cosmosdb/cosmos/samples/MultiRegionWrite/readme.md', '#1583'] - - ['sdk/cosmosdb/cosmos/samples/ServerSideScripts/README.md', '#1583'] - - ['sdk/cosmosdb/cosmos/samples/ServerSideScripts/JS/README.md', '#1583'] - - ['sdk/cosmosdb/cosmos/samples/IndexManagement/README.md', '#1583'] - - ['sdk/cosmosdb/cosmos/samples/ItemManagement/README.md', '#1583'] - - ['sdk/cosmosdb/cosmos/samples/DatabaseManagement/README.md', '#1583'] - - ['sdk/cosmosdb/cosmos/samples/ContainerManagement/README.md', '#1583'] - - ['sdk/eventhub/README.md', '#1583'] - - ['sdk/eventhub/event-hubs/README.md', '#1583'] - - ['sdk/eventhub/event-hubs/samples/README.md', '#1583'] - - ['sdk/eventhub/event-processor-host/README.md', '#1583'] - - ['sdk/eventhub/event-processor-host/samples/README.md', '#1583'] - - ['sdk/eventhub/testhub/README.md', '#1583'] - - ['sdk/graphrbac/graph/README.md', '#1583'] - - ['sdk/keyvault/keyvault/README.md', '#1583'] - - ['sdk/operationalinsights/loganalytics/README.md', '#1583'] - - ['sdk/servicebus/service-bus/README.md', '#1583'] - - ['sdk/servicebus/service-bus/samples/README.md', '#1583'] - - ['sdk/servicebus/service-bus/test/README.md', '#1583'] - - ['sdk/servicefabric/servicefabric/README.md', '#1583'] - - ['sdk/storage/README.md', '#1583'] - - ['sdk/storage/storage-blob/README.md', '#1583'] - - ['sdk/storage/storage-blob/swagger/README.md', '#1583'] - - ['sdk/storage/storage-blob/samples/README.md', '#1583'] - - ['sdk/storage/storage-blob/test/README.md', '#1583'] - - ['sdk/storage/storage-file/README.md', '#1583'] - - ['sdk/storage/storage-file/swagger/README.md', '#1583'] - - ['sdk/storage/storage-file/samples/README.md', '#1583'] - - ['sdk/storage/storage-file/test/README.md', '#1583'] - - ['sdk/storage/storage-queue/README.md', '#1583'] - - ['sdk/storage/storage-queue/swagger/README.md', '#1583'] - - ['sdk/storage/storage-queue/samples/README.md', '#1583'] - - ['sdk/storage/storage-queue/test/README.md', '#1583'] - - ['sdk/storage/storage-datalake/README.md', '#1583'] + - ["README.md", "#1583"] + - ["sdk/template/template/README.md", "#1583"] + - ["sdk/applicationinsights/applicationinsights-query/README.md", "#1583"] + - ["sdk/batch/batch/README.md", "#1583"] + - [ + "sdk/cognitiveservices/cognitiveservices-anomalydetector/README.md", + "#1583", + ] + - ["sdk/cognitiveservices/cognitiveservices-autosuggest/README.md", "#1583"] + - [ + "sdk/cognitiveservices/cognitiveservices-computervision/README.md", + "#1583", + ] + - [ + "sdk/cognitiveservices/cognitiveservices-contentmoderator/README.md", + "#1583", + ] + - [ + "sdk/cognitiveservices/cognitiveservices-customimagesearch/README.md", + "#1583", + ] + - ["sdk/cognitiveservices/cognitiveservices-customsearch/README.md", "#1583"] + - [ + "sdk/cognitiveservices/cognitiveservices-customvision-prediction/README.md", + "#1583", + ] + - [ + "sdk/cognitiveservices/cognitiveservices-customvision-training/README.md", + "#1583", + ] + - ["sdk/cognitiveservices/cognitiveservices-entitysearch/README.md", "#1583"] + - ["sdk/cognitiveservices/cognitiveservices-face/README.md", "#1583"] + - ["sdk/cognitiveservices/cognitiveservices-imagesearch/README.md", "#1583"] + - ["sdk/cognitiveservices/cognitiveservices-localsearch/README.md", "#1583"] + - [ + "sdk/cognitiveservices/cognitiveservices-luis-authoring/README.md", + "#1583", + ] + - ["sdk/cognitiveservices/cognitiveservices-luis-runtime/README.md", "#1583"] + - ["sdk/cognitiveservices/cognitiveservices-newssearch/README.md", "#1583"] + - ["sdk/cognitiveservices/cognitiveservices-qnamaker/README.md", "#1583"] + - ["sdk/cognitiveservices/cognitiveservices-spellcheck/README.md", "#1583"] + - ["sdk/cognitiveservices/cognitiveservices-textanalytics/README.md", "#1583"] + - ["sdk/cognitiveservices/cognitiveservices-videosearch/README.md", "#1583"] + - ["sdk/cognitiveservices/cognitiveservices-visualsearch/README.md", "#1583"] + - ["sdk/cognitiveservices/cognitiveservices-websearch/README.md", "#1583"] + - ["sdk/eventgrid/eventgrid/README.md", "#1583"] + - ["sdk/core/core-http/README.md", "#1583"] + - ["sdk/cosmosdb/cosmos/README.md", "#1583"] + - ["sdk/cosmosdb/cosmos/src/test/readme.md", "#1583"] + - ["sdk/cosmosdb/cosmos/samples/readme.md", "#1583"] + - ["sdk/cosmosdb/cosmos/samples/UserManagement/README.md", "#1583"] + - ["sdk/cosmosdb/cosmos/samples/TodoApp/readme.md", "#1583"] + - ["sdk/cosmosdb/cosmos/samples/ChangeFeed/README.md", "#1583"] + - ["sdk/cosmosdb/cosmos/samples/MultiRegionWrite/readme.md", "#1583"] + - ["sdk/cosmosdb/cosmos/samples/ServerSideScripts/README.md", "#1583"] + - ["sdk/cosmosdb/cosmos/samples/ServerSideScripts/JS/README.md", "#1583"] + - ["sdk/cosmosdb/cosmos/samples/IndexManagement/README.md", "#1583"] + - ["sdk/cosmosdb/cosmos/samples/ItemManagement/README.md", "#1583"] + - ["sdk/cosmosdb/cosmos/samples/DatabaseManagement/README.md", "#1583"] + - ["sdk/cosmosdb/cosmos/samples/ContainerManagement/README.md", "#1583"] + - ["sdk/eventhub/README.md", "#1583"] + - ["sdk/eventhub/event-hubs/README.md", "#1583"] + - ["sdk/eventhub/event-hubs/samples/README.md", "#1583"] + - ["sdk/eventhub/event-processor-host/README.md", "#1583"] + - ["sdk/eventhub/event-processor-host/samples/README.md", "#1583"] + - ["sdk/eventhub/testhub/README.md", "#1583"] + - ["sdk/graphrbac/graph/README.md", "#1583"] + - ["sdk/keyvault/keyvault/README.md", "#1583"] + - ["sdk/operationalinsights/loganalytics/README.md", "#1583"] + - ["sdk/servicebus/service-bus/README.md", "#1583"] + - ["sdk/servicebus/service-bus/samples/README.md", "#1583"] + - ["sdk/servicebus/service-bus/test/README.md", "#1583"] + - ["sdk/servicefabric/servicefabric/README.md", "#1583"] + - ["sdk/storage/README.md", "#1583"] + - ["sdk/storage/storage-blob/README.md", "#1583"] + - ["sdk/storage/storage-blob/swagger/README.md", "#1583"] + - ["sdk/storage/storage-blob/samples/README.md", "#1583"] + - ["sdk/storage/storage-blob/test/README.md", "#1583"] + - ["sdk/storage/storage-file/README.md", "#1583"] + - ["sdk/storage/storage-file/swagger/README.md", "#1583"] + - ["sdk/storage/storage-file/samples/README.md", "#1583"] + - ["sdk/storage/storage-file/test/README.md", "#1583"] + - ["sdk/storage/storage-queue/README.md", "#1583"] + - ["sdk/storage/storage-queue/swagger/README.md", "#1583"] + - ["sdk/storage/storage-queue/samples/README.md", "#1583"] + - ["sdk/storage/storage-queue/test/README.md", "#1583"] + - ["sdk/storage/storage-datalake/README.md", "#1583"] package_indexing_exclusion_list: - - '@azure/template' - - 'azure-sp' - - 'testhub' - - 'azure-sdk-for-js' + - "@azure/template" + - "azure-sp" + - "testhub" + - "azure-sdk-for-js" diff --git a/sdk/core/aborter/README.md b/sdk/core/aborter/README.md index 4f42bbd2e91c..ba22239e6120 100644 --- a/sdk/core/aborter/README.md +++ b/sdk/core/aborter/README.md @@ -1,13 +1,24 @@ -# Aborter +# Azure Core Aborter library for JS `Aborter` is used by the Azure SDK for JavaScript to abort pending work based on timeouts or other signals. `Aborter` is compatible with the `AbortSignal` used by the `fetch` API built into modern browsers. ## Getting started +### Installation + - Installing this library ``` npm install @azure/core-aborter ``` +## Key Concepts +This library contains the `Aborter` class which is used by the Azure SDK for JavaScript to abort pending +work based on timeouts or other signales. +`Aborter` is compatible with the `AbortSignal` used by the `fetch` API built into modern browsers. + +## Examples + +### Example 1 - basic usage + ```js import { Aborter } from "@azure/core-aborter"; @@ -18,7 +29,7 @@ doAsyncWork({ abortSignal: signal }); signal.abort(); ``` -### Aborting after a timeout +### Example 2 - Aborting with timeout ```js import { Aborter } from "@azure/core-aborter"; @@ -27,7 +38,7 @@ const signal = Aborter.timeout(1000); doAsyncWork({ abortSignal: signal }); ``` -### Aborting sub-tasks +### Example 3 - Aborting sub-tasks ```js import { Aborter } from "@azure/core-aborter"; @@ -40,3 +51,19 @@ const subtask2 = allTasksSignal.withValue("key2", "value2"); allTasksSignal.abort(); // aborts allTasksSignal, subTask1, subTask2 subTask1.abort(); // aborts only subTask1 ``` + +## Next Steps +Please take a look at the Examples section above to use this package. + +## Contributing +This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor +License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your +contribution. For details, visit https://cla.microsoft.com. + +When you submit a pull request, a CLA-bot will automatically determine whether you need to provide a CLA and +decorate the PR appropriately (e.g., label, comment). Simply follow the instructions provided by the bot. +You will only need to do this once across all repos using our CLA. + +This project has adopted the Microsoft Open Source Code of Conduct. +For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional +questions or comments. From 1b81f1a920f92325849957eefb55f8e26de494c8 Mon Sep 17 00:00:00 2001 From: chradek Date: Fri, 31 May 2019 09:23:32 -0700 Subject: [PATCH 04/11] [core-aborter] updates .prettierrc.json location and outputs typings to types dir --- sdk/core/aborter/.prettierrc.json | 6 ------ sdk/core/aborter/package.json | 8 ++++---- sdk/core/aborter/tsconfig.json | 13 +++---------- 3 files changed, 7 insertions(+), 20 deletions(-) delete mode 100644 sdk/core/aborter/.prettierrc.json diff --git a/sdk/core/aborter/.prettierrc.json b/sdk/core/aborter/.prettierrc.json deleted file mode 100644 index 766611669209..000000000000 --- a/sdk/core/aborter/.prettierrc.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "tabWidth": 2, - "singleQuote": false, - "arrowParens": "always", - "printWidth": 100 -} diff --git a/sdk/core/aborter/package.json b/sdk/core/aborter/package.json index 16257db79f43..bae9aa7a70bb 100644 --- a/sdk/core/aborter/package.json +++ b/sdk/core/aborter/package.json @@ -13,10 +13,10 @@ "build:nodebrowser": "rollup -c 2>&1", "build:test": "rollup -c rollup.test.config.js 2>&1", "build": "npm run build:es6 && npm run build:nodebrowser", - "check-format": "prettier --list-different --config .prettierrc.json \"src/**/*.ts\" \"test/**/*.ts\" \"*.{js,json}\"", + "check-format": "prettier --list-different --config ../../.prettierrc.json \"src/**/*.ts\" \"test/**/*.ts\" \"*.{js,json}\"", "clean": "rimraf dist dist-esm dist-test types temp browser/*.js* browser/*.zip statistics.html coverage coverage-browser .nyc_output *.tgz *.log test*.xml TEST*.xml", "extract-api": "tsc -p . && api-extractor run --local", - "format": "prettier --write --config .prettierrc.json \"src/**/*.ts\" \"test/**/*.ts\" \"*.{js,json}\"", + "format": "prettier --write --config ../../.prettierrc.json \"src/**/*.ts\" \"test/**/*.ts\" \"*.{js,json}\"", "integration-test:browser": "echo skipped", "integration-test:node": "echo skipped", "integration-test": "npm run integration-test:node && npm run integration-test:browser", @@ -32,7 +32,7 @@ "unit-test:node": "npm run build && npm run test:node", "unit-test": "npm run unit-test:node && npm run unit-test:browser" }, - "types": "./typings/src/aborter.d.ts", + "types": "./types/src/aborter.d.ts", "engine": { "node": ">=6.0.0" }, @@ -78,7 +78,7 @@ "dist/", "dist-esm/src/", "src/", - "typings/src", + "types/src", "tsconfig.json" ], "repository": { diff --git a/sdk/core/aborter/tsconfig.json b/sdk/core/aborter/tsconfig.json index 12b5ff852eab..e1da3caae545 100644 --- a/sdk/core/aborter/tsconfig.json +++ b/sdk/core/aborter/tsconfig.json @@ -9,7 +9,7 @@ "sourceMap": true /* Generates corresponding '.map' file. */, "outDir": "./dist-esm" /* Redirect output structure to the directory. */, "stripInternal": true /* Do not emit declarations for code with @internal annotation*/, - "declarationDir": "./typings" /* Output directory for generated declaration files.*/, + "declarationDir": "./types" /* Output directory for generated declaration files.*/, "importHelpers": true /* Import emit helpers from 'tslib'. */, /* Strict Type-Checking Options */ "strict": true /* Enable all strict type-checking options. */, @@ -27,13 +27,6 @@ "allowJs": false /* Don't allow JavaScript files to be compiled.*/ }, "compileOnSave": true, - "exclude": [ - "node_modules", - "./typings/**/*.d.ts", - "./samples/**/*.ts" - ], - "include": [ - "./src/**/*.ts", - "./test/**/*.ts" - ] + "exclude": ["node_modules", "./typings/**/*.d.ts", "./samples/**/*.ts"], + "include": ["./src/**/*.ts", "./test/**/*.ts"] } From fddd23434938bfa0281f7fa52a9454b757792651 Mon Sep 17 00:00:00 2001 From: chradek Date: Fri, 31 May 2019 09:24:19 -0700 Subject: [PATCH 05/11] [core-aborter] updates files using new prettier config --- sdk/core/aborter/karma.conf.js | 2 +- sdk/core/aborter/rollup.base.config.js | 6 +++--- sdk/core/aborter/rollup.config.js | 2 +- sdk/core/aborter/rollup.test.config.js | 2 +- sdk/core/aborter/src/aborter.ts | 2 +- sdk/core/aborter/test/aborter.spec.ts | 2 +- 6 files changed, 8 insertions(+), 8 deletions(-) diff --git a/sdk/core/aborter/karma.conf.js b/sdk/core/aborter/karma.conf.js index 6bb1b3bef68e..df94236c36a4 100644 --- a/sdk/core/aborter/karma.conf.js +++ b/sdk/core/aborter/karma.conf.js @@ -106,4 +106,4 @@ module.exports = function(config) { } } }); -}; \ No newline at end of file +}; diff --git a/sdk/core/aborter/rollup.base.config.js b/sdk/core/aborter/rollup.base.config.js index 42cbbf7e8405..89f84ca77c30 100644 --- a/sdk/core/aborter/rollup.base.config.js +++ b/sdk/core/aborter/rollup.base.config.js @@ -85,7 +85,7 @@ export function browserConfig(test = false) { } ), nodeResolve({ - mainFields: ['module', 'browser'], + mainFields: ["module", "browser"], preferBuiltins: false }), cjs({ @@ -96,10 +96,10 @@ export function browserConfig(test = false) { }) ] }; - console.log('browser build'); + console.log("browser build"); if (test) { - console.log('yes test') + console.log("yes test"); baseConfig.input = "dist-esm/test/**/*.spec.js"; baseConfig.plugins.unshift(multiEntry({ exports: false })); baseConfig.output.file = "test-browser/index.js"; diff --git a/sdk/core/aborter/rollup.config.js b/sdk/core/aborter/rollup.config.js index 58ff3a947d7a..fd25a0257a1f 100644 --- a/sdk/core/aborter/rollup.config.js +++ b/sdk/core/aborter/rollup.config.js @@ -14,4 +14,4 @@ if (!process.env.ONLY_NODE) { inputs.push(base.browserConfig()); } -export default inputs; \ No newline at end of file +export default inputs; diff --git a/sdk/core/aborter/rollup.test.config.js b/sdk/core/aborter/rollup.test.config.js index 954f9d9e5a4f..ad98718cce46 100644 --- a/sdk/core/aborter/rollup.test.config.js +++ b/sdk/core/aborter/rollup.test.config.js @@ -3,4 +3,4 @@ import * as base from "./rollup.base.config"; -export default [base.nodeConfig(true), base.browserConfig(true)]; \ No newline at end of file +export default [base.nodeConfig(true), base.browserConfig(true)]; diff --git a/sdk/core/aborter/src/aborter.ts b/sdk/core/aborter/src/aborter.ts index 65bc069f2f95..f734d4623003 100644 --- a/sdk/core/aborter/src/aborter.ts +++ b/sdk/core/aborter/src/aborter.ts @@ -281,4 +281,4 @@ export class Aborter implements AbortSignalLike { clearTimeout(this.timer); } } -} \ No newline at end of file +} diff --git a/sdk/core/aborter/test/aborter.spec.ts b/sdk/core/aborter/test/aborter.spec.ts index 8c608737c31e..172ee7e80d0d 100644 --- a/sdk/core/aborter/test/aborter.spec.ts +++ b/sdk/core/aborter/test/aborter.spec.ts @@ -86,4 +86,4 @@ describe("Aborter", () => { assert.equal(s, "aborted"); } }); -}); \ No newline at end of file +}); From 82858d6a0e36d9459c7caf424b17ab72904dae6f Mon Sep 17 00:00:00 2001 From: chradek Date: Fri, 31 May 2019 09:33:21 -0700 Subject: [PATCH 06/11] [core-aborter] update api-extractor to use types instead of typings --- sdk/core/aborter/api-extractor.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sdk/core/aborter/api-extractor.json b/sdk/core/aborter/api-extractor.json index 3044d1419f4e..04d20e605c21 100644 --- a/sdk/core/aborter/api-extractor.json +++ b/sdk/core/aborter/api-extractor.json @@ -1,6 +1,6 @@ { "$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json", - "mainEntryPointFilePath": "typings/src/aborter.d.ts", + "mainEntryPointFilePath": "types/src/aborter.d.ts", "docModel": { "enabled": false }, @@ -10,7 +10,7 @@ }, "dtsRollup": { "enabled": true, - "publicTrimmedFilePath": "./typings/aborter.d.ts" + "publicTrimmedFilePath": "./types/aborter.d.ts" }, "messages": { "tsdocMessageReporting": { From b8a20a402ed3a5f1fc5c84a610e5ddd59913e861 Mon Sep 17 00:00:00 2001 From: chradek Date: Fri, 31 May 2019 09:34:14 -0700 Subject: [PATCH 07/11] [core-aborter] update doc examples in source files --- sdk/core/aborter/src/aborter.ts | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/sdk/core/aborter/src/aborter.ts b/sdk/core/aborter/src/aborter.ts index f734d4623003..bfc3d80a8a41 100644 --- a/sdk/core/aborter/src/aborter.ts +++ b/sdk/core/aborter/src/aborter.ts @@ -17,18 +17,18 @@ import { AbortSignalLike, isNode } from "@azure/ms-rest-js"; * * @example * // Abort without timeout - * await blockBlobClient.upload(Aborter.none, buf, buf.length); + * await doAsyncWork(Aborter.none); * * @example * // Abort container create in 1000ms - * await blockBlobClient.upload(Aborter.timeout(1000), buf, buf.length); + * await doAsyncWork(Aborter.timeout(1000)); * * @example * // Share aborter cross multiple operations in 30s * // Upload the same data to 2 different data centers at the same time, abort another when any of them is finished * const aborter = Aborter.timeout(30 * 1000); - * blockBlobClient1.upload(aborter, buf, buf.length).then(aborter.abort); - * blockBlobClient2.upload(aborter, buf, buf.length).then(aborter.abort); + * doAsyncWork(aborter).then(aborter.abort); + * doAsyncWork(aborter).then(aborter.abort); * * @example * // Cascaded aborting @@ -36,8 +36,8 @@ import { AbortSignalLike, isNode } from "@azure/ms-rest-js"; * const aborter = Aborter.timeout(30 * 1000); * * // Following 2 operations can't take more than 25 seconds - * await blockBlobClient.upload(aborter.withTimeout(25 * 1000), buf, buf.length); - * await blockBlobClient.upload(aborter.withTimeout(25 * 1000), buf, buf.length); + * await doAsyncWork(aborter.withTimeout(25 * 1000)); + * await doAsyncWork(aborter.withTimeout(25 * 1000)); * * @export * @class Aborter From 3359ed19ad4056cd6387dd15f5fd58f2c3a96686 Mon Sep 17 00:00:00 2001 From: chradek Date: Fri, 31 May 2019 09:41:35 -0700 Subject: [PATCH 08/11] [core-aborter] updates typings to types in tsconfig excludes list --- sdk/core/aborter/tsconfig.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sdk/core/aborter/tsconfig.json b/sdk/core/aborter/tsconfig.json index e1da3caae545..98b8f2143270 100644 --- a/sdk/core/aborter/tsconfig.json +++ b/sdk/core/aborter/tsconfig.json @@ -27,6 +27,6 @@ "allowJs": false /* Don't allow JavaScript files to be compiled.*/ }, "compileOnSave": true, - "exclude": ["node_modules", "./typings/**/*.d.ts", "./samples/**/*.ts"], + "exclude": ["node_modules", "./types/**/*.d.ts", "./samples/**/*.ts"], "include": ["./src/**/*.ts", "./test/**/*.ts"] } From 00fb0584e750f1916cd9f8a4e0d62093f04a1e7a Mon Sep 17 00:00:00 2001 From: chradek Date: Wed, 5 Jun 2019 09:34:35 -0700 Subject: [PATCH 09/11] [core-aborter] rename sdk/core/aborter to sdk/core/core-aborter --- .docsettings.yml | 1 + rush.json | 4 ++++ sdk/core/{aborter => core-aborter}/LICENSE | 0 sdk/core/{aborter => core-aborter}/README.md | 0 sdk/core/{aborter => core-aborter}/api-extractor.json | 0 sdk/core/{aborter => core-aborter}/karma.conf.js | 0 .../mocha.reporter.config.json | 0 sdk/core/{aborter => core-aborter}/package.json | 10 +++++----- .../review/core-aborter.api.md | 0 .../{aborter => core-aborter}/rollup.base.config.js | 0 sdk/core/{aborter => core-aborter}/rollup.config.js | 0 .../{aborter => core-aborter}/rollup.test.config.js | 0 sdk/core/{aborter => core-aborter}/src/aborter.ts | 0 .../{aborter => core-aborter}/test/aborter.spec.ts | 0 sdk/core/{aborter => core-aborter}/tsconfig.json | 0 15 files changed, 10 insertions(+), 5 deletions(-) rename sdk/core/{aborter => core-aborter}/LICENSE (100%) rename sdk/core/{aborter => core-aborter}/README.md (100%) rename sdk/core/{aborter => core-aborter}/api-extractor.json (100%) rename sdk/core/{aborter => core-aborter}/karma.conf.js (100%) rename sdk/core/{aborter => core-aborter}/mocha.reporter.config.json (100%) rename sdk/core/{aborter => core-aborter}/package.json (83%) rename sdk/core/{aborter => core-aborter}/review/core-aborter.api.md (100%) rename sdk/core/{aborter => core-aborter}/rollup.base.config.js (100%) rename sdk/core/{aborter => core-aborter}/rollup.config.js (100%) rename sdk/core/{aborter => core-aborter}/rollup.test.config.js (100%) rename sdk/core/{aborter => core-aborter}/src/aborter.ts (100%) rename sdk/core/{aborter => core-aborter}/test/aborter.spec.ts (100%) rename sdk/core/{aborter => core-aborter}/tsconfig.json (100%) diff --git a/.docsettings.yml b/.docsettings.yml index e4ff4d21ee41..c75faab0ebd4 100644 --- a/.docsettings.yml +++ b/.docsettings.yml @@ -60,6 +60,7 @@ known_content_issues: - ["sdk/cognitiveservices/cognitiveservices-visualsearch/README.md", "#1583"] - ["sdk/cognitiveservices/cognitiveservices-websearch/README.md", "#1583"] - ["sdk/eventgrid/eventgrid/README.md", "#1583"] + - ["sdk/core/core-aborter/README.md", "#1583"] - ["sdk/core/core-http/README.md", "#1583"] - ["sdk/cosmosdb/cosmos/README.md", "#1583"] - ["sdk/cosmosdb/cosmos/src/test/readme.md", "#1583"] diff --git a/rush.json b/rush.json index a15f482f58c1..36b497cd9557 100644 --- a/rush.json +++ b/rush.json @@ -314,6 +314,10 @@ "packageName": "@azure/amqp-common", "projectFolder": "sdk/core/amqp-common" }, + { + "packageName": "@azure/core-aborter", + "projectFolder": "sdk/core/core-aborter" + }, { "packageName": "@azure/core-http", "projectFolder": "sdk/core/core-http" diff --git a/sdk/core/aborter/LICENSE b/sdk/core/core-aborter/LICENSE similarity index 100% rename from sdk/core/aborter/LICENSE rename to sdk/core/core-aborter/LICENSE diff --git a/sdk/core/aborter/README.md b/sdk/core/core-aborter/README.md similarity index 100% rename from sdk/core/aborter/README.md rename to sdk/core/core-aborter/README.md diff --git a/sdk/core/aborter/api-extractor.json b/sdk/core/core-aborter/api-extractor.json similarity index 100% rename from sdk/core/aborter/api-extractor.json rename to sdk/core/core-aborter/api-extractor.json diff --git a/sdk/core/aborter/karma.conf.js b/sdk/core/core-aborter/karma.conf.js similarity index 100% rename from sdk/core/aborter/karma.conf.js rename to sdk/core/core-aborter/karma.conf.js diff --git a/sdk/core/aborter/mocha.reporter.config.json b/sdk/core/core-aborter/mocha.reporter.config.json similarity index 100% rename from sdk/core/aborter/mocha.reporter.config.json rename to sdk/core/core-aborter/mocha.reporter.config.json diff --git a/sdk/core/aborter/package.json b/sdk/core/core-aborter/package.json similarity index 83% rename from sdk/core/aborter/package.json rename to sdk/core/core-aborter/package.json index bae9aa7a70bb..1dd00b755d0d 100644 --- a/sdk/core/aborter/package.json +++ b/sdk/core/core-aborter/package.json @@ -25,11 +25,11 @@ "pack": "npm pack 2>&1", "prebuild": "npm run clean", "pretest": "npm run build:test", - "test:browser": "karma start --single-run", - "test:node": "cross-env TS_NODE_COMPILER_OPTIONS=\"{\\\"module\\\": \\\"commonjs\\\"}\" mocha --require ts-node/register --require source-map-support/register --reporter mocha-multi-reporters --reporter-options configFile=mocha.reporter.config.json --full-trace --no-timeouts test/*.spec.ts", - "test": "npm run test:node && npm run test:browser", - "unit-test:browser": "npm run build && npm run test:browser", - "unit-test:node": "npm run build && npm run test:node", + "test:browser": "npm run build:test && npm run unit-test:browser && npm run integration-test:browser", + "test:node": "npm run build:test && npm run unit-test:node && npm run integration-test:node", + "test": "npm run build:test && npm run unit-test && npm run integration-test", + "unit-test:browser": "karma start --single-run", + "unit-test:node": "cross-env TS_NODE_COMPILER_OPTIONS=\"{\\\"module\\\": \\\"commonjs\\\"}\" mocha --require ts-node/register --require source-map-support/register --reporter mocha-multi-reporters --reporter-options configFile=mocha.reporter.config.json --full-trace --no-timeouts test/*.spec.ts", "unit-test": "npm run unit-test:node && npm run unit-test:browser" }, "types": "./types/src/aborter.d.ts", diff --git a/sdk/core/aborter/review/core-aborter.api.md b/sdk/core/core-aborter/review/core-aborter.api.md similarity index 100% rename from sdk/core/aborter/review/core-aborter.api.md rename to sdk/core/core-aborter/review/core-aborter.api.md diff --git a/sdk/core/aborter/rollup.base.config.js b/sdk/core/core-aborter/rollup.base.config.js similarity index 100% rename from sdk/core/aborter/rollup.base.config.js rename to sdk/core/core-aborter/rollup.base.config.js diff --git a/sdk/core/aborter/rollup.config.js b/sdk/core/core-aborter/rollup.config.js similarity index 100% rename from sdk/core/aborter/rollup.config.js rename to sdk/core/core-aborter/rollup.config.js diff --git a/sdk/core/aborter/rollup.test.config.js b/sdk/core/core-aborter/rollup.test.config.js similarity index 100% rename from sdk/core/aborter/rollup.test.config.js rename to sdk/core/core-aborter/rollup.test.config.js diff --git a/sdk/core/aborter/src/aborter.ts b/sdk/core/core-aborter/src/aborter.ts similarity index 100% rename from sdk/core/aborter/src/aborter.ts rename to sdk/core/core-aborter/src/aborter.ts diff --git a/sdk/core/aborter/test/aborter.spec.ts b/sdk/core/core-aborter/test/aborter.spec.ts similarity index 100% rename from sdk/core/aborter/test/aborter.spec.ts rename to sdk/core/core-aborter/test/aborter.spec.ts diff --git a/sdk/core/aborter/tsconfig.json b/sdk/core/core-aborter/tsconfig.json similarity index 100% rename from sdk/core/aborter/tsconfig.json rename to sdk/core/core-aborter/tsconfig.json From 639a55501cb10d77fea16728f3cd8e55cef6692b Mon Sep 17 00:00:00 2001 From: chradek Date: Wed, 5 Jun 2019 09:37:30 -0700 Subject: [PATCH 10/11] [core-aborter] updates pnpm-lock.yaml --- common/config/rush/pnpm-lock.yaml | 195 ++++++++++++++++++------------ 1 file changed, 119 insertions(+), 76 deletions(-) diff --git a/common/config/rush/pnpm-lock.yaml b/common/config/rush/pnpm-lock.yaml index ca776f9eb462..b1712cf2b0ea 100644 --- a/common/config/rush/pnpm-lock.yaml +++ b/common/config/rush/pnpm-lock.yaml @@ -7,6 +7,7 @@ dependencies: '@azure/ms-rest-nodeauth': 0.9.3 '@microsoft/api-extractor': 7.1.7 '@rush-temp/amqp-common': 'file:projects/amqp-common.tgz' + '@rush-temp/core-aborter': 'file:projects/core-aborter.tgz' '@rush-temp/core-http': 'file:projects/core-http.tgz' '@rush-temp/cosmos': 'file:projects/cosmos.tgz' '@rush-temp/event-hubs': 'file:projects/event-hubs.tgz' @@ -123,7 +124,7 @@ dependencies: rhea: 1.0.7 rhea-promise: 0.1.15 rimraf: 2.6.3 - rollup: 1.13.1 + rollup: 1.14.2 rollup-plugin-alias: 1.5.2 rollup-plugin-commonjs: 9.3.4 rollup-plugin-inject: 2.2.0 @@ -2093,7 +2094,7 @@ packages: /browserslist/3.2.8: dependencies: caniuse-lite: 1.0.30000973 - electron-to-chromium: 1.3.145 + electron-to-chromium: 1.3.146 dev: false hasBin: true resolution: @@ -3131,10 +3132,10 @@ packages: dev: false resolution: integrity: sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0= - /electron-to-chromium/1.3.145: + /electron-to-chromium/1.3.146: dev: false resolution: - integrity: sha512-2uDL0CszZ002mkJsgorZv15YNz8xKuOOi/MfnMnGla9J6p/j4zicc0RkcpZzMZZOJb6H2CJXOxC3PK98aQunEQ== + integrity: sha512-BrUq08sx7eR4PCwLbjFxXmjcbDro6DSoc1pN8VCxq76U+o9JQzJlWH/NVtcpAqcktwpE5CVvMyqHqTQfCETNoQ== /elliptic/6.4.1: dependencies: bn.js: 4.11.8 @@ -5335,11 +5336,11 @@ packages: rollup: '>= 1.0.0' resolution: integrity: sha512-/a7bBtinT4+fdbnatCh5ZWvbqIqPzse7O3tvT4x9tadXsxPqybo1Lilpe7AKEmvhAcUwGRlcLOWeV66lIPFrXQ== - /karma-rollup-preprocessor/7.0.0_rollup@1.13.1: + /karma-rollup-preprocessor/7.0.0_rollup@1.14.2: dependencies: chokidar: 2.1.6 debounce: 1.2.0 - rollup: 1.13.1 + rollup: 1.14.2 dev: false engines: node: '>= 8.0.0' @@ -7652,12 +7653,12 @@ packages: rollup: '>=0.56.0' resolution: integrity: sha512-DTZOvRoiVIHHLFBCL4pFxOaJt8pagxsVldEXBOn6wl3/V21wVaj17HFfyzTsQUuou3sZL3lEJZVWKPFblJfI6w== - /rollup-plugin-commonjs/9.3.4_rollup@1.13.1: + /rollup-plugin-commonjs/9.3.4_rollup@1.14.2: dependencies: estree-walker: 0.6.1 magic-string: 0.25.2 resolve: 1.11.0 - rollup: 1.13.1 + rollup: 1.14.2 rollup-pluginutils: 2.8.1 dev: false peerDependencies: @@ -7731,9 +7732,9 @@ packages: rollup: '>=0.31.2' resolution: integrity: sha1-YhJaqUCHqt97g+9N+vYptHMTXoc= - /rollup-plugin-sourcemaps/0.4.2_rollup@1.13.1: + /rollup-plugin-sourcemaps/0.4.2_rollup@1.14.2: dependencies: - rollup: 1.13.1 + rollup: 1.14.2 rollup-pluginutils: 2.8.1 source-map-resolve: 0.5.2 dev: false @@ -7755,11 +7756,11 @@ packages: rollup: '>=0.66.0 <2' resolution: integrity: sha512-wPANT5XKVJJ8RDUN0+wIr7UPd0lIXBo4UdJ59VmlPCtlFsE20AM+14pe+tk7YunCsWEiuzkDBY3QIkSCjtrPXg== - /rollup-plugin-terser/4.0.4_rollup@1.13.1: + /rollup-plugin-terser/4.0.4_rollup@1.14.2: dependencies: '@babel/code-frame': 7.0.0 jest-worker: 24.6.0 - rollup: 1.13.1 + rollup: 1.14.2 serialize-javascript: 1.7.0 terser: 3.17.0 dev: false @@ -7778,11 +7779,11 @@ packages: rollup: '>=0.66.0 <2' resolution: integrity: sha512-qwz2Tryspn5QGtPUowq5oumKSxANKdrnfz7C0jm4lKxvRDsNe/hSGsB9FntUul7UeC4TsZEWKErVgE1qWSO0gw== - /rollup-plugin-uglify/6.0.2_rollup@1.13.1: + /rollup-plugin-uglify/6.0.2_rollup@1.14.2: dependencies: '@babel/code-frame': 7.0.0 jest-worker: 24.6.0 - rollup: 1.13.1 + rollup: 1.14.2 serialize-javascript: 1.7.0 uglify-js: 3.6.0 dev: false @@ -7803,11 +7804,11 @@ packages: rollup: '>=0.60.0' resolution: integrity: sha512-7xkSKp+dyJmSC7jg2LXqViaHuOnF1VvIFCnsZEKjrgT5ZVyiLLSbeszxFcQSfNJILphqgAEmWAUz0Z4xYScrRw== - /rollup-plugin-visualizer/1.1.1_rollup@1.13.1: + /rollup-plugin-visualizer/1.1.1_rollup@1.14.2: dependencies: mkdirp: 0.5.1 opn: 5.5.0 - rollup: 1.13.1 + rollup: 1.14.2 source-map: 0.7.3 typeface-oswald: 0.0.54 dev: false @@ -7823,7 +7824,7 @@ packages: dev: false resolution: integrity: sha512-J5oAoysWar6GuZo0s+3bZ6sVZAC0pfqKz68De7ZgDi5z63jOVZn1uJL/+z1jeKHNbGII8kAyHF5q8LnxSX5lQg== - /rollup/1.13.1: + /rollup/1.14.2: dependencies: '@types/estree': 0.0.39 '@types/node': 12.0.4 @@ -7831,7 +7832,7 @@ packages: dev: false hasBin: true resolution: - integrity: sha512-TWBmVU5WS4wOy5Ij2qxrJYRUn/keECvStcXDpJSwgr95JZ6VFf1PDewiAk4VPf5vxr7drRJlxh9kYpxHveYOOg== + integrity: sha512-rFFIbi8UqFdZMRwYj+wVGQFTPBu++CDfbdlM10OZIpxrsRIgafos3cbGhXWxXo5jyRBB98u+0lEkdsvdE0IiyQ== /run-async/2.3.0: dependencies: is-promise: 2.1.0 @@ -9792,8 +9793,8 @@ packages: rhea: 1.0.7 rhea-promise: 0.1.15 rimraf: 2.6.3 - rollup: 1.13.1 - rollup-plugin-commonjs: 9.3.4_rollup@1.13.1 + rollup: 1.14.2 + rollup-plugin-commonjs: 9.3.4_rollup@1.14.2 rollup-plugin-inject: 2.2.0 rollup-plugin-json: 3.1.0 rollup-plugin-multi-entry: 2.1.0 @@ -9801,8 +9802,8 @@ packages: rollup-plugin-node-resolve: 4.2.4 rollup-plugin-replace: 2.2.0 rollup-plugin-shim: 1.0.0 - rollup-plugin-sourcemaps: 0.4.2_rollup@1.13.1 - rollup-plugin-uglify: 6.0.2_rollup@1.13.1 + rollup-plugin-sourcemaps: 0.4.2_rollup@1.14.2 + rollup-plugin-uglify: 6.0.2_rollup@1.14.2 sinon: 7.3.2 stream-browserify: 2.0.2 ts-node: 7.0.1 @@ -9815,9 +9816,50 @@ packages: dev: false name: '@rush-temp/amqp-common' resolution: - integrity: sha512-6/TjvEwJ0nNRfQOLu9FCRORtACz2FSaP2BLMekbSGycTXETwLgcYXTPrQPxApYvWQf52jML2coAD1+b2gbMe/Q== + integrity: sha512-+GIw7m23Lu6QMeIpFgFuHIYOVLwyDyg1I81R2bXUi9+/YBqh2UQbjoHPKbfCaDn7UkQ+7dgvMROeCNUS13FvpQ== tarball: 'file:projects/amqp-common.tgz' version: 0.0.0 + 'file:projects/core-aborter.tgz': + dependencies: + '@azure/ms-rest-js': 1.8.10 + '@microsoft/api-extractor': 7.1.7 + '@types/mocha': 5.2.7 + '@types/node': 8.10.49 + assert: 1.5.0 + cross-env: 5.2.0 + delay: 4.2.0 + karma: 4.1.0 + karma-chrome-launcher: 2.2.0 + karma-coverage: 1.1.2 + karma-edge-launcher: 0.4.2_karma@4.1.0 + karma-env-preprocessor: 0.1.1 + karma-firefox-launcher: 1.1.0 + karma-ie-launcher: 1.0.0_karma@4.1.0 + karma-junit-reporter: 1.2.0_karma@4.1.0 + karma-mocha: 1.3.0 + karma-mocha-reporter: 2.2.5_karma@4.1.0 + karma-remap-coverage: 0.1.5_karma-coverage@1.1.2 + mocha: 5.2.0 + mocha-junit-reporter: 1.22.0_mocha@5.2.0 + mocha-multi-reporters: 1.1.7 + nyc: 14.1.1 + prettier: 1.17.1 + rimraf: 2.6.3 + rollup: 1.14.2 + rollup-plugin-commonjs: 9.3.4_rollup@1.14.2 + rollup-plugin-multi-entry: 2.1.0 + rollup-plugin-node-resolve: 4.2.4 + rollup-plugin-replace: 2.2.0 + rollup-plugin-sourcemaps: 0.4.2_rollup@1.14.2 + rollup-plugin-uglify: 6.0.2_rollup@1.14.2 + tslib: 1.9.3 + typescript: 3.5.1 + dev: false + name: '@rush-temp/core-aborter' + resolution: + integrity: sha512-5gXxVFysKSs4h8jggD5hpaTCQ9houBi+dYz6w+6JAvKofNDT/NYJp6q4uvjdjspwLw7vYwERwUeN6+MlzXNrgA== + tarball: 'file:projects/core-aborter.tgz' + version: 0.0.0 'file:projects/core-http.tgz': dependencies: '@azure/logger-js': 1.1.0 @@ -9847,7 +9889,7 @@ packages: karma-chai: 0.1.0_chai@4.2.0+karma@4.1.0 karma-chrome-launcher: 2.2.0 karma-mocha: 1.3.0 - karma-rollup-preprocessor: 7.0.0_rollup@1.13.1 + karma-rollup-preprocessor: 7.0.0_rollup@1.14.2 karma-sourcemap-loader: 0.3.7 karma-typescript-es6-transform: 4.1.0 karma-webpack: 4.0.0-rc.6_webpack@4.33.0 @@ -9860,15 +9902,15 @@ packages: opn-cli: 4.1.0 puppeteer: 1.17.0 rimraf: 2.6.3 - rollup: 1.13.1 + rollup: 1.14.2 rollup-plugin-alias: 1.5.2 - rollup-plugin-commonjs: 9.3.4_rollup@1.13.1 + rollup-plugin-commonjs: 9.3.4_rollup@1.14.2 rollup-plugin-json: 3.1.0 rollup-plugin-multi-entry: 2.1.0 rollup-plugin-node-resolve: 4.2.4 rollup-plugin-resolve: 0.0.1-predev.1 - rollup-plugin-sourcemaps: 0.4.2_rollup@1.13.1 - rollup-plugin-visualizer: 1.1.1_rollup@1.13.1 + rollup-plugin-sourcemaps: 0.4.2_rollup@1.14.2 + rollup-plugin-visualizer: 1.1.1_rollup@1.14.2 semver: 5.7.0 shx: 0.3.2 sinon: 7.3.2 @@ -9891,7 +9933,7 @@ packages: dev: false name: '@rush-temp/core-http' resolution: - integrity: sha512-E9dUWK/fMKVHAhCK7Z848WsZOErJDTV531+SUyeJ5YvAQyiD0D4+oEzaU8xb/fXDD2vGmzd/ttfXbsW7cimNLw== + integrity: sha512-T3U+WVtmX5X8t51w0Gif9CLWlbK6aqlRThQpr8zS/VpzSPV8lr5lTinaQNHuVYS+ctiQnsCwPCwpA60CMdQwbQ== tarball: 'file:projects/core-http.tgz' version: 0.0.0 'file:projects/cosmos.tgz': @@ -9927,7 +9969,7 @@ packages: dev: false name: '@rush-temp/cosmos' resolution: - integrity: sha512-YQgXDVnkcyIiUgCN2IXIG9LcD5C8+v8oBJ3hu11GMAazLEZEAPP0Qu3ko3cnIXsQj6l+3GJb6p3MkauHxKZZnA== + integrity: sha512-TOCQxf0WCu5cMmRg0MctcaHctzwWutcqwTA3XgzcCtCCNwzBVphmtVm5zNNUqQcBzagPy9B2NOTdFAr0kHzs1g== tarball: 'file:projects/cosmos.tgz' version: 0.0.0 'file:projects/event-hubs.tgz': @@ -9970,16 +10012,16 @@ packages: prettier: 1.17.1 rhea-promise: 0.1.15 rimraf: 2.6.3 - rollup: 1.13.1 - rollup-plugin-commonjs: 9.3.4_rollup@1.13.1 + rollup: 1.14.2 + rollup-plugin-commonjs: 9.3.4_rollup@1.14.2 rollup-plugin-inject: 2.2.0 rollup-plugin-json: 3.1.0 rollup-plugin-multi-entry: 2.1.0 rollup-plugin-node-resolve: 4.2.4 rollup-plugin-replace: 2.2.0 rollup-plugin-shim: 1.0.0 - rollup-plugin-sourcemaps: 0.4.2_rollup@1.13.1 - rollup-plugin-uglify: 6.0.2_rollup@1.13.1 + rollup-plugin-sourcemaps: 0.4.2_rollup@1.14.2 + rollup-plugin-uglify: 6.0.2_rollup@1.14.2 ts-node: 7.0.1 tslib: 1.9.3 tslint: 5.17.0_typescript@3.5.1 @@ -9989,7 +10031,7 @@ packages: dev: false name: '@rush-temp/event-hubs' resolution: - integrity: sha512-cG4Z5gFK5dVSig4PGGsRfEgBwUxT8gPLqbNJZEkahGiXBSZVqy8EEzFoy3hM/4dxrF2pehz5ja7zRoZT1WDRlA== + integrity: sha512-DX8kn5TAG30fzLmnOr1oubzF6HZSRr8E5p7oFeQ7KVpaiJHIi0YdK04xiMtMapqx1mM1jjev9Mdum4H03u/Psw== tarball: 'file:projects/event-hubs.tgz' version: 0.0.0 'file:projects/event-processor-host.tgz': @@ -10029,14 +10071,14 @@ packages: path-browserify: 1.0.0 prettier: 1.17.1 rimraf: 2.6.3 - rollup: 1.13.1 - rollup-plugin-commonjs: 9.3.4_rollup@1.13.1 + rollup: 1.14.2 + rollup-plugin-commonjs: 9.3.4_rollup@1.14.2 rollup-plugin-json: 3.1.0 rollup-plugin-multi-entry: 2.1.0 rollup-plugin-node-resolve: 4.2.4 rollup-plugin-replace: 2.2.0 - rollup-plugin-sourcemaps: 0.4.2_rollup@1.13.1 - rollup-plugin-uglify: 6.0.2_rollup@1.13.1 + rollup-plugin-sourcemaps: 0.4.2_rollup@1.14.2 + rollup-plugin-uglify: 6.0.2_rollup@1.14.2 ts-node: 7.0.1 tslib: 1.9.3 tslint: 5.17.0_typescript@3.5.1 @@ -10045,7 +10087,7 @@ packages: dev: false name: '@rush-temp/event-processor-host' resolution: - integrity: sha512-6LOgcg0Uz7i3zndSQ+a19fVlecwkezWT/J0XWL+aPszyT5JBcSBdxVNZA4NOjawIXRiy3vOX6c45xU50OjPNTA== + integrity: sha512-QDRNiNUiUb14TZvNnffJR54IzpRoRlBXoLFq+TGsJpuiuuLF3SGoFzI+jnd0drCMwTZr3rRskm1z8BL9mXnwqg== tarball: 'file:projects/event-processor-host.tgz' version: 0.0.0 'file:projects/keyvault-keys.tgz': @@ -10057,8 +10099,8 @@ packages: chai: 4.2.0 prettier: 1.17.1 rimraf: 2.6.3 - rollup: 1.13.1 - rollup-plugin-commonjs: 9.3.4_rollup@1.13.1 + rollup: 1.14.2 + rollup-plugin-commonjs: 9.3.4_rollup@1.14.2 rollup-plugin-node-resolve: 4.2.4 tslib: 1.9.3 typescript: 3.5.1 @@ -10066,7 +10108,7 @@ packages: dev: false name: '@rush-temp/keyvault-keys' resolution: - integrity: sha512-3le7qEz7hoCxCK+BEoDPg1EtnqE4FnZxgS9Iy+yE4NksyD/1SHPTd0zN2F/JrKPxJIWPh78ZRuwEc1fNYzcItA== + integrity: sha512-jgNzwEZwR2AuPCol+ASbEHvjL9PlatdG6peUn9NWg8m3b3Q6H06tJXTRcA8MYHVNRw+2XmLbrocNE/a9loHJrg== tarball: 'file:projects/keyvault-keys.tgz' version: 0.0.0 'file:projects/keyvault-secrets.tgz': @@ -10078,8 +10120,8 @@ packages: chai: 4.2.0 prettier: 1.17.1 rimraf: 2.6.3 - rollup: 1.13.1 - rollup-plugin-commonjs: 9.3.4_rollup@1.13.1 + rollup: 1.14.2 + rollup-plugin-commonjs: 9.3.4_rollup@1.14.2 rollup-plugin-node-resolve: 4.2.4 tslib: 1.9.3 typescript: 3.5.1 @@ -10087,7 +10129,7 @@ packages: dev: false name: '@rush-temp/keyvault-secrets' resolution: - integrity: sha512-PC3oNCKcjyQhHGRKoQF2zjtRnxkdM5aof3yBu3wRJf60NxyveVY5aPlmQnv3kW6nIGACjWuOg7jtarciTG4l1Q== + integrity: sha512-Vf1jmb7M1HpBBFohSOL3K9lwx4dvzn//v2Ozn+keHq194ROe7o6xdAcc/VKGXy4RtC/L2T5oSpwk8AmqZRS7CA== tarball: 'file:projects/keyvault-secrets.tgz' version: 0.0.0 'file:projects/service-bus.tgz': @@ -10147,16 +10189,16 @@ packages: rhea: 1.0.7 rhea-promise: 0.1.15 rimraf: 2.6.3 - rollup: 1.13.1 - rollup-plugin-commonjs: 9.3.4_rollup@1.13.1 + rollup: 1.14.2 + rollup-plugin-commonjs: 9.3.4_rollup@1.14.2 rollup-plugin-inject: 2.2.0 rollup-plugin-json: 3.1.0 rollup-plugin-multi-entry: 2.1.0 rollup-plugin-node-resolve: 4.2.4 rollup-plugin-replace: 2.2.0 rollup-plugin-shim: 1.0.0 - rollup-plugin-sourcemaps: 0.4.2_rollup@1.13.1 - rollup-plugin-terser: 4.0.4_rollup@1.13.1 + rollup-plugin-sourcemaps: 0.4.2_rollup@1.14.2 + rollup-plugin-terser: 4.0.4_rollup@1.14.2 ts-node: 7.0.1 tslib: 1.9.3 tslint: 5.16.0_typescript@3.5.1 @@ -10165,7 +10207,7 @@ packages: dev: false name: '@rush-temp/service-bus' resolution: - integrity: sha512-scfR34SyQYHqDwiOkIVnK/GSYNHNqql73bKjsO3cwMARBnkb/MsllwOnj9o0S81KP88ZtOD2pnkrQN7mcjR5bg== + integrity: sha512-xgW6JX0wi8/Gfm+78e2qEl8udBlvDar6umDODSBbjBidyRyez20cAh6dRQy1J5DwTckX/dellxeDo+FsSGlfig== tarball: 'file:projects/service-bus.tgz' version: 0.0.0 'file:projects/storage-blob.tgz': @@ -10209,15 +10251,15 @@ packages: prettier: 1.17.1 puppeteer: 1.17.0 rimraf: 2.6.3 - rollup: 1.13.1 - rollup-plugin-commonjs: 9.3.4_rollup@1.13.1 + rollup: 1.14.2 + rollup-plugin-commonjs: 9.3.4_rollup@1.14.2 rollup-plugin-multi-entry: 2.1.0 rollup-plugin-node-resolve: 4.2.4 rollup-plugin-replace: 2.2.0 rollup-plugin-shim: 1.0.0 - rollup-plugin-sourcemaps: 0.4.2_rollup@1.13.1 - rollup-plugin-uglify: 6.0.2_rollup@1.13.1 - rollup-plugin-visualizer: 1.1.1_rollup@1.13.1 + rollup-plugin-sourcemaps: 0.4.2_rollup@1.14.2 + rollup-plugin-uglify: 6.0.2_rollup@1.14.2 + rollup-plugin-visualizer: 1.1.1_rollup@1.14.2 source-map-support: 0.5.12 ts-node: 7.0.1 tslib: 1.9.3 @@ -10226,7 +10268,7 @@ packages: dev: false name: '@rush-temp/storage-blob' resolution: - integrity: sha512-W2RMqiAgipexCGkPRRY6cG8uL6WWdx4wuJZOPTUjQfXZb8Dzw7cgKdV3OhWqJJZIh4LyHnc8xLidzw7bmZ2+fg== + integrity: sha512-TJpS56wG8qiDClHG16xTT7gCEcFVauAUYfeAaDduOsESMJVlu1cRGUgEt648o6EF+2Z3lzkiFLxGYTtY5jJFyg== tarball: 'file:projects/storage-blob.tgz' version: 0.0.0 'file:projects/storage-file.tgz': @@ -10270,15 +10312,15 @@ packages: prettier: 1.17.1 puppeteer: 1.17.0 rimraf: 2.6.3 - rollup: 1.13.1 - rollup-plugin-commonjs: 9.3.4_rollup@1.13.1 + rollup: 1.14.2 + rollup-plugin-commonjs: 9.3.4_rollup@1.14.2 rollup-plugin-multi-entry: 2.1.0 rollup-plugin-node-resolve: 4.2.4 rollup-plugin-replace: 2.2.0 rollup-plugin-shim: 1.0.0 - rollup-plugin-sourcemaps: 0.4.2_rollup@1.13.1 - rollup-plugin-uglify: 6.0.2_rollup@1.13.1 - rollup-plugin-visualizer: 1.1.1_rollup@1.13.1 + rollup-plugin-sourcemaps: 0.4.2_rollup@1.14.2 + rollup-plugin-uglify: 6.0.2_rollup@1.14.2 + rollup-plugin-visualizer: 1.1.1_rollup@1.14.2 source-map-support: 0.5.12 ts-node: 7.0.1 tslib: 1.9.3 @@ -10287,7 +10329,7 @@ packages: dev: false name: '@rush-temp/storage-file' resolution: - integrity: sha512-IggwmF9FMAoNRoePe8hFn6NocobTvIrGU+jBfEe/Ba+CrNzdN0jIKyjXTg6P9ofKvD1RUKkCXChQR6dVWhuHwQ== + integrity: sha512-+a+8c5vSweLlJAnnh+i/AoCDZfbMgZehduTk6K1wVPRRFVBO4YvziRTf16pHj/ej+uL5HKPLV0XeKKPCwhkugg== tarball: 'file:projects/storage-file.tgz' version: 0.0.0 'file:projects/storage-queue.tgz': @@ -10330,15 +10372,15 @@ packages: prettier: 1.17.1 puppeteer: 1.17.0 rimraf: 2.6.3 - rollup: 1.13.1 - rollup-plugin-commonjs: 9.3.4_rollup@1.13.1 + rollup: 1.14.2 + rollup-plugin-commonjs: 9.3.4_rollup@1.14.2 rollup-plugin-multi-entry: 2.1.0 rollup-plugin-node-resolve: 4.2.4 rollup-plugin-replace: 2.2.0 rollup-plugin-shim: 1.0.0 - rollup-plugin-sourcemaps: 0.4.2_rollup@1.13.1 - rollup-plugin-uglify: 6.0.2_rollup@1.13.1 - rollup-plugin-visualizer: 1.1.1_rollup@1.13.1 + rollup-plugin-sourcemaps: 0.4.2_rollup@1.14.2 + rollup-plugin-uglify: 6.0.2_rollup@1.14.2 + rollup-plugin-visualizer: 1.1.1_rollup@1.14.2 source-map-support: 0.5.12 ts-node: 7.0.1 tslib: 1.9.3 @@ -10347,7 +10389,7 @@ packages: dev: false name: '@rush-temp/storage-queue' resolution: - integrity: sha512-3uiXLFzFdHRLcTjagTminJ9Lne4klR2QTI3szXdQQo0etG2pawPwm+W6+NGwxLhq+SaPOi7AVPRS/Fh6pYLTUg== + integrity: sha512-WlLovzgNMYtwa5bZ5z3Njkgk/66w2AhcyU0ApgShKQYLYr1rurLOH/vPwfbqKb/rq+f5CBlcQN2s+JAxP9dO8Q== tarball: 'file:projects/storage-queue.tgz' version: 0.0.0 'file:projects/template.tgz': @@ -10372,22 +10414,22 @@ packages: mocha-multi: 1.1.0_mocha@5.2.0 prettier: 1.17.1 rimraf: 2.6.3 - rollup: 1.13.1 - rollup-plugin-commonjs: 9.3.4_rollup@1.13.1 + rollup: 1.14.2 + rollup-plugin-commonjs: 9.3.4_rollup@1.14.2 rollup-plugin-json: 3.1.0 rollup-plugin-multi-entry: 2.1.0 rollup-plugin-node-resolve: 4.2.4 rollup-plugin-replace: 2.2.0 - rollup-plugin-sourcemaps: 0.4.2_rollup@1.13.1 - rollup-plugin-uglify: 6.0.2_rollup@1.13.1 - rollup-plugin-visualizer: 1.1.1_rollup@1.13.1 + rollup-plugin-sourcemaps: 0.4.2_rollup@1.14.2 + rollup-plugin-uglify: 6.0.2_rollup@1.14.2 + rollup-plugin-visualizer: 1.1.1_rollup@1.14.2 tslib: 1.9.3 typescript: 3.5.1 util: 0.11.1 dev: false name: '@rush-temp/template' resolution: - integrity: sha512-M4lKSJH4L7LqMkIyYttlPEyPoVDhmEpBCLcU7erMsgE1yOac8BZeV4UBGz/vg9iiEH6ByUZZwhk9l1VRywIBiw== + integrity: sha512-lW73pJFOdcpLI5d2G2ueKQW9FPJTzB4Lh1nJphQaEooylwwp4D/cr0qaoDm37H7ovBU/24wD9OSkczTrHAmSkg== tarball: 'file:projects/template.tgz' version: 0.0.0 'file:projects/testhub.tgz': @@ -10412,7 +10454,7 @@ packages: dev: false name: '@rush-temp/testhub' resolution: - integrity: sha512-zbODslMIEBAdmUsDIlwLbxG1R2sPMry3/X/1rpHF0+ahxw0rTbSoolEXBli+WR8Omnes5/O/EcdnDpFCaw6xKQ== + integrity: sha512-c3cFI0Our99carkgcyOFLmX5QRh5fIqyVv9S75VRX7woNtBGXPvWRE8VOxEN9o8N8FjSEQzc6PPEO6YRz7ok8Q== tarball: 'file:projects/testhub.tgz' version: 0.0.0 registry: '' @@ -10425,6 +10467,7 @@ specifiers: '@azure/ms-rest-nodeauth': ^0.9.2 '@microsoft/api-extractor': ^7.1.5 '@rush-temp/amqp-common': 'file:./projects/amqp-common.tgz' + '@rush-temp/core-aborter': 'file:./projects/core-aborter.tgz' '@rush-temp/core-http': 'file:./projects/core-http.tgz' '@rush-temp/cosmos': 'file:./projects/cosmos.tgz' '@rush-temp/event-hubs': 'file:./projects/event-hubs.tgz' From ee748ef4364d570f791576d132adc1f3abd27ffb Mon Sep 17 00:00:00 2001 From: chradek Date: Wed, 5 Jun 2019 16:42:52 -0700 Subject: [PATCH 11/11] add untrimmedFilePath to api-extractor.json --- sdk/core/core-aborter/api-extractor.json | 1 + 1 file changed, 1 insertion(+) diff --git a/sdk/core/core-aborter/api-extractor.json b/sdk/core/core-aborter/api-extractor.json index 04d20e605c21..b915f2ef1523 100644 --- a/sdk/core/core-aborter/api-extractor.json +++ b/sdk/core/core-aborter/api-extractor.json @@ -10,6 +10,7 @@ }, "dtsRollup": { "enabled": true, + "untrimmedFilePath": "", "publicTrimmedFilePath": "./types/aborter.d.ts" }, "messages": {