From 8493608e5d93a481b51a18dbc06fb98e0b525431 Mon Sep 17 00:00:00 2001 From: Jana R <94439978+grjan7@users.noreply.github.com> Date: Tue, 9 Apr 2024 05:24:52 +0530 Subject: [PATCH] docs: fix typos (#5972) --- CODE_OF_CONDUCT.md | 2 +- CONTRIBUTING.md | 4 ++-- README.md | 18 +++++++++--------- UPGRADING.md | 6 +++--- deprecated/packages/middleware-stack/README.md | 2 +- lib/lib-dynamodb/README.md | 2 +- packages/chunked-stream-reader-node/README.md | 2 +- packages/credential-provider-node/README.md | 2 +- packages/credential-providers/README.md | 8 ++++---- packages/ec2-metadata-service/README.md | 4 ++-- packages/util-create-request/README.md | 2 +- scripts/benchmark-size/README.md | 4 ++-- scripts/cli-dispatcher/readme.md | 4 ++-- supplemental-docs/CLIENTS.md | 4 ++-- supplemental-docs/performance/bundle-sizes.md | 4 ++-- tests/e2e/README.md | 2 +- tests/react-native/End2End/README.md | 4 ++-- 17 files changed, 37 insertions(+), 37 deletions(-) diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md index ec98f2b76e80..f93babd52808 100644 --- a/CODE_OF_CONDUCT.md +++ b/CODE_OF_CONDUCT.md @@ -1,5 +1,5 @@ ## Code of Conduct This project has adopted the [Amazon Open Source Code of Conduct](https://aws.github.io/code-of-conduct). -For more information see the [Code of Conduct FAQ](https://aws.github.io/code-of-conduct-faq) or contact +For more information, see the [Code of Conduct FAQ](https://aws.github.io/code-of-conduct-faq) or contact opensource-codeofconduct@amazon.com with any additional questions or comments. diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index a379ec08cc40..030bb402e9f2 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -201,7 +201,7 @@ the generated code change to your PR. Here's how to generate clients: There are optional CLI helpers. The CLI helpers assist in the dispatch of commands to package or subfolder contexts. -To activate the default aliases run: +To activate the default aliases, run: ``` . ./scripts/cli-dispatcher/set-alias.sh @@ -260,7 +260,7 @@ matches to: yarn **t**est in packages/**m**iddleware-**sign**ing The package name query is used to find the package within clients, lib, or packages, and the npm script query is used to find a command to execute from within `package.json` `scripts`. -In both queries, you can use space-separated substrings. They must occur in the matching package or command in linear order. Priority is given to whole-word matches, initial word matches, and shorter strings. If your instructions are ambiguous the first priority match will be executed. Use the dry-run or confirm options to check your command before execution. +In both queries, you can use space-separated substrings. They must occur in the matching package or command in linear order. Priority is given to whole-word matches, initial word matches, and shorter strings. If your instructions are ambiguous, the first priority match will be executed. Use the dry-run or confirm options to check your command before execution. Additional options: --dry (dry run), --c (confirm before execution), --help diff --git a/README.md b/README.md index 388b7e0c8870..dffd12e9fdd1 100644 --- a/README.md +++ b/README.md @@ -187,7 +187,7 @@ we have them listed in [UPGRADING.md](https://github.com/aws/aws-sdk-js-v3/blob/ ### General Info -The Lambda provided AWS SDK is set to a specific minor version, and **NOT** the latest version. To check the minor version used by Lambda please refer to [Lambda runtimes doc page](https://docs.aws.amazon.com/lambda/latest/dg/lambda-runtimes.html). +The Lambda provided AWS SDK is set to a specific minor version, and **NOT** the latest version. To check the minor version used by Lambda, please refer to [Lambda runtimes doc page](https://docs.aws.amazon.com/lambda/latest/dg/lambda-runtimes.html). If you wish to use the latest / different version of the SDK from the one provided by lambda, we recommend that you [bundle and minify](https://aws.amazon.com/blogs/compute/optimizing-node-js-dependencies-in-aws-lambda/) your project, or [upload it as a Lambda layer](https://aws.amazon.com/blogs/compute/using-lambda-layers-to-simplify-your-development-process/). The performance of the AWS SDK for JavaScript v3 on node 18 has improved from v2 as seen in the [performance benchmarking](https://aws.amazon.com/blogs/developer/reduce-lambda-cold-start-times-migrate-to-aws-sdk-for-javascript-v3/) @@ -344,7 +344,7 @@ The v3 codebase is generated from internal AWS models that AWS services expose. Clients depend on common "utility" code in `/packages`. The code in `/packages` is manually written and outside of special cases (like credentials or abort controller) is generally not very useful alone. -Lastly we have higher level libraries in `/lib`. These are javascript specific libraries that wrap client operations to make them easier to work with. Popular examples are `@aws-sdk/lib-dynamodb` which [simplifies working with items in Amazon DynamoDB](https://github.com/aws/aws-sdk-js-v3/blob/main/lib/lib-dynamodb/README.md) or `@aws-sdk/lib-storage` which exposes the `Upload` function and [simplifies parallel uploads in S3's multipartUpload](https://github.com/aws/aws-sdk-js-v3/blob/main/lib/lib-storage/README.md). +Lastly, we have higher level libraries in `/lib`. These are javascript specific libraries that wrap client operations to make them easier to work with. Popular examples are `@aws-sdk/lib-dynamodb` which [simplifies working with items in Amazon DynamoDB](https://github.com/aws/aws-sdk-js-v3/blob/main/lib/lib-dynamodb/README.md) or `@aws-sdk/lib-storage` which exposes the `Upload` function and [simplifies parallel uploads in S3's multipartUpload](https://github.com/aws/aws-sdk-js-v3/blob/main/lib/lib-storage/README.md). 1. `/packages`. This sub directory is where most manual code updates are done. These are published to NPM under `@aws-sdk/XXXX` and have no special prefix. 1. `/clients`. This sub directory is code generated and depends on code published from `/packages` . It is 1:1 with AWS services and operations. Manual edits should generally not occur here. These are published to NPM under `@aws-sdk/client-XXXX`. @@ -394,7 +394,7 @@ on a stream. Many AWS operations return paginated results when the response object is too large to return in a single response. In AWS SDK for JavaScript v2, the response contains a token you can use to retrieve the next page of results. You then need to write additional functions to process pages of results. -In AWS SDK for JavaScript v3 we’ve improved pagination using async generator functions, which are similar to generator functions, with the following differences: +In AWS SDK for JavaScript v3, we’ve improved pagination using async generator functions, which are similar to generator functions, with the following differences: - When called, async generator functions return an object, an async generator whose methods (`next`, `throw`, and `return`) return promises for `{ `value`, `done` }`, instead of directly returning `{ `value`, `done` }`. This automatically makes the returned async generator objects async iterators. - await expressions and `for await (x of y)` statements are allowed. @@ -489,7 +489,7 @@ abortController.abort(); await requestPromise; ``` -For a full pagination deep dive please check out our [blog post](https://aws.amazon.com/blogs/developer/pagination-using-async-iterators-in-modular-aws-sdk-for-javascript/). +For a full pagination deep dive, please check out our [blog post](https://aws.amazon.com/blogs/developer/pagination-using-async-iterators-in-modular-aws-sdk-for-javascript/). #### AbortController Example @@ -523,7 +523,7 @@ const uploadObject = async (file) => { } ``` -For a full abort controller deep dive please check out our [blog post](https://aws.amazon.com/blogs/developer/abortcontroller-in-modular-aws-sdk-for-javascript/). +For a full abort controller deep dive, please check out our [blog post](https://aws.amazon.com/blogs/developer/abortcontroller-in-modular-aws-sdk-for-javascript/). ### Middleware Stack @@ -568,7 +568,7 @@ The example above adds middleware to `build` step of middleware stack. The middl - The **build** lifecycle step builds on top of serialized HTTP request. Examples of typical build tasks include injecting HTTP headers that describe a stable aspect of the request, such as `Content-Length` or a body checksum. Any request alterations will be applied to all retries. - The **finalizeRequest** lifecycle step prepares the request to be sent over the wire. The request in this stage is semantically complete and should therefore only be altered to match the recipient’s expectations. Examples of typical finalization tasks include request signing, performing retries and injecting hop-by-hop headers. - The **deserialize** lifecycle step deserializes the raw response object to a structured response. The upstream middleware have access to deserialized data in next callbacks return value: `result.output`. - Each middleware must be added to a specific step. By default each middleware in the same step has undifferentiated order. In some cases, you might want to execute a middleware before or after another middleware in the same step. You can achieve it by specifying its `priority`. + Each middleware must be added to a specific step. By default, each middleware in the same step has undifferentiated order. In some cases, you might want to execute a middleware before or after another middleware in the same step. You can achieve it by specifying its `priority`. ```javascript client.middlewareStack.add(middleware, { @@ -579,7 +579,7 @@ client.middlewareStack.add(middleware, { }); ``` -For a full middleware stack deep dive please check out our [blog post](https://aws.amazon.com/blogs/developer/middleware-stack-modular-aws-sdk-js/). +For a full middleware stack deep dive, please check out our [blog post](https://aws.amazon.com/blogs/developer/middleware-stack-modular-aws-sdk-js/). ## Release Cadence @@ -639,7 +639,7 @@ bindings to be included as a dependency with your application. This functionalit - [Amazon S3 Multi-Region Access Points](https://docs.aws.amazon.com/AmazonS3/latest/userguide/MultiRegionAccessPoints.html) - [Amazon S3 Object Integrity](https://docs.aws.amazon.com/AmazonS3/latest/userguide/checking-object-integrity.html) -If the required AWS Common Runtime components are not installed you will receive an error like: +If the required AWS Common Runtime components are not installed, you will receive an error like: ```console Cannot find module '@aws-sdk/signature-v4-crt' @@ -651,7 +651,7 @@ For more information please go to https://github.com/aws/aws-sdk-js-v3#functionality-requiring-aws-common-runtime-crt" ``` -indicating that the required dependency is missing to use the associated functionality. To install this dependency follow +indicating that the required dependency is missing to use the associated functionality. To install this dependency, follow the provided [instructions](#installing-the-aws-common-runtime-crt-dependency). #### Installing the AWS Common Runtime (CRT) Dependency diff --git a/UPGRADING.md b/UPGRADING.md index 9d452aa7e9a8..ff2036ebcd06 100644 --- a/UPGRADING.md +++ b/UPGRADING.md @@ -3,7 +3,7 @@ This document captures notable changes from AWS SDK for JavaScript v2 to v3. The v3 is also known as modular AWS SDK for JavaScript. -Because v3 is a modular rewrite of v2, some basic conceptions are different between v2 and v3. You can learn about +Because, v3 is a modular rewrite of v2, some basic conceptions are different between v2 and v3. You can learn about these changes in our [blog posts](https://aws.amazon.com/blogs/developer/category/developer-tools/aws-sdk-for-javascript-in-node-js/). The following blog posts will get you up to speed: @@ -65,7 +65,7 @@ This list is indexed by [v2 config parameters](https://docs.aws.amazon.com/AWSJa httpsAgent: new Agent({ /*params*/ }), - connectionTimeout: /*number in milliseconds*/ + connectionTimeout: /*number in milliseconds*/, socketTimeout: /*number in milliseconds*/ }), }); @@ -496,7 +496,7 @@ await ddbDocClient.send( ### `undefined` values in when marshalling -- In v2 `undefined` values in objects were automatically omitted during the marshalling process to DynamoDB. +- In v2, `undefined` values in objects were automatically omitted during the marshalling process to DynamoDB. - In v3, the default marshalling behavior in @aws-sdk/lib-dynamodb has changed: objects with `undefined` values are no longer omitted. To align with v2's functionality, developers must explicitly set the `removeUndefinedValues` to `true` in the `marshallOptions` of the DynamoDBDocumentClient. diff --git a/deprecated/packages/middleware-stack/README.md b/deprecated/packages/middleware-stack/README.md index 90a1c78fab8b..58b8120d058f 100644 --- a/deprecated/packages/middleware-stack/README.md +++ b/deprecated/packages/middleware-stack/README.md @@ -36,7 +36,7 @@ stack.add(middleware, { }); ``` -This approach works for most cases. Sometimes you want your middleware to be executed in the front of the `Step`, you can set the `Priority` to `high`. Set the `Priority` to `low` then this middleware will be executed at the end of `Step`: +This approach works for most cases. Sometimes you want your middleware to be executed in the front of the `Step`, you can set the `Priority` to `high`. Set the `Priority` to `low`, then this middleware will be executed at the end of `Step`: ```javascript stack.add(middleware, { diff --git a/lib/lib-dynamodb/README.md b/lib/lib-dynamodb/README.md index 72339396282f..d97cecacf984 100644 --- a/lib/lib-dynamodb/README.md +++ b/lib/lib-dynamodb/README.md @@ -50,7 +50,7 @@ both input and output: ## Usage -To create document client you need to create DynamoDB client first as follows: +To create document client, you need to create DynamoDB client first as follows: ```js import { DynamoDBClient } from "@aws-sdk/client-dynamodb"; // ES6 import diff --git a/packages/chunked-stream-reader-node/README.md b/packages/chunked-stream-reader-node/README.md index be43972d7504..6baf4f646f2e 100644 --- a/packages/chunked-stream-reader-node/README.md +++ b/packages/chunked-stream-reader-node/README.md @@ -3,7 +3,7 @@ [![NPM version](https://img.shields.io/npm/v/@aws-sdk/chunked-stream-reader-node/latest.svg)](https://www.npmjs.com/package/@aws-sdk/chunked-stream-reader-node) [![NPM downloads](https://img.shields.io/npm/dm/@aws-sdk/chunked-stream-reader-node.svg)](https://www.npmjs.com/package/@aws-sdk/chunked-stream-reader-node) -Exports a streamReader function that accepts a readable stream, a function to call on each chunk, and a chunk size in bytes to buffer interally before calling the supplied function. +Exports a streamReader function that accepts a readable stream, a function to call on each chunk, and a chunk size in bytes to buffer internally before calling the supplied function. This package is meant for the AWS SDK for JavaScript to enable reading a stream with consistent chunk sizes. diff --git a/packages/credential-provider-node/README.md b/packages/credential-provider-node/README.md index 6fd902d855a4..82e58a6c8f7a 100644 --- a/packages/credential-provider-node/README.md +++ b/packages/credential-provider-node/README.md @@ -28,7 +28,7 @@ that does not exist), then the chained provider will be rejected with an error and will not invoke the next provider in the list. _IMPORTANT_: if you intend to acquire credentials using EKS -[IAM Roles for Service Accounts](https://docs.aws.amazon.com/eks/latest/userguide/iam-roles-for-service-accounts.html) +[IAM Roles for Service Accounts](https://docs.aws.amazon.com/eks/latest/userguide/iam-roles-for-service-accounts.html), then you must explicitly specify a value for `roleAssumerWithWebIdentity`. There is a default function available in `@aws-sdk/client-sts` package. An example of using this: diff --git a/packages/credential-providers/README.md b/packages/credential-providers/README.md index c098379a6029..a5dc718f9f77 100644 --- a/packages/credential-providers/README.md +++ b/packages/credential-providers/README.md @@ -501,7 +501,7 @@ role_arn=arn:aws:iam::123456789012:role/example-role #### profile with sso credentials -See [`fromSSO()`](#fromsso) fro more information +See [`fromSSO()`](#fromsso) for more information ## `fromEnv()` @@ -522,7 +522,7 @@ environment variables: - `AWS_ACCESS_KEY_ID` - The access key for your AWS account. - `AWS_SECRET_ACCESS_KEY` - The secret key for your AWS account. - `AWS_SESSION_TOKEN` - The session key for your AWS account. This is only needed when you are using - temporarycredentials. + temporary credentials. - `AWS_CREDENTIAL_EXPIRATION` - The expiration time of the credentials contained in the environment variables described above. This value must be in a format compatible with the [ISO-8601 standard][iso8601_standard] and is only needed when you are using temporary credentials. @@ -704,14 +704,14 @@ CLI profile name [123456789011_ReadOnly]: my-sso-profile ```javascript //... -const client = new FooClient({ credentials: fromSSO({ profile: "my-sso-profile" }); +const client = new FooClient({ credentials: fromSSO({ profile: "my-sso-profile" })}); ``` Alternatively, the SSO credential provider is supported in shared INI credentials provider ```javascript //... -const client = new FooClient({ credentials: fromIni({ profile: "my-sso-profile" }); +const client = new FooClient({ credentials: fromIni({ profile: "my-sso-profile" })}); ``` 3. To log out from the current SSO session, use the AWS CLI: diff --git a/packages/ec2-metadata-service/README.md b/packages/ec2-metadata-service/README.md index ea47f9cfad36..7c912dee4850 100644 --- a/packages/ec2-metadata-service/README.md +++ b/packages/ec2-metadata-service/README.md @@ -11,7 +11,7 @@ The basic usage of EC2 IMDS utils in the AWS SDK for JavaScript v3 is as follows JavaScript example -``` +```JavaScript const { MetadataService } = require("@aws-sdk/ec2-metadata-service"); const metadataService = new MetadataService({}); @@ -21,7 +21,7 @@ const metadata = await metadataService.request("/latest/meta-data/", {}); // req ES6 example -``` +```JavaScript import { MetadataService } from "@aws-sdk/ec2-metadata-service"; const metadataService = new MetadataService({}); diff --git a/packages/util-create-request/README.md b/packages/util-create-request/README.md index 700266772baa..a067efb4d1bc 100644 --- a/packages/util-create-request/README.md +++ b/packages/util-create-request/README.md @@ -65,7 +65,7 @@ const request = await createRequest