retold-data-service 2.1.1 → 2.1.5
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/BUILDING-AND-PUBLISHING.md +2 -2
- package/Dockerfile +1 -1
- package/README.md +12 -27
- package/build-all.js +66 -0
- package/diagrams/architecture.excalidraw +2966 -0
- package/diagrams/architecture.mmd +17 -0
- package/diagrams/architecture.svg +2 -0
- package/docs/README.md +12 -12
- package/docs/_brand.json +18 -0
- package/docs/_cover.md +1 -1
- package/docs/_topbar.md +1 -1
- package/docs/_version.json +3 -3
- package/docs/api/reference.md +8 -8
- package/docs/architecture.md +6 -84
- package/docs/diagrams/component-diagram.excalidraw +2807 -0
- package/docs/diagrams/component-diagram.mmd +14 -0
- package/docs/diagrams/component-diagram.svg +2 -0
- package/docs/diagrams/component-stack.excalidraw +1169 -0
- package/docs/diagrams/component-stack.mmd +6 -0
- package/docs/diagrams/component-stack.svg +2 -0
- package/docs/diagrams/hook-execution-order.excalidraw +3230 -0
- package/docs/diagrams/hook-execution-order.mmd +19 -0
- package/docs/diagrams/hook-execution-order.svg +2 -0
- package/docs/diagrams/initialization-flow.excalidraw +1800 -0
- package/docs/diagrams/initialization-flow.mmd +22 -0
- package/docs/diagrams/initialization-flow.svg +2 -0
- package/docs/index.html +6 -7
- package/docs/lifecycle-hooks.md +2 -21
- package/docs/retold-catalog.json +141 -141
- package/docs/retold-keyword-index.json +6818 -1608
- package/package.json +130 -96
- package/source/services/RetoldDataService-Brand.js +13 -0
- package/source/services/comprehension-loader/pict-app/Pict-Application-ComprehensionLoader.js +65 -15
- package/source/services/comprehension-loader/pict-app/providers/Pict-Provider-ComprehensionLoader.js +2 -2
- package/source/services/comprehension-loader/pict-app/views/PictView-ComprehensionLoader-Layout.js +68 -114
- package/source/services/comprehension-loader/pict-app/views/PictView-ComprehensionLoader-Load.js +29 -29
- package/source/services/comprehension-loader/pict-app/views/PictView-ComprehensionLoader-Schema.js +3 -3
- package/source/services/comprehension-loader/pict-app/views/PictView-ComprehensionLoader-Session.js +2 -2
- package/source/services/comprehension-loader/pict-app/views/PictView-ComprehensionLoader-SettingsPanel.js +62 -0
- package/source/services/comprehension-loader/pict-app/views/PictView-ComprehensionLoader-Shell.js +142 -0
- package/source/services/comprehension-loader/pict-app/views/PictView-ComprehensionLoader-Source.js +7 -7
- package/source/services/comprehension-loader/pict-app/views/PictView-ComprehensionLoader-StatusBar.js +125 -0
- package/source/services/comprehension-loader/pict-app/views/PictView-ComprehensionLoader-StatusDetail.js +89 -0
- package/source/services/comprehension-loader/pict-app/views/PictView-ComprehensionLoader-TopBar-Nav.js +42 -0
- package/source/services/comprehension-loader/pict-app/views/PictView-ComprehensionLoader-TopBar-User.js +48 -0
- package/source/services/comprehension-loader/web/comprehension-loader.js +5475 -6243
- package/source/services/comprehension-loader/web/comprehension-loader.js.map +1 -1
- package/source/services/comprehension-loader/web/comprehension-loader.min.js +75 -1
- package/source/services/comprehension-loader/web/comprehension-loader.min.js.map +1 -1
- package/source/services/comprehension-loader/web/favicons/favicon-dark.svg +13 -0
- package/source/services/comprehension-loader/web/favicons/favicon-light.svg +13 -0
- package/source/services/comprehension-loader/web/favicons/favicon.svg +13 -0
- package/source/services/comprehension-loader/web/index.html +3 -0
- package/source/services/comprehension-loader/web/pict.min.js +12 -0
- package/source/services/data-cloner/DataCloner-Command-Headless.js +2 -1
- package/source/services/data-cloner/DataCloner-Command-Sync.js +110 -75
- package/source/services/data-cloner/pict-app/Pict-Application-DataCloner.js +70 -47
- package/source/services/data-cloner/pict-app/providers/Pict-Provider-DataCloner.js +3 -3
- package/source/services/data-cloner/pict-app/views/PictView-DataCloner-Connection.js +1 -1
- package/source/services/data-cloner/pict-app/views/PictView-DataCloner-Deploy.js +5 -5
- package/source/services/data-cloner/pict-app/views/PictView-DataCloner-Export.js +11 -11
- package/source/services/data-cloner/pict-app/views/PictView-DataCloner-Layout.js +89 -135
- package/source/services/data-cloner/pict-app/views/PictView-DataCloner-Schema.js +3 -3
- package/source/services/data-cloner/pict-app/views/PictView-DataCloner-Session.js +2 -2
- package/source/services/data-cloner/pict-app/views/PictView-DataCloner-SettingsPanel.js +61 -0
- package/source/services/data-cloner/pict-app/views/PictView-DataCloner-Shell.js +136 -0
- package/source/services/data-cloner/pict-app/views/PictView-DataCloner-StatusBar.js +117 -0
- package/source/services/data-cloner/pict-app/views/PictView-DataCloner-StatusDetail.js +81 -0
- package/source/services/data-cloner/pict-app/views/PictView-DataCloner-Sync.js +38 -38
- package/source/services/data-cloner/pict-app/views/PictView-DataCloner-TopBar-Nav.js +42 -0
- package/source/services/data-cloner/pict-app/views/PictView-DataCloner-TopBar-User.js +48 -0
- package/source/services/data-cloner/pict-app/views/PictView-DataCloner-ViewData.js +5 -5
- package/source/services/data-cloner/web/data-cloner.js +5855 -8067
- package/source/services/data-cloner/web/data-cloner.js.map +1 -1
- package/source/services/data-cloner/web/data-cloner.min.js +75 -1
- package/source/services/data-cloner/web/data-cloner.min.js.map +1 -1
- package/source/services/data-cloner/web/favicons/favicon-dark.svg +13 -0
- package/source/services/data-cloner/web/favicons/favicon-light.svg +13 -0
- package/source/services/data-cloner/web/favicons/favicon.svg +13 -0
- package/source/services/data-cloner/web/favicons/favicons/favicon-dark.svg +13 -0
- package/source/services/data-cloner/web/favicons/favicons/favicon-light.svg +13 -0
- package/source/services/data-cloner/web/favicons/favicons/favicon.svg +13 -0
- package/source/services/data-cloner/web/index.html +3 -0
- package/source/services/data-cloner/web/pict.min.js +12 -0
- package/test/Bundles_smoke_tests.js +43 -0
- package/test/ComprehensionLoader_smoke_tests.js +95 -0
- package/test/DataCloner-RuntimeOverrides_tests.js +344 -0
- package/test/DataCloner_smoke_tests.js +87 -0
- package/docs/css/docuserve.css +0 -327
|
@@ -29,7 +29,7 @@ dependencies, env-var contract, or the Dockerfile changed.
|
|
|
29
29
|
|
|
30
30
|
- **npm login** — `npm whoami` should print your username.
|
|
31
31
|
- **Git remote configured** — `git remote get-url origin` should print
|
|
32
|
-
`git@github.com:
|
|
32
|
+
`git@github.com:fable-retold/retold-data-service.git` (or the
|
|
33
33
|
HTTPS equivalent).
|
|
34
34
|
- **Push access to the repo** — required so `postversion` /
|
|
35
35
|
`postpublish` hooks can push commits and tags.
|
|
@@ -118,7 +118,7 @@ BUILD_DOCKER=1 npm publish (or: npm run publish:docker)
|
|
|
118
118
|
## Verifying a release
|
|
119
119
|
|
|
120
120
|
1. **npm**: `npm view retold-data-service version`
|
|
121
|
-
2. **Workflow**: `https://github.com/
|
|
121
|
+
2. **Workflow**: `https://github.com/fable-retold/retold-data-service/actions`
|
|
122
122
|
3. **Image**: `docker pull ghcr.io/stevenvelozo/retold-data-service:latest`
|
|
123
123
|
|
|
124
124
|
If the first `docker pull` returns `denied`, the package is private by
|
package/Dockerfile
CHANGED
package/README.md
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
# Retold Data Service
|
|
2
2
|
|
|
3
|
-
[
|
|
3
|
+
> **[Read the Retold-Data-Service Documentation](https://fable-retold.github.io/retold-data-service/)** - interactive docs with the full API reference.
|
|
4
|
+
|
|
5
|
+
[MIT License](LICENSE)
|
|
4
6
|
|
|
5
7
|
> An all-in-one Fable service that turns a compiled Stricture schema into a complete REST API
|
|
6
8
|
|
|
@@ -70,25 +72,8 @@ _Fable.RetoldDataService.initializeService(
|
|
|
70
72
|
|
|
71
73
|
Retold Data Service orchestrates the full Meadow stack into a single initialization sequence:
|
|
72
74
|
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
└── Retold Data Service
|
|
76
|
-
├── Orator (API Server)
|
|
77
|
-
│ └── Restify (HTTP Engine)
|
|
78
|
-
├── Meadow (Data Access Layer)
|
|
79
|
-
│ ├── Schema (from compiled Stricture model)
|
|
80
|
-
│ ├── FoxHound (Query DSL)
|
|
81
|
-
│ └── Provider (MySQL / MSSQL / PostgreSQL / SQLite / MongoDB / etc.)
|
|
82
|
-
└── Meadow Endpoints (REST Routes)
|
|
83
|
-
├── Create POST /1.0/Entity
|
|
84
|
-
├── Read GET /1.0/Entity/:ID
|
|
85
|
-
├── Reads GET /1.0/Entities/:Begin/:Cap
|
|
86
|
-
├── Update PUT /1.0/Entity
|
|
87
|
-
├── Delete DELETE /1.0/Entity/:ID
|
|
88
|
-
├── Count GET /1.0/Entities/Count
|
|
89
|
-
├── Schema GET /1.0/Entity/Schema
|
|
90
|
-
└── New GET /1.0/Entity/Schema/New
|
|
91
|
-
```
|
|
75
|
+
<!-- bespoke diagram: edit diagrams/architecture.mmd or .hints.json, then: npx pict-renderer-graph build modules/meadow/retold-data-service -->
|
|
76
|
+

|
|
92
77
|
|
|
93
78
|
## Options
|
|
94
79
|
|
|
@@ -226,13 +211,13 @@ npx docsify-cli serve docs
|
|
|
226
211
|
|
|
227
212
|
## Related Packages
|
|
228
213
|
|
|
229
|
-
- [meadow](https://github.com/
|
|
230
|
-
- [meadow-endpoints](https://github.com/
|
|
231
|
-
- [foxhound](https://github.com/
|
|
232
|
-
- [stricture](https://github.com/
|
|
233
|
-
- [orator](https://github.com/
|
|
234
|
-
- [fable](https://github.com/
|
|
235
|
-
- [retold-harness](https://github.com/
|
|
214
|
+
- [meadow](https://github.com/fable-retold/meadow) -- data access and ORM
|
|
215
|
+
- [meadow-endpoints](https://github.com/fable-retold/meadow-endpoints) -- auto-generated REST endpoints
|
|
216
|
+
- [foxhound](https://github.com/fable-retold/foxhound) -- query DSL for SQL generation
|
|
217
|
+
- [stricture](https://github.com/fable-retold/stricture) -- schema definition DDL compiler
|
|
218
|
+
- [orator](https://github.com/fable-retold/orator) -- API server abstraction
|
|
219
|
+
- [fable](https://github.com/fable-retold/fable) -- application services framework
|
|
220
|
+
- [retold-harness](https://github.com/fable-retold/retold-harness) -- application harness using this service
|
|
236
221
|
|
|
237
222
|
## License
|
|
238
223
|
|
package/build-all.js
ADDED
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
/**
|
|
3
|
+
* Build every web app in this package.
|
|
4
|
+
*
|
|
5
|
+
* Quackage reads `.quackage.json` from CWD with no `--config` flag, so to
|
|
6
|
+
* build the two apps we swap that file between runs. The original
|
|
7
|
+
* `.quackage.json` is restored even if a build fails.
|
|
8
|
+
*
|
|
9
|
+
* Apps are listed in `_Apps` — add a row for each new web app:
|
|
10
|
+
* { Name: <label>, Config: <relative-path-to-its-quackage-config-file> }
|
|
11
|
+
*
|
|
12
|
+
* The primary config (`.quackage.json`) acts as the default state — the
|
|
13
|
+
* runner restores it from a backup taken at start.
|
|
14
|
+
*/
|
|
15
|
+
'use strict';
|
|
16
|
+
|
|
17
|
+
const libFS = require('fs');
|
|
18
|
+
const libChild = require('child_process');
|
|
19
|
+
|
|
20
|
+
const _PrimaryConfig = '.quackage.json';
|
|
21
|
+
const _Apps =
|
|
22
|
+
[
|
|
23
|
+
{ Name: 'data-cloner', Config: '.quackage.json' },
|
|
24
|
+
{ Name: 'comprehension-loader', Config: '.quackage-comprehension-loader.json' }
|
|
25
|
+
];
|
|
26
|
+
|
|
27
|
+
let tmpBackup = null;
|
|
28
|
+
let tmpExitCode = 0;
|
|
29
|
+
|
|
30
|
+
try
|
|
31
|
+
{
|
|
32
|
+
tmpBackup = libFS.readFileSync(_PrimaryConfig, 'utf8');
|
|
33
|
+
|
|
34
|
+
for (let i = 0; i < _Apps.length; i++)
|
|
35
|
+
{
|
|
36
|
+
let tmpApp = _Apps[i];
|
|
37
|
+
if (tmpApp.Config !== _PrimaryConfig)
|
|
38
|
+
{
|
|
39
|
+
libFS.writeFileSync(_PrimaryConfig, libFS.readFileSync(tmpApp.Config, 'utf8'));
|
|
40
|
+
}
|
|
41
|
+
else
|
|
42
|
+
{
|
|
43
|
+
libFS.writeFileSync(_PrimaryConfig, tmpBackup);
|
|
44
|
+
}
|
|
45
|
+
console.log('\n=== Building ' + tmpApp.Name + ' (config: ' + tmpApp.Config + ') ===\n');
|
|
46
|
+
libChild.execSync('npx quack build', { stdio: 'inherit' });
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
catch (pError)
|
|
50
|
+
{
|
|
51
|
+
console.error('\nbuild-all: build failed — ' + pError.message);
|
|
52
|
+
tmpExitCode = 1;
|
|
53
|
+
}
|
|
54
|
+
finally
|
|
55
|
+
{
|
|
56
|
+
if (tmpBackup !== null)
|
|
57
|
+
{
|
|
58
|
+
libFS.writeFileSync(_PrimaryConfig, tmpBackup);
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
if (tmpExitCode === 0)
|
|
63
|
+
{
|
|
64
|
+
console.log('\nAll bundles built.');
|
|
65
|
+
}
|
|
66
|
+
process.exit(tmpExitCode);
|