v2.0.9
Maintained fork of cottz:publish-relations
by lfades (MIT).
This bugfix release fixes the long-standing oplog error from this.join():
The Mongo server and the Meteor query disagree on how many documents match your query
Fixes
- Stop leaked join observers — when a join cursor was re-issued with a new
selector, the previousobserveChangeshandler was overwritten without being
stopped, leaving a stale observer running against an older$inselector. It
is now stopped before being replaced. - Shrink the join
$inon contributor removal — joined ids were only ever
added, never released, so the$ingrew without bound on long-lived / busy
subscriptions and eventually diverged from Mongo during oplog reconciliation.
The$inis now refcounted per joined id and shrinks when contributor
documents are removed (dropped documents are explicitly retracted from the
client), while staying fully reactive.
Fully backwards compatible with cottz:publish-relations — same API.