-
Notifications
You must be signed in to change notification settings - Fork 89
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Normalize read-model Store API. Add functional tests. (#1837)
- Loading branch information
Showing
95 changed files
with
4,634 additions
and
1,441 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
25 changes: 0 additions & 25 deletions
25
...ime/adapters/eventstore-adapters/eventstore-postgresql-serverless/src/resource/dispose.ts
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
43 changes: 43 additions & 0 deletions
43
packages/runtime/adapters/readmodel-adapters/readmodel-base/src/make-split-nested-path.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
import { MakeSplitNestedPathMethod, SplitNestedPathMethod } from './types' | ||
|
||
const makeSplitNestedPath: MakeSplitNestedPathMethod = (imports) => { | ||
const pathToolkit = new imports.PathToolkit() | ||
pathToolkit.setOptions({ | ||
cache: false, | ||
force: false, | ||
simple: false, | ||
defaultReturnVal: undefined, | ||
separators: { | ||
'.': { | ||
exec: 'property', | ||
}, | ||
}, | ||
prefixes: {}, | ||
containers: { | ||
"'": { | ||
closer: "'", | ||
exec: `${'single'}${'quote'}`, | ||
}, | ||
'"': { | ||
closer: '"', | ||
exec: `${'double'}${'quote'}`, | ||
}, | ||
}, | ||
}) | ||
|
||
const splitNestedPath: SplitNestedPathMethod = (input) => { | ||
if (input == null || input.constructor !== String) { | ||
throw new Error(`Invalid json path ${input}: must be string`) | ||
} | ||
const output = pathToolkit.getTokens(input) | ||
if (output == null) { | ||
throw new Error(`Invalid json path ${input}: parse failed`) | ||
} | ||
|
||
return output.t | ||
} | ||
|
||
return splitNestedPath | ||
} | ||
|
||
export default makeSplitNestedPath |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.