Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Key Vault] Full LRO refactoring #12630

Merged
merged 16 commits into from
Nov 25, 2020
1 change: 1 addition & 0 deletions sdk/keyvault/keyvault-admin/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

## 4.0.0-beta.2 (Unreleased)

- Updated the Key Vault Admin Long Running Operation Pollers to follow a more compact and meaningful approach moving forward.

## 4.0.0-beta.1 (2020-09-11)

Expand Down
31 changes: 12 additions & 19 deletions sdk/keyvault/keyvault-admin/review/keyvault-admin.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,7 @@ export interface BackupClientOptions extends coreHttp.PipelineOptions {
}

// @public
export interface BackupOperationState extends PollOperationState<string> {
endTime?: Date;
jobId?: string;
startTime?: Date;
status?: string;
statusDetails?: string;
}
export type BackupOperationState = KeyVaultAdminPollOperationState<string>;

// @public
export interface BackupPollerOptions extends coreHttp.OperationOptions {
Expand Down Expand Up @@ -70,6 +64,15 @@ export class KeyVaultAccessControlClient {
readonly vaultUrl: string;
}

// @public
export interface KeyVaultAdminPollOperationState<TResult> extends PollOperationState<TResult> {
endTime?: Date;
jobId?: string;
startTime?: Date;
status?: string;
statusDetails?: string;
}

// @public
export class KeyVaultBackupClient {
constructor(vaultUrl: string, credential: TokenCredential, pipelineOptions?: BackupClientOptions);
Expand Down Expand Up @@ -142,12 +145,7 @@ export interface ListRoleDefinitionsPageSettings {
}

// @public
export interface RestoreOperationState extends PollOperationState<undefined> {
endTime?: Date;
jobId?: string;
startTime?: Date;
status?: string;
statusDetails?: string;
export interface RestoreOperationState extends KeyVaultAdminPollOperationState<undefined> {
}

// @public
Expand All @@ -157,12 +155,7 @@ export type RoleAssignmentScope = "/" | "/keys" | string;
export const SDK_VERSION: string;

// @public
export interface SelectiveRestoreOperationState extends PollOperationState<undefined> {
endTime?: Date;
jobId?: string;
startTime?: Date;
status?: string;
statusDetails?: string;
export interface SelectiveRestoreOperationState extends KeyVaultAdminPollOperationState<undefined> {
}

// @public
Expand Down
2 changes: 1 addition & 1 deletion sdk/keyvault/keyvault-admin/src/accessControlClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ import {
} from "./accessControlModels";

import { SDK_VERSION, LATEST_API_VERSION } from "./constants";
import { createSpan, setParentSpan } from "./tracing";
import { createSpan, setParentSpan } from "../../keyvault-common/src";
import { mappings } from "./mappings";
import { logger } from "./log";

Expand Down
8 changes: 7 additions & 1 deletion sdk/keyvault/keyvault-admin/src/backupClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,15 @@ import { RestorePoller } from "./lro/restore/poller";
import { SelectiveRestorePoller } from "./lro/selectiveRestore/poller";
import { BackupOperationState } from "./lro/backup/operation";
import { RestoreOperationState } from "./lro/restore/operation";
import { KeyVaultAdminPollOperationState } from "./lro/keyVaultAdminPoller";
import { SelectiveRestoreOperationState } from "./lro/selectiveRestore/operation";

export { BackupOperationState, RestoreOperationState, SelectiveRestoreOperationState };
export {
BackupOperationState,
RestoreOperationState,
SelectiveRestoreOperationState,
KeyVaultAdminPollOperationState
};

/**
* The KeyVaultBackupClient provides methods to generate backups
Expand Down
Loading