update the strings (#5904)

* update the strings

* PR comments and remove the workaround
This commit is contained in:
Alan Ren
2019-06-06 13:03:03 -07:00
committed by GitHub
parent 76a84a2cf4
commit 1150433c0a
15 changed files with 45 additions and 73 deletions

View File

@@ -43,6 +43,12 @@
}
],
"menus": {
"commandPalette": [
{
"command": "azdata.resource.deploy",
"when": "false"
}
],
"dataExplorer/action": [
{
"command": "azdata.resource.sql-image.deploy",
@@ -125,8 +131,8 @@
"displayName": "%version-display-name%",
"values": [
{
"name": "ctp3.0",
"displayName": "%sql-2019ctp30-display-name%"
"name": "ctp3.1",
"displayName": "%sql-2019ctp31-display-name%"
}
]
},
@@ -147,7 +153,7 @@
],
"providers": [
{
"notebook": "%bdc-ctp30-aks-notebook%",
"notebook": "%bdc-ctp31-aks-notebook%",
"requiredTools": [
{
"name": "kubectl"
@@ -159,10 +165,10 @@
"name": "mssqlctl"
}
],
"when": "target=aks&&version=ctp3.0"
"when": "target=aks&&version=ctp3.1"
},
{
"notebook": "%bdc-ctp30-existing-cluster-notebook%",
"notebook": "%bdc-ctp31-existing-cluster-notebook%",
"requiredTools": [
{
"name": "kubectl"
@@ -171,7 +177,7 @@
"name": "mssqlctl"
}
],
"when": "target=existingCluster&&version=ctp3.0"
"when": "target=existingCluster&&version=ctp3.1"
}
]
}

View File

@@ -1,23 +1,23 @@
{
"extension-displayName": "Resource Deployment extension for Azure Data Studio",
"extension-description": "Provides a notebook-based experience to deploy SQL Server and other Azure Data Services",
"extension-displayName": "SQL Server Deployment extension for Azure Data Studio",
"extension-description": "Provides a notebook-based experience to deploy Microsoft SQL Server",
"deploy-sql-image-command-name": "Deploy SQL Server on Docker…",
"deploy-sql-bdc-command-name": "Deploy SQL Server Big Data Cluster…",
"deploy-sql-bdc-command-name": "Deploy SQL Server big data cluster…",
"deploy-resource-command-name": "Deploy SQL Server…",
"deploy-resource-command-category": "Resource Deployment",
"resource-type-sql-image-display-name": "Container Image",
"resource-type-sql-image-description": "SQL Server container image on Docker",
"resource-type-sql-bdc-display-name": "Big Data Cluster",
"resource-type-sql-bdc-description": "SQL Server Big Data Cluster",
"deploy-resource-command-category": "Deployment",
"resource-type-sql-image-display-name": "SQL Server container image",
"resource-type-sql-image-description": "Run SQL Server container image with Docker",
"resource-type-sql-bdc-display-name": "SQL Server big data cluster",
"resource-type-sql-bdc-description": "SQL Server big data cluster allows you to deploy scalable clusters of SQL Server, Spark, and HDFS containers running on Kubernetes",
"version-display-name": "Version",
"sql-2017-display-name": "SQL Server 2017",
"sql-2019-display-name": "SQL Server 2019",
"sql-2017-docker-notebook": "./notebooks/sql2017-image-docker.ipynb",
"sql-2019-docker-notebook": "./notebooks/sql2019-image-docker.ipynb",
"sql-2019ctp30-display-name": "SQL Server 2019 Big Data Cluster CTP 3.0",
"sql-2017-docker-notebook": "./notebooks/docker/2017/deploy-sql2017-image.ipynb",
"sql-2019-docker-notebook": "./notebooks/docker/2019/deploy-sql2019-image.ipynb",
"sql-2019ctp31-display-name": "SQL Server 2019 big data cluster CTP 3.1",
"bdc-deployment-target": "Deployment target",
"bdc-deployment-target-aks": "New Azure Kubernetes Service Cluster",
"bdc-deployment-target-existing-cluster": "Existing Kubernetes Cluster",
"bdc-ctp30-aks-notebook": "./notebooks/sql2019-ctp30-bdc-aks.ipynb",
"bdc-ctp30-existing-cluster-notebook": "./notebooks/sql2019-ctp30-bdc-existing-cluster.ipynb"
"bdc-ctp31-aks-notebook": "./notebooks/bdc/2019/ctp3-1/deploy-bdc-aks.ipynb",
"bdc-ctp31-existing-cluster-notebook": "./notebooks/bdc/2019/ctp3-1/deploy-bdc-existing-cluster.ipynb"
}

View File

@@ -47,7 +47,6 @@ export enum ToolType {
AzCli,
KubeCtl,
Docker,
Python,
MSSQLCtl
}

View File

@@ -13,7 +13,7 @@ export class AzCliTool implements ITool {
}
get description(): string {
return localize('resourceDeployment.AzCLIDescription', 'Tool used for managing Azure services');
return localize('resourceDeployment.AzCLIDescription', 'A command-line tool for managing Azure resources');
}
get type(): ToolType {

View File

@@ -13,7 +13,7 @@ export class DockerTool implements ITool {
}
get description(): string {
return localize('resourceDeployment.DockerDescription', 'Manages the containers');
return localize('resourceDeployment.DockerDescription', 'Provides the ability to package and run an application in isolated containers');
}
get type(): ToolType {

View File

@@ -13,7 +13,7 @@ export class KubeCtlTool implements ITool {
}
get description(): string {
return localize('resourceDeployment.KubeCtlDescription', 'Tool used for managing the Kubernetes cluster');
return localize('resourceDeployment.KubeCtlDescription', 'A command-line tool allows you to run commands against Kubernetes clusters');
}
get type(): ToolType {

View File

@@ -13,7 +13,7 @@ export class MSSQLCtlTool implements ITool {
}
get description(): string {
return localize('resourceDeployment.MssqlCtlDescription', 'Command-line tool for installing and managing the SQL Server big data cluster');
return localize('resourceDeployment.MssqlCtlDescription', 'A command-line utility written in Python that enables cluster administrators to bootstrap and manage the big data cluster via REST APIs');
}
get type(): ToolType {

View File

@@ -1,26 +0,0 @@
/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the Source EULA. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
'use strict';
import { ToolType, ITool } from '../../interfaces';
import * as nls from 'vscode-nls';
const localize = nls.loadMessageBundle();
export class PythonTool implements ITool {
get name(): string {
return 'python';
}
get description(): string {
return localize('resourceDeployment.PythonDescription', 'Required by notebook feature');
}
get type(): ToolType {
return ToolType.Python;
}
get displayName(): string {
return localize('resourceDeployment.PythonDisplayName', 'Python');
}
}

View File

@@ -4,7 +4,6 @@
*--------------------------------------------------------------------------------------------*/
'use strict';
import { ITool } from '../interfaces';
import { PythonTool } from './tools/pythonTool';
import { DockerTool } from './tools/dockerTool';
import { AzCliTool } from './tools/azCliTool';
import { MSSQLCtlTool } from './tools/mssqlCtlTool';
@@ -16,7 +15,7 @@ export interface IToolsService {
export class ToolsService implements IToolsService {
constructor() {
this.SupportedTools = [new PythonTool(), new DockerTool(), new AzCliTool(), new MSSQLCtlTool(), new KubeCtlTool()];
this.SupportedTools = [new DockerTool(), new AzCliTool(), new MSSQLCtlTool(), new KubeCtlTool()];
}
private SupportedTools: ITool[];

View File

@@ -20,8 +20,7 @@ suite('Tools Service Tests', function (): void {
{ name: 'azcli', type: ToolType.AzCli },
{ name: 'docker', type: ToolType.Docker },
{ name: 'kubectl', type: ToolType.KubeCtl },
{ name: 'mssqlctl', type: ToolType.MSSQLCtl },
{ name: 'python', type: ToolType.Python }];
{ name: 'mssqlctl', type: ToolType.MSSQLCtl }];
const missingTypes: string[] = [];

View File

@@ -32,9 +32,9 @@ export class ResourceDeploymentDialog {
private resourceTypeService: IResourceTypeService,
resourceType: ResourceType) {
this._selectedResourceType = resourceType;
this._dialogObject = azdata.window.createModelViewDialog(localize('deploymentDialog.title', 'Select a configuration'), 'resourceDeploymentDialog', true);
this._dialogObject = azdata.window.createModelViewDialog(localize('deploymentDialog.title', 'Select the deployment options'), 'resourceDeploymentDialog', true);
this._dialogObject.cancelButton.onClick(() => this.onCancel());
this._dialogObject.okButton.label = localize('deploymentDialog.OKButtonText', 'Select');
this._dialogObject.okButton.label = localize('deploymentDialog.OKButtonText', 'Open Notebook');
this._dialogObject.okButton.onClick(() => this.onComplete());
}
@@ -89,11 +89,11 @@ export class ResourceDeploymentDialog {
const form = formBuilder.withLayout({ width: '100%' }).component();
if (this._selectedResourceType) {
this.selectResourceType(this._selectedResourceType);
}
return view.initializeModel(form);
return view.initializeModel(form).then(() => {
if (this._selectedResourceType) {
this.selectResourceType(this._selectedResourceType);
}
});
});
this._dialogObject.content = [tab];
}
@@ -160,18 +160,13 @@ export class ResourceDeploymentDialog {
}
private updateTools(): void {
// do a 10 ms delay to workaround the issue of first time load:
// during initialization this update to table will be processed prior to the table initialization update
// as a result the data will be overwritten, introduce a short delay so that the order of updates can be maintained.
setTimeout(() => {
const tools = this.getCurrentProvider().requiredTools;
const headerRowHeight = 28;
this._toolsTable.height = 25 * tools.length + headerRowHeight;
this._toolsTable.data = tools.map(toolRef => {
const tool = this.toolsService.getToolByName(toolRef.name)!;
return [tool.displayName, tool.description];
});
}, 10);
const tools = this.getCurrentProvider().requiredTools;
const headerRowHeight = 28;
this._toolsTable.height = 25 * tools.length + headerRowHeight;
this._toolsTable.data = tools.map(toolRef => {
const tool = this.toolsService.getToolByName(toolRef.name)!;
return [tool.displayName, tool.description];
});
}
private getCurrentProvider(): DeploymentProvider {