Skip to content

Mark collectGarbage idempotent #2267

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

Merged
merged 1 commit into from
Oct 15, 2019

Conversation

schmidt-sebastian
Copy link
Contributor

I looked through all the code that is called from collectGarbage() (and there is a lot), but it seems like there is no in-memory state that is modified during garbage collection. It seems safe to be re-run.

FWIW, we could also blindly swallow all errors that collectGarbage() might throw, but then we would likely never receive feedback about any LRU problems.

@schmidt-sebastian schmidt-sebastian changed the base branch from mrschmidt/idempotent to mrschmidt/applyremoteevent October 11, 2019 23:01
Copy link
Contributor

@wilhuff wilhuff left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@wilhuff wilhuff assigned schmidt-sebastian and unassigned wilhuff Oct 15, 2019
@schmidt-sebastian schmidt-sebastian changed the base branch from mrschmidt/applyremoteevent to mrschmidt/idempotent October 15, 2019 16:37
@schmidt-sebastian schmidt-sebastian merged commit 83ccb76 into mrschmidt/idempotent Oct 15, 2019
hsubox76 pushed a commit that referenced this pull request Oct 15, 2019
* Add transaction retries (#2250)

* Marking SimpleDb calls as idempotent (#2251)

* Mark mostly readonly calls as idempotent (#2252)

* Fix test failure (#2256)

* Make handleUserChange idempotent (#2257)

* Temporarily disable CountingQueryEngine tests (#2258)

*  Improve test hack (#2259)

* Improve test hack

* Comment in test hack

* Make getNewDocumentChanges() idempotent (#2255)

* Add onCommitted listeners for transactions (#2265)

* Fix build

* Fix Lint

* Make applyRemoteEvent idempotent (#2263)

* Make notifyLocalViewChanges idempotent (#2268)

* Make releaseQuery idempotent (#2266)

* Mark acknowledgeBatch and rejectBatch idempotent (#2269)

* idempotent `allocateQuery` and `notifyLocalViewChanges` (#2264)

* Mark collectGarbage idempotent (#2267)

* Idempotency: Address TODOs, add Changelog (#2270)
@schmidt-sebastian schmidt-sebastian deleted the mrschmidt/collectgarbage branch October 15, 2019 22:24
@firebase firebase locked and limited conversation to collaborators Nov 15, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants