redis-oplog icon indicating copy to clipboard operation
redis-oplog copied to clipboard

Inserts with callbacks are not actually async

Open leonardoventurini opened this issue 8 months ago • 1 comments

When passing a callback to an insert the insert actually happens synchronously in the wrap and then the callback is is run asynchronously, which we think misses the point of running the actual insert async.

https://github.com/cult-of-coders/redis-oplog/blob/1daf81232ac1ef2483b3ff1808374937e3c70a3e/lib/mongo/Mutator.js#L72

Perhaps it should run all the rest of logic asynchronously when the callback is present (wrapping the callback).

leonardoventurini avatar Oct 09 '23 16:10 leonardoventurini

Thank you for submitting this issue!

We, the Members of Meteor Community Packages take every issue seriously. Our goal is to provide long-term lifecycles for packages and keep up with the newest changes in Meteor and the overall NodeJs/JavaScript ecosystem.

However, we contribute to these packages mostly in our free time. Therefore, we can't guarantee you issues to be solved within certain time.

If you think this issue is trivial to solve, don't hesitate to submit a pull request, too! We will accompany you in the process with reviews and hints on how to get development set up.

Please also consider sponsoring the maintainers of the package. If you don't know who is currently maintaining this package, just leave a comment and we'll let you know

github-actions[bot] avatar Oct 09 '23 16:10 github-actions[bot]