@platformatic/runtime 2.30.1-alpha.0 → 2.30.1

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.
package/config.d.ts CHANGED
@@ -5,7 +5,7 @@
5
5
  * and run json-schema-to-typescript to regenerate this file.
6
6
  */
7
7
 
8
- export type HttpsSchemasPlatformaticDevPlatformaticRuntime2301Alpha0Json = {
8
+ export type HttpsSchemasPlatformaticDevPlatformaticRuntime2301Json = {
9
9
  [k: string]: unknown;
10
10
  } & {
11
11
  $schema?: string;
@@ -132,6 +132,8 @@ const httpCacheInterceptor = (interceptorOpts) => {
132
132
  const originOnResponseStart = handler.onResponseStart.bind(handler)
133
133
  handler.onResponseStart = (ac, statusCode, headers, statusMessage) => {
134
134
  const cacheEntryId = headers[kCacheIdHeader] ?? headers[CACHE_ID_HEADER]
135
+ const isCacheHit = headers.age !== undefined
136
+
135
137
  if (cacheEntryId) {
136
138
  // Setting a cache id header on cache hit
137
139
  headers[CACHE_ID_HEADER] = cacheEntryId
@@ -142,6 +144,7 @@ const httpCacheInterceptor = (interceptorOpts) => {
142
144
  const { span } = clientSpansAls.getStore()
143
145
  if (span) {
144
146
  span.setAttribute('http.cache.id', cacheEntryId)
147
+ span.setAttribute('http.cache.hit', isCacheHit.toString())
145
148
  }
146
149
  } catch (err) {
147
150
  interceptorOpts.logger.error(err, 'Error setting cache id on span')
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@platformatic/runtime",
3
- "version": "2.30.1-alpha.0",
3
+ "version": "2.30.1",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "bin": {
@@ -35,12 +35,12 @@
35
35
  "typescript": "^5.5.4",
36
36
  "undici-oidc-interceptor": "^0.5.0",
37
37
  "why-is-node-running": "^2.2.2",
38
- "@platformatic/composer": "2.30.1-alpha.0",
39
- "@platformatic/db": "2.30.1-alpha.0",
40
- "@platformatic/node": "2.30.1-alpha.0",
41
- "@platformatic/service": "2.30.1-alpha.0",
42
- "@platformatic/sql-graphql": "2.30.1-alpha.0",
43
- "@platformatic/sql-mapper": "2.30.1-alpha.0"
38
+ "@platformatic/composer": "2.30.1",
39
+ "@platformatic/node": "2.30.1",
40
+ "@platformatic/sql-graphql": "2.30.1",
41
+ "@platformatic/sql-mapper": "2.30.1",
42
+ "@platformatic/service": "2.30.1",
43
+ "@platformatic/db": "2.30.1"
44
44
  },
45
45
  "dependencies": {
46
46
  "@fastify/accepts": "^5.0.0",
@@ -74,13 +74,13 @@
74
74
  "undici": "^7.0.0",
75
75
  "undici-thread-interceptor": "^0.10.3",
76
76
  "ws": "^8.16.0",
77
- "@platformatic/basic": "2.30.1-alpha.0",
78
- "@platformatic/config": "2.30.1-alpha.0",
79
- "@platformatic/generators": "2.30.1-alpha.0",
80
- "@platformatic/itc": "2.30.1-alpha.0",
81
- "@platformatic/telemetry": "2.30.1-alpha.0",
82
- "@platformatic/utils": "2.30.1-alpha.0",
83
- "@platformatic/ts-compiler": "2.30.1-alpha.0"
77
+ "@platformatic/basic": "2.30.1",
78
+ "@platformatic/generators": "2.30.1",
79
+ "@platformatic/config": "2.30.1",
80
+ "@platformatic/itc": "2.30.1",
81
+ "@platformatic/telemetry": "2.30.1",
82
+ "@platformatic/ts-compiler": "2.30.1",
83
+ "@platformatic/utils": "2.30.1"
84
84
  },
85
85
  "scripts": {
86
86
  "test": "npm run lint && borp --concurrency=1 --timeout=300000 && tsd",
package/schema.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "$id": "https://schemas.platformatic.dev/@platformatic/runtime/2.30.1-alpha.0.json",
2
+ "$id": "https://schemas.platformatic.dev/@platformatic/runtime/2.30.1.json",
3
3
  "$schema": "http://json-schema.org/draft-07/schema#",
4
4
  "type": "object",
5
5
  "properties": {