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
16 changes: 3 additions & 13 deletions sdk/applicationinsights/arm-appinsights/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,18 +1,8 @@
# Release History

## 5.0.0-beta.4 (2022-05-31)

## 5.0.0-beta.4 (Unreleased)

### Features Added

### Breaking Changes

### Bugs Fixed

### Other Changes

## 5.0.0-beta.3 (2022-03-15)

The package of @azure/arm-appinsights is using our next generation design principles since version 5.0.0-beta.3, which contains breaking changes.
The package of @azure/arm-appinsights is using our next generation design principles since version 5.0.0-beta.4, which contains breaking changes.

To understand the detail of the change, please refer to [Changelog](https://aka.ms/js-track2-changelog).

Expand Down
8 changes: 4 additions & 4 deletions sdk/applicationinsights/arm-appinsights/_meta.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"commit": "e432d9cc87bfed320d8feead4b448be9481c9181",
"commit": "6b99a68f01d4ff7da9fcf5d6d315652ebc1d3031",
"readme": "specification/applicationinsights/resource-manager/readme.md",
"autorest_command": "autorest --version=3.7.3 --typescript --modelerfour.lenient-model-deduplication --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\mydev\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\applicationinsights\\resource-manager\\readme.md --use=@autorest/[email protected]beta.16",
"autorest_command": "autorest --version=3.7.3 --typescript --modelerfour.lenient-model-deduplication --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/applicationinsights/resource-manager/readme.md --use=@autorest/[email protected]alpha.19.20220425.1",
"repository_url": "https://github.com/Azure/azure-rest-api-specs.git",
"release_tool": "@azure-tools/js-sdk-release-tools@2.1.1",
"use": "@autorest/[email protected]beta.16"
"release_tool": "@azure-tools/js-sdk-release-tools@2.3.1",
"use": "@autorest/[email protected]alpha.19.20220425.1"
}
14 changes: 8 additions & 6 deletions sdk/applicationinsights/arm-appinsights/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
},
"dependencies": {
"@azure/core-paging": "^1.2.0",
"@azure/core-client": "^1.0.0",
"@azure/core-client": "^1.5.0",
"@azure/core-auth": "^1.3.0",
"@azure/core-rest-pipeline": "^1.1.0",
"@azure/core-rest-pipeline": "^1.8.0",
"tslib": "^2.2.0"
},
"keywords": [
Expand All @@ -38,9 +38,11 @@
"uglify-js": "^3.4.9",
"rimraf": "^3.0.0",
"@azure/identity": "^2.0.1",
"@azure-tools/test-recorder": "^1.0.0",
"@azure-tools/test-recorder": "^2.0.0",
"@azure-tools/test-credential": "^1.0.0",
"mocha": "^7.1.1",
"cross-env": "^7.0.2"
"cross-env": "^7.0.2",
"@azure/dev-tool": "^1.0.0"
},
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/applicationinsights/arm-appinsights",
"repository": {
Expand Down Expand Up @@ -91,7 +93,7 @@
"unit-test:node": "cross-env TEST_MODE=playback npm run integration-test:node",
"unit-test:browser": "echo skipped",
"integration-test": "npm run integration-test:node && npm run integration-test:browser",
"integration-test:node": "mocha -r esm --require ts-node/register --timeout 1200000 --full-trace test/*.ts --reporter ../../../common/tools/mocha-multi-reporter.js",
"integration-test:node": "dev-tool run test:node-ts-input -- --timeout 1200000 'test/*.ts'",
"integration-test:browser": "echo skipped",
"docs": "echo skipped"
},
Expand All @@ -105,4 +107,4 @@
]
},
"autoPublish": true
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -968,17 +968,21 @@ export enum KnownRequestSource {
}

