Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Use callbacks for evaluation hotpath. #234

Merged
merged 24 commits into from
Aug 21, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
62f7b42
feat: Do not use async for evaluation hotpath.
kinyoklion Aug 10, 2023
bdebdff
feat: Switch to es2017 target to ensure native async/await.
kinyoklion Aug 10, 2023
fca0b27
Remove pre-release versions.
kinyoklion Aug 10, 2023
d6686ba
Merge branch 'rlamb/switch-to-es2017' into rlamb/performance-experime…
kinyoklion Aug 10, 2023
83b7ede
Bug fixes.
kinyoklion Aug 10, 2023
4055933
Basic functionality working with eval callbacks.
kinyoklion Aug 10, 2023
96878e3
Async data access.
kinyoklion Aug 10, 2023
33a982f
Conversion mostly complete.
kinyoklion Aug 10, 2023
c336712
Debugging
kinyoklion Aug 11, 2023
7d98812
Change recursion limit.
kinyoklion Aug 11, 2023
8b54759
Merge branch 'main' into rlamb/performance-experimentation
kinyoklion Aug 11, 2023
33617dc
Remove test from debugging.
kinyoklion Aug 11, 2023
26d0ede
Cleanup.
kinyoklion Aug 11, 2023
17ff57a
Remove async from methods that return a promise directly.
kinyoklion Aug 11, 2023
19ad6b9
Style changes.
kinyoklion Aug 11, 2023
204de93
Fix callback name.
kinyoklion Aug 11, 2023
7a3ef53
Add documentation about callbacks.
kinyoklion Aug 11, 2023
31e4cda
Better iterator callback name.
kinyoklion Aug 11, 2023
6908265
Do not use a class for Match/MatchError
kinyoklion Aug 14, 2023
8a15e15
Evaluate all flags concurrently.
kinyoklion Aug 14, 2023
3bca8a5
Merge branch 'main' into rlamb/performance-experimentation
kinyoklion Aug 14, 2023
9bba8dc
Merge branch 'main' into rlamb/performance-experimentation
kinyoklion Aug 15, 2023
19c8a89
Remove double allFlags
kinyoklion Aug 18, 2023
462d63c
Merge branch 'main' into rlamb/performance-experimentation
kinyoklion Aug 21, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -34,12 +34,14 @@ class TestQueries implements Queries {
},
) {}

async getFlag(key: string): Promise<Flag | undefined> {
return this.data.flags?.find((flag) => flag.key === key);
getFlag(key: string, cb: (flag: Flag | undefined) => void): void {
const res = this.data.flags?.find((flag) => flag.key === key);
cb(res);
}

async getSegment(key: string): Promise<Segment | undefined> {
return this.data.segments?.find((segment) => segment.key === key);
getSegment(key: string, cb: (segment: Segment | undefined) => void): void {
const res = this.data.segments?.find((segment) => segment.key === key);
cb(res);
}

getBigSegmentsMembership(
Expand Down
Loading