Skip to content

Commit 97b584f

Browse files
author
SDKAuto
committed
CodeGen from PR 15498 in Azure/azure-rest-api-specs
Merge 1ca26568d1c6f609bc0d3ad677d52bac02ede56e into 6bb4782e4dff98197e3bb79e7a2d6625d5185656
1 parent 3b51a6e commit 97b584f

14 files changed

+309
-39
lines changed

sdk/databricks/arm-databricks/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
"rollup-plugin-sourcemaps": "^0.4.2",
2828
"uglify-js": "^3.6.0"
2929
},
30-
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/feature/v4/sdk/databricks/arm-databricks",
30+
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/databricks/arm-databricks",
3131
"repository": {
3232
"type": "git",
3333
"url": "https://github.com/Azure/azure-sdk-for-js.git"

sdk/databricks/arm-databricks/src/azureDatabricksManagementClient.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ class AzureDatabricksManagementClient extends AzureDatabricksManagementClientCon
2121
operations: operations.Operations;
2222
privateLinkResources: operations.PrivateLinkResources;
2323
privateEndpointConnections: operations.PrivateEndpointConnections;
24+
outboundNetworkDependenciesEndpoints: operations.OutboundNetworkDependenciesEndpoints;
2425
vNetPeering: operations.VNetPeering;
2526

2627
/**
@@ -40,6 +41,7 @@ class AzureDatabricksManagementClient extends AzureDatabricksManagementClientCon
4041
this.operations = new operations.Operations(this);
4142
this.privateLinkResources = new operations.PrivateLinkResources(this);
4243
this.privateEndpointConnections = new operations.PrivateEndpointConnections(this);
44+
this.outboundNetworkDependenciesEndpoints = new operations.OutboundNetworkDependenciesEndpoints(this);
4345
this.vNetPeering = new operations.VNetPeering(this);
4446
}
4547
}

sdk/databricks/arm-databricks/src/azureDatabricksManagementClientContext.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ const packageVersion = "2.0.0";
1818
export class AzureDatabricksManagementClientContext extends msRestAzure.AzureServiceClient {
1919
credentials: msRest.ServiceClientCredentials | TokenCredential;
2020
subscriptionId: string;
21+
apiVersion?: string;
2122

2223
/**
2324
* Initializes a new instance of the AzureDatabricksManagementClient class.
@@ -48,6 +49,7 @@ export class AzureDatabricksManagementClientContext extends msRestAzure.AzureSer
4849

4950
super(credentials, options);
5051

52+
this.apiVersion = '2021-04-01-preview';
5153
this.acceptLanguage = 'en-US';
5254
this.longRunningOperationRetryTimeout = 30;
5355
this.baseUri = options.baseUri || this.baseUri || "https://management.azure.com";

sdk/databricks/arm-databricks/src/models/index.ts

Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -640,6 +640,58 @@ export interface GroupIdInformation extends Resource {
640640
properties: GroupIdInformationProperties;
641641
}
642642

643+
/**
644+
* Connect information from the Workspace to a single endpoint.
645+
*/
646+
export interface EndpointDetail {
647+
/**
648+
* An IP Address that Domain Name currently resolves to.
649+
*/
650+
ipAddress?: string;
651+
/**
652+
* The port an endpoint is connected to.
653+
*/
654+
port?: number;
655+
/**
656+
* The time in milliseconds it takes for the connection to be created from the Workspace to this
657+
* IpAddress at this Port.
658+
*/
659+
latency?: number;
660+
/**
661+
* Whether it is possible to create a connection from the Workspace to this IpAddress at this
662+
* Port.
663+
*/
664+
isAccessible?: boolean;
665+
}
666+
667+
/**
668+
* A domain name or IP address the Workspace is reaching at.
669+
*/
670+
export interface EndpointDependency {
671+
/**
672+
* The domain name of the dependency.
673+
*/
674+
domainName?: string;
675+
/**
676+
* The Ports used when connecting to domainName.
677+
*/
678+
endpointDetails?: EndpointDetail[];
679+
}
680+
681+
/**
682+
* Egress endpoints which Workspace connects to for common purposes.
683+
*/
684+
export interface OutboundEnvironmentEndpoint {
685+
/**
686+
* The category of endpoints accessed by the Workspace, e.g. azure-storage, azure-mysql, etc.
687+
*/
688+
category?: string;
689+
/**
690+
* The endpoints that Workspace connect to
691+
*/
692+
endpoints?: EndpointDependency[];
693+
}
694+
643695
/**
644696
* The remote virtual network should be in the same region. See here to learn more
645697
* (https://docs.microsoft.com/en-us/azure/databricks/administration-guide/cloud-configurations/azure/vnet-peering).
@@ -1274,6 +1326,26 @@ export type PrivateEndpointConnectionsListNextResponse = PrivateEndpointConnecti
12741326
};
12751327
};
12761328

1329+
/**
1330+
* Contains response data for the list operation.
1331+
*/
1332+
export type OutboundNetworkDependenciesEndpointsListResponse = Array<OutboundEnvironmentEndpoint> & {
1333+
/**
1334+
* The underlying HTTP response.
1335+
*/
1336+
_response: msRest.HttpResponse & {
1337+
/**
1338+
* The response body as text (string format)
1339+
*/
1340+
bodyAsText: string;
1341+
1342+
/**
1343+
* The response body as parsed JSON or XML
1344+
*/
1345+
parsedBody: OutboundEnvironmentEndpoint[];
1346+
};
1347+
};
1348+
12771349
/**
12781350
* Contains response data for the get operation.
12791351
*/

sdk/databricks/arm-databricks/src/models/mappers.ts

Lines changed: 90 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1043,6 +1043,96 @@ export const GroupIdInformation: msRest.CompositeMapper = {
10431043
}
10441044
};
10451045

