Skip to content

Commit

Permalink
CodeGen from PR 25168 in Azure/azure-rest-api-specs
Browse files Browse the repository at this point in the history
Merge 3eba7b6855b227590026b68a1ada936dd8b0a598 into 223073b94a88fb23697fd099073162cdf1737051
  • Loading branch information
SDKAuto committed Feb 15, 2024
1 parent 70865b9 commit 9ddf934
Show file tree
Hide file tree
Showing 28 changed files with 761 additions and 1,569 deletions.
6 changes: 3 additions & 3 deletions sdk/schemaregistry/ci.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# NOTE: Please refer to https://aka.ms/azsdk/engsys/ci-yaml before editing this file.

trigger:
branches:
include:
Expand All @@ -9,18 +9,18 @@ trigger:
paths:
include:
- sdk/schemaregistry/

pr:
branches:
include:
- main
- feature/*
- release/*
- hotfix/*
exclude:
- feature/v4
paths:
include:
- sdk/schemaregistry/

extends:
template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml
parameters:
Expand Down
2 changes: 1 addition & 1 deletion sdk/schemaregistry/schema-registry/api-extractor.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,4 @@
}
}
}
}
}
2 changes: 1 addition & 1 deletion sdk/schemaregistry/schema-registry/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -123,4 +123,4 @@
"ts-node": "^10.0.0",
"esm": "^3.2.18"
}
}
}
115 changes: 115 additions & 0 deletions sdk/schemaregistry/schema-registry/src/clientDefinitions.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,115 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.

import {
ListSchemaGroupsParameters,
ListSchemaVersionsParameters,
GetSchemaByIdParameters,
GetSchemaByVersionParameters,
GetSchemaPropertiesByContentParameters,
RegisterSchemaParameters,
} from "./parameters";
import {
ListSchemaGroups200Response,
ListSchemaGroupsDefaultResponse,
ListSchemaVersions200Response,
ListSchemaVersionsDefaultResponse,
GetSchemaById200Response,
GetSchemaByIdDefaultResponse,
GetSchemaByVersion200Response,
GetSchemaByVersionDefaultResponse,
GetSchemaPropertiesByContent204Response,
GetSchemaPropertiesByContentDefaultResponse,
RegisterSchema204Response,
RegisterSchemaDefaultResponse,
} from "./responses";
import { Client, StreamableMethod } from "@azure-rest/core-client";

export interface ListSchemaGroups {
/** Gets the list of schema groups user is authorized to access. */
get(
options?: ListSchemaGroupsParameters,
): StreamableMethod<
ListSchemaGroups200Response | ListSchemaGroupsDefaultResponse
>;
}

export interface ListSchemaVersions {
/** Gets the list of all versions of one schema. */
get(
options?: ListSchemaVersionsParameters,
): StreamableMethod<
ListSchemaVersions200Response | ListSchemaVersionsDefaultResponse
>;
}

export interface GetSchemaById {
/** Gets a registered schema by its unique ID. Azure Schema Registry guarantees that ID is unique within a namespace. Operation response type is based on serialization of schema requested. */
get(
options?: GetSchemaByIdParameters,
): StreamableMethod<GetSchemaById200Response | GetSchemaByIdDefaultResponse>;
}

export interface GetSchemaByVersion {
/** Gets one specific version of one schema. */
get(
options?: GetSchemaByVersionParameters,
): StreamableMethod<
GetSchemaByVersion200Response | GetSchemaByVersionDefaultResponse
>;
}

export interface GetSchemaPropertiesByContent {
/** Gets the properties referencing an existing schema within the specified schema group, as matched by schema content comparison. */
post(
options: GetSchemaPropertiesByContentParameters,
): StreamableMethod<
| GetSchemaPropertiesByContent204Response
| GetSchemaPropertiesByContentDefaultResponse
>;
}

export interface RegisterSchema {
/** Register new schema. If schema of specified name does not exist in specified group, schema is created at version 1. If schema of specified name exists already in specified group, schema is created at latest version + 1. */
put(
options: RegisterSchemaParameters,
): StreamableMethod<
RegisterSchema204Response | RegisterSchemaDefaultResponse
>;
}

export interface Routes {
/** Resource for '/$schemaGroups' has methods for the following verbs: get */
(path: "/$schemaGroups"): ListSchemaGroups;
/** Resource for '/$schemaGroups/\{groupName\}/schemas/\{schemaName\}/versions' has methods for the following verbs: get */
(
path: "/$schemaGroups/{groupName}/schemas/{schemaName}/versions",
groupName: string,
schemaName: string,
): ListSchemaVersions;
/** Resource for '/$schemaGroups/$schemas/\{id\}' has methods for the following verbs: get */
(path: "/$schemaGroups/$schemas/{id}", id: string): GetSchemaById;
/** Resource for '/$schemaGroups/\{groupName\}/schemas/\{schemaName\}/versions/\{schemaVersion\}' has methods for the following verbs: get */
(
path: "/$schemaGroups/{groupName}/schemas/{schemaName}/versions/{schemaVersion}",
groupName: string,
schemaName: string,
schemaVersion: number,
): GetSchemaByVersion;
/** Resource for '/$schemaGroups/\{groupName\}/schemas/\{schemaName\}:get-id' has methods for the following verbs: post */
(
path: "/$schemaGroups/{groupName}/schemas/{schemaName}:get-id",
groupName: string,
schemaName: string,
): GetSchemaPropertiesByContent;
/** Resource for '/$schemaGroups/\{groupName\}/schemas/\{schemaName\}' has methods for the following verbs: put */
(
path: "/$schemaGroups/{groupName}/schemas/{schemaName}",
groupName: string,
schemaName: string,
): RegisterSchema;
}

export type SchemaRegistryClient = Client & {
path: Routes;
};
12 changes: 0 additions & 12 deletions sdk/schemaregistry/schema-registry/src/constants.ts

This file was deleted.

88 changes: 0 additions & 88 deletions sdk/schemaregistry/schema-registry/src/conversions.ts

This file was deleted.

This file was deleted.

11 changes: 0 additions & 11 deletions sdk/schemaregistry/schema-registry/src/generated/index.ts

This file was deleted.

Loading

0 comments on commit 9ddf934

Please sign in to comment.