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

Meteor 3 #405

Open
wants to merge 8 commits into
base: master
Choose a base branch
from
Open

Conversation

matheusccastroo
Copy link

@matheusccastroo matheusccastroo commented May 6, 2024

Hi!

This PR goal is to have a version that is compatible with Meteor 3.

  • Convert code
  • Fix tests

Closes #395

@matheusccastroo matheusccastroo changed the title [WIP] - Meteor 3 Meteor 3 May 6, 2024
@matheusccastroo matheusccastroo marked this pull request as ready for review May 6, 2024 22:15
api.mainModule('redis-oplog.js', 'server');
api.mainModule('redis-oplog.client.js', 'client');
Package.onUse(function (api) {
api.versionsFrom(["3.0-rc.0"]);
Copy link
Author

Choose a reason for hiding this comment

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

We might be able to support meteor 2.12 too I think - would need to double check when we have the CI running

Comment on lines -41 to -62
if (!this.collection) {
throw new Meteor.Error(
`We could not find the collection instance by name: "${
this.collectionName
}", the cursor description was: ${JSON.stringify(
cursorDescription
)}`
);
}

// Here we apply the logic of changing the cursor based on the collection-level configuration
if (this.collection._redisOplog) {
const { cursor } = this.collection._redisOplog;
if (cursor) {
const context = DDP._CurrentPublicationInvocation.get();
cursor.call(
context,
cursorDescription.options,
cursorDescription.selector
);
}
}
Copy link

@renanc-br renanc-br May 7, 2024

Choose a reason for hiding this comment

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

why remove these checks?

Copy link
Author

Choose a reason for hiding this comment

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

They were moved to an init function, we just removed from the constructor.

Copy link
Collaborator

@StorytellerCZ StorytellerCZ left a comment

Choose a reason for hiding this comment

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

Please fix the prettier settings to be more inline with the current setup.

@@ -0,0 +1,6 @@
{
"semi": true,
"singleQuote": false,
Copy link
Collaborator

Choose a reason for hiding this comment

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

This should be true to reduce the number of prettier changes and make it easier to review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Using new meteor mongo async api
3 participants