scale_manager.go ×4

Frontier kind: Code frontier

unlabeled · c_13684e742251

2 tests · 3513 LOC · 155 files · introduces 0 tests · 15 LOC · 2 files

Introduces — evidence that enters the hierarchy at this concept

Code
5 ranges15 lines · 2 files
Tests
0 tests

Contains — complete concept membership

All code (extent)
626 ranges3513 lines · 155 files · Browse complete extent
All tests (intent)
2 testsBrowse complete intent

Neighbourhood graph

The orange circle is the focus. Violet and green circles are every ancestor and descendant, broader and narrower, at any distance; blue squares and pink diamonds are the introduced files and exact introduced tests of every visible concept, not only the focus's. Arrows point from broader to narrower concepts and bridge only concepts omitted from this view. Undirected links show source or test introduction. Concept and file size follows LOC; exact test nodes use test-count units.

Introduced files, introduced tests, and structurally relevant concept specialization

In the embedded map, ordinary wheel input scrolls the page; use the visible controls to zoom and drag to pan. Open the full-screen map for canvas navigation: wheel pans, Ctrl/Command plus wheel zooms, and arrow keys pan when this region is focused. On touch screens, open the full-screen map to pan or pinch. If JavaScript or WebGL is unavailable, use the native relationship evidence on this page.

Graph controls are ready.

Interactive rendering requires JavaScript and WebGL. Use the native relationship evidence on this page while the interactive map is unavailable.

Native relationship evidence

Every exact file and test below is linked only from the concept that introduces it.

Introduced tests

Every collected test enters the hierarchy at exactly one concept.

No tests are introduced at this concept. Its intent tests are introduced by other concepts.

Introduced code

Every collected source range enters the hierarchy at exactly one concept.

2 files ranked by introduced lines: 15 introduced LOC across 5 ranges. Expand a file to inspect source; the > gutter marks introduced lines.

go.temporal.io/server/service/matching/scale_manager.go 11 introduced LOC · 4 ranges

Open complete file

367 bitSet(scaleState.BacklogState).get(id) &&
368 partitionIsFullyDrained(res, info) {
369 > toClear = append(toClear, id) scale_manager.go
370 > }
371 }
372
389 newState.BacklogCounts = newBacklog
390 for _, i := range toClear {
391 > newState.BacklogState = bitSet(newState.BacklogState).clear(i) scale_manager.go
392 > }
393
394 // sync to DB only when drain bits changed (must be persisted before taking effect).
402
403 if len(toClear) > 0 {
404 > sm.logger.Info("drain", scale_manager.go
405 > tag.Any("drained-partitions", toClear),
406 > tag.Int32("target", info.Write),
407 > tag.Int32("prev-read", info.Read),
408 > tag.Int32("read", bitSet(newState.BacklogState).len()))
409 > }
410
411 sm.setState(newState, settings)
go.temporal.io/server/api/matchingservice/v1/request_response.pb.go 4 introduced LOC · 1 range

Open complete file

2050 }
2051
2052 > func (x *DescribeTaskQueuePartitionRequest) GetTaskQueuePartition() *v18.TaskQueuePartition { request_response.pb.go
2053 > if x != nil {
2054 > return x.TaskQueuePartition
2055 > }
2056 return nil
2057 }