mutable_state_task_store.go ×5

Frontier kind: Code frontier

unlabeled · c_0fa3b22351d5

2 tests · 4104 LOC · 179 files · introduces 0 tests · 51 LOC · 2 files

Introduces — evidence that enters the hierarchy at this concept

Code
6 ranges51 lines · 2 files
Tests
0 tests

Contains — complete concept membership

All code (extent)
730 ranges4104 lines · 179 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: 51 introduced LOC across 6 ranges. Expand a file to inspect source; the > gutter marks introduced lines.

go.temporal.io/server/common/persistence/cassandra/mutable_state_task_store.go 39 introduced LOC · 5 ranges

Open complete file

235 case tasks.CategoryIDVisibility:
236 return d.getVisibilityTasks(ctx, request)
237 > case tasks.CategoryIDReplication: mutable_state_task_store.go
238 > return d.getReplicationTasks(ctx, request)
239 default:
240 return d.getHistoryTasks(ctx, request)
451 ctx context.Context,
452 request *p.GetHistoryTasksRequest,
453 > ) (*p.InternalGetHistoryTasksResponse, error) { mutable_state_task_store.go
454 >
455 > // Reading replication tasks need to be quorum level consistent, otherwise we could lose task
456 > query := d.Session.Query(templateGetReplicationTasksQuery,
457 > request.ShardID,
458 > rowTypeReplicationTask,
459 > rowTypeReplicationNamespaceID,
460 > rowTypeReplicationWorkflowID,
461 > rowTypeReplicationRunID,
462 > defaultVisibilityTimestamp,
463 > request.InclusiveMinTaskKey.TaskID,
464 > request.ExclusiveMaxTaskKey.TaskID,
465 > ).WithContext(ctx).PageSize(request.BatchSize).PageState(request.NextPageToken)
466 >
467 > return d.populateGetReplicationTasksResponse(query, "GetReplicationTasks")
468 > }
469
470 func (d *MutableStateTaskStore) completeReplicationTask(
702 query gocql.Query,
703 operation string,
704 > ) (*p.InternalGetHistoryTasksResponse, error) { mutable_state_task_store.go
705 > iter := query.Iter()
706 >
707 > response := &p.InternalGetHistoryTasksResponse{}
708 > var taskID int64
709 > var data []byte
710 > var encoding string
711 >
712 > for iter.Scan(&taskID, &data, &encoding) {
713 > response.Tasks = append(response.Tasks, p.InternalHistoryTask{
714 > Key: tasks.NewImmediateKey(taskID),
715 > Blob: p.NewDataBlob(data, encoding),
716 > })
717 >
718 > taskID = 0
719 > data = nil
720 > encoding = ""
721 > }
722 > if len(iter.PageState()) > 0 {
723 response.NextPageToken = iter.PageState()
724 }
725
726 > if err := iter.Close(); err != nil { mutable_state_task_store.go
727 return nil, gocql.ConvertError(operation, err)
728 }
729
730 > return response, nil mutable_state_task_store.go
731 }
732
go.temporal.io/server/common/persistence/cassandra/util.go 12 introduced LOC · 1 range

Open complete file

545 ) error {
546 for _, task := range replicationTasks {
547 > batch.Query(templateCreateReplicationTaskQuery, util.go
548 > shardID,
549 > rowTypeReplicationTask,
550 > rowTypeReplicationNamespaceID,
551 > rowTypeReplicationWorkflowID,
552 > rowTypeReplicationRunID,
553 > task.Blob.Data,
554 > task.Blob.EncodingType.String(),
555 > defaultVisibilityTimestamp,
556 > task.Key.TaskID,
557 > )
558 > }
559 return nil
560 }