@platformatic/service 2.7.0 → 2.7.1-alpha.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/lib/stackable.js +8 -1
- package/package.json +9 -9
- package/schema.json +2 -2
package/lib/stackable.js
CHANGED
|
@@ -9,6 +9,8 @@ const { extractTypeScriptCompileOptionsFromConfig } = require('./compile')
|
|
|
9
9
|
const { compile } = require('@platformatic/ts-compiler')
|
|
10
10
|
const { deepmerge } = require('@platformatic/utils')
|
|
11
11
|
|
|
12
|
+
const kITC = Symbol.for('plt.runtime.itc')
|
|
13
|
+
|
|
12
14
|
class ServiceStackable {
|
|
13
15
|
constructor (options) {
|
|
14
16
|
this.app = null
|
|
@@ -34,7 +36,8 @@ class ServiceStackable {
|
|
|
34
36
|
this.registerGlobals({
|
|
35
37
|
setOpenapiSchema: this.setOpenapiSchema.bind(this),
|
|
36
38
|
setGraphqlSchema: this.setGraphqlSchema.bind(this),
|
|
37
|
-
setBasePath: this.setBasePath.bind(this)
|
|
39
|
+
setBasePath: this.setBasePath.bind(this),
|
|
40
|
+
invalidateHttpCache: this.#invalidateHttpCache.bind(this)
|
|
38
41
|
})
|
|
39
42
|
}
|
|
40
43
|
|
|
@@ -218,6 +221,10 @@ class ServiceStackable {
|
|
|
218
221
|
globalThis.platformatic = Object.assign(globalThis.platformatic ?? {}, globals)
|
|
219
222
|
}
|
|
220
223
|
|
|
224
|
+
async #invalidateHttpCache (opts = {}) {
|
|
225
|
+
await globalThis[kITC].send('invalidateHttpCache', opts)
|
|
226
|
+
}
|
|
227
|
+
|
|
221
228
|
#setHttpMetrics () {
|
|
222
229
|
this.app.register(httpMetrics, {
|
|
223
230
|
registry: this.metricsRegistry,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@platformatic/service",
|
|
3
|
-
"version": "2.7.
|
|
3
|
+
"version": "2.7.1-alpha.1",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"bin": {
|
|
@@ -76,14 +76,14 @@
|
|
|
76
76
|
"rfdc": "^1.3.1",
|
|
77
77
|
"semgrator": "^0.3.0",
|
|
78
78
|
"undici": "^6.9.0",
|
|
79
|
-
"@platformatic/client": "2.7.
|
|
80
|
-
"@platformatic/metrics": "2.7.
|
|
81
|
-
"@platformatic/scalar-theme": "2.7.
|
|
82
|
-
"@platformatic/generators": "2.7.
|
|
83
|
-
"@platformatic/telemetry": "2.7.
|
|
84
|
-
"@platformatic/ts-compiler": "2.7.
|
|
85
|
-
"@platformatic/utils": "2.7.
|
|
86
|
-
"@platformatic/config": "2.7.
|
|
79
|
+
"@platformatic/client": "2.7.1-alpha.1",
|
|
80
|
+
"@platformatic/metrics": "2.7.1-alpha.1",
|
|
81
|
+
"@platformatic/scalar-theme": "2.7.1-alpha.1",
|
|
82
|
+
"@platformatic/generators": "2.7.1-alpha.1",
|
|
83
|
+
"@platformatic/telemetry": "2.7.1-alpha.1",
|
|
84
|
+
"@platformatic/ts-compiler": "2.7.1-alpha.1",
|
|
85
|
+
"@platformatic/utils": "2.7.1-alpha.1",
|
|
86
|
+
"@platformatic/config": "2.7.1-alpha.1"
|
|
87
87
|
},
|
|
88
88
|
"scripts": {
|
|
89
89
|
"test": "pnpm run lint && borp -T --concurrency=1 --timeout=180000 && tsd",
|
package/schema.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
|
-
"$id": "https://schemas.platformatic.dev/@platformatic/service/2.7.
|
|
3
|
-
"version": "2.7.
|
|
2
|
+
"$id": "https://schemas.platformatic.dev/@platformatic/service/2.7.1-alpha.1.json",
|
|
3
|
+
"version": "2.7.1-alpha.1",
|
|
4
4
|
"title": "Platformatic Service",
|
|
5
5
|
"type": "object",
|
|
6
6
|
"properties": {
|