Skip to content

Conversation

jamis
Copy link
Contributor

@jamis jamis commented Sep 15, 2025

Backport #6035 to 9.0-stable.

@jamis jamis requested a review from a team as a code owner September 15, 2025 17:48
@jamis jamis added the bug Fixes a bug, with no new features or broken compatibility label Sep 15, 2025
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This pull request backports MONGOID-5887 to include server hints for aggregate operations, allowing MongoDB query hints to be passed through to the aggregation pipeline for better query optimization.

  • Modifies the aggregates method to pass hint options to the MongoDB aggregate command
  • Adds comprehensive test coverage for hint functionality in aggregation operations

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
lib/mongoid/contextual/aggregable/mongo.rb Updates aggregates method to include hint parameter from view
spec/mongoid/contextual/aggregable/mongo_spec.rb Adds test cases to verify hint inclusion and exclusion in aggregate commands

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Copy link
Contributor

@alexbevi alexbevi left a comment

Choose a reason for hiding this comment

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

LGTM

@jamis jamis merged commit e98d956 into mongodb:9.0-stable Sep 17, 2025
62 checks passed
@jamis jamis deleted the 5887-server-hint-for-aggregation branch September 17, 2025 17:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Fixes a bug, with no new features or broken compatibility

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants