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(reducers): cache reducer for increased performance - @puppybits #335

Merged
merged 148 commits into from
Nov 23, 2021
Merged
Show file tree
Hide file tree
Changes from 99 commits
Commits
Show all changes
148 commits
Select commit Hold shift + click to select a range
f4b0910
chore(cache-reducer): include id & parent path as prep work
Feb 15, 2021
1a16fa6
chore(cache-reducer): include id & parent path as prep work
puppybits Feb 26, 2021
48838e2
feat(firebase-actions): optionally support includeMetadataChanges
Feb 15, 2021
38373f5
feat(cache-reducer): added new reducer for instant mutation changes
Feb 15, 2021
b99dbc0
docs: added rfc to immediate mode mutations
Feb 26, 2021
b3cdc2e
docs: update rfc
Feb 26, 2021
4773fbf
feat(cacheReducer): enabled immediate mode w/ new cache reducer
puppybits Mar 1, 2021
eb96c89
doc(immediate_mode): updated mutation rfc
puppybits Mar 1, 2021
2cd6f0f
chore(validation): added global data convertor
Mar 14, 2021
a134c69
Merge branch 'master' into feature/immediate-mode-mutate
Mar 14, 2021
ccdc39b
chore(immediate-mode): added spec to README doc
Mar 14, 2021
b66b89c
wip(immediate-mutates): stubbed mutate test
Mar 14, 2021
a9dfe85
wip(immediate-mutates): supported solo mutates
Mar 14, 2021
95ce6aa
feat(immediate-mutates): supported batches
Mar 14, 2021
0127bc9
feat(immediate-mutate): support mutate transactions
Mar 14, 2021
70fb110
chore(immediate-mutates): clean up doc & code
Mar 14, 2021
941fbd0
chore(immediate-mutates): clean up doc & code
Mar 14, 2021
401381b
Merge branch 'feature/immediate-mode-mutate' of github.com:TARAAI/red…
Mar 14, 2021
9e9ad27
chore: updates
Mar 14, 2021
83f7f0a
chore(immediate-mutate): updated write format to support `data` field
Mar 16, 2021
5290a2b
chore: updates
Mar 16, 2021
69f77be
Merge pull request #5 from TARAAI/feature/immediate-mode-mutate
Mar 16, 2021
e6ef8a0
chore: included kacper's code
Mar 17, 2021
6d0127f
feat(immediate-mode): populate support for array of ids
Mar 24, 2021
4a59e93
feat(immediate-mode): support nested & __name__ queries
Mar 28, 2021
b097122
chore(immediate-mode): failures remove, updates remove when contains …
Mar 28, 2021
7791e82
chore(immediate-mode): added types
Mar 29, 2021
26f25e7
docs(immediate-mode): cleaned up API doc to match API
Mar 29, 2021
7e67b90
chore: updates
Mar 29, 2021
be0ecf6
fix(mutate): added id & path to transaction.get calls
Apr 1, 2021
e3843f0
chore: added performance marks
Apr 2, 2021
9cc0236
feat(immedate-mode): 16x performance boost on populates w/ 3 lookups
puppybits Apr 11, 2021
fc21ce0
Merge pull request #7 from prescottprue/master
Apr 11, 2021
79903df
chore: upped code coverage to 90%
puppybits Apr 14, 2021
df9e9b7
chore: added where compare tests
puppybits Apr 14, 2021
6cf773a
chore: tests on where compares
puppybits Apr 14, 2021
1dd7b76
chore: remove impossible branch
puppybits Apr 14, 2021
8ab3b5d
chore: readded support for nested populates
puppybits Apr 14, 2021
6d8282a
fix: support Timestamp values in a mutate
puppybits Apr 15, 2021
ff85d1a
fix(cache): removed overrides from cache.database
puppybits Apr 17, 2021
f53695d
feat(debug): added DEBUG=rrf:* for cache + mutate
puppybits Apr 17, 2021
c0fbc2d
chore: updated minification to terser
puppybits Apr 17, 2021
7ace172
chore: updated all libs (except mocha)
puppybits Apr 17, 2021
b9228fd
fix: switched perpare to postinstall to fix issues in CI
puppybits Apr 18, 2021
3025a1f
chore: profiling is a noop in prod
puppybits Apr 19, 2021
f2579dd
chore: webpack fix
puppybits Apr 19, 2021
4c22e30
fix: bad check when query doesn’t return
puppybits Apr 19, 2021
c6a511a
fix: transaction write debug fix
puppybits Apr 20, 2021
aebb89a
fix: immer object issue
puppybits Apr 20, 2021
a09d5be
fix: null fix
puppybits Apr 20, 2021
973b34c
fix: null fix
puppybits Apr 20, 2021
1cdf5a9
chore: added stats to profiling
Apr 21, 2021
0bc00b1
fix(immediate-mode): ordered not getting saved on reprocessing
Apr 26, 2021
a0639de
fix(immediate-mode): only remove docs if still in the list
Apr 27, 2021
8d3c159
fix: nested fields only supported w/ firestore.update
Apr 27, 2021
6338152
fix: removed dupe sometimes from an add_doc action
Apr 28, 2021
3689930
fix: minor tweak
Apr 28, 2021
a926141
feat(profiling): added firestore load measurements
Apr 29, 2021
567ba32
Merge branch 'master' of github.com:TARAAI/redux-firestore
Apr 29, 2021
eae16f4
wip: pre-value inspection on override removals
Apr 30, 2021
8c07fa9
feat(immediate-mode): added pre-property reconciliation
Apr 30, 2021
b91c7fe
chore: PR changes
Apr 30, 2021
bbee4ef
fix: profile fix
Apr 30, 2021
59f663d
fix: reprocessing where clause failed on undefined values
Apr 30, 2021
ae24022
chore: update
puppybits May 1, 2021
6893ede
chore: update
puppybits May 1, 2021
47b1e0b
chore: added testing for per-property optimitic removal
puppybits May 1, 2021
4377ca2
chore: removed debugs for a separate PR
puppybits May 1, 2021
3e4c480
feat: support arrays for arrayUnions/arrayRemove
puppybits May 19, 2021
c2b2f1b
chore: requested changes
puppybits May 19, 2021
11fc158
feat: support arrayUnion/Remove single values and arrays
May 19, 2021
2d8de81
revert: removed debugs for a separate PR
puppybits May 19, 2021
fe6299a
feat: add optimistic reads
puppybits May 20, 2021
ad976a6
fix: mirror Firestore’s orderBy
puppybits May 20, 2021
bf12e4d
chore: test update
puppybits May 20, 2021
18175b3
fix: bug fix
puppybits May 20, 2021
86da9e1
feat: optimistic reads
May 21, 2021
51497fa
feat: return undeinfed initial read when in-memory db empty
puppybits May 25, 2021
a120da6
fix: proper boolean check
puppybits May 25, 2021
5a356a5
fix: bug with ‘in’ queries
puppybits May 26, 2021
b8087f5
fix: fromCache
puppybits May 26, 2021
f56439b
chore: fromCache change
puppybits May 26, 2021
4b1a27f
feat: returns undefined on initial read when in-memory db is empty
May 26, 2021
53e8126
docs: added docs for cache and mutate
puppybits May 28, 2021
e3fc24f
Merge pull request #12 from TARAAI/u/bs/docs
Jun 3, 2021
34cbc25
fix: corrected query limit
puppybits Jun 9, 2021
f274188
perf: on multiple changes, batch reprocessing at the end
puppybits Jun 9, 2021
5bcfa32
chore: Update src/reducers/cacheReducer.js
Jun 9, 2021
1782a3b
Merge pull request #13 from TARAAI/u/bs/limit-fix
Jun 9, 2021
9ccfc13
perf: on multiple changes, batch reprocessing at the end
Jun 11, 2021
cb39c43
fix: in operator in query processes map
lukeKonopka Jun 15, 2021
88971d8
Merge pull request #15 from TARAAI/fix-in-operator-in-query-processes
syedahmedz Jun 16, 2021
f1bfe67
Preserve data on UNSET_LISTENER
fatfisz Jun 28, 2021
a27cdef
Fix a typo
fatfisz Jun 28, 2021
6066ea1
Update tests
fatfisz Jun 28, 2021
8cbec2b
Run lint:fix to prevent extra changes when saving
fatfisz Jun 30, 2021
d030e08
Move pathListenerCounts to firebase internal config
fatfisz Jun 30, 2021
d0c275e
Add an option to preserve cache on unset
fatfisz Jun 30, 2021
d188673
feat: Preserve data on UNSET_LISTENER
Jun 30, 2021
412f371
Implement PROCESSES_TIMESTAMP
comlaterra Jul 14, 2021
70e0d88
lint
comlaterra Jul 14, 2021
a9b0a87
feat: support where clauses with timestamp values
Jul 14, 2021
002b4c2
wip: initial working/checked code for pagination
puppybits Jul 14, 2021
0584061
chore: clean up
puppybits Jul 15, 2021
63ce98b
feat: add mutate read provider
puppybits Jul 15, 2021
7e0769b
chore: test for mutate provider
puppybits Jul 15, 2021
101d63b
chore: tests for pagination
puppybits Jul 15, 2021
fc54554
chore: review updates
puppybits Jul 16, 2021
41ce436
chore: update
puppybits Jul 16, 2021
aae83e7
feat: pagination support #20
Jul 16, 2021
43d2b16
chore: packages update, excluded IE (1.5% globally) to reduce .min file
puppybits Jul 16, 2021
86c08bc
chore: fixed regeneratorRuntime
puppybits Jul 16, 2021
582063a
chore: bump
puppybits Jul 16, 2021
0929ab2
chore: added mock mutate for testing
puppybits Jul 27, 2021
7743615
feat: allow error handling in mutate writes
puppybits Jul 27, 2021
74a1306
fix: fixed provider support in cache reducer
Jul 28, 2021
b7526cc
chore: clean up
puppybits Jul 29, 2021
f1b9621
chore: deleted populates
puppybits Aug 2, 2021
854b135
chore: switched .docs to .ordered + .database
puppybits Aug 2, 2021
0d3c4ee
chore: deleted fields
puppybits Aug 2, 2021
d59e325
wip: rewrote processor
puppybits Aug 3, 2021
f2f950d
chore: large test
puppybits Aug 3, 2021
7163f52
perf: delete cross/data/ordered/queries reducers
puppybits Aug 3, 2021
797bf04
fix: query overwrites id/path with firestore vals
puppybits Aug 3, 2021
ce9dafa
chore: add benchmark tests
puppybits Aug 4, 2021
bc37d03
chore: clean up
puppybits Aug 4, 2021
3110c08
fix: no optimisticReads now returns undefined
puppybits Aug 4, 2021
fdbe348
fix: pagination only applies in optimisticRead
puppybits Aug 4, 2021
348d0a4
feat: added via: optimistic state
puppybits Aug 4, 2021
3e597b3
chore: ensure debug disabled on production
puppybits Aug 4, 2021
96664b5
Merge branch 'master' into u/bs/mutate-write-error-handling
puppybits Aug 5, 2021
fdcdf5a
chore: v++
puppybits Aug 5, 2021
0fe8db7
perf: fast redux & mutate write error handling
Aug 5, 2021
38bf0a5
chore: version bump
puppybits Aug 5, 2021
932959b
chore: set performance bar
puppybits Aug 5, 2021
1b93810
fix: mutate reads
puppybits Aug 9, 2021
89a7036
fix: pagination aligned with firestore results
puppybits Aug 10, 2021
c711ac7
chore: bump version
puppybits Aug 10, 2021
30c3b43
chore: update test
puppybits Aug 10, 2021
b4f52d9
fix: pagination and optimistic write creation (#22)
Aug 10, 2021
ea17e97
fix: pagination update
puppybits Aug 19, 2021
8d74020
fix: run pagination in optimistic writes (#23)
Aug 19, 2021
0aa4c16
chore: deps++
puppybits Nov 17, 2021
79b54ac
chore: deps++
Nov 17, 2021
7f24eff
fix: missed support for path & id
puppybits Nov 19, 2021
d0d52b3
fix: added check for no query results
puppybits Nov 19, 2021
619cba3
fix: write functions can each return an array of writes
puppybits Nov 19, 2021
6a239bb
Revert "chore: deps++"
puppybits Nov 19, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
71 changes: 33 additions & 38 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,41 +1,36 @@
module.exports = {
root: true,
parser: 'babel-eslint',
'extends': [
'airbnb-base',
'google',
'prettier',
'plugin:jsdoc/recommended'
],
plugins: [
'babel',
'prettier',
'jsdoc'
],
env: {
browser: true,
es6: true,
node: true
},
settings: {
root: true,
parser: 'babel-eslint',
extends: ['airbnb-base', 'google', 'prettier', 'plugin:jsdoc/recommended'],
plugins: ['babel', 'prettier', 'jsdoc'],
env: {
browser: true,
es6: true,
node: true,
},
settings: {
'import/resolver': {
node: {
moduleDirectory: ['node_modules', '/']
}
}
},
rules: {
'prettier/prettier': ['error', {
'singleQuote': true,
'trailingComma': 'all'
}],
'no-console': 'error',
'valid-jsdoc': 0, // from google
'no-confusing-arrow': 0,
'no-case-declarations': 0,
'arrow-parens': [2, 'as-needed'],
'prefer-default-export': 0,
'jsdoc/newline-after-description': 0,
'jsdoc/no-undefined-types': [1, { definedTypes: ['firebase'] }]
}
}
moduleDirectory: ['node_modules', '/'],
},
},
},
rules: {
'prettier/prettier': [
'error',
{
singleQuote: true,
trailingComma: 'all',
},
],
'no-console': 'error',
'valid-jsdoc': 0, // from google
'no-confusing-arrow': 0,
'no-case-declarations': 0,
'no-param-reassign': [2, { props: false }],
'arrow-parens': 0, // handled by Prettier
'prefer-default-export': 0,
'jsdoc/newline-after-description': 0,
'jsdoc/no-undefined-types': [1, { definedTypes: ['firebase'] }],
},
};