Commit fc320ca
committed
adapters: postgres_output: multiple worker threads
Adds support for multiple worker threads in the postgres output connector.
The postgres output endpoint spawns n (default: 4) PostgresWorkers
(a postgres worker is the same as the old PostgresOutputEndpoint), and then
each worker is passed a SplitCursor to process.
Each worker has its own retry mechanism, and each worker performs its
own transaction on the table, so, if a worker fails only this fraction
of the batch will not be committed to Postgres.
Workers are created at the start, and then sent BatchStart, BatchEnd,
Encode and Shutdown messages.
Signed-off-by: Abhinav Gyawali <22275402+abhizer@users.noreply.github.com>1 parent fa06b6f commit fc320ca
File tree
5 files changed
+933
-214
lines changed- crates
- adapters
- benches
- src/integrated/postgres
- feldera-types/src/transport
- docs.feldera.com/docs/connectors/sinks
5 files changed
+933
-214
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
135 | 135 | | |
136 | 136 | | |
137 | 137 | | |
138 | | - | |
| 138 | + | |
139 | 139 | | |
140 | 140 | | |
141 | 141 | | |
142 | 142 | | |
143 | 143 | | |
144 | 144 | | |
145 | 145 | | |
146 | | - | |
| 146 | + | |
147 | 147 | | |
148 | 148 | | |
149 | 149 | | |
| |||
0 commit comments