Commit 95ae4db
committed
[SPARK-4006] In long running contexts, we encountered the situation of double registe...
...r without a remove in between. The cause for that is unknown, and assumed a temp network issue.
However, since the second register is with a BlockManagerId on a different port, blockManagerInfo.contains() returns false, while blockManagerIdByExecutor returns Some. This inconsistency is caught in a conditional statement that does System.exit(1), which is a huge robustness issue for us.
The fix - simply remove the old id from both maps during register when this happens. We are mimicking the behavior of expireDeadHosts(), by doing local cleanup of the maps before trying to add new ones.
Also - added some logging for register and unregister.
This is just like #2854 except it's on master
Author: Tal Sliwowicz <[email protected]>
Closes #2886 from tsliwowicz/master-block-mgr-removal and squashes the following commits:
094d508 [Tal Sliwowicz] some more white space change undone
41a2217 [Tal Sliwowicz] some more whitspaces change undone
7bcfc3d [Tal Sliwowicz] whitspaces fix
df9d98f [Tal Sliwowicz] Code review comments fixed
f48bce9 [Tal Sliwowicz] In long running contexts, we encountered the situation of double register without a remove in between. The cause for that is unknown, and assumed a temp network issue.
(cherry picked from commit 6b48522)
Conflicts:
core/src/main/scala/org/apache/spark/storage/BlockManagerMasterActor.scala1 parent 81d69f0 commit 95ae4db
File tree
1 file changed
+11
-20
lines changed- core/src/main/scala/org/apache/spark/storage
1 file changed
+11
-20
lines changedLines changed: 11 additions & 20 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
145 | 145 | | |
146 | 146 | | |
147 | 147 | | |
148 | | - | |
| 148 | + | |
149 | 149 | | |
150 | 150 | | |
151 | | - | |
152 | | - | |
153 | 151 | | |
154 | 152 | | |
155 | 153 | | |
156 | | - | |
157 | | - | |
158 | | - | |
159 | 154 | | |
160 | 155 | | |
161 | 156 | | |
| |||
165 | 160 | | |
166 | 161 | | |
167 | 162 | | |
168 | | - | |
169 | | - | |
| 163 | + | |
170 | 164 | | |
171 | 165 | | |
172 | 166 | | |
| |||
187 | 181 | | |
188 | 182 | | |
189 | 183 | | |
190 | | - | |
191 | 184 | | |
192 | 185 | | |
193 | 186 | | |
| |||
231 | 224 | | |
232 | 225 | | |
233 | 226 | | |
234 | | - | |
235 | | - | |
236 | 227 | | |
237 | 228 | | |
238 | | - | |
239 | | - | |
240 | | - | |
241 | | - | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
242 | 234 | | |
243 | | - | |
244 | 235 | | |
| 236 | + | |
| 237 | + | |
245 | 238 | | |
246 | 239 | | |
247 | | - | |
248 | 240 | | |
249 | | - | |
250 | | - | |
251 | | - | |
| 241 | + | |
| 242 | + | |
252 | 243 | | |
253 | 244 | | |
254 | 245 | | |
| |||
0 commit comments