Commit 29c6b41
authored
chore(shard-manager): provide metadata in constructor (#7711)
**What changed?**
Refactoring for #7712:
Providing shard executor metadata to the constructor instead of
Initalising this separately.
In addition, unifying panic -> logger.Fatal as we do in other cases.
**Why?**
+Better readability as code is more aligned with other usages of
log.Fatal.
Passing metadata to constructor allows to avoid partial structure
initialization.
**How did you test it?**
go test -v ./service/matching/handler
**Potential risks**
**Release notes**
**Documentation Changes**
Signed-off-by: Jan Kisel <dkrot@uber.com>1 parent 0a14583 commit 29c6b41
File tree
2 files changed
+16
-15
lines changed- service
- matching/handler
- sharddistributor/client/executorclient
2 files changed
+16
-15
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
198 | 198 | | |
199 | 199 | | |
200 | 200 | | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
201 | 208 | | |
202 | 209 | | |
203 | 210 | | |
204 | 211 | | |
205 | 212 | | |
206 | 213 | | |
207 | 214 | | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
208 | 220 | | |
209 | 221 | | |
210 | 222 | | |
211 | | - | |
| 223 | + | |
212 | 224 | | |
213 | 225 | | |
214 | | - | |
215 | | - | |
216 | | - | |
217 | | - | |
218 | | - | |
219 | | - | |
220 | | - | |
221 | | - | |
222 | | - | |
223 | | - | |
224 | | - | |
225 | | - | |
226 | 226 | | |
227 | 227 | | |
228 | 228 | | |
| |||
Lines changed: 3 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
138 | 138 | | |
139 | 139 | | |
140 | 140 | | |
141 | | - | |
142 | 141 | | |
143 | | - | |
144 | 142 | | |
| 143 | + | |
| 144 | + | |
145 | 145 | | |
146 | 146 | | |
147 | 147 | | |
| |||
162 | 162 | | |
163 | 163 | | |
164 | 164 | | |
| 165 | + | |
165 | 166 | | |
166 | 167 | | |
167 | 168 | | |
| |||
0 commit comments