Closed dragonfriend0013 closed 3 years ago
Still possible, this library just adds a couple methods. You wouldn’t use them during a transaction.
On Mon, Nov 16, 2020 at 4:21 PM Jason Murphy notifications@github.com wrote:
Since this library is initialized using a collection, are Transactions using multiple collections not possible?
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/GraphQLGuide/apollo-datasource-mongodb/issues/39, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAB5LGEULYWWPEXLJZD3M33SQGJUJANCNFSM4TXW4APQ .
based on the code, the datasource is initialized with a collection, not a database or client. transactions are done at the database(s) level, not the collection level.
You aren't limited to using this.collection
in your datasource
methods—you can also import and use the database client / other
collections.
On Wed, Nov 18, 2020 at 9:06 AM Jason Murphy notifications@github.com wrote:
based on the code, the datasource is initialized with a collection, not a database or client. transactions are done at the database(s) level, not the collection level.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/GraphQLGuide/apollo-datasource-mongodb/issues/39#issuecomment-729699796, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAB5LGC3S6D6AIUY4B7PEK3SQPIHRANCNFSM4TXW4APQ .
Since this library is initialized using a collection, are Transactions using multiple collections not possible?