3 ms·
Not op, I think what he means is the session, even when already failed once, can still be used (without error) in the next operation without being invalidated.
by fendy3002 6y ago
Not op, I think what he means is the session, even when already failed once, can still be used (without error) in the next operation without being invalidated.
Without promise.all, I think it can be replicated like this:
try{
await someOp(session);
catch { }
await someOtherOp(session);
He expected what the session to be invalidated during someOtherOp.
- inglor 6y agoThat is correct and what I meant. Thanks, and there doesn't have to be a `try/catch` because it is possible to "fork" control with promises. They implemented a "disposer" incorrectly (I added this to several other libraries and made a Q&A about it here https://stackoverflow.com/questions/28915677/what-is-the-promise-disposer-pattern https://stackoverflow.com/questions/28915677/what-is-the-pro... )