Repository navigation
Commit 48279b4
committed
Fail deferrable KPO when a GC'd pod takes its XCom with it
A deferrable KubernetesPodOperator with do_xcom_push=True was silently
marked SUCCESS when its pod was garbage-collected between the trigger
firing and task re-entry: the 404 handler in trigger_reentry() returned
None for any "success" event, so no return_value XCom was ever pushed and
downstream tasks failed unrecoverably at templating time.
Keep the existing silent-success behavior when do_xcom_push is off (only
pod logs are lost there). When XCom was expected, raise PodNotFoundException
so the task fails/retries and recreates the pod along with its XCom sidecar.
Fixes: apache#73117
Signed-off-by: Rakesh Ramakrishna Pai <[email protected]>1 parent c4a0a88 commit 48279b4
2 files changed
Lines changed: 35 additions & 5 deletions
File tree
- providers/cncf/kubernetes
- src/airflow/providers/cncf/kubernetes/operators
- tests/unit/cncf/kubernetes/operators
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1144 | 1144 | | |
1145 | 1145 | | |
1146 | 1146 | | |
1147 | | - | |
1148 | | - | |
1149 | | - | |
| 1147 | + | |
| 1148 | + | |
| 1149 | + | |
1150 | 1150 | | |
| 1151 | + | |
| 1152 | + | |
| 1153 | + | |
1151 | 1154 | | |
1152 | 1155 | | |
1153 | 1156 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4093 | 4093 | | |
4094 | 4094 | | |
4095 | 4095 | | |
4096 | | - | |
| 4096 | + | |
4097 | 4097 | | |
4098 | | - | |
| 4098 | + | |
4099 | 4099 | | |
4100 | 4100 | | |
4101 | 4101 | | |
| |||
4114 | 4114 | | |
4115 | 4115 | | |
4116 | 4116 | | |
| 4117 | + | |
| 4118 | + | |
| 4119 | + | |
| 4120 | + | |
| 4121 | + | |
| 4122 | + | |
| 4123 | + | |
| 4124 | + | |
| 4125 | + | |
| 4126 | + | |
| 4127 | + | |
| 4128 | + | |
| 4129 | + | |
| 4130 | + | |
| 4131 | + | |
| 4132 | + | |
| 4133 | + | |
| 4134 | + | |
| 4135 | + | |
| 4136 | + | |
| 4137 | + | |
| 4138 | + | |
| 4139 | + | |
| 4140 | + | |
| 4141 | + | |
| 4142 | + | |
| 4143 | + | |
4117 | 4144 | | |
4118 | 4145 | | |
4119 | 4146 | | |
| |||
0 commit comments