Commit 233bcf3
fix: add 30-second per-file timeout to prevent index from hanging
Future.get() in all three analysis paths (analyze, index batched, smart index)
had no timeout — if an ANTLR parser or regex hangs on a pathological file,
the entire batch blocks forever.
Fix: Future.get(30, TimeUnit.SECONDS) with TimeoutException handler that
cancels the stuck task, logs a warning, and continues with the next file.
Affects Analyzer.java lines 300, 591, 961.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>1 parent 654e920 commit 233bcf3
1 file changed
Lines changed: 12 additions & 3 deletions
Lines changed: 12 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
297 | 297 | | |
298 | 298 | | |
299 | 299 | | |
300 | | - | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
301 | 304 | | |
302 | 305 | | |
303 | 306 | | |
| |||
585 | 588 | | |
586 | 589 | | |
587 | 590 | | |
588 | | - | |
| 591 | + | |
| 592 | + | |
| 593 | + | |
| 594 | + | |
589 | 595 | | |
590 | 596 | | |
591 | 597 | | |
| |||
952 | 958 | | |
953 | 959 | | |
954 | 960 | | |
955 | | - | |
| 961 | + | |
| 962 | + | |
| 963 | + | |
| 964 | + | |
956 | 965 | | |
957 | 966 | | |
958 | 967 | | |
| |||
0 commit comments