sst 2.11.13 → 2.11.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -570,6 +570,7 @@ export declare class Function extends CDKFunction implements SSTConstruct {
570
570
  type: "Function";
571
571
  data: {
572
572
  arn: string;
573
+ handler: string | undefined;
573
574
  localId: string;
574
575
  secrets: string[];
575
576
  };
@@ -316,6 +316,7 @@ export class Function extends CDKFunction {
316
316
  type: "Function",
317
317
  data: {
318
318
  arn: this.functionArn,
319
+ handler: this.props.handler,
319
320
  localId: this.node.addr,
320
321
  secrets: this.allBindings
321
322
  .filter((c) => c instanceof Secret)
@@ -13,7 +13,7 @@ export interface RDSProps {
13
13
  /**
14
14
  * Database engine of the cluster. Cannot be changed once set.
15
15
  */
16
- engine: "mysql5.6" | "mysql5.7" | "postgresql10.14" | "postgresql11.13";
16
+ engine: "mysql5.6" | "mysql5.7" | "postgresql10.14" | "postgresql11.13" | "postgresql11.16";
17
17
  /**
18
18
  * Name of a database which is automatically created inside the cluster.
19
19
  */
@@ -191,7 +191,7 @@ export declare class RDS extends Construct implements SSTConstruct {
191
191
  getConstructMetadata(): {
192
192
  type: "RDS";
193
193
  data: {
194
- engine: "mysql5.6" | "mysql5.7" | "postgresql10.14" | "postgresql11.13";
194
+ engine: "mysql5.6" | "mysql5.7" | "postgresql10.14" | "postgresql11.13" | "postgresql11.16";
195
195
  secretArn: string;
196
196
  types: RDSTypes | undefined;
197
197
  clusterArn: string;
package/constructs/RDS.js CHANGED
@@ -204,7 +204,12 @@ export class RDS extends Construct {
204
204
  version: rds.AuroraPostgresEngineVersion.VER_11_13,
205
205
  });
206
206
  }
207
- throw new Error(`The specified "engine" is not supported for sst.RDS. Only mysql5.6, mysql5.7, postgresql10.14, and postgresql11.13 engines are currently supported.`);
207
+ else if (engine === "postgresql11.16") {
208
+ return rds.DatabaseClusterEngine.auroraPostgres({
209
+ version: rds.AuroraPostgresEngineVersion.VER_11_16,
210
+ });
211
+ }
212
+ throw new Error(`The specified "engine" is not supported for sst.RDS. Only mysql5.6, mysql5.7, postgresql11.13, and postgresql11.16 engines are currently supported.`);
208
213
  }
209
214
  getScaling(scaling) {
210
215
  return {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "sideEffects": false,
3
3
  "name": "sst",
4
- "version": "2.11.13",
4
+ "version": "2.11.16",
5
5
  "bin": {
6
6
  "sst": "cli/sst.js"
7
7
  },
@@ -85,12 +85,15 @@ function isBinaryType(contentType) {
85
85
 
86
86
  function convertCfRequestToNode(event) {
87
87
  const request = event.Records[0].cf.request;
88
+ if (request.headers["x-forwarded-host"]) {
89
+ request.headers.host = request.headers["x-forwarded-host"];
90
+ }
88
91
 
89
- const host = request.headers["host"]
90
- ? request.headers["host"][0].value
91
- : undefined;
92
92
  const search = request.querystring.length ? `?${request.querystring}` : "";
93
- const url = new URL(request.uri + search, `https://${host}`);
93
+ const url = new URL(
94
+ request.uri + search,
95
+ `https://${request.headers["host"][0].value}`
96
+ );
94
97
 
95
98
  // Build headers
96
99
  const headers = new NodeHeaders();
@@ -83,11 +83,13 @@ function isBinaryType(contentType) {
83
83
  }
84
84
 
85
85
  function convertApigRequestToNode(event) {
86
- let host = event.headers["x-forwarded-host"] || event.headers.host;
87
- let search = event.rawQueryString.length ? `?${event.rawQueryString}` : "";
88
- let scheme = "https";
89
- let url = new URL(event.rawPath + search, `${scheme}://${host}`);
90
- let isFormData = event.headers["content-type"]?.includes(
86
+ if (event.headers["x-forwarded-host"]) {
87
+ event.headers.host = event.headers["x-forwarded-host"];
88
+ }
89
+
90
+ const search = event.rawQueryString.length ? `?${event.rawQueryString}` : "";
91
+ const url = new URL(event.rawPath + search, `https://${event.headers.host}`);
92
+ const isFormData = event.headers["content-type"]?.includes(
91
93
  "multipart/form-data"
92
94
  );
93
95