clients/client-s3tables/README.md
AWS SDK for JavaScript S3Tables Client for Node.js, Browser and React Native.
<p>An Amazon S3 table represents a structured dataset consisting of tabular data in <a href="https://parquet.apache.org/docs/">Apache Parquet</a> format and related metadata. This data is stored inside an S3 table as a subresource. All tables in a table bucket are stored in the <a href="https://iceberg.apache.org/docs/latest/">Apache Iceberg</a> table format. Through integration with the <a href="https://docs.aws.amazon.com/https:/docs.aws.amazon.com/glue/latest/dg/catalog-and-crawler.html">Amazon Web Services Glue Data Catalog</a> you can interact with your tables using Amazon Web Services analytics services, such as <a href="https://docs.aws.amazon.com/https:/docs.aws.amazon.com/athena/">Amazon Athena</a> and <a href="https://docs.aws.amazon.com/https:/docs.aws.amazon.com/redshift/">Amazon Redshift</a>. Amazon S3 manages maintenance of your tables through automatic file compaction and snapshot management. For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-tables-buckets.html">Amazon S3 table buckets</a>.</p>To install this package, use the CLI of your favorite package manager:
npm install @aws-sdk/client-s3tablesyarn add @aws-sdk/client-s3tablespnpm add @aws-sdk/client-s3tablesThe AWS SDK is modulized by clients and commands.
To send a request, you only need to import the S3TablesClient and
the commands you need, for example ListTableBucketsCommand:
// ES5 example
const { S3TablesClient, ListTableBucketsCommand } = require("@aws-sdk/client-s3tables");
// ES6+ example
import { S3TablesClient, ListTableBucketsCommand } from "@aws-sdk/client-s3tables";
To send a request:
send operation on the client, providing the command object as input.const client = new S3TablesClient({ region: "REGION" });
const params = { /** input parameters */ };
const command = new ListTableBucketsCommand(params);
We recommend using the await operator to wait for the promise returned by send operation as follows:
// async/await.
try {
const data = await client.send(command);
// process data.
} catch (error) {
// error handling.
} finally {
// finally.
}
You can also use Promise chaining.
client
.send(command)
.then((data) => {
// process data.
})
.catch((error) => {
// error handling.
})
.finally(() => {
// finally.
});
The aggregated client class is exported from the same package, but without the "Client" suffix.
S3Tables extends S3TablesClient and additionally supports all operations, waiters, and paginators as methods.
This style may be familiar to you from the AWS SDK for JavaScript v2.
If you are bundling the AWS SDK, we recommend using only the bare-bones client (S3TablesClient).
More details are in the blog post on
modular packages in AWS SDK for JavaScript.
import { S3Tables } from "@aws-sdk/client-s3tables";
const client = new S3Tables({ region: "REGION" });
// async/await.
try {
const data = await client.listTableBuckets(params);
// process data.
} catch (error) {
// error handling.
}
// Promises.
client
.listTableBuckets(params)
.then((data) => {
// process data.
})
.catch((error) => {
// error handling.
});
// callbacks (not recommended).
client.listTableBuckets(params, (err, data) => {
// process err and data.
});
When the service returns an exception, the error will include the exception information, as well as response metadata (e.g. request id).
try {
const data = await client.send(command);
// process data.
} catch (error) {
const { requestId, cfId, extendedRequestId } = error.$metadata;
console.log({ requestId, cfId, extendedRequestId });
/**
* The keys within exceptions are also parsed.
* You can access them by specifying exception names:
* if (error.name === 'SomeServiceException') {
* const value = error.specialKeyInException;
* }
*/
}
See also docs/ERROR_HANDLING.
Please use these community resources for getting help. We use GitHub issues for tracking bugs and feature requests, but have limited bandwidth to address them.
aws-sdk-js
on AWS Developer Blog.aws-sdk-js.To test your universal JavaScript code in Node.js, browser and react-native environments, visit our code samples repo.
This client code is generated automatically. Any modifications will be overwritten the next time the @aws-sdk/client-s3tables package is updated.
To contribute to client you can check our generate clients scripts.
This SDK is distributed under the Apache License, Version 2.0, see LICENSE for more information.
Command API Reference / Input / Output
</details> <details> <summary> CreateTable </summary>Command API Reference / Input / Output
</details> <details> <summary> CreateTableBucket </summary>Command API Reference / Input / Output
</details> <details> <summary> DeleteNamespace </summary>Command API Reference / Input / Output
</details> <details> <summary> DeleteTable </summary>Command API Reference / Input / Output
</details> <details> <summary> DeleteTableBucket </summary>Command API Reference / Input / Output
</details> <details> <summary> DeleteTableBucketEncryption </summary>Command API Reference / Input / Output
</details> <details> <summary> DeleteTableBucketMetricsConfiguration </summary>Command API Reference / Input / Output
</details> <details> <summary> DeleteTableBucketPolicy </summary>Command API Reference / Input / Output
</details> <details> <summary> DeleteTableBucketReplication </summary>Command API Reference / Input / Output
</details> <details> <summary> DeleteTablePolicy </summary>Command API Reference / Input / Output
</details> <details> <summary> DeleteTableReplication </summary>Command API Reference / Input / Output
</details> <details> <summary> GetNamespace </summary>Command API Reference / Input / Output
</details> <details> <summary> GetTable </summary>Command API Reference / Input / Output
</details> <details> <summary> GetTableBucket </summary>Command API Reference / Input / Output
</details> <details> <summary> GetTableBucketEncryption </summary>Command API Reference / Input / Output
</details> <details> <summary> GetTableBucketMaintenanceConfiguration </summary>Command API Reference / Input / Output
</details> <details> <summary> GetTableBucketMetricsConfiguration </summary>Command API Reference / Input / Output
</details> <details> <summary> GetTableBucketPolicy </summary>Command API Reference / Input / Output
</details> <details> <summary> GetTableBucketReplication </summary>Command API Reference / Input / Output
</details> <details> <summary> GetTableBucketStorageClass </summary>Command API Reference / Input / Output
</details> <details> <summary> GetTableEncryption </summary>Command API Reference / Input / Output
</details> <details> <summary> GetTableMaintenanceConfiguration </summary>Command API Reference / Input / Output
</details> <details> <summary> GetTableMaintenanceJobStatus </summary>Command API Reference / Input / Output
</details> <details> <summary> GetTableMetadataLocation </summary>Command API Reference / Input / Output
</details> <details> <summary> GetTablePolicy </summary>Command API Reference / Input / Output
</details> <details> <summary> GetTableRecordExpirationConfiguration </summary>Command API Reference / Input / Output
</details> <details> <summary> GetTableRecordExpirationJobStatus </summary>Command API Reference / Input / Output
</details> <details> <summary> GetTableReplication </summary>Command API Reference / Input / Output
</details> <details> <summary> GetTableReplicationStatus </summary>Command API Reference / Input / Output
</details> <details> <summary> GetTableStorageClass </summary>Command API Reference / Input / Output
</details> <details> <summary> ListNamespaces </summary>Command API Reference / Input / Output
</details> <details> <summary> ListTableBuckets </summary>Command API Reference / Input / Output
</details> <details> <summary> ListTables </summary>Command API Reference / Input / Output
</details> <details> <summary> ListTagsForResource </summary>Command API Reference / Input / Output
</details> <details> <summary> PutTableBucketEncryption </summary>Command API Reference / Input / Output
</details> <details> <summary> PutTableBucketMaintenanceConfiguration </summary>Command API Reference / Input / Output
</details> <details> <summary> PutTableBucketMetricsConfiguration </summary>Command API Reference / Input / Output
</details> <details> <summary> PutTableBucketPolicy </summary>Command API Reference / Input / Output
</details> <details> <summary> PutTableBucketReplication </summary>Command API Reference / Input / Output
</details> <details> <summary> PutTableBucketStorageClass </summary>Command API Reference / Input / Output
</details> <details> <summary> PutTableMaintenanceConfiguration </summary>Command API Reference / Input / Output
</details> <details> <summary> PutTablePolicy </summary>Command API Reference / Input / Output
</details> <details> <summary> PutTableRecordExpirationConfiguration </summary>Command API Reference / Input / Output
</details> <details> <summary> PutTableReplication </summary>Command API Reference / Input / Output
</details> <details> <summary> RenameTable </summary>Command API Reference / Input / Output
</details> <details> <summary> TagResource </summary>Command API Reference / Input / Output
</details> <details> <summary> UntagResource </summary> </details> <details> <summary> UpdateTableMetadataLocation </summary> </details>