@cedarjs/graphql-server 4.0.0-canary.13831 → 4.0.0-canary.13833
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.
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useRedwoodLogger.d.ts","sourceRoot":"","sources":["../../../src/plugins/useRedwoodLogger.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,cAAc,CAAA;AAI1C,OAAO,KAAK,EAAE,MAAM,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAA;AAGlE,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,aAAa,CAAA;AAEtD;;;;;;;;;;;;;GAaG;AACH,KAAK,oBAAoB,GAAG;IAC1B;;;;;;;;;;;;;;;;;;;;;;OAsBG;IACH,KAAK,CAAC,EAAE,eAAe,GAAG,MAAM,CAAA;IAEhC;;OAEG;IACH,IAAI,CAAC,EAAE,OAAO,CAAA;IAEd;;;;;;;;;;OAUG;IACH,aAAa,CAAC,EAAE,OAAO,CAAA;IAEvB;;;;OAIG;IACH,SAAS,CAAC,EAAE,OAAO,CAAA;IAEnB;;OAEG;IACH,KAAK,CAAC,EAAE,OAAO,CAAA;IAEf;;;;OAIG;IACH,OAAO,CAAC,EAAE,OAAO,CAAA;IAEjB;;;;OAIG;IACH,SAAS,CAAC,EAAE,OAAO,CAAA;IAEnB;;;;;OAKG;IACH,iBAAiB,CAAC,EAAE,MAAM,EAAE,CAAA;CAC7B,CAAA;AAED;;;;;GAKG;AACH,MAAM,MAAM,YAAY,GAAG;IACzB,MAAM,EAAE,MAAM,CAAA;IACd,OAAO,CAAC,EAAE,oBAAoB,CAAA;CAC/B,CAAA;AA+DD;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,gBAAgB,GAC3B,cAAc,YAAY,KACzB,MAAM,CAAC,mBAAmB,
|
|
1
|
+
{"version":3,"file":"useRedwoodLogger.d.ts","sourceRoot":"","sources":["../../../src/plugins/useRedwoodLogger.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,cAAc,CAAA;AAI1C,OAAO,KAAK,EAAE,MAAM,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAA;AAGlE,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,aAAa,CAAA;AAEtD;;;;;;;;;;;;;GAaG;AACH,KAAK,oBAAoB,GAAG;IAC1B;;;;;;;;;;;;;;;;;;;;;;OAsBG;IACH,KAAK,CAAC,EAAE,eAAe,GAAG,MAAM,CAAA;IAEhC;;OAEG;IACH,IAAI,CAAC,EAAE,OAAO,CAAA;IAEd;;;;;;;;;;OAUG;IACH,aAAa,CAAC,EAAE,OAAO,CAAA;IAEvB;;;;OAIG;IACH,SAAS,CAAC,EAAE,OAAO,CAAA;IAEnB;;OAEG;IACH,KAAK,CAAC,EAAE,OAAO,CAAA;IAEf;;;;OAIG;IACH,OAAO,CAAC,EAAE,OAAO,CAAA;IAEjB;;;;OAIG;IACH,SAAS,CAAC,EAAE,OAAO,CAAA;IAEnB;;;;;OAKG;IACH,iBAAiB,CAAC,EAAE,MAAM,EAAE,CAAA;CAC7B,CAAA;AAED;;;;;GAKG;AACH,MAAM,MAAM,YAAY,GAAG;IACzB,MAAM,EAAE,MAAM,CAAA;IACd,OAAO,CAAC,EAAE,oBAAoB,CAAA;CAC/B,CAAA;AA+DD;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,gBAAgB,GAC3B,cAAc,YAAY,KACzB,MAAM,CAAC,mBAAmB,CAgH5B,CAAA"}
|
|
@@ -122,10 +122,17 @@ const useRedwoodLogger = (loggerConfig) => {
|
|
|
122
122
|
options["query"] = args.variableValues;
|
|
123
123
|
}
|
|
124
124
|
if (includeRequestId) {
|
|
125
|
-
options["requestId"] =
|
|
125
|
+
options["requestId"] = // x-request-id is a widely adopted (though informal) HTTP header for
|
|
126
|
+
// distributed tracing. Load balancers, API gateways, and clients set
|
|
127
|
+
// it on each request so that all log lines for a single request can
|
|
128
|
+
// be correlated across services. We check it first so that an
|
|
129
|
+
// externally assigned ID is preserved end-to-end; if it is absent we
|
|
130
|
+
// fall back to the Lambda/API-Gateway request ID, and finally
|
|
131
|
+
// generate a UUID so there is always something to correlate on.
|
|
132
|
+
args.contextValue.request?.headers.get("x-request-id") || args.contextValue.requestContext?.awsRequestId || args.contextValue.event?.requestContext?.requestId || (0, import_uuid.v4)();
|
|
126
133
|
}
|
|
127
134
|
if (includeUserAgent) {
|
|
128
|
-
options["userAgent"] = args.contextValue.event?.headers["user-agent"];
|
|
135
|
+
options["userAgent"] = args.contextValue.request?.headers.get("user-agent") || args.contextValue.event?.headers["user-agent"];
|
|
129
136
|
}
|
|
130
137
|
const envelopLogger = childLogger.child({
|
|
131
138
|
...options
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useRedwoodLogger.d.ts","sourceRoot":"","sources":["../../src/plugins/useRedwoodLogger.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,cAAc,CAAA;AAI1C,OAAO,KAAK,EAAE,MAAM,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAA;AAGlE,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,aAAa,CAAA;AAEtD;;;;;;;;;;;;;GAaG;AACH,KAAK,oBAAoB,GAAG;IAC1B;;;;;;;;;;;;;;;;;;;;;;OAsBG;IACH,KAAK,CAAC,EAAE,eAAe,GAAG,MAAM,CAAA;IAEhC;;OAEG;IACH,IAAI,CAAC,EAAE,OAAO,CAAA;IAEd;;;;;;;;;;OAUG;IACH,aAAa,CAAC,EAAE,OAAO,CAAA;IAEvB;;;;OAIG;IACH,SAAS,CAAC,EAAE,OAAO,CAAA;IAEnB;;OAEG;IACH,KAAK,CAAC,EAAE,OAAO,CAAA;IAEf;;;;OAIG;IACH,OAAO,CAAC,EAAE,OAAO,CAAA;IAEjB;;;;OAIG;IACH,SAAS,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,CAAA;CAC/B,CAAA;AA+DD;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,gBAAgB,GAC3B,cAAc,YAAY,KACzB,MAAM,CAAC,mBAAmB,CAgH5B,CAAA"}
|
|
@@ -99,10 +99,17 @@ const useRedwoodLogger = (loggerConfig) => {
|
|
|
99
99
|
options["query"] = args.variableValues;
|
|
100
100
|
}
|
|
101
101
|
if (includeRequestId) {
|
|
102
|
-
options["requestId"] =
|
|
102
|
+
options["requestId"] = // x-request-id is a widely adopted (though informal) HTTP header for
|
|
103
|
+
// distributed tracing. Load balancers, API gateways, and clients set
|
|
104
|
+
// it on each request so that all log lines for a single request can
|
|
105
|
+
// be correlated across services. We check it first so that an
|
|
106
|
+
// externally assigned ID is preserved end-to-end; if it is absent we
|
|
107
|
+
// fall back to the Lambda/API-Gateway request ID, and finally
|
|
108
|
+
// generate a UUID so there is always something to correlate on.
|
|
109
|
+
args.contextValue.request?.headers.get("x-request-id") || args.contextValue.requestContext?.awsRequestId || args.contextValue.event?.requestContext?.requestId || uuidv4();
|
|
103
110
|
}
|
|
104
111
|
if (includeUserAgent) {
|
|
105
|
-
options["userAgent"] = args.contextValue.event?.headers["user-agent"];
|
|
112
|
+
options["userAgent"] = args.contextValue.request?.headers.get("user-agent") || args.contextValue.event?.headers["user-agent"];
|
|
106
113
|
}
|
|
107
114
|
const envelopLogger = childLogger.child({
|
|
108
115
|
...options
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cedarjs/graphql-server",
|
|
3
|
-
"version": "4.0.0-canary.
|
|
3
|
+
"version": "4.0.0-canary.13833+8afeb9410d",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "git+https://github.com/cedarjs/cedar.git",
|
|
@@ -37,8 +37,8 @@
|
|
|
37
37
|
"test:watch": "yarn test --watch"
|
|
38
38
|
},
|
|
39
39
|
"dependencies": {
|
|
40
|
-
"@cedarjs/api": "4.0.0-canary.
|
|
41
|
-
"@cedarjs/context": "4.0.0-canary.
|
|
40
|
+
"@cedarjs/api": "4.0.0-canary.13833",
|
|
41
|
+
"@cedarjs/context": "4.0.0-canary.13833",
|
|
42
42
|
"@envelop/core": "5.5.1",
|
|
43
43
|
"@envelop/depth-limit": "4.0.0",
|
|
44
44
|
"@envelop/disable-introspection": "6.0.0",
|
|
@@ -61,9 +61,9 @@
|
|
|
61
61
|
"devDependencies": {
|
|
62
62
|
"@babel/cli": "7.28.6",
|
|
63
63
|
"@babel/core": "^7.26.10",
|
|
64
|
-
"@cedarjs/framework-tools": "4.0.0-canary.
|
|
65
|
-
"@cedarjs/project-config": "4.0.0-canary.
|
|
66
|
-
"@cedarjs/realtime": "4.0.0-canary.
|
|
64
|
+
"@cedarjs/framework-tools": "4.0.0-canary.13833",
|
|
65
|
+
"@cedarjs/project-config": "4.0.0-canary.13833",
|
|
66
|
+
"@cedarjs/realtime": "4.0.0-canary.13833",
|
|
67
67
|
"@envelop/types": "5.2.1",
|
|
68
68
|
"@types/aws-lambda": "8.10.161",
|
|
69
69
|
"@types/jsonwebtoken": "9.0.10",
|
|
@@ -83,5 +83,5 @@
|
|
|
83
83
|
"publishConfig": {
|
|
84
84
|
"access": "public"
|
|
85
85
|
},
|
|
86
|
-
"gitHead": "
|
|
86
|
+
"gitHead": "8afeb9410d1b51349ba27521bbb3bc71eba71ac5"
|
|
87
87
|
}
|