Commit b6f3ed4
committed
refactor: derive hasMore from nextPageToken instead of separate parameter
Remove hasMore as an explicit parameter from IListMessagesProgress.OnComplete().
The hasMore field is now automatically derived from whether nextPageToken is empty.
This simplifies the interface by removing redundant state - the information about
whether more pages exist is already encoded in the presence/absence of nextPageToken.
Changes:
- Remove hasMore parameter from OnComplete() interface (4 params -> 3 params)
- Derive HasMore automatically: HasMore = nextPageToken != ""
- Update all call sites to pass 3 parameters instead of 4
- Update integration tests to check nextPageToken instead of hasMore
- Update mocks to match new 3-parameter signature
The protobuf has_more field is still populated for wire compatibility, but is no
longer passed as a separate parameter through the application layers.1 parent b63dbea commit b6f3ed4
File tree
9 files changed
+72
-92
lines changed- backend/pkg
- api
- connect/service/console
- console
- protogen/redpanda/api/console/v1alpha1
- frontend/src/protogen/redpanda/api/console/v1alpha1
- proto/gen/openapi
9 files changed
+72
-92
lines changedLines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
216 | 216 | | |
217 | 217 | | |
218 | 218 | | |
219 | | - | |
| 219 | + | |
220 | 220 | | |
221 | 221 | | |
222 | 222 | | |
| |||
226 | 226 | | |
227 | 227 | | |
228 | 228 | | |
229 | | - | |
| 229 | + | |
230 | 230 | | |
231 | 231 | | |
232 | 232 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1145 | 1145 | | |
1146 | 1146 | | |
1147 | 1147 | | |
1148 | | - | |
1149 | 1148 | | |
1150 | 1149 | | |
1151 | 1150 | | |
| |||
1202 | 1201 | | |
1203 | 1202 | | |
1204 | 1203 | | |
1205 | | - | |
| 1204 | + | |
1206 | 1205 | | |
1207 | | - | |
| 1206 | + | |
1208 | 1207 | | |
1209 | 1208 | | |
1210 | 1209 | | |
| |||
1269 | 1268 | | |
1270 | 1269 | | |
1271 | 1270 | | |
1272 | | - | |
1273 | 1271 | | |
1274 | 1272 | | |
1275 | 1273 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
81 | 81 | | |
82 | 82 | | |
83 | 83 | | |
84 | | - | |
| 84 | + | |
85 | 85 | | |
86 | 86 | | |
87 | 87 | | |
| |||
224 | 224 | | |
225 | 225 | | |
226 | 226 | | |
227 | | - | |
228 | 227 | | |
229 | 228 | | |
230 | 229 | | |
| |||
260 | 259 | | |
261 | 260 | | |
262 | 261 | | |
263 | | - | |
| 262 | + | |
264 | 263 | | |
265 | 264 | | |
266 | 265 | | |
| |||
274 | 273 | | |
275 | 274 | | |
276 | 275 | | |
277 | | - | |
| 276 | + | |
278 | 277 | | |
279 | 278 | | |
280 | 279 | | |
| |||
305 | 304 | | |
306 | 305 | | |
307 | 306 | | |
308 | | - | |
| 307 | + | |
309 | 308 | | |
310 | 309 | | |
311 | 310 | | |
| |||
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 56 additions & 66 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
0 commit comments