// @public
export enum KnownSharedTypeKind {
export enum KnownStorageType {
// (undocumented)
Shared = "shared",
ServiceProfiler = "ServiceProfiler"
}

// @public
export enum KnownWorkbookSharedTypeKind {
// (undocumented)
User = "user"
Shared = "shared"
}

// @public
export enum KnownStorageType {
export enum KnownWorkbookUpdateSharedTypeKind {
// (undocumented)
ServiceProfiler = "ServiceProfiler"
Shared = "shared"
}

// @public
Expand Down Expand Up @@ -1238,9 +1242,6 @@ export interface Resource {
readonly type?: string;
}

// @public
export type SharedTypeKind = string;

// @public
export type StorageType = string;

Expand Down Expand Up @@ -1447,7 +1448,7 @@ export interface WorkbookInnerErrorTrace {
// @public
export type WorkbookResource = TrackedResource & {
identity?: WorkbookResourceIdentity;
kind?: Kind;
kind?: WorkbookSharedTypeKind;
etag?: string;
};

Expand Down Expand Up @@ -1486,6 +1487,9 @@ export interface WorkbooksGetOptionalParams extends coreClient.OperationOptions
// @public
export type WorkbooksGetResponse = Workbook;

// @public
export type WorkbookSharedTypeKind = string;

// @public
export interface WorkbooksListByResourceGroupNextOptionalParams extends coreClient.OperationOptions {
canFetchContent?: boolean;
Expand Down Expand Up @@ -1683,7 +1687,7 @@ export interface WorkbookUpdateParameters {
category?: string;
description?: string;
displayName?: string;
kind?: SharedTypeKind;
kind?: WorkbookUpdateSharedTypeKind;
revision?: string;
serializedData?: string;
tags?: {
Expand All @@ -1692,6 +1696,9 @@ export interface WorkbookUpdateParameters {
tagsPropertiesTags?: string[];
}

// @public
export type WorkbookUpdateSharedTypeKind = string;

// @public
export interface WorkItemConfiguration {
configDisplayName?: string;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
*/

import * as coreClient from "@azure/core-client";
import * as coreRestPipeline from "@azure/core-rest-pipeline";
import * as coreAuth from "@azure/core-auth";
import {
AnnotationsImpl,
Expand Down Expand Up @@ -98,9 +99,33 @@ export class ApplicationInsightsManagementClient extends coreClient.ServiceClien
userAgentOptions: {
userAgentPrefix
},
baseUri: options.endpoint || "https://management.azure.com"
baseUri:
options.endpoint ?? options.baseUri ?? "https://management.azure.com"
};
super(optionsWithDefaults);

if (options?.pipeline && options.pipeline.getOrderedPolicies().length > 0) {
const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = options.pipeline.getOrderedPolicies();
const bearerTokenAuthenticationPolicyFound = pipelinePolicies.some(
(pipelinePolicy) =>
pipelinePolicy.name ===
coreRestPipeline.bearerTokenAuthenticationPolicyName
);
if (!bearerTokenAuthenticationPolicyFound) {
this.pipeline.removePolicy({
name: coreRestPipeline.bearerTokenAuthenticationPolicyName
});
this.pipeline.addPolicy(
coreRestPipeline.bearerTokenAuthenticationPolicy({
scopes: `${optionsWithDefaults.baseUri}/.default`,
challengeCallbacks: {
authorizeRequestOnChallenge:
coreClient.authorizeRequestOnClaimChallenge
}
})
);
}
}
// Parameter assignments
this.subscriptionId = subscriptionId;

Expand Down
32 changes: 22 additions & 10 deletions sdk/applicationinsights/arm-appinsights/src/models/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -924,7 +924,7 @@ export interface WorkbookErrorDefinition {
/** The parameters that can be provided when updating workbook properties properties. */
export interface WorkbookUpdateParameters {
/** The kind of workbook. Only valid value is shared. */
kind?: SharedTypeKind;
kind?: WorkbookUpdateSharedTypeKind;
/** Resource tags. */
tags?: { [propertyName: string]: string };
/** The user-defined name (display name) of the workbook. */
Expand Down Expand Up @@ -1341,7 +1341,7 @@ export type WorkbookResource = TrackedResource & {
/** Identity used for BYOS */
identity?: WorkbookResourceIdentity;
/** The kind of workbook. Only valid value is shared. */
kind?: Kind;
kind?: WorkbookSharedTypeKind;
/** Resource etag */
etag?: string;
};
Expand All @@ -1352,7 +1352,7 @@ export type ComponentLinkedStorageAccounts = ProxyResource & {
linkedStorageAccount?: string;
};

/** An Application Insights workbook definition. */
/** A workbook definition. */
export type Workbook = WorkbookResource & {
/**
* Metadata pertaining to creation and last modification of the resource.
Expand Down Expand Up @@ -1586,21 +1586,33 @@ export enum KnownManagedServiceIdentityType {
*/
export type ManagedServiceIdentityType = string;

/** Known values of {@link SharedTypeKind} that the service accepts. */
export enum KnownSharedTypeKind {
User = "user",
/** Known values of {@link WorkbookSharedTypeKind} that the service accepts. */
export enum KnownWorkbookSharedTypeKind {
Shared = "shared"
}

/**
* Defines values for SharedTypeKind. \
* {@link KnownSharedTypeKind} can be used interchangeably with SharedTypeKind,
* Defines values for WorkbookSharedTypeKind. \
* {@link KnownWorkbookSharedTypeKind} can be used interchangeably with WorkbookSharedTypeKind,
* this enum contains the known values that the service supports.
* ### Known values supported by the service
* **shared**
*/
export type WorkbookSharedTypeKind = string;

/** Known values of {@link WorkbookUpdateSharedTypeKind} that the service accepts. */
export enum KnownWorkbookUpdateSharedTypeKind {
Shared = "shared"
}

/**
* Defines values for WorkbookUpdateSharedTypeKind. \
* {@link KnownWorkbookUpdateSharedTypeKind} can be used interchangeably with WorkbookUpdateSharedTypeKind,
* this enum contains the known values that the service supports.
* ### Known values supported by the service
* **user** \
* **shared**
*/
export type SharedTypeKind = string;
export type WorkbookUpdateSharedTypeKind = string;

/** Known values of {@link ApplicationType} that the service accepts. */
export enum KnownApplicationType {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -357,7 +357,7 @@ export const scope: OperationQueryParameter = {
};

export const typeParam: OperationQueryParameter = {
parameterPath: ["options", "typeParam"],
parameterPath: ["options", "type"],
mapper: {
defaultValue: "none",
serializedName: "type",
Expand Down Expand Up @@ -475,7 +475,7 @@ export const workbookProperties: OperationParameter = {
export const apiVersion3: OperationQueryParameter = {
parameterPath: "apiVersion",
mapper: {
defaultValue: "2021-08-01",
defaultValue: "2022-04-01",
isConstant: true,
serializedName: "api-version",
type: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ export class WorkbooksImpl implements Workbooks {
/**
* Get the revisions for the workbook defined by its resourceName.
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the Application Insights component resource.
* @param resourceName The name of the resource.
* @param options The options parameters.
*/
public listRevisionsList(
Expand Down Expand Up @@ -281,7 +281,7 @@ export class WorkbooksImpl implements Workbooks {
/**
* Get a single workbook by its resourceName.
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the Application Insights component resource.
* @param resourceName The name of the resource.
* @param options The options parameters.
*/
get(
Expand All @@ -298,7 +298,7 @@ export class WorkbooksImpl implements Workbooks {
/**
* Delete a workbook.
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the Application Insights component resource.
* @param resourceName The name of the resource.
* @param options The options parameters.
*/
delete(
Expand All @@ -315,7 +315,7 @@ export class WorkbooksImpl implements Workbooks {
/**
* Create a new workbook.
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the Application Insights component resource.
* @param resourceName The name of the resource.
* @param workbookProperties Properties that need to be specified to create a new workbook.
* @param options The options parameters.
*/
Expand All @@ -334,7 +334,7 @@ export class WorkbooksImpl implements Workbooks {
/**
* Updates a workbook that has already been added.
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the Application Insights component resource.
* @param resourceName The name of the resource.
* @param options The options parameters.
*/
update(
Expand All @@ -351,7 +351,7 @@ export class WorkbooksImpl implements Workbooks {
/**
* Get the revisions for the workbook defined by its resourceName.
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the Application Insights component resource.
* @param resourceName The name of the resource.
* @param options The options parameters.
*/
private _revisionsList(
Expand All @@ -368,7 +368,7 @@ export class WorkbooksImpl implements Workbooks {
/**
* Get a single workbook revision defined by its revisionId.
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the Application Insights component resource.
* @param resourceName The name of the resource.
* @param revisionId The id of the workbook's revision.
* @param options The options parameters.
*/
Expand Down Expand Up @@ -423,7 +423,7 @@ export class WorkbooksImpl implements Workbooks {
/**
* RevisionsListNext
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the Application Insights component resource.
* @param resourceName The name of the resource.
* @param nextLink The nextLink from the previous successful call to the RevisionsList method.
* @param options The options parameters.
*/
Expand Down
Loading