Commit f2773ad
authored
fix(arrow/flight/flightsql): drain channel in flightSqlServer.DoGet (#437)
### Rationale for this change
This PR fixes #435.
If writing to the RecordWriter fails, the current implementation does
not drain the channel when an error occurs while writing to the record
writer.
### What changes are included in this PR?
We add a deferred function that will drain the channel and call
`.Release()` on the underlying `StreamChunks` in order to be able to
release the RecordReader.
### Are these changes tested?
@zeroshade as you suggested, I'll gladly accept a recommendation for the
test setup.
### Are there any user-facing changes?
No.1 parent 542afb6 commit f2773ad
1 file changed
Lines changed: 8 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
916 | 916 | | |
917 | 917 | | |
918 | 918 | | |
| 919 | + | |
| 920 | + | |
| 921 | + | |
| 922 | + | |
| 923 | + | |
| 924 | + | |
| 925 | + | |
| 926 | + | |
919 | 927 | | |
920 | 928 | | |
921 | 929 | | |
| |||
0 commit comments