Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
187 changes: 158 additions & 29 deletions common/config/rush/pnpm-lock.yaml

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions sdk/batch/arm-batch/_meta.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"commit": "64efc48302878a07d1d1231eaed0ca9cadfaf037",
"commit": "c10717e7d69bb8114fb1b248fad4cc16e517189d",
"readme": "specification/batch/resource-manager/readme.md",
"autorest_command": "autorest --version=3.9.3 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\Git\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\batch\\resource-manager\\readme.md --use=@autorest/[email protected].5 --generate-sample=true",
"autorest_command": "autorest --version=3.9.7 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/batch/resource-manager/readme.md --use=@autorest/typescript@^6.0.4",
"repository_url": "https://github.com/Azure/azure-rest-api-specs.git",
"release_tool": "@azure-tools/[email protected].0",
"use": "@autorest/[email protected].5"
"release_tool": "@azure-tools/[email protected].2",
"use": "@autorest/typescript@^6.0.4"
}
25 changes: 8 additions & 17 deletions sdk/batch/arm-batch/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@
"node": ">=14.0.0"
},
"dependencies": {
"@azure/core-lro": "^2.5.3",
"@azure/core-lro": "^2.5.4",
"@azure/abort-controller": "^1.0.0",
"@azure/core-paging": "^1.2.0",
"@azure/core-client": "^1.7.0",
"@azure/core-auth": "^1.3.0",
"@azure/core-rest-pipeline": "^1.8.0",
"@azure/core-rest-pipeline": "^1.12.0",
"tslib": "^2.2.0"
},
"keywords": [
Expand All @@ -38,7 +38,7 @@
"rollup-plugin-sourcemaps": "^0.6.3",
"typescript": "~5.0.0",
"uglify-js": "^3.4.9",
"rimraf": "^3.0.0",
"rimraf": "^5.0.0",
"dotenv": "^16.0.0",
"@azure/identity": "^2.0.1",
"@azure-tools/test-recorder": "^3.0.0",
Expand All @@ -48,9 +48,8 @@
"chai": "^4.2.0",
"cross-env": "^7.0.2",
"@types/node": "^14.0.0",
"@azure/dev-tool": "^1.0.0",
"@azure/arm-storage": "^17.1.0",
"ts-node": "^10.0.0"
"ts-node": "^10.0.0",
"@azure/dev-tool": "^1.0.0"
},
"repository": {
"type": "git",
Expand Down Expand Up @@ -85,7 +84,7 @@
"extract-api": "api-extractor run --local",
"lint": "echo skipped",
"audit": "echo skipped",
"clean": "rimraf dist dist-browser dist-esm test-dist temp types *.tgz *.log",
"clean": "rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log",
"build:node": "echo skipped",
"build:browser": "echo skipped",
"build:test": "echo skipped",
Expand Down Expand Up @@ -113,13 +112,5 @@
]
},
"autoPublish": true,
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/batch/arm-batch",
"//sampleConfiguration": {
"productName": "",
"productSlugs": [
"azure"
],
"disableDocsMs": true,
"apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-batch?view=azure-node-preview"
}
}
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/batch/arm-batch"
}
2 changes: 1 addition & 1 deletion sdk/batch/arm-batch/src/models/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -805,7 +805,7 @@ export interface StartTask {
environmentSettings?: EnvironmentSetting[];
/** If omitted, the task runs as a non-administrative user unique to the task. */
userIdentity?: UserIdentity;
/** The Batch service retries a task if its exit code is nonzero. Note that this value specifically controls the number of retries. The Batch service will try the task once, and may then retry up to this limit. For example, if the maximum retry count is 3, Batch tries the task up to 4 times (one initial try and 3 retries). If the maximum retry count is 0, the Batch service does not retry the task. If the maximum retry count is -1, the Batch service retries the task without limit. */
/** The Batch service retries a task if its exit code is nonzero. Note that this value specifically controls the number of retries. The Batch service will try the task once, and may then retry up to this limit. For example, if the maximum retry count is 3, Batch tries the task up to 4 times (one initial try and 3 retries). If the maximum retry count is 0, the Batch service does not retry the task. If the maximum retry count is -1, the Batch service retries the task without limit. Default is 0. */
maxTaskRetryCount?: number;
/** If true and the start task fails on a compute node, the Batch service retries the start task up to its maximum retry count (maxTaskRetryCount). If the task has still not completed successfully after all retries, then the Batch service marks the compute node unusable, and will not schedule tasks to it. This condition can be detected via the node state and scheduling error detail. If false, the Batch service will not wait for the start task to complete. In this case, other tasks can start executing on the compute node while the start task is still running; and even if the start task fails, new tasks will continue to be scheduled on the node. The default is true. */
waitForSuccess?: boolean;
Expand Down
6 changes: 6 additions & 0 deletions sdk/batch/arm-batch/src/models/mappers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1376,6 +1376,7 @@ export const ImageReference: coreClient.CompositeMapper = {
}
},
version: {
defaultValue: "latest",
serializedName: "version",
type: {
name: "String"
Expand Down Expand Up @@ -1688,6 +1689,7 @@ export const FixedScaleSettings: coreClient.CompositeMapper = {
className: "FixedScaleSettings",
modelProperties: {
resizeTimeout: {
defaultValue: "PT15M",
serializedName: "resizeTimeout",
type: {
name: "TimeSpan"
Expand Down Expand Up @@ -1819,6 +1821,7 @@ export const NetworkConfiguration: coreClient.CompositeMapper = {
}
},
dynamicVnetAssignmentScope: {
defaultValue: "none",
serializedName: "dynamicVnetAssignmentScope",
type: {
name: "Enum",
Expand Down Expand Up @@ -2003,6 +2006,7 @@ export const TaskSchedulingPolicy: coreClient.CompositeMapper = {
className: "TaskSchedulingPolicy",
modelProperties: {
nodeFillType: {
defaultValue: "Spread",
serializedName: "nodeFillType",
required: true,
type: {
Expand Down Expand Up @@ -2167,6 +2171,7 @@ export const StartTask: coreClient.CompositeMapper = {
}
},
maxTaskRetryCount: {
defaultValue: 0,
serializedName: "maxTaskRetryCount",
type: {
name: "Number"
Expand Down Expand Up @@ -3273,6 +3278,7 @@ export const Pool: coreClient.CompositeMapper = {
}
},
taskSlotsPerNode: {
defaultValue: 1,
serializedName: "properties.taskSlotsPerNode",
type: {
name: "Number"
Expand Down
4 changes: 2 additions & 2 deletions sdk/batch/arm-batch/src/operations/batchAccountOperations.ts
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,7 @@ export class BatchAccountOperationsImpl implements BatchAccountOperations {
* you must make sure your network allows outbound access to these endpoints. Failure to allow access
* to these endpoints may cause Batch to mark the affected nodes as unusable. For more information
* about creating a pool inside of a virtual network, see
* https://docs.microsoft.com/azure/batch/batch-virtual-network.
* https://docs.microsoft.com/en-us/azure/batch/batch-virtual-network.
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
* @param options The options parameters.
Expand Down Expand Up @@ -717,7 +717,7 @@ export class BatchAccountOperationsImpl implements BatchAccountOperations {
* you must make sure your network allows outbound access to these endpoints. Failure to allow access
* to these endpoints may cause Batch to mark the affected nodes as unusable. For more information
* about creating a pool inside of a virtual network, see
* https://docs.microsoft.com/azure/batch/batch-virtual-network.
* https://docs.microsoft.com/en-us/azure/batch/batch-virtual-network.
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
* @param options The options parameters.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ export interface BatchAccountOperations {
* you must make sure your network allows outbound access to these endpoints. Failure to allow access
* to these endpoints may cause Batch to mark the affected nodes as unusable. For more information
* about creating a pool inside of a virtual network, see
* https://docs.microsoft.com/azure/batch/batch-virtual-network.
* https://docs.microsoft.com/en-us/azure/batch/batch-virtual-network.
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
* @param options The options parameters.
Expand Down
43 changes: 43 additions & 0 deletions sdk/batch/arm-batch/test/sampleTest.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/

import {
Recorder,
RecorderStartOptions,
env
} from "@azure-tools/test-recorder";
import { assert } from "chai";
import { Context } from "mocha";

const replaceableVariables: Record<string, string> = {
AZURE_CLIENT_ID: "azure_client_id",
AZURE_CLIENT_SECRET: "azure_client_secret",
AZURE_TENANT_ID: "88888888-8888-8888-8888-888888888888",
SUBSCRIPTION_ID: "azure_subscription_id"
};

const recorderOptions: RecorderStartOptions = {
envSetupForPlayback: replaceableVariables
};

describe("My test", () => {
let recorder: Recorder;

beforeEach(async function(this: Context) {
recorder = new Recorder(this.currentTest);
await recorder.start(recorderOptions);
});

afterEach(async function() {
await recorder.stop();
});

it("sample test", async function() {
console.log("Hi, I'm a test!");
});
});
10 changes: 2 additions & 8 deletions sdk/batch/arm-batch/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,17 +15,11 @@
],
"declaration": true,
"outDir": "./dist-esm",
"importHelpers": true,
"paths": {
"@azure/arm-batch": [
"./src/index"
]
}
"importHelpers": true
},
"include": [
"./src/**/*.ts",
"./test/**/*.ts",
"samples-dev/**/*.ts"
"./test/**/*.ts"
],
"exclude": [
"node_modules"
Expand Down