Files
azuredatastudio/extensions/arc/src/typings/arc.d.ts
Charles Gagnon febd8b29c9 Arc updates for March release (#14970)
* Updated Postgres Spec for where to find engine version, removed calling calling -ev in edit commands (#14735)

* Added spec.engine.version, took out calling engine version with edit calls

* Added text wrong place

* missed updates

* PR fix

* Update Arc Postgres troubleshooting notebook

Co-authored-by: Brian Bergeron <brberger@microsoft.com>

* Remove AzdataSession from azdata commands (#14856)

* remove session

* Add in controller-context support

* Revert "Add in controller-context support"

This reverts commit 3b39b968efbf6054041cb01cb2d8443532643a82.

* Add azdataContext to login

* Undo book change

* Undo change correctly

* Add controller context support (#14862)

* remove session

* Add in controller-context support

* Add params to fake

* Fix tests

* Add info and placeholder for controller URL/name (#14887)

* Add info and placeholder for controller URL

* add period + update name

* update memento and allow editing of namespace/URL

* vBump

* vBump

* Fix tests

Co-authored-by: nasc17 <69922333+nasc17@users.noreply.github.com>
Co-authored-by: Brian Bergeron <brian.e.bergeron@gmail.com>
Co-authored-by: Brian Bergeron <brberger@microsoft.com>
2021-04-05 11:47:36 -07:00

58 lines
1.7 KiB
TypeScript

/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the Source EULA. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
declare module 'arc' {
/**
* Covers defining what the arc extension exports to other extensions
*
* IMPORTANT: THIS IS NOT A HARD DEFINITION unlike vscode; therefore no enums or classes should be defined here
* (const enums get evaluated when typescript -> javascript so those are fine)
*/
export const enum extension {
name = 'Microsoft.arc'
}
export const enum ResourceType {
dataControllers = 'dataControllers',
postgresInstances = 'postgresInstances',
sqlManagedInstances = 'sqlManagedInstances'
}
export type MiaaResourceInfo = ResourceInfo & {
userName?: string
};
export type PGResourceInfo = ResourceInfo & {
userName?: string
};
export type ResourceInfo = {
name: string,
resourceType: ResourceType | string,
connectionId?: string
};
export type ControllerInfo = {
id: string,
kubeConfigFilePath: string,
kubeClusterContext: string
endpoint: string | undefined,
namespace: string,
name: string,
username: string,
rememberPassword: boolean,
resources: ResourceInfo[]
};
export interface DataController {
label: string,
info: ControllerInfo
}
export interface IExtension {
getRegisteredDataControllers(): Promise<DataController[]>;
getControllerPassword(controllerInfo: ControllerInfo): Promise<string>;
reacquireControllerPassword(controllerInfo: ControllerInfo, password: string, retryCount?: number): Promise<string>;
}
}