S-Wing
S-Wing

Reputation: 591

MongoDB updateOne vs findAndModify: concurrency

Both UpdateOne and FindAndModify accept query and update part.

Is it possible that another process goes between the execution of the query part and the update part?

Are there differences between UpdateOne and FindAndModify from a performance point of view?

Upvotes: 0

Views: 65

Answers (1)

Yossale
Yossale

Reputation: 14361

Is it possible that another process goes between the execution of the query part and the update part?

No. Read here

Are there differences between UpdateOne and FindAndModify from a performance point of view?

No. Read Here

Upvotes: 1

Related Questions