Commit aa3ba5e
authored
fix(amazonq): Update exception handling for feature dev to improve observability (#4953)
**Problem:** Feature dev instrumentation 1) records all failures as `FeatureDevException`, losing information about the specific exception type, and 2) lacks annotation of `reasonDesc` and the operation related to the error. (By operation, although we do capture `amazonq_codeGenerationInvoke`, we're missing the subprocess name such as `StartCodeGeneration`.) As a result, we do not have insight into feature dev failures in JetBrains.
**Solution:** 1) Update exception modeling pattern for feature dev functionality to derive subclasses of `FeatureDevException`, providing a meaningful class name when inspected as error `reason`. 2) On `FeatureDevException`, accept an `operation` and `desc` to provide further annotation (merged when logged as `reasonDesc`).
This change will have conflicts with #4938 and #4949. I'll rebase on top of those and reconcile any drift in a subsequent revision.1 parent 96331c8 commit aa3ba5e
File tree
9 files changed
+152
-87
lines changed- plugins
- amazonq/chat/jetbrains-community
- src/software/aws/toolkits/jetbrains/services/amazonqFeatureDev
- controller
- session
- util
- tst/software/aws/toolkits/jetbrains/services/amazonqFeatureDev/util
- core/resources/resources/software/aws/toolkits/resources
9 files changed
+152
-87
lines changedLines changed: 13 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
Lines changed: 52 additions & 23 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
9 | | - | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
10 | 18 | | |
11 | | - | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
12 | 25 | | |
13 | | - | |
| 26 | + | |
| 27 | + | |
14 | 28 | | |
15 | | - | |
| 29 | + | |
| 30 | + | |
16 | 31 | | |
17 | | - | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
18 | 39 | | |
19 | | - | |
20 | | - | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
| 40 | + | |
| 41 | + | |
25 | 42 | | |
26 | | - | |
27 | | - | |
| 43 | + | |
| 44 | + | |
28 | 45 | | |
29 | | - | |
30 | | - | |
| 46 | + | |
| 47 | + | |
31 | 48 | | |
32 | | - | |
33 | | - | |
| 49 | + | |
| 50 | + | |
34 | 51 | | |
35 | | - | |
36 | | - | |
| 52 | + | |
| 53 | + | |
37 | 54 | | |
38 | | - | |
39 | | - | |
| 55 | + | |
| 56 | + | |
40 | 57 | | |
41 | | - | |
42 | | - | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
43 | 72 | | |
44 | 73 | | |
45 | 74 | | |
| |||
Lines changed: 31 additions & 27 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
32 | | - | |
| 32 | + | |
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
37 | 37 | | |
38 | 38 | | |
39 | 39 | | |
40 | | - | |
| 40 | + | |
41 | 41 | | |
42 | 42 | | |
43 | 43 | | |
| |||
433 | 433 | | |
434 | 434 | | |
435 | 435 | | |
436 | | - | |
| 436 | + | |
437 | 437 | | |
438 | 438 | | |
439 | 439 | | |
| |||
451 | 451 | | |
452 | 452 | | |
453 | 453 | | |
454 | | - | |
455 | | - | |
456 | | - | |
457 | | - | |
458 | | - | |
459 | | - | |
460 | | - | |
461 | | - | |
462 | | - | |
| 454 | + | |
463 | 455 | | |
464 | 456 | | |
465 | 457 | | |
| |||
479 | 471 | | |
480 | 472 | | |
481 | 473 | | |
482 | | - | |
483 | | - | |
484 | | - | |
485 | | - | |
486 | | - | |
487 | | - | |
488 | | - | |
489 | | - | |
| 474 | + | |
| 475 | + | |
| 476 | + | |
| 477 | + | |
| 478 | + | |
| 479 | + | |
| 480 | + | |
| 481 | + | |
| 482 | + | |
| 483 | + | |
| 484 | + | |
| 485 | + | |
| 486 | + | |
| 487 | + | |
| 488 | + | |
| 489 | + | |
| 490 | + | |
| 491 | + | |
| 492 | + | |
| 493 | + | |
| 494 | + | |
490 | 495 | | |
| 496 | + | |
| 497 | + | |
| 498 | + | |
| 499 | + | |
| 500 | + | |
| 501 | + | |
491 | 502 | | |
492 | | - | |
493 | 503 | | |
494 | | - | |
495 | | - | |
496 | | - | |
497 | | - | |
498 | | - | |
499 | | - | |
500 | 504 | | |
501 | 505 | | |
502 | 506 | | |
| |||
Lines changed: 18 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
| 11 | + | |
| 12 | + | |
11 | 13 | | |
12 | | - | |
13 | | - | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
14 | 19 | | |
15 | 20 | | |
16 | 21 | | |
| |||
37 | 42 | | |
38 | 43 | | |
39 | 44 | | |
| 45 | + | |
40 | 46 | | |
41 | 47 | | |
42 | 48 | | |
| |||
86 | 92 | | |
87 | 93 | | |
88 | 94 | | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
89 | 99 | | |
90 | 100 | | |
91 | 101 | | |
| |||
100 | 110 | | |
101 | 111 | | |
102 | 112 | | |
| 113 | + | |
103 | 114 | | |
104 | 115 | | |
105 | 116 | | |
| |||
149 | 160 | | |
150 | 161 | | |
151 | 162 | | |
152 | | - | |
| 163 | + | |
153 | 164 | | |
154 | 165 | | |
155 | 166 | | |
156 | | - | |
| 167 | + | |
157 | 168 | | |
158 | 169 | | |
159 | 170 | | |
160 | | - | |
| 171 | + | |
161 | 172 | | |
162 | 173 | | |
163 | 174 | | |
164 | | - | |
165 | | - | |
| 175 | + | |
| 176 | + | |
166 | 177 | | |
167 | 178 | | |
168 | 179 | | |
| |||
Lines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
| 12 | + | |
12 | 13 | | |
13 | 14 | | |
14 | 15 | | |
15 | | - | |
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| |||
138 | 138 | | |
139 | 139 | | |
140 | 140 | | |
141 | | - | |
| 141 | + | |
142 | 142 | | |
143 | 143 | | |
144 | 144 | | |
| |||
0 commit comments