Code Monkey home page Code Monkey logo

Comments (12)

mitar avatar mitar commented on May 28, 2024

Hm, can you make a small reproduction using directcollection which is a direct connection to Mongo.

I am unsure why would this happen though with this package. Really strange. I do not know that it would rely on changes coming from inside.

from meteor-reactive-publish.

ramezrafla avatar ramezrafla commented on May 28, 2024

Thanks @mitar, so you want me to (a) replace the mongo collection in the reactive publish with the directcollection or (b) have meteor make the change with directcollection and see how the reactive publish behaves?

As mentioned above, I faced the same issue with redis-oplog (issue raised but I volunteered to get to the bottom of it).

from meteor-reactive-publish.

mitar avatar mitar commented on May 28, 2024

(b). So direct collection directly changes the Mongo. I am curious if you can replicate with that. Then we know that there is nothing fancy with redis-oplog integration (or hooking machinsm) or something like that.

from meteor-reactive-publish.

ramezrafla avatar ramezrafla commented on May 28, 2024

Ok, but this is similar to what I did already. I altered the DB externally to my app using mongoclient [Edit: fixed app name] (running as an external app, so for all practical purposes, independent from the app we are testing), and the reactive publish triggered this error. Not using redis-oplog at the moment, just wanted to highlight that we face the same issue there.

from meteor-reactive-publish.

ramezrafla avatar ramezrafla commented on May 28, 2024

Ok, so we found what was going on (at least I believe we do). We had in our reactive publish a reactive find which contained extra fields, that seemed to trigger reruns of the publish -- looks like a race condition.

What is odd is that line 36 in server.coffee is within a try, yet triggers an error.

I'll go ahead and close this so not to litter, but it's something that could cause issues with redis-oplog. I'll investigate and revert if need be.

Thanks @mitar for your continued courtesy.

from meteor-reactive-publish.

mitar avatar mitar commented on May 28, 2024

Yes, I wanted to have a reproduction without redis-oplog, and a command from inside which changes the meteor so that I could investigate. I understand that this is probably the same as changing it manually. But it is good to have it in a code because it then possible to create a test to test in the future.

from meteor-reactive-publish.

mitar avatar mitar commented on May 28, 2024

What is odd is that line 36 in server.coffee is within a try, yet triggers an error.

Sometimes I realized that numbers do not match always. All this preprocesing of CoffeeScript/JavaScript can move things around and make lines wrong.

But still, why would extra fields throw such an error?

from meteor-reactive-publish.

ramezrafla avatar ramezrafla commented on May 28, 2024

But still, why would extra fields throw such an error?

The only unscientific reason I can think of is a race condition somewhere, that causes the reactive publishing to be triggered twice (or more), with the second call failing.

I wanted to have a reproduction without redis-oplog, and a command from inside which changes the meteor so that I could investigate.

Understood. It's high on our to-do's as are supporting @theodorDiaconu in getting redis-oplog to work with reactive publishing. I'll work on getting you a test repo.

from meteor-reactive-publish.

mitar avatar mitar commented on May 28, 2024

Has this ever be resolved? @theodorDiaconu?

from meteor-reactive-publish.

theodorDiaconu avatar theodorDiaconu commented on May 28, 2024

@mitar not yet :(

from meteor-reactive-publish.

mitar avatar mitar commented on May 28, 2024

So is this error still happening?

from meteor-reactive-publish.

mitar avatar mitar commented on May 28, 2024

Closing because of no activity.

from meteor-reactive-publish.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.