AWS aurora-dsql documentation change
Summary
Updated code example to use current_timestamp query and expanded examples section with connection pooling guidance
Security assessment
Changes are example improvements without security context. The connection pooling recommendation improves performance but doesn't directly address security vulnerabilities or document security features.
Diff
diff --git a/aurora-dsql/latest/userguide/SECTION_program-with-dsql-connector-for-postgresjs.md b/aurora-dsql/latest/userguide/SECTION_program-with-dsql-connector-for-postgresjs.md index 292d01382..378b0cf6f 100644 --- a//aurora-dsql/latest/userguide/SECTION_program-with-dsql-connector-for-postgresjs.md +++ b//aurora-dsql/latest/userguide/SECTION_program-with-dsql-connector-for-postgresjs.md @@ -88,2 +88,2 @@ The Aurora DSQL Connector for Postgres.js is designed to understand these requir - const users = await sql`SELECT * FROM users WHERE age > ${25}`; - console.log(users); + const result = await sql`SELECT current_timestamp`; + console.log(result); @@ -166 +166,6 @@ For more information on authentication in Aurora DSQL, see the [user guide](http -A JavaScript example using the Aurora DSQL Connector for Postgres.js is available [here](https://github.com/awslabs/aurora-dsql-connectors/tree/main/node/postgres-js/example). +JavaScript examples using the Aurora DSQL Connector for Postgres.js are available on GitHub. For instructions on how to run the examples, refer to the [examples directory](https://github.com/awslabs/aurora-dsql-connectors/tree/main/node/postgres-js/example). + +Description | Example +---|--- +Connection pooling with concurrent queries, including table creation, inserts, and reads across multiple workers | [Connection pool example (preferred)](https://github.com/awslabs/aurora-dsql-connectors/blob/main/node/postgres-js/example/src/example_preferred.js) +CRUD operations (create table, insert, select, delete) without connection pooling | [Example without connection pool](https://github.com/awslabs/aurora-dsql-connectors/blob/main/node/postgres-js/example/src/alternatives/no_connection_pool/example_with_no_connection_pool.js)