@platformatic/db 2.74.3 → 3.0.0-alpha.2

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.
Files changed (60) hide show
  1. package/config.d.ts +2 -30
  2. package/eslint.config.js +9 -5
  3. package/index.d.ts +56 -31
  4. package/index.js +67 -128
  5. package/lib/application.js +102 -0
  6. package/lib/commands/index.js +59 -0
  7. package/lib/commands/migrations-apply.js +62 -0
  8. package/lib/commands/migrations-create.js +48 -0
  9. package/lib/commands/print-schema.js +30 -0
  10. package/lib/commands/seed.js +72 -0
  11. package/lib/commands/types.js +21 -0
  12. package/lib/errors.js +15 -11
  13. package/lib/generator.js +229 -0
  14. package/lib/{migrator.mjs → migrator.js} +44 -37
  15. package/lib/{root-endpoint/index.js → root.js} +6 -7
  16. package/lib/schema.js +38 -22
  17. package/lib/stackable.js +14 -26
  18. package/lib/{generator/code-templates.js → templates.js} +57 -16
  19. package/lib/types.js +160 -0
  20. package/lib/upgrade.js +8 -12
  21. package/lib/utils.js +12 -23
  22. package/lib/versions/0.18.0.js +3 -5
  23. package/lib/versions/{from-zero-twenty-height-to-will-see.js → 0.28.0.js} +3 -5
  24. package/lib/versions/2.0.0.js +3 -5
  25. package/lib/versions/3.0.0.js +14 -0
  26. package/package.json +20 -28
  27. package/schema.json +9 -154
  28. package/tsconfig.json +16 -6
  29. package/.snapshots/810d795d512560f3863d8db472c81c27/0.json +0 -1
  30. package/.snapshots/810d795d512560f3863d8db472c81c27/1.json +0 -1
  31. package/db.mjs +0 -86
  32. package/help/compile.txt +0 -17
  33. package/help/create.txt +0 -13
  34. package/help/help.txt +0 -11
  35. package/help/migrations apply.txt +0 -45
  36. package/help/migrations create.txt +0 -27
  37. package/help/migrations.txt +0 -4
  38. package/help/schema.txt +0 -25
  39. package/help/seed.txt +0 -36
  40. package/help/start.txt +0 -47
  41. package/help/types.txt +0 -40
  42. package/index.test-d.ts +0 -43
  43. package/lib/adjust-config.js +0 -42
  44. package/lib/create.mjs +0 -89
  45. package/lib/gen-migration.mjs +0 -53
  46. package/lib/gen-schema.mjs +0 -68
  47. package/lib/gen-types.mjs +0 -202
  48. package/lib/generator/README.md +0 -38
  49. package/lib/generator/db-generator.js +0 -262
  50. package/lib/generator.d.ts +0 -7
  51. package/lib/migrate.mjs +0 -87
  52. package/lib/seed.mjs +0 -90
  53. /package/{lib/root-endpoint/public → public}/images/dark_mode.svg +0 -0
  54. /package/{lib/root-endpoint/public → public}/images/favicon.ico +0 -0
  55. /package/{lib/root-endpoint/public → public}/images/light_mode.svg +0 -0
  56. /package/{lib/root-endpoint/public → public}/images/platformatic-logo-dark.svg +0 -0
  57. /package/{lib/root-endpoint/public → public}/images/platformatic-logo-light.svg +0 -0
  58. /package/{lib/root-endpoint/public → public}/images/triangle_dark.svg +0 -0
  59. /package/{lib/root-endpoint/public → public}/images/triangle_light.svg +0 -0
  60. /package/{lib/root-endpoint/public → public}/index.html +0 -0
package/lib/stackable.js CHANGED
@@ -1,38 +1,27 @@
1
- 'use strict'
1
+ import { ServiceStackable } from '@platformatic/service'
2
+ import { platformaticDatabase } from './application.js'
3
+ import { packageJson } from './schema.js'
2
4
 
