Commit 7ca59cb
Timothy Dodd
Refactor log processing with Deployment/Pod composite key
Enhanced log processing by introducing a composite key (`Deployment/Pod`) to uniquely identify and manage logs for multiple containers per deployment.
- Added deployment count retrieval in `InitializeDeploymentTimesAsync` to optimize backfilling.
- Updated `ReadNewLinesAsync` and `ProcessEventLogFileAsync` to use the composite key for deployment settings.
- Refactored `ConvertEventRecordToLogLine` to improve clarity and align with the composite key approach.
- Added a new API endpoint (`GET /api/log/counts`) to expose deployment and pod counts.
- Implemented `GetDeploymentCounts` in `LogRepo.cs` to query deployment and pod counts from the database.
- Introduced the `DeploymentCount` class to represent deployment and pod count data.
- Improved logging for better traceability of deployment/pod combinations.
- Cleaned up redundant code and updated comments to reflect the new structure.
These changes improve the granularity, accuracy, and maintainability of log processing.1 parent 410f8f4 commit 7ca59cb
4 files changed
Lines changed: 56 additions & 12 deletions
File tree
- src
- LogMkAgent/Services
- LogMkApi
- Controllers
- Data
- LogMkCommon
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
133 | 133 | | |
134 | 134 | | |
135 | 135 | | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
136 | 147 | | |
137 | 148 | | |
138 | 149 | | |
139 | | - | |
140 | | - | |
| 150 | + | |
141 | 151 | | |
142 | | - | |
143 | | - | |
144 | | - | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
145 | 158 | | |
146 | 159 | | |
147 | 160 | | |
| |||
304 | 317 | | |
305 | 318 | | |
306 | 319 | | |
307 | | - | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
308 | 323 | | |
309 | 324 | | |
310 | 325 | | |
| |||
640 | 655 | | |
641 | 656 | | |
642 | 657 | | |
643 | | - | |
| 658 | + | |
| 659 | + | |
| 660 | + | |
| 661 | + | |
644 | 662 | | |
645 | 663 | | |
646 | 664 | | |
| |||
670 | 688 | | |
671 | 689 | | |
672 | 690 | | |
673 | | - | |
| 691 | + | |
674 | 692 | | |
675 | 693 | | |
676 | 694 | | |
| |||
728 | 746 | | |
729 | 747 | | |
730 | 748 | | |
731 | | - | |
| 749 | + | |
732 | 750 | | |
733 | 751 | | |
734 | 752 | | |
735 | 753 | | |
736 | 754 | | |
737 | 755 | | |
738 | | - | |
739 | 756 | | |
740 | 757 | | |
741 | | - | |
742 | | - | |
743 | 758 | | |
744 | 759 | | |
745 | 760 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
479 | 479 | | |
480 | 480 | | |
481 | 481 | | |
| 482 | + | |
| 483 | + | |
| 484 | + | |
| 485 | + | |
| 486 | + | |
| 487 | + | |
| 488 | + | |
| 489 | + | |
482 | 490 | | |
483 | 491 | | |
484 | 492 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
170 | 170 | | |
171 | 171 | | |
172 | 172 | | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
173 | 186 | | |
174 | 187 | | |
175 | 188 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
0 commit comments