Commit 6c8b565
feat: introduce schemas (#1064)
* feat: introduce schemas
* feat: plug schema on writes (#1065)
* feat: plug schema on writes
* feat: Chart of accounts & tx validation (#1109)
* wip chart of account & serialization
* tx validation
* improve structure
* fix test
* more tests & fixes
* cleanup & improve coverage
* remove rules prototype
* force schemaVersion if ledger has one
* cleanup & better naming
* remove useless if, rename regex
* change segment prop prefix
* add missing test & cleanup leftover errors
* missed pre-commit
* address review suggestions
- used strings.HasPrefix to avoid potential panics
- group var definitions
- validate .pattern type & regex
- fix .self validation `{ }`
* improve error message for forbidden keys
* fix permissive regexes
* table-driven tests & t.Parallel
* fix api pattern examples
* review fixes
- Use log validation method instead of ad-hoc controller check
- Handle errors: non-specified schema, already-existing schema version, missing chart
- Add e2e unspecified schema check
* fix test
---------
Co-authored-by: Alix Bott <bott.alix@gmail.com>
* improve error messages (#1148)
* remove special handling of 'world' in charts
* feat: Chart of accounts: default metadata (#1164)
* default metadata on upsert account
* use global schemaVersion on bulks
* fix migrations
* fix missing units in schema otel histograms
* consistency: rename update->insert
* 400->409 for SchemaAlreadyExist
* tweak comment
* fix pagination test, add `previous` to v2schemacursor
* tweak test
* fix: read schema (#1180)
* improve naming consistency
* skip marshaling empty rules
* fix marshal
* pre-commit
* throw error on root .pattern + allow patternless variable segments
* throw error when account fields are used on non-accounts
* fix migration number
* fix
* schema enforcement mode
* address review comments
- pass schema to createTransaction
- schemaVersion in BulkingOptions
- use Store.newScopedSelect
- remove the errors.Unwraps
---------
Co-authored-by: Alix Bott <bott.alix@gmail.com>
Co-authored-by: David Ragot <35502263+Dav-14@users.noreply.github.com>1 parent 55d8b18 commit 6c8b565
File tree
129 files changed
+6938
-322
lines changed- cmd
- docs
- api
- events
- internal
- api
- bulking
- common
- v1
- v2
- bus
- controller
- ledger
- system
- storage
- bucket
- migrations/44-add-schema
- ledger
- openapi
- pkg
- client
- .speakeasy
- logs
- docs
- models
- components
- operations
- sdks/v2
- models
- components
- operations
- speakeasyusagegen/.speakeasy/logs
- events
- testserver
- test/e2e
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
129 files changed
+6938
-322
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
| 11 | + | |
| 12 | + | |
11 | 13 | | |
12 | 14 | | |
13 | 15 | | |
14 | | - | |
15 | | - | |
16 | | - | |
17 | | - | |
18 | | - | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
19 | 22 | | |
20 | 23 | | |
21 | 24 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
36 | 36 | | |
37 | 37 | | |
38 | 38 | | |
| 39 | + | |
39 | 40 | | |
40 | 41 | | |
41 | 42 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
68 | | - | |
69 | | - | |
70 | | - | |
71 | | - | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
72 | 73 | | |
73 | 74 | | |
74 | 75 | | |
| |||
112 | 113 | | |
113 | 114 | | |
114 | 115 | | |
115 | | - | |
| 116 | + | |
| 117 | + | |
116 | 118 | | |
117 | 119 | | |
118 | 120 | | |
| |||
187 | 189 | | |
188 | 190 | | |
189 | 191 | | |
| 192 | + | |
190 | 193 | | |
191 | 194 | | |
192 | 195 | | |
| |||
0 commit comments