3
- const { ServiceStackable } = require('@platformatic/service')
5
+ export class DatabaseStackable extends ServiceStackable {
6
+ constructor (root, config, context) {
7
+ super(root, config, context)
8
+ this.type = 'db'
9
+ this.version = packageJson.version
4
10
 
5
- class DbStackable extends ServiceStackable {
6
- constructor (options) {
7
- super(options)
8
- this.#updateConfig()
11
+ this.applicationFactory = this.context.applicationFactory ?? platformaticDatabase
9
12
  }
10
13
 
11
- #updateConfig () {
12
- if (!this.context) return
14
+ updateContext (context) {
15
+ super.updateContext(context)
13
16
 
14
- const { isProduction } = this.context
15
- const config = this.configManager.current
16
-
17
- if (isProduction) {
18
- if (config.autogenerate) {
19
- config.autogenerate = false
20
- }
17
+ if (this.context.isProduction && this.config.autogenerate) {
18
+ this.config.autogenerate = false
21
19
  }
22
-
23
- this.configManager.update(config)
24
20
  }
25
21
 
26
22
  async getMeta () {
27
- await this.init()
28
- await this.app.ready()
29
-
30
23
  const serviceMeta = await super.getMeta()
31
-
32
- const config = this.configManager.current
33
-
34
- const dbConfig = config.db
35
- const connectionString = dbConfig?.connectionString
24
+ const connectionString = this.config.db?.connectionString
36
25
 
37
26
  if (connectionString) {
38
27
  return {
@@ -44,4 +33,3 @@ class DbStackable extends ServiceStackable {
44
33
  return serviceMeta
45
34
  }
46
35
  }
47
- module.exports = { DbStackable }
@@ -1,6 +1,4 @@
1
- 'use strict'
2
-
3
- const jsHelperSqlite = {
1
+ export const jsHelperSqlite = {
4
2
  requires: `
5
3
  const os = require('node:os')
6
4
  const path = require('node:path')
@@ -21,10 +19,10 @@ let counter = 0
21
19
  t.after(async () => {
22
20
  await fs.unlink(dbPath)
23
21
  })
24
- `,
22
+ `
25
23
  }
26
24
 
27
- function jsHelperPostgres (connectionString) {
25
+ export function jsHelperPostgres (connectionString) {
28
26
  return {
29
27
  // TODO(mcollina): replace sql-mapper
30
28
  requires: `
@@ -62,11 +60,11 @@ let counter = 0
62
60
  \`)
63
61
  await db.dispose()
64
62
  })
65
- `,
63
+ `
66
64
  }
67
65
  }
68
66
 
69
- function jsHelperMySQL (connectionString) {
67
+ export function jsHelperMySQL (connectionString) {
70
68
  return {
71
69
  // TODO(mcollina): replace sql-mapper
72
70
  requires: `
@@ -104,11 +102,11 @@ let counter = 0
104
102
  \`)
105
103
  await db.dispose()
106
104
  })
107
- `,
105
+ `
108
106
  }
109
107
  }
110
108
 
111
- const moviesTestJS = `\
109
+ export const moviesTestJS = `\
112
110
  'use strict'
113
111
 
114
112
  const test = require('node:test')
@@ -160,7 +158,7 @@ test('movies', async (t) => {
160
158
  })
161
159
  `
162
160
 
163
- const moviesTestTS = `\
161
+ export const moviesTestTS = `\
164
162
  import test from 'node:test'
165
163
  import assert from 'node:assert'
166
164
  import { getServer } from '../helper'
@@ -210,10 +208,53 @@ test('movies', async (t) => {
210
208
  })
211
209
  `
212
210
 
213
- module.exports = {
214
- jsHelperMySQL,
215
- jsHelperPostgres,
216
- jsHelperSqlite,
217
- moviesTestJS,
218
- moviesTestTS,
211
+ export const README = `
212
+ # Platformatic DB API
213
+
214
+ This is a generated [Platformatic DB](https://docs.platformatic.dev/docs/db/overview) application.
215
+
216
+ ## Requirements
217
+
218
+ Platformatic supports macOS, Linux and Windows ([WSL](https://docs.microsoft.com/windows/wsl/) recommended).
219
+ You'll need to have [Node.js](https://nodejs.org/) >= v18.8.0 or >= v20.6.0
220
+
221
+ ## Setup
222
+
223
+ 1. Install dependencies:
224
+
225
+ \`\`\`bash
226
+ npm install
227
+ \`\`\`
228
+
229
+ 2. Apply migrations:
230
+
231
+ \`\`\`bash
232
+ npm run migrate
233
+ \`\`\`
234
+
235
+
236
+ ## Usage
237
+
238
+ Run the API with:
239
+
240
+ \`\`\`bash
241
+ npm start
242
+ \`\`\`
243
+
244
+ ### Explore
245
+ - ⚡ The Platformatic DB server is running at http://localhost:3042/
246
+ - 📔 View the REST API's Swagger documentation at http://localhost:3042/documentation/
247
+ - 🔍 Try out the GraphiQL web UI at http://localhost:3042/graphiql
248
+
249
+ `
250
+
251
+ export const ENVIRONMENT_TEMPLATE = `
252
+ import { type FastifyInstance } from 'fastify'
253
+ import { PlatformaticApplication, PlatformaticDatabaseConfig, PlatformaticDatabaseMixin, Entities } from '@platformatic/db'
254
+
255
+ declare module 'fastify' {
256
+ interface FastifyInstance {
257
+ platformatic: PlatformaticApplication<PlatformaticDatabaseConfig> & PlatformaticDatabaseMixin<Entities>
258
+ }
219
259
  }
260
+ `
package/lib/types.js ADDED
@@ -0,0 +1,160 @@
1
+ import { createDirectory, isFileAccessible } from '@platformatic/foundation'
2
+ import { mapOpenAPItoTypes, mapSQLEntityToJSONSchema } from '@platformatic/sql-json-schema-mapper'
3
+ import camelcase from 'camelcase'
4
+ import { readFile, readdir, unlink, writeFile } from 'node:fs/promises'
5
+ import { basename, join, relative, resolve, sep } from 'node:path'
6
+ import { setupDB } from './utils.js'
7
+
8
+ async function removeUnusedTypeFiles (entities, dir) {
9
+ const entityTypes = await readdir(dir)
10
+ const entityNames = Object.keys(entities)
11
+ const removedEntityNames = entityTypes.filter(
12
+ file => file !== 'index.d.ts' && !entityNames.includes(basename(file, '.d.ts'))
13
+ )
14
+ await Promise.all(removedEntityNames.map(file => unlink(join(dir, file))))
15
+ }
16
+
17
+ async function generateEntityType (entity) {
18
+ const jsonSchema = mapSQLEntityToJSONSchema(entity)
19
+ const fieldDefinitions = Object.fromEntries(
20
+ Object.entries(entity.fields).map(([, value]) => [value.camelcase, value])
21
+ )
22
+
23
+ const tsCode = mapOpenAPItoTypes(jsonSchema, fieldDefinitions, { indentSpaces: 2 })
24
+
25
+ entity.name = camelcase(entity.name).replace(/^\w/, c => c.toUpperCase())
26
+ return tsCode.replaceAll(/^declare interface/gm, 'export interface')
27
+ }
28
+
29
+ async function generateIndexTypes (entities) {
30
+ const allImports = []
31
+ const allExports = []
32
+ const entityMembers = []
33
+ const entityTypesMembers = []
34
+ const entitiesHooks = []
35
+ const schemaGetters = []
36
+
37
+ const values = Object.entries(entities)
38
+ .map(([file, entity]) => [file, entity.name])
39
+ .sort((a, b) => a[0].localeCompare(b[0]))
40
+
41
+ for (const [name, type] of values) {
42
+ allImports.push(`import { ${type} } from './${name}'`)
43
+ allExports.push(`export { ${type} } from './${name}'`)
44
+ entityMembers.push(` ${name}: Entity<${type}>`)
45
+ entityTypesMembers.push(` ${name}: ${type}`)
46
+ entitiesHooks.push(` addEntityHooks(entityName: '${name}', hooks: EntityHooks<${type}>): any`)
47
+ schemaGetters.push(`getSchema(schemaId: '${name}'): {
48
+ '$id': string,
49
+ title: string,
50
+ description: string,
51
+ type: string,
52
+ properties: { [x in keyof ${type}]: { type: string, nullable?: boolean } },
53
+ required: string[]
54
+ }`)
55
+ }
56
+
57
+ const content = `import { Entity, EntityHooks, Entities as DatabaseEntities, PlatformaticDatabaseConfig, PlatformaticDatabaseMixin } from '@platformatic/db'
58
+ import { PlatformaticApplication, PlatformaticServiceConfig } from '@platformatic/service'
59
+ import { type FastifyInstance } from 'fastify'
60
+
61
+ ${allImports.join('\n')}
62
+
63
+ ${allExports.join('\n')}
64
+
65
+ export interface Entities extends DatabaseEntities {
66
+ ${entityMembers.join('\n')}
67
+ }
68
+
69
+ export interface EntityTypes {
70
+ ${entityTypesMembers.join('\n')}
71
+ }
72
+
73
+ export interface EntitiesHooks {
74
+ ${entitiesHooks.join('\n')}
75
+ }
76
+
77
+ export interface SchemaGetters {
78
+ ${schemaGetters.join('\n\n')}
79
+ }
80
+
81
+ export type ServerInstance<Configuration = PlatformaticDatabaseConfig> = FastifyInstance & {
82
+ platformatic: PlatformaticApplication<Configuration> & PlatformaticDatabaseMixin<Entities> & EntitiesHooks & SchemaGetters
83
+ }
84
+ `
85
+
86
+ return content
87
+ }
88
+
89
+ function generateEnvironmentTypes (folder) {
90
+ return `import { PlatformaticApplication, PlatformaticDatabaseConfig, PlatformaticDatabaseMixin } from "@platformatic/db";
91
+ import { Entities, EntitiesHooks, SchemaGetters } from "./${folder.replaceAll(sep, '/')}/index.js";
92
+
93
+ declare module "fastify" {
94
+ interface FastifyInstance {
95
+ platformatic: PlatformaticApplication<PlatformaticDatabaseConfig> & PlatformaticDatabaseMixin<Entities> & EntitiesHooks & SchemaGetters;
96
+ }
97
+ }
98
+ `
99
+ }
100
+
101
+ async function writeFileIfChanged (filename, content) {
102
+ const isFileExists = await isFileAccessible(filename)
103
+
104
+ if (isFileExists) {
105
+ const fileContent = await readFile(filename, 'utf-8')
106
+ if (fileContent === content) {
107
+ return false
108
+ }
109
+ }
110
+
111
+ await writeFile(filename, content)
112
+ return true
113
+ }
114
+
115
+ export async function execute ({ logger, config }) {
116
+ const wrap = await setupDB(logger, config.db)
117
+ const { db, entities } = wrap
118
+
119
+ const count = Object.keys(entities).length
120
+ if (count === 0) {
121
+ // do not generate types if no schema is found
122
+ return 0
123
+ }
124
+
125
+ const typesFolderPath = resolve(process.cwd(), config.types?.dir ?? 'types')
126
+
127
+ // Prepare the types folder
128
+ if (await isFileAccessible(typesFolderPath)) {
129
+ await removeUnusedTypeFiles(entities, typesFolderPath)
130
+ } else {
131
+ await createDirectory(typesFolderPath)
132
+ }
133
+
134
+ // Generate all entities
135
+ for (const [name, entity] of Object.entries(entities)) {
136
+ const types = await generateEntityType(entity)
137
+ const pathToFile = join(typesFolderPath, name + '.d.ts')
138
+
139
+ if (await writeFileIfChanged(pathToFile, types)) {
140
+ logger.info(`Generated type for ${entity.name} entity.`)
141
+ }
142
+ }
143
+
144
+ // Generate index.d.ts
145
+ const indexFilePath = join(typesFolderPath, 'index.d.ts')
146
+ const indexTypes = await generateIndexTypes(entities)
147
+ if (await writeFileIfChanged(indexFilePath, indexTypes)) {
148
+ logger.info('Regenerated index.d.ts.')
149
+ }
150
+
151
+ // Generate plt-env.d.ts
152
+ const environmentPath = join(process.cwd(), 'plt-env.d.ts')
153
+ const pltEnvironment = await generateEnvironmentTypes(relative(process.cwd(), typesFolderPath))
154
+ if (await writeFileIfChanged(environmentPath, pltEnvironment)) {
155
+ logger.info('Regenerated plt-env.d.ts.')
156
+ }
157
+
158
+ await db.dispose()
159
+ return count
160
+ }
package/lib/upgrade.js CHANGED
@@ -1,16 +1,12 @@
1
- 'use strict'
1
+ import { abstractLogger } from '@platformatic/foundation'
2
+ import zeroSixteen from '@platformatic/service/lib/versions/0.16.0.js'
3
+ import { join } from 'node:path'
4
+ import { loadMigrationsFromPath, semgrator } from 'semgrator'
2
5
 
3
- const { join } = require('path')
4
- const zeroSixteen = require('@platformatic/service/lib/versions/0.16.0.js')
6
+ export async function upgrade (logger, config, version) {
7
+ const iterator = loadMigrationsFromPath(join(import.meta.dirname, 'versions'))
5
8
 
6
- module.exports = async function upgrade (config, version) {
7
- const { semgrator, loadMigrationsFromPath } = await import('semgrator')
8
-
9
- const iterator = loadMigrationsFromPath(join(__dirname, 'versions'))
10
-
11
- const migrations = [
12
- zeroSixteen,
13
- ]
9
+ const migrations = [zeroSixteen]
14
10
 
15
11
  for await (const migration of iterator) {
16
12
  migrations.push(migration)
@@ -20,7 +16,7 @@ module.exports = async function upgrade (config, version) {
20
16
  version,
21
17
  migrations,
22
18
  input: config,
23
- logger: this.logger.child({ name: '@platformatic/db' }),
19
+ logger: logger?.child({ name: '@platformatic/db' }) ?? abstractLogger
24
20
  })
25
21
 
26
22
  let result
package/lib/utils.js CHANGED
@@ -1,45 +1,34 @@
1
- 'use strict'
1
+ import { connect } from '@platformatic/db-core'
2
+ import { kMetadata } from '@platformatic/foundation'
3
+ import fs from 'node:fs/promises'
4
+ import { dirname, join } from 'node:path'
5
+ import { fileURLToPath } from 'node:url'
2
6
 
3
- const { connect } = require('@platformatic/db-core')
4
- const { join, dirname } = require('path')
5
- const { fileURLToPath } = require('url')
6
- const fs = require('fs/promises')
7
- const { isFileAccessible } = require('@platformatic/utils')
8
-
9
- async function setupDB (log, config) {
7
+ export async function setupDB (log, config) {
10
8
  const { db, sql, entities, dbschema } = await connect({ ...config, log })
11
9
 
12
10
  return {
13
11
  db,
14
12
  sql,
15
13
  entities,
16
- dbschema,
14
+ dbschema
17
15
  }
18
16
  }
19
17
 
20
- function urlDirname (url) {
18
+ export function urlDirname (url) {
21
19
  return dirname(fileURLToPath(url))
22
20
  }
23
21
 
24
- function locateSchemaLock (configManager) {
25
- return configManager.current.db.schemalock.path ?? join(configManager.dirname, 'schema.lock')
22
+ export function locateSchemaLock (config) {
23
+ return config.db.schemalock.path ?? join(config[kMetadata].root, 'schema.lock')
26
24
  }
27
25
 
28
- async function updateSchemaLock (logger, configManager) {
29
- const config = configManager.current
26
+ export async function updateSchemaLock (logger, config) {
30
27
  if (config.db.schemalock) {
31
28
  const conn = await setupDB(logger, { ...config.db, dbschema: null })
32
- const schemaLockPath = locateSchemaLock(configManager)
29
+ const schemaLockPath = locateSchemaLock(config)
33
30
  await fs.writeFile(schemaLockPath, JSON.stringify(conn.dbschema, null, 2))
34
31
 
35
32
  await conn.db.dispose()
36
33
  }
37
34
  }
38
-
39
- module.exports = {
40
- setupDB,
41
- isFileAccessible,
42
- urlDirname,
43
- updateSchemaLock,
44
- locateSchemaLock,
45
- }
@@ -1,10 +1,8 @@
1
- 'use strict'
2
-
3
- module.exports = {
1
+ export default {
4
2
  version: '0.18.0',
5
- up: function (config) {
3
+ up (config) {
6
4
  config.db = config.core
7
5
  delete config.core
8
6
  return config
9
- },
7
+ }
10
8
  }
@@ -1,8 +1,6 @@
1
- 'use strict'
2
-
3
- module.exports.migration = {
1
+ export default {
4
2
  version: '0.28.0',
5
- up: function (config) {
3
+ up (config) {
6
4
  if (config.watch !== false) {
7
5
  config.watch = typeof config.watch === 'object' ? config.watch : {}
8
6
 
@@ -15,5 +13,5 @@ module.exports.migration = {
15
13
  delete config.db?.dashboard
16
14
 
17
15
  return config
18
- },
16
+ }
19
17
  }
@@ -1,11 +1,9 @@
1
- 'use strict'
1
+ import { version } from '../schema.js'
2
2
 
3
- const pkg = require('../../package.json')
4
-
5
- module.exports = {
3
+ export default {
6
4
  version: '2.0.0',
7
5
  up: function (config) {
8
- config.$schema = `https://schemas.platformatic.dev/@platformatic/db/${pkg.version}.json`
6
+ config.$schema = `https://schemas.platformatic.dev/@platformatic/db/${version}.json`
9
7
  return config
10
8
  }
11
9
  }
@@ -0,0 +1,14 @@
1
+ export default {
2
+ version: '2.99.0',
3
+ up (config) {
4
+ if (typeof config.plugins?.typescript !== 'undefined') {
5
+ delete config.plugins.typescript
6
+ }
7
+
8
+ if (typeof config.clients !== 'undefined') {
9
+ delete config.clients
10
+ }
11
+
12
+ return config
13
+ }
14
+ }
package/package.json CHANGED
@@ -1,12 +1,10 @@
1
1
  {
2
2
  "name": "@platformatic/db",
3
- "version": "2.74.3",
3
+ "version": "3.0.0-alpha.2",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "types": "index.d.ts",
7
- "bin": {
8
- "plt-db": "./db.mjs"
9
- },
7
+ "type": "module",
10
8
  "author": "Platformatic Inc. <oss@platformatic.dev> (https://platformatic.dev)",
11
9
  "repository": {
12
10
  "type": "git",
@@ -20,8 +18,7 @@
20
18
  "devDependencies": {
21
19
  "@databases/pg": "^5.5.0",
22
20
  "@databases/sql": "^3.3.0",
23
- "@opentelemetry/api": "^1.8.0",
24
- "@matteo.collina/snap": "^0.3.0",
21
+ "@opentelemetry/api": "^1.9.0",
25
22
  "ajv": "^8.12.0",
26
23
  "bindings": "^1.5.0",
27
24
  "borp": "^0.20.0",
@@ -33,7 +30,6 @@
33
30
  "neostandard": "^0.12.0",
34
31
  "openapi-types": "^12.1.3",
35
32
  "split2": "^4.2.0",
36
- "strip-ansi": "^7.1.0",
37
33
  "tsd": "^0.32.0",
38
34
  "typescript": "^5.5.4",
39
35
  "undici": "^7.0.0",
@@ -52,11 +48,8 @@
52
48
  "camelcase": "^6.3.0",
53
49
  "close-with-grace": "^2.0.0",
54
50
  "code-block-writer": "^13.0.1",
55
- "commist": "^3.2.0",
56
51
  "console-table-printer": "^2.12.0",
57
- "desm": "^1.3.1",
58
52
  "env-schema": "^6.0.0",
59
- "es-main": "^1.3.0",
60
53
  "execa": "^9.0.0",
61
54
  "fastify": "^5.0.0",
62
55
  "fastify-metrics": "^12.0.0",
@@ -67,31 +60,30 @@
67
60
  "minimist": "^1.2.8",
68
61
  "my-ua-parser": "^2.0.2",
69
62
  "ora": "^6.3.1",
70
- "pino": "^9.0.0",
63
+ "pino": "^9.9.0",
71
64
  "pino-pretty": "^13.0.0",
72
65
  "postgrator": "^8.0.0",
73
66
  "rfdc": "^1.3.1",
74
67
  "rimraf": "^4.4.1",
75
68
  "semgrator": "^0.3.0",
76
- "@platformatic/config": "2.74.3",
77
- "@platformatic/db-authorization": "2.74.3",
78
- "@platformatic/db-core": "2.74.3",
79
- "@platformatic/generators": "2.74.3",
80
- "@platformatic/service": "2.74.3",
81
- "@platformatic/sql-graphql": "2.74.3",
82
- "@platformatic/sql-json-schema-mapper": "2.74.3",
83
- "@platformatic/sql-mapper": "2.74.3",
84
- "@platformatic/sql-events": "2.74.3",
85
- "@platformatic/sql-openapi": "2.74.3",
86
- "@platformatic/telemetry": "2.74.3",
87
- "@platformatic/ts-compiler": "2.74.3",
88
- "@platformatic/utils": "2.74.3"
69
+ "@platformatic/db-authorization": "3.0.0-alpha.2",
70
+ "@platformatic/db-core": "3.0.0-alpha.2",
71
+ "@platformatic/generators": "3.0.0-alpha.2",
72
+ "@platformatic/sql-events": "3.0.0-alpha.2",
73
+ "@platformatic/sql-graphql": "3.0.0-alpha.2",
74
+ "@platformatic/service": "3.0.0-alpha.2",
75
+ "@platformatic/basic": "3.0.0-alpha.2",
76
+ "@platformatic/sql-mapper": "3.0.0-alpha.2",
77
+ "@platformatic/sql-openapi": "3.0.0-alpha.2",
78
+ "@platformatic/sql-json-schema-mapper": "3.0.0-alpha.2",
79
+ "@platformatic/telemetry": "3.0.0-alpha.2",
80
+ "@platformatic/foundation": "3.0.0-alpha.2"
81
+ },
82
+ "engines": {
83
+ "node": ">=22.18.0"
89
84
  },
90
85
  "scripts": {
91
- "test": "pnpm run lint && borp -T --concurrency=1 --timeout=1200000 && tsd ",
92
- "test:postgresql": "DB=postgresql borp -T --concurrency=1 --timeout=1200000",
93
- "test:mariadb": "DB=mariadb borp -T --concurrency=1 --timeout=1200000",
94
- "test:mysql": "DB=mysql borp -T --concurrency=1 --timeout=1200000",
86
+ "test": "pnpm run lint && borp -T --concurrency=1 --timeout 1200000",
95
87
  "gen-schema": "node lib/schema.js > schema.json",
96
88
  "gen-types": "json2ts > config.d.ts < schema.json",
97
89
  "build": "pnpm run gen-schema && pnpm run gen-types",