1046+
export const EndpointDetail: msRest.CompositeMapper = {
1047+
serializedName: "EndpointDetail",
1048+
type: {
1049+
name: "Composite",
1050+
className: "EndpointDetail",
1051+
modelProperties: {
1052+
ipAddress: {
1053+
serializedName: "ipAddress",
1054+
type: {
1055+
name: "String"
1056+
}
1057+
},
1058+
port: {
1059+
serializedName: "port",
1060+
type: {
1061+
name: "Number"
1062+
}
1063+
},
1064+
latency: {
1065+
serializedName: "latency",
1066+
type: {
1067+
name: "Number"
1068+
}
1069+
},
1070+
isAccessible: {
1071+
serializedName: "isAccessible",
1072+
type: {
1073+
name: "Boolean"
1074+
}
1075+
}
1076+
}
1077+
}
1078+
};
1079+
1080+
export const EndpointDependency: msRest.CompositeMapper = {
1081+
serializedName: "EndpointDependency",
1082+
type: {
1083+
name: "Composite",
1084+
className: "EndpointDependency",
1085+
modelProperties: {
1086+
domainName: {
1087+
serializedName: "domainName",
1088+
type: {
1089+
name: "String"
1090+
}
1091+
},
1092+
endpointDetails: {
1093+
serializedName: "endpointDetails",
1094+
type: {
1095+
name: "Sequence",
1096+
element: {
1097+
type: {
1098+
name: "Composite",
1099+
className: "EndpointDetail"
1100+
}
1101+
}
1102+
}
1103+
}
1104+
}
1105+
}
1106+
};
1107+
1108+
export const OutboundEnvironmentEndpoint: msRest.CompositeMapper = {
1109+
serializedName: "OutboundEnvironmentEndpoint",
1110+
type: {
1111+
name: "Composite",
1112+
className: "OutboundEnvironmentEndpoint",
1113+
modelProperties: {
1114+
category: {
1115+
serializedName: "category",
1116+
type: {
1117+
name: "String"
1118+
}
1119+
},
1120+
endpoints: {
1121+
serializedName: "endpoints",
1122+
type: {
1123+
name: "Sequence",
1124+
element: {
1125+
type: {
1126+
name: "Composite",
1127+
className: "EndpointDependency"
1128+
}
1129+
}
1130+
}
1131+
}
1132+
}
1133+
}
1134+
};
1135+
10461136
export const VirtualNetworkPeeringPropertiesFormatDatabricksVirtualNetwork: msRest.CompositeMapper = {
10471137
serializedName: "VirtualNetworkPeeringPropertiesFormat_databricksVirtualNetwork",
10481138
type: {
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
/*
2+
* Copyright (c) Microsoft Corporation.
3+
* Licensed under the MIT License.
4+
*
5+
* Code generated by Microsoft (R) AutoRest Code Generator.
6+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
7+
*/
8+
9+
export {
10+
EndpointDependency,
11+
EndpointDetail,
12+
ErrorDetail,
13+
ErrorInfo,
14+
ErrorResponse,
15+
OutboundEnvironmentEndpoint
16+
} from "../models/mappers";

sdk/databricks/arm-databricks/src/models/parameters.ts

Lines changed: 1 addition & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -19,25 +19,11 @@ export const acceptLanguage: msRest.OperationParameter = {
1919
}
2020
}
2121
};
22-
export const apiVersion0: msRest.OperationQueryParameter = {
22+
export const apiVersion: msRest.OperationQueryParameter = {
2323
parameterPath: "apiVersion",
2424
mapper: {
2525
required: true,
26-
isConstant: true,
2726
serializedName: "api-version",
28-
defaultValue: '2021-04-01-preview',
29-
type: {
30-
name: "String"
31-
}
32-
}
33-
};
34-
export const apiVersion1: msRest.OperationQueryParameter = {
35-
parameterPath: "apiVersion",
36-
mapper: {
37-
required: true,
38-
isConstant: true,
39-
serializedName: "api-version",
40-
defaultValue: '2018-04-01',
4127
type: {
4228
name: "String"
4329
}

sdk/databricks/arm-databricks/src/operations/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,5 @@ export * from "./workspaces";
1111
export * from "./operations";
1212
export * from "./privateLinkResources";
1313
export * from "./privateEndpointConnections";
14+
export * from "./outboundNetworkDependenciesEndpoints";
1415
export * from "./vNetPeering";

sdk/databricks/arm-databricks/src/operations/operations.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ const listOperationSpec: msRest.OperationSpec = {
8484
httpMethod: "GET",
8585
path: "providers/Microsoft.Databricks/operations",
8686
queryParameters: [
87-
Parameters.apiVersion0
87+
Parameters.apiVersion
8888
],
8989
headerParameters: [
9090
Parameters.acceptLanguage
@@ -108,7 +108,7 @@ const listNextOperationSpec: msRest.OperationSpec = {
108108
Parameters.nextPageLink
109109
],
110110
queryParameters: [
111-
Parameters.apiVersion0
111+
Parameters.apiVersion
112112
],
113113
headerParameters: [
114114
Parameters.acceptLanguage
Lines changed: 101 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,101 @@
1+
/*
2+
* Copyright (c) Microsoft Corporation.
3+
* Licensed under the MIT License.
4+
*
5+
* Code generated by Microsoft (R) AutoRest Code Generator.
6+
* Changes may cause incorrect behavior and will be lost if the code is
7+
* regenerated.
8+
*/
9+
10+
import * as msRest from "@azure/ms-rest-js";
11+
import * as Models from "../models";
12+
import * as Mappers from "../models/outboundNetworkDependenciesEndpointsMappers";
13+
import * as Parameters from "../models/parameters";
14+
import { AzureDatabricksManagementClientContext } from "../azureDatabricksManagementClientContext";
15+
16+
/** Class representing a OutboundNetworkDependenciesEndpoints. */
17+
export class OutboundNetworkDependenciesEndpoints {
18+
private readonly client: AzureDatabricksManagementClientContext;
19+
20+
/**
21+
* Create a OutboundNetworkDependenciesEndpoints.
22+
* @param {AzureDatabricksManagementClientContext} client Reference to the service client.
23+
*/
24+
constructor(client: AzureDatabricksManagementClientContext) {
25+
this.client = client;
26+
}
27+
28+
/**
29+
* Gets the list of endpoints that VNET Injected Workspace's Cluster call Azure Databricks Control
30+
* Plane. You must configure outbound access to these endpoints. For more information, see
31+
* https://docs.microsoft.com/en-us/azure/databricks/administration-guide/cloud-configurations/azure/udr
32+
* @summary Gets a list of egress endpoints (network endpoints of all outbound dependencies) in the
33+
* specified Workspace.
34+
* @param resourceGroupName The name of the resource group. The name is case insensitive.
35+
* @param workspaceName The name of the workspace.
36+
* @param [options] The optional parameters
37+
* @returns Promise<Models.OutboundNetworkDependenciesEndpointsListResponse>
38+
*/
39+
list(resourceGroupName: string, workspaceName: string, options?: msRest.RequestOptionsBase): Promise<Models.OutboundNetworkDependenciesEndpointsListResponse>;
40+
/**
41+
* @param resourceGroupName The name of the resource group. The name is case insensitive.
42+
* @param workspaceName The name of the workspace.
43+
* @param callback The callback
44+
*/
45+
list(resourceGroupName: string, workspaceName: string, callback: msRest.ServiceCallback<Models.OutboundEnvironmentEndpoint[]>): void;
46+
/**
47+
* @param resourceGroupName The name of the resource group. The name is case insensitive.
48+
* @param workspaceName The name of the workspace.
49+
* @param options The optional parameters
50+
* @param callback The callback
51+
*/
52+
list(resourceGroupName: string, workspaceName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.OutboundEnvironmentEndpoint[]>): void;
53+
list(resourceGroupName: string, workspaceName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.OutboundEnvironmentEndpoint[]>, callback?: msRest.ServiceCallback<Models.OutboundEnvironmentEndpoint[]>): Promise<Models.OutboundNetworkDependenciesEndpointsListResponse> {
54+
return this.client.sendOperationRequest(
55+
{
56+
resourceGroupName,
57+
workspaceName,
58+
options
59+
},
60+
listOperationSpec,
61+
callback) as Promise<Models.OutboundNetworkDependenciesEndpointsListResponse>;
62+
}
63+
}
64+
65+
// Operation Specifications
66+
const serializer = new msRest.Serializer(Mappers);
67+
const listOperationSpec: msRest.OperationSpec = {
68+
httpMethod: "GET",
69+
path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Databricks/workspaces/{workspaceName}/outboundNetworkDependenciesEndpoints",
70+
urlParameters: [
71+
Parameters.resourceGroupName,
72+
Parameters.workspaceName,
73+
Parameters.subscriptionId
74+
],
75+
queryParameters: [
76+
Parameters.apiVersion
77+
],
78+
headerParameters: [
79+
Parameters.acceptLanguage
80+
],
81+
responses: {
82+
200: {
83+
bodyMapper: {
84+
serializedName: "parsedResponse",
85+
type: {
86+
name: "Sequence",
87+
element: {
88+
type: {
89+
name: "Composite",
90+
className: "OutboundEnvironmentEndpoint"
91+
}
92+
}
93+
}
94+
}
95+
},
96+
default: {
97+
bodyMapper: Mappers.ErrorResponse
98+
}
99+
},
100+
serializer
101+
};

0 commit comments

Comments
 (0)