Skip to content

Commit

Permalink
Reworded a bit warning about returning IAsyncEnumerable outside of th…
Browse files Browse the repository at this point in the history
…e connection lifetime scope
  • Loading branch information
oskardudycz committed Aug 7, 2023
1 parent 3672443 commit dbd587e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/documents/querying/linq/async-enumerable.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ public async Task query_to_async_enumerable()
```

::: warning
Be aware not to return the IAsyncEnumerable out of the scope in which the session that produces it is used. This would prevent the data base connection from being reused afterwards and thus leading to a connection bleed.
Be aware not to return the IAsyncEnumerable out of the scope in which the session that produces it is used. This would prevent the database connection from being reused afterwards and thus lead to a connection bleed.
:::

<sup><a href='https://github.com/JasperFx/marten/blob/master/src/DocumentDbTests/Reading/Linq/invoking_query_with_ToAsyncEnumerable.cs#L18-L43' title='Snippet source file'>snippet source</a> | <a href='#snippet-sample_query_to_async_enumerable' title='Start of snippet'>anchor</a></sup>
Expand Down

0 comments on commit dbd587e

Please sign in to comment.