Skip to content

RUBY-3103 Exclude create events from change stream events when testing showExpandedEvents #2612

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

Merged
merged 1 commit into from
Sep 4, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,15 @@ tests:
- name: createChangeStream
object: *collection0
arguments:
pipeline: []
pipeline:
# On sharded clusters, the create command run when loading initial
# data sometimes is still reported in the change stream. To avoid
# this, we exclude the create command when creating the change
# stream, but specifically don't exclude other events to still catch
# driver errors.
- $match:
operationType:
$ne: create
showExpandedEvents: true
saveResultAsEntity: &changeStream0 changeStream0
- name: createIndex
Expand Down Expand Up @@ -259,9 +267,7 @@ tests:
arguments:
command:
collMod: *collection0
# Added here to fix our tests as we require a commandName but don't
# do anything with it.
commandName: modify_collection
commandName: collMod
- name: iterateUntilDocumentOrError
object: *changeStream0
expectResult:
Expand Down Expand Up @@ -292,6 +298,7 @@ tests:
shardCollection: shardedDb.shardedCollection
key:
_id: 1
commandName: shardCollection
- name: iterateUntilDocumentOrError
object: *changeStream0
expectResult:
Expand Down