Skip to content

Commit

Permalink
feat(client-neptune-graph): Adding new APIs in SDK for Amazon Neptune…
Browse files Browse the repository at this point in the history
… Analytics. These APIs include operations to execute, cancel, list queries and get the graph summary.
  • Loading branch information
awstools committed Feb 1, 2024
1 parent 2093c17 commit b1650d4
Show file tree
Hide file tree
Showing 36 changed files with 2,950 additions and 218 deletions.
46 changes: 43 additions & 3 deletions clients/client-neptune-graph/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@

AWS SDK for JavaScript NeptuneGraph Client for Node.js, Browser and React Native.

<p>Neptune Analytics is a serverless in-memory graph database service for analytics
that delivers high-performance analytics and real-time queries for any graph type. It
complements the Amazon Neptune Database, an industry-leading managed graph database.</p>
<p>Neptune Analytics is a new analytics database engine for Amazon Neptune that helps customers get to
insights faster by quickly processing large amounts of graph data, invoking popular graph analytic
algorithms in low-latency queries, and getting analytics results in seconds.</p>

## Installing

Expand Down Expand Up @@ -212,6 +212,14 @@ CancelImportTask

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/neptune-graph/command/CancelImportTaskCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-neptune-graph/Interface/CancelImportTaskCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-neptune-graph/Interface/CancelImportTaskCommandOutput/)

</details>
<details>
<summary>
CancelQuery
</summary>

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/neptune-graph/command/CancelQueryCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-neptune-graph/Interface/CancelQueryCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-neptune-graph/Interface/CancelQueryCommandOutput/)

</details>
<details>
<summary>
Expand Down Expand Up @@ -268,6 +276,14 @@ DeletePrivateGraphEndpoint

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/neptune-graph/command/DeletePrivateGraphEndpointCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-neptune-graph/Interface/DeletePrivateGraphEndpointCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-neptune-graph/Interface/DeletePrivateGraphEndpointCommandOutput/)

</details>
<details>
<summary>
ExecuteQuery
</summary>

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/neptune-graph/command/ExecuteQueryCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-neptune-graph/Interface/ExecuteQueryCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-neptune-graph/Interface/ExecuteQueryCommandOutput/)

</details>
<details>
<summary>
Expand All @@ -284,6 +300,14 @@ GetGraphSnapshot

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/neptune-graph/command/GetGraphSnapshotCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-neptune-graph/Interface/GetGraphSnapshotCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-neptune-graph/Interface/GetGraphSnapshotCommandOutput/)

</details>
<details>
<summary>
GetGraphSummary
</summary>

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/neptune-graph/command/GetGraphSummaryCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-neptune-graph/Interface/GetGraphSummaryCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-neptune-graph/Interface/GetGraphSummaryCommandOutput/)

</details>
<details>
<summary>
Expand All @@ -300,6 +324,14 @@ GetPrivateGraphEndpoint

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/neptune-graph/command/GetPrivateGraphEndpointCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-neptune-graph/Interface/GetPrivateGraphEndpointCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-neptune-graph/Interface/GetPrivateGraphEndpointCommandOutput/)

</details>
<details>
<summary>
GetQuery
</summary>

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/neptune-graph/command/GetQueryCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-neptune-graph/Interface/GetQueryCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-neptune-graph/Interface/GetQueryCommandOutput/)

</details>
<details>
<summary>
Expand Down Expand Up @@ -332,6 +364,14 @@ ListPrivateGraphEndpoints

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/neptune-graph/command/ListPrivateGraphEndpointsCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-neptune-graph/Interface/ListPrivateGraphEndpointsCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-neptune-graph/Interface/ListPrivateGraphEndpointsCommandOutput/)

</details>
<details>
<summary>
ListQueries
</summary>

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/neptune-graph/command/ListQueriesCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-neptune-graph/Interface/ListQueriesCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-neptune-graph/Interface/ListQueriesCommandOutput/)

</details>
<details>
<summary>
Expand Down
1 change: 1 addition & 0 deletions clients/client-neptune-graph/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@
"@smithy/util-defaults-mode-node": "^2.1.1",
"@smithy/util-endpoints": "^1.1.1",
"@smithy/util-retry": "^2.1.1",
"@smithy/util-stream": "^2.1.1",
"@smithy/util-utf8": "^2.1.1",
"@smithy/util-waiter": "^2.1.1",
"tslib": "^2.5.0"
Expand Down
82 changes: 79 additions & 3 deletions clients/client-neptune-graph/src/NeptuneGraph.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import {
CancelImportTaskCommandInput,
CancelImportTaskCommandOutput,
} from "./commands/CancelImportTaskCommand";
import { CancelQueryCommand, CancelQueryCommandInput, CancelQueryCommandOutput } from "./commands/CancelQueryCommand";
import { CreateGraphCommand, CreateGraphCommandInput, CreateGraphCommandOutput } from "./commands/CreateGraphCommand";
import {
CreateGraphSnapshotCommand,
Expand Down Expand Up @@ -34,12 +35,22 @@ import {
DeletePrivateGraphEndpointCommandInput,
DeletePrivateGraphEndpointCommandOutput,
} from "./commands/DeletePrivateGraphEndpointCommand";
import {
ExecuteQueryCommand,
ExecuteQueryCommandInput,
ExecuteQueryCommandOutput,
} from "./commands/ExecuteQueryCommand";
import { GetGraphCommand, GetGraphCommandInput, GetGraphCommandOutput } from "./commands/GetGraphCommand";
import {
GetGraphSnapshotCommand,
GetGraphSnapshotCommandInput,
GetGraphSnapshotCommandOutput,
} from "./commands/GetGraphSnapshotCommand";
import {
GetGraphSummaryCommand,
GetGraphSummaryCommandInput,
GetGraphSummaryCommandOutput,
} from "./commands/GetGraphSummaryCommand";
import {
GetImportTaskCommand,
GetImportTaskCommandInput,
Expand All @@ -50,6 +61,7 @@ import {
GetPrivateGraphEndpointCommandInput,
GetPrivateGraphEndpointCommandOutput,
} from "./commands/GetPrivateGraphEndpointCommand";
import { GetQueryCommand, GetQueryCommandInput, GetQueryCommandOutput } from "./commands/GetQueryCommand";
import { ListGraphsCommand, ListGraphsCommandInput, ListGraphsCommandOutput } from "./commands/ListGraphsCommand";
import {
ListGraphSnapshotsCommand,
Expand All @@ -66,6 +78,7 @@ import {
ListPrivateGraphEndpointsCommandInput,
ListPrivateGraphEndpointsCommandOutput,
} from "./commands/ListPrivateGraphEndpointsCommand";
import { ListQueriesCommand, ListQueriesCommandInput, ListQueriesCommandOutput } from "./commands/ListQueriesCommand";
import {
ListTagsForResourceCommand,
ListTagsForResourceCommandInput,
Expand All @@ -88,21 +101,26 @@ import { NeptuneGraphClient, NeptuneGraphClientConfig } from "./NeptuneGraphClie

const commands = {
CancelImportTaskCommand,
CancelQueryCommand,
CreateGraphCommand,
CreateGraphSnapshotCommand,
CreateGraphUsingImportTaskCommand,
CreatePrivateGraphEndpointCommand,
DeleteGraphCommand,
DeleteGraphSnapshotCommand,
DeletePrivateGraphEndpointCommand,
ExecuteQueryCommand,
GetGraphCommand,
GetGraphSnapshotCommand,
GetGraphSummaryCommand,
GetImportTaskCommand,
GetPrivateGraphEndpointCommand,
GetQueryCommand,
ListGraphsCommand,
ListGraphSnapshotsCommand,
ListImportTasksCommand,
ListPrivateGraphEndpointsCommand,
ListQueriesCommand,
ListTagsForResourceCommand,
ResetGraphCommand,
RestoreGraphFromSnapshotCommand,
Expand All @@ -129,6 +147,17 @@ export interface NeptuneGraph {
cb: (err: any, data?: CancelImportTaskCommandOutput) => void
): void;

/**
* @see {@link CancelQueryCommand}
*/
cancelQuery(args: CancelQueryCommandInput, options?: __HttpHandlerOptions): Promise<CancelQueryCommandOutput>;
cancelQuery(args: CancelQueryCommandInput, cb: (err: any, data?: CancelQueryCommandOutput) => void): void;
cancelQuery(
args: CancelQueryCommandInput,
options: __HttpHandlerOptions,
cb: (err: any, data?: CancelQueryCommandOutput) => void
): void;

/**
* @see {@link CreateGraphCommand}
*/
Expand Down Expand Up @@ -236,6 +265,17 @@ export interface NeptuneGraph {
cb: (err: any, data?: DeletePrivateGraphEndpointCommandOutput) => void
): void;

/**
* @see {@link ExecuteQueryCommand}
*/
executeQuery(args: ExecuteQueryCommandInput, options?: __HttpHandlerOptions): Promise<ExecuteQueryCommandOutput>;
executeQuery(args: ExecuteQueryCommandInput, cb: (err: any, data?: ExecuteQueryCommandOutput) => void): void;
executeQuery(
args: ExecuteQueryCommandInput,
options: __HttpHandlerOptions,
cb: (err: any, data?: ExecuteQueryCommandOutput) => void
): void;

/**
* @see {@link GetGraphCommand}
*/
Expand Down Expand Up @@ -264,6 +304,20 @@ export interface NeptuneGraph {
cb: (err: any, data?: GetGraphSnapshotCommandOutput) => void
): void;

/**
* @see {@link GetGraphSummaryCommand}
*/
getGraphSummary(
args: GetGraphSummaryCommandInput,
options?: __HttpHandlerOptions
): Promise<GetGraphSummaryCommandOutput>;
getGraphSummary(args: GetGraphSummaryCommandInput, cb: (err: any, data?: GetGraphSummaryCommandOutput) => void): void;
getGraphSummary(
args: GetGraphSummaryCommandInput,
options: __HttpHandlerOptions,
cb: (err: any, data?: GetGraphSummaryCommandOutput) => void
): void;

/**
* @see {@link GetImportTaskCommand}
*/
Expand Down Expand Up @@ -292,6 +346,17 @@ export interface NeptuneGraph {
cb: (err: any, data?: GetPrivateGraphEndpointCommandOutput) => void
): void;

/**
* @see {@link GetQueryCommand}
*/
getQuery(args: GetQueryCommandInput, options?: __HttpHandlerOptions): Promise<GetQueryCommandOutput>;
getQuery(args: GetQueryCommandInput, cb: (err: any, data?: GetQueryCommandOutput) => void): void;
getQuery(
args: GetQueryCommandInput,
options: __HttpHandlerOptions,
cb: (err: any, data?: GetQueryCommandOutput) => void
): void;

/**
* @see {@link ListGraphsCommand}
*/
Expand Down Expand Up @@ -351,6 +416,17 @@ export interface NeptuneGraph {
cb: (err: any, data?: ListPrivateGraphEndpointsCommandOutput) => void
): void;

/**
* @see {@link ListQueriesCommand}
*/
listQueries(args: ListQueriesCommandInput, options?: __HttpHandlerOptions): Promise<ListQueriesCommandOutput>;
listQueries(args: ListQueriesCommandInput, cb: (err: any, data?: ListQueriesCommandOutput) => void): void;
listQueries(
args: ListQueriesCommandInput,
options: __HttpHandlerOptions,
cb: (err: any, data?: ListQueriesCommandOutput) => void
): void;

/**
* @see {@link ListTagsForResourceCommand}
*/
Expand Down Expand Up @@ -432,9 +508,9 @@ export interface NeptuneGraph {

/**
* @public
* <p>Neptune Analytics is a serverless in-memory graph database service for analytics
* that delivers high-performance analytics and real-time queries for any graph type. It
* complements the Amazon Neptune Database, an industry-leading managed graph database.</p>
* <p>Neptune Analytics is a new analytics database engine for Amazon Neptune that helps customers get to
* insights faster by quickly processing large amounts of graph data, invoking popular graph analytic
* algorithms in low-latency queries, and getting analytics results in seconds.</p>
*/
export class NeptuneGraph extends NeptuneGraphClient implements NeptuneGraph {}
createAggregatedClient(commands, NeptuneGraph);
28 changes: 25 additions & 3 deletions clients/client-neptune-graph/src/NeptuneGraphClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,12 +43,14 @@ import {
Logger as __Logger,
Provider as __Provider,
Provider,
SdkStreamMixinInjector as __SdkStreamMixinInjector,
StreamCollector as __StreamCollector,
UrlParser as __UrlParser,
UserAgent as __UserAgent,
} from "@smithy/types";

import { CancelImportTaskCommandInput, CancelImportTaskCommandOutput } from "./commands/CancelImportTaskCommand";
import { CancelQueryCommandInput, CancelQueryCommandOutput } from "./commands/CancelQueryCommand";
import { CreateGraphCommandInput, CreateGraphCommandOutput } from "./commands/CreateGraphCommand";
import {
CreateGraphSnapshotCommandInput,
Expand All @@ -71,20 +73,24 @@ import {
DeletePrivateGraphEndpointCommandInput,
DeletePrivateGraphEndpointCommandOutput,
} from "./commands/DeletePrivateGraphEndpointCommand";
import { ExecuteQueryCommandInput, ExecuteQueryCommandOutput } from "./commands/ExecuteQueryCommand";
import { GetGraphCommandInput, GetGraphCommandOutput } from "./commands/GetGraphCommand";
import { GetGraphSnapshotCommandInput, GetGraphSnapshotCommandOutput } from "./commands/GetGraphSnapshotCommand";
import { GetGraphSummaryCommandInput, GetGraphSummaryCommandOutput } from "./commands/GetGraphSummaryCommand";
import { GetImportTaskCommandInput, GetImportTaskCommandOutput } from "./commands/GetImportTaskCommand";
import {
GetPrivateGraphEndpointCommandInput,
GetPrivateGraphEndpointCommandOutput,
} from "./commands/GetPrivateGraphEndpointCommand";
import { GetQueryCommandInput, GetQueryCommandOutput } from "./commands/GetQueryCommand";
import { ListGraphsCommandInput, ListGraphsCommandOutput } from "./commands/ListGraphsCommand";
import { ListGraphSnapshotsCommandInput, ListGraphSnapshotsCommandOutput } from "./commands/ListGraphSnapshotsCommand";
import { ListImportTasksCommandInput, ListImportTasksCommandOutput } from "./commands/ListImportTasksCommand";
import {
ListPrivateGraphEndpointsCommandInput,
ListPrivateGraphEndpointsCommandOutput,
} from "./commands/ListPrivateGraphEndpointsCommand";
import { ListQueriesCommandInput, ListQueriesCommandOutput } from "./commands/ListQueriesCommand";
import {
ListTagsForResourceCommandInput,
ListTagsForResourceCommandOutput,
Expand Down Expand Up @@ -113,21 +119,26 @@ export { __Client };
*/
export type ServiceInputTypes =
| CancelImportTaskCommandInput
| CancelQueryCommandInput
| CreateGraphCommandInput
| CreateGraphSnapshotCommandInput
| CreateGraphUsingImportTaskCommandInput
| CreatePrivateGraphEndpointCommandInput
| DeleteGraphCommandInput
| DeleteGraphSnapshotCommandInput
| DeletePrivateGraphEndpointCommandInput
| ExecuteQueryCommandInput
| GetGraphCommandInput
| GetGraphSnapshotCommandInput
| GetGraphSummaryCommandInput
| GetImportTaskCommandInput
| GetPrivateGraphEndpointCommandInput
| GetQueryCommandInput
| ListGraphSnapshotsCommandInput
| ListGraphsCommandInput
| ListImportTasksCommandInput
| ListPrivateGraphEndpointsCommandInput
| ListQueriesCommandInput
| ListTagsForResourceCommandInput
| ResetGraphCommandInput
| RestoreGraphFromSnapshotCommandInput
Expand All @@ -140,21 +151,26 @@ export type ServiceInputTypes =
*/
export type ServiceOutputTypes =
| CancelImportTaskCommandOutput
| CancelQueryCommandOutput
| CreateGraphCommandOutput
| CreateGraphSnapshotCommandOutput
| CreateGraphUsingImportTaskCommandOutput
| CreatePrivateGraphEndpointCommandOutput
| DeleteGraphCommandOutput
| DeleteGraphSnapshotCommandOutput
| DeletePrivateGraphEndpointCommandOutput
| ExecuteQueryCommandOutput
| GetGraphCommandOutput
| GetGraphSnapshotCommandOutput
| GetGraphSummaryCommandOutput
| GetImportTaskCommandOutput
| GetPrivateGraphEndpointCommandOutput
| GetQueryCommandOutput
| ListGraphSnapshotsCommandOutput
| ListGraphsCommandOutput
| ListImportTasksCommandOutput
| ListPrivateGraphEndpointsCommandOutput
| ListQueriesCommandOutput
| ListTagsForResourceCommandOutput
| ResetGraphCommandOutput
| RestoreGraphFromSnapshotCommandOutput
Expand Down Expand Up @@ -291,6 +307,12 @@ export interface ClientDefaults extends Partial<__SmithyResolvedConfiguration<__
* The {@link @smithy/smithy-client#DefaultsMode} that will be used to determine how certain default configuration options are resolved in the SDK.
*/
defaultsMode?: __DefaultsMode | __Provider<__DefaultsMode>;

/**
* The internal function that inject utilities to runtime-specific stream to help users consume the data
* @internal
*/
sdkStreamMixin?: __SdkStreamMixinInjector;
}

/**
Expand Down Expand Up @@ -334,9 +356,9 @@ export interface NeptuneGraphClientResolvedConfig extends NeptuneGraphClientReso

/**
* @public
* <p>Neptune Analytics is a serverless in-memory graph database service for analytics
* that delivers high-performance analytics and real-time queries for any graph type. It
* complements the Amazon Neptune Database, an industry-leading managed graph database.</p>
* <p>Neptune Analytics is a new analytics database engine for Amazon Neptune that helps customers get to
* insights faster by quickly processing large amounts of graph data, invoking popular graph analytic
* algorithms in low-latency queries, and getting analytics results in seconds.</p>
*/
export class NeptuneGraphClient extends __Client<
__HttpHandlerOptions,
Expand Down
Loading

0 comments on commit b1650d4

Please sign in to comment.