Skip to content

Commit

Permalink
feat(client-glue): This release adds APIs to create, read, delete, li…
Browse files Browse the repository at this point in the history
…st, and batch read of Glue custom entity types
  • Loading branch information
awstools committed Apr 21, 2022
1 parent f07f481 commit 546dab6
Show file tree
Hide file tree
Showing 23 changed files with 2,261 additions and 573 deletions.
170 changes: 170 additions & 0 deletions clients/client-glue/src/Glue.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,11 @@ import {
BatchGetCrawlersCommandInput,
BatchGetCrawlersCommandOutput,
} from "./commands/BatchGetCrawlersCommand";
import {
BatchGetCustomEntityTypesCommand,
BatchGetCustomEntityTypesCommandInput,
BatchGetCustomEntityTypesCommandOutput,
} from "./commands/BatchGetCustomEntityTypesCommand";
import {
BatchGetDevEndpointsCommand,
BatchGetDevEndpointsCommandInput,
Expand Down Expand Up @@ -105,6 +110,11 @@ import {
CreateCrawlerCommandInput,
CreateCrawlerCommandOutput,
} from "./commands/CreateCrawlerCommand";
import {
CreateCustomEntityTypeCommand,
CreateCustomEntityTypeCommandInput,
CreateCustomEntityTypeCommandOutput,
} from "./commands/CreateCustomEntityTypeCommand";
import {
CreateDatabaseCommand,
CreateDatabaseCommandInput,
Expand Down Expand Up @@ -202,6 +212,11 @@ import {
DeleteCrawlerCommandInput,
DeleteCrawlerCommandOutput,
} from "./commands/DeleteCrawlerCommand";
import {
DeleteCustomEntityTypeCommand,
DeleteCustomEntityTypeCommandInput,
DeleteCustomEntityTypeCommandOutput,
} from "./commands/DeleteCustomEntityTypeCommand";
import {
DeleteDatabaseCommand,
DeleteDatabaseCommandInput,
Expand Down Expand Up @@ -336,6 +351,11 @@ import {
GetCrawlerMetricsCommandOutput,
} from "./commands/GetCrawlerMetricsCommand";
import { GetCrawlersCommand, GetCrawlersCommandInput, GetCrawlersCommandOutput } from "./commands/GetCrawlersCommand";
import {
GetCustomEntityTypeCommand,
GetCustomEntityTypeCommandInput,
GetCustomEntityTypeCommandOutput,
} from "./commands/GetCustomEntityTypeCommand";
import { GetDatabaseCommand, GetDatabaseCommandInput, GetDatabaseCommandOutput } from "./commands/GetDatabaseCommand";
import {
GetDatabasesCommand,
Expand Down Expand Up @@ -522,6 +542,11 @@ import {
ListCrawlersCommandInput,
ListCrawlersCommandOutput,
} from "./commands/ListCrawlersCommand";
import {
ListCustomEntityTypesCommand,
ListCustomEntityTypesCommandInput,
ListCustomEntityTypesCommandOutput,
} from "./commands/ListCustomEntityTypesCommand";
import {
ListDevEndpointsCommand,
ListDevEndpointsCommandInput,
Expand Down Expand Up @@ -1007,6 +1032,35 @@ export class Glue extends GlueClient {
}
}

public batchGetCustomEntityTypes(
args: BatchGetCustomEntityTypesCommandInput,
options?: __HttpHandlerOptions
): Promise<BatchGetCustomEntityTypesCommandOutput>;
public batchGetCustomEntityTypes(
args: BatchGetCustomEntityTypesCommandInput,
cb: (err: any, data?: BatchGetCustomEntityTypesCommandOutput) => void
): void;
public batchGetCustomEntityTypes(
args: BatchGetCustomEntityTypesCommandInput,
options: __HttpHandlerOptions,
cb: (err: any, data?: BatchGetCustomEntityTypesCommandOutput) => void
): void;
public batchGetCustomEntityTypes(
args: BatchGetCustomEntityTypesCommandInput,
optionsOrCb?: __HttpHandlerOptions | ((err: any, data?: BatchGetCustomEntityTypesCommandOutput) => void),
cb?: (err: any, data?: BatchGetCustomEntityTypesCommandOutput) => void
): Promise<BatchGetCustomEntityTypesCommandOutput> | void {
const command = new BatchGetCustomEntityTypesCommand(args);
if (typeof optionsOrCb === "function") {
this.send(command, optionsOrCb);
} else if (typeof cb === "function") {
if (typeof optionsOrCb !== "object") throw new Error(`Expect http options but get ${typeof optionsOrCb}`);
this.send(command, optionsOrCb || {}, cb);
} else {
return this.send(command, optionsOrCb);
}
}

/**
* <p>Returns a list of resource metadata for a given list of development endpoint names. After
* calling the <code>ListDevEndpoints</code> operation, you can call this operation to access the
Expand Down Expand Up @@ -1462,6 +1516,35 @@ export class Glue extends GlueClient {
}
}

public createCustomEntityType(
args: CreateCustomEntityTypeCommandInput,
options?: __HttpHandlerOptions
): Promise<CreateCustomEntityTypeCommandOutput>;
public createCustomEntityType(
args: CreateCustomEntityTypeCommandInput,
cb: (err: any, data?: CreateCustomEntityTypeCommandOutput) => void
): void;
public createCustomEntityType(
args: CreateCustomEntityTypeCommandInput,
options: __HttpHandlerOptions,
cb: (err: any, data?: CreateCustomEntityTypeCommandOutput) => void
): void;
public createCustomEntityType(
args: CreateCustomEntityTypeCommandInput,
optionsOrCb?: __HttpHandlerOptions | ((err: any, data?: CreateCustomEntityTypeCommandOutput) => void),
cb?: (err: any, data?: CreateCustomEntityTypeCommandOutput) => void
): Promise<CreateCustomEntityTypeCommandOutput> | void {
const command = new CreateCustomEntityTypeCommand(args);
if (typeof optionsOrCb === "function") {
this.send(command, optionsOrCb);
} else if (typeof cb === "function") {
if (typeof optionsOrCb !== "object") throw new Error(`Expect http options but get ${typeof optionsOrCb}`);
this.send(command, optionsOrCb || {}, cb);
} else {
return this.send(command, optionsOrCb);
}
}

/**
* <p>Creates a new database in a Data Catalog.</p>
*/
Expand Down Expand Up @@ -2135,6 +2218,35 @@ export class Glue extends GlueClient {
}
}

public deleteCustomEntityType(
args: DeleteCustomEntityTypeCommandInput,
options?: __HttpHandlerOptions
): Promise<DeleteCustomEntityTypeCommandOutput>;
public deleteCustomEntityType(
args: DeleteCustomEntityTypeCommandInput,
cb: (err: any, data?: DeleteCustomEntityTypeCommandOutput) => void
): void;
public deleteCustomEntityType(
args: DeleteCustomEntityTypeCommandInput,
options: __HttpHandlerOptions,
cb: (err: any, data?: DeleteCustomEntityTypeCommandOutput) => void
): void;
public deleteCustomEntityType(
args: DeleteCustomEntityTypeCommandInput,
optionsOrCb?: __HttpHandlerOptions | ((err: any, data?: DeleteCustomEntityTypeCommandOutput) => void),
cb?: (err: any, data?: DeleteCustomEntityTypeCommandOutput) => void
): Promise<DeleteCustomEntityTypeCommandOutput> | void {
const command = new DeleteCustomEntityTypeCommand(args);
if (typeof optionsOrCb === "function") {
this.send(command, optionsOrCb);
} else if (typeof cb === "function") {
if (typeof optionsOrCb !== "object") throw new Error(`Expect http options but get ${typeof optionsOrCb}`);
this.send(command, optionsOrCb || {}, cb);
} else {
return this.send(command, optionsOrCb);
}
}

/**
* <p>Removes a specified database from a Data Catalog.</p>
* <note>
Expand Down Expand Up @@ -3102,6 +3214,35 @@ export class Glue extends GlueClient {
}
}

public getCustomEntityType(
args: GetCustomEntityTypeCommandInput,
options?: __HttpHandlerOptions
): Promise<GetCustomEntityTypeCommandOutput>;
public getCustomEntityType(
args: GetCustomEntityTypeCommandInput,
cb: (err: any, data?: GetCustomEntityTypeCommandOutput) => void
): void;
public getCustomEntityType(
args: GetCustomEntityTypeCommandInput,
options: __HttpHandlerOptions,
cb: (err: any, data?: GetCustomEntityTypeCommandOutput) => void
): void;
public getCustomEntityType(
args: GetCustomEntityTypeCommandInput,
optionsOrCb?: __HttpHandlerOptions | ((err: any, data?: GetCustomEntityTypeCommandOutput) => void),
cb?: (err: any, data?: GetCustomEntityTypeCommandOutput) => void
): Promise<GetCustomEntityTypeCommandOutput> | void {
const command = new GetCustomEntityTypeCommand(args);
if (typeof optionsOrCb === "function") {
this.send(command, optionsOrCb);
} else if (typeof cb === "function") {
if (typeof optionsOrCb !== "object") throw new Error(`Expect http options but get ${typeof optionsOrCb}`);
this.send(command, optionsOrCb || {}, cb);
} else {
return this.send(command, optionsOrCb);
}
}

/**
* <p>Retrieves the definition of a specified database.</p>
*/
Expand Down Expand Up @@ -4625,6 +4766,35 @@ export class Glue extends GlueClient {
}
}

public listCustomEntityTypes(
args: ListCustomEntityTypesCommandInput,
options?: __HttpHandlerOptions
): Promise<ListCustomEntityTypesCommandOutput>;
public listCustomEntityTypes(
args: ListCustomEntityTypesCommandInput,
cb: (err: any, data?: ListCustomEntityTypesCommandOutput) => void
): void;
public listCustomEntityTypes(
args: ListCustomEntityTypesCommandInput,
options: __HttpHandlerOptions,
cb: (err: any, data?: ListCustomEntityTypesCommandOutput) => void
): void;
public listCustomEntityTypes(
args: ListCustomEntityTypesCommandInput,
optionsOrCb?: __HttpHandlerOptions | ((err: any, data?: ListCustomEntityTypesCommandOutput) => void),
cb?: (err: any, data?: ListCustomEntityTypesCommandOutput) => void
): Promise<ListCustomEntityTypesCommandOutput> | void {
const command = new ListCustomEntityTypesCommand(args);
if (typeof optionsOrCb === "function") {
this.send(command, optionsOrCb);
} else if (typeof cb === "function") {
if (typeof optionsOrCb !== "object") throw new Error(`Expect http options but get ${typeof optionsOrCb}`);
this.send(command, optionsOrCb || {}, cb);
} else {
return this.send(command, optionsOrCb);
}
}

/**
* <p>Retrieves the names of all <code>DevEndpoint</code> resources in this Amazon Web Services account, or the
* resources with the specified tag. This operation allows you to see which resources are
Expand Down
30 changes: 30 additions & 0 deletions clients/client-glue/src/GlueClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,10 @@ import {
} from "./commands/BatchDeleteTableVersionCommand";
import { BatchGetBlueprintsCommandInput, BatchGetBlueprintsCommandOutput } from "./commands/BatchGetBlueprintsCommand";
import { BatchGetCrawlersCommandInput, BatchGetCrawlersCommandOutput } from "./commands/BatchGetCrawlersCommand";
import {
BatchGetCustomEntityTypesCommandInput,
BatchGetCustomEntityTypesCommandOutput,
} from "./commands/BatchGetCustomEntityTypesCommand";
import {
BatchGetDevEndpointsCommandInput,
BatchGetDevEndpointsCommandOutput,
Expand All @@ -93,6 +97,10 @@ import { CreateBlueprintCommandInput, CreateBlueprintCommandOutput } from "./com
import { CreateClassifierCommandInput, CreateClassifierCommandOutput } from "./commands/CreateClassifierCommand";
import { CreateConnectionCommandInput, CreateConnectionCommandOutput } from "./commands/CreateConnectionCommand";
import { CreateCrawlerCommandInput, CreateCrawlerCommandOutput } from "./commands/CreateCrawlerCommand";
import {
CreateCustomEntityTypeCommandInput,
CreateCustomEntityTypeCommandOutput,
} from "./commands/CreateCustomEntityTypeCommand";
import { CreateDatabaseCommandInput, CreateDatabaseCommandOutput } from "./commands/CreateDatabaseCommand";
import { CreateDevEndpointCommandInput, CreateDevEndpointCommandOutput } from "./commands/CreateDevEndpointCommand";
import { CreateJobCommandInput, CreateJobCommandOutput } from "./commands/CreateJobCommand";
Expand Down Expand Up @@ -129,6 +137,10 @@ import {
} from "./commands/DeleteColumnStatisticsForTableCommand";
import { DeleteConnectionCommandInput, DeleteConnectionCommandOutput } from "./commands/DeleteConnectionCommand";
import { DeleteCrawlerCommandInput, DeleteCrawlerCommandOutput } from "./commands/DeleteCrawlerCommand";
import {
DeleteCustomEntityTypeCommandInput,
DeleteCustomEntityTypeCommandOutput,
} from "./commands/DeleteCustomEntityTypeCommand";
import { DeleteDatabaseCommandInput, DeleteDatabaseCommandOutput } from "./commands/DeleteDatabaseCommand";
import { DeleteDevEndpointCommandInput, DeleteDevEndpointCommandOutput } from "./commands/DeleteDevEndpointCommand";
import { DeleteJobCommandInput, DeleteJobCommandOutput } from "./commands/DeleteJobCommand";
Expand Down Expand Up @@ -183,6 +195,10 @@ import { GetConnectionsCommandInput, GetConnectionsCommandOutput } from "./comma
import { GetCrawlerCommandInput, GetCrawlerCommandOutput } from "./commands/GetCrawlerCommand";
import { GetCrawlerMetricsCommandInput, GetCrawlerMetricsCommandOutput } from "./commands/GetCrawlerMetricsCommand";
import { GetCrawlersCommandInput, GetCrawlersCommandOutput } from "./commands/GetCrawlersCommand";
import {
GetCustomEntityTypeCommandInput,
GetCustomEntityTypeCommandOutput,
} from "./commands/GetCustomEntityTypeCommand";
import { GetDatabaseCommandInput, GetDatabaseCommandOutput } from "./commands/GetDatabaseCommand";
import { GetDatabasesCommandInput, GetDatabasesCommandOutput } from "./commands/GetDatabasesCommand";
import {
Expand Down Expand Up @@ -275,6 +291,10 @@ import {
} from "./commands/ImportCatalogToGlueCommand";
import { ListBlueprintsCommandInput, ListBlueprintsCommandOutput } from "./commands/ListBlueprintsCommand";
import { ListCrawlersCommandInput, ListCrawlersCommandOutput } from "./commands/ListCrawlersCommand";
import {
ListCustomEntityTypesCommandInput,
ListCustomEntityTypesCommandOutput,
} from "./commands/ListCustomEntityTypesCommand";
import { ListDevEndpointsCommandInput, ListDevEndpointsCommandOutput } from "./commands/ListDevEndpointsCommand";
import { ListJobsCommandInput, ListJobsCommandOutput } from "./commands/ListJobsCommand";
import { ListMLTransformsCommandInput, ListMLTransformsCommandOutput } from "./commands/ListMLTransformsCommand";
Expand Down Expand Up @@ -389,6 +409,7 @@ export type ServiceInputTypes =
| BatchDeleteTableVersionCommandInput
| BatchGetBlueprintsCommandInput
| BatchGetCrawlersCommandInput
| BatchGetCustomEntityTypesCommandInput
| BatchGetDevEndpointsCommandInput
| BatchGetJobsCommandInput
| BatchGetPartitionCommandInput
Expand All @@ -403,6 +424,7 @@ export type ServiceInputTypes =
| CreateClassifierCommandInput
| CreateConnectionCommandInput
| CreateCrawlerCommandInput
| CreateCustomEntityTypeCommandInput
| CreateDatabaseCommandInput
| CreateDevEndpointCommandInput
| CreateJobCommandInput
Expand All @@ -424,6 +446,7 @@ export type ServiceInputTypes =
| DeleteColumnStatisticsForTableCommandInput
| DeleteConnectionCommandInput
| DeleteCrawlerCommandInput
| DeleteCustomEntityTypeCommandInput
| DeleteDatabaseCommandInput
| DeleteDevEndpointCommandInput
| DeleteJobCommandInput
Expand Down Expand Up @@ -454,6 +477,7 @@ export type ServiceInputTypes =
| GetCrawlerCommandInput
| GetCrawlerMetricsCommandInput
| GetCrawlersCommandInput
| GetCustomEntityTypeCommandInput
| GetDataCatalogEncryptionSettingsCommandInput
| GetDatabaseCommandInput
| GetDatabasesCommandInput
Expand Down Expand Up @@ -504,6 +528,7 @@ export type ServiceInputTypes =
| ImportCatalogToGlueCommandInput
| ListBlueprintsCommandInput
| ListCrawlersCommandInput
| ListCustomEntityTypesCommandInput
| ListDevEndpointsCommandInput
| ListJobsCommandInput
| ListMLTransformsCommandInput
Expand Down Expand Up @@ -569,6 +594,7 @@ export type ServiceOutputTypes =
| BatchDeleteTableVersionCommandOutput
| BatchGetBlueprintsCommandOutput
| BatchGetCrawlersCommandOutput
| BatchGetCustomEntityTypesCommandOutput
| BatchGetDevEndpointsCommandOutput
| BatchGetJobsCommandOutput
| BatchGetPartitionCommandOutput
Expand All @@ -583,6 +609,7 @@ export type ServiceOutputTypes =
| CreateClassifierCommandOutput
| CreateConnectionCommandOutput
| CreateCrawlerCommandOutput
| CreateCustomEntityTypeCommandOutput
| CreateDatabaseCommandOutput
| CreateDevEndpointCommandOutput
| CreateJobCommandOutput
Expand All @@ -604,6 +631,7 @@ export type ServiceOutputTypes =
| DeleteColumnStatisticsForTableCommandOutput
| DeleteConnectionCommandOutput
| DeleteCrawlerCommandOutput
| DeleteCustomEntityTypeCommandOutput
| DeleteDatabaseCommandOutput
| DeleteDevEndpointCommandOutput
| DeleteJobCommandOutput
Expand Down Expand Up @@ -634,6 +662,7 @@ export type ServiceOutputTypes =
| GetCrawlerCommandOutput
| GetCrawlerMetricsCommandOutput
| GetCrawlersCommandOutput
| GetCustomEntityTypeCommandOutput
| GetDataCatalogEncryptionSettingsCommandOutput
| GetDatabaseCommandOutput
| GetDatabasesCommandOutput
Expand Down Expand Up @@ -684,6 +713,7 @@ export type ServiceOutputTypes =
| ImportCatalogToGlueCommandOutput
| ListBlueprintsCommandOutput
| ListCrawlersCommandOutput
| ListCustomEntityTypesCommandOutput
| ListDevEndpointsCommandOutput
| ListJobsCommandOutput
| ListMLTransformsCommandOutput
Expand Down
Loading

0 comments on commit 546dab6

Please sign in to comment.