task_refresher.go ×17

Frontier kind: Code frontier

unlabeled · c_8c220192618d

6 tests · 5290 LOC · 202 files · introduces 0 tests · 87 LOC · 2 files

Introduces — evidence that enters the hierarchy at this concept

Code
18 ranges87 lines · 2 files
Tests
0 tests

Contains — complete concept membership

All code (extent)
933 ranges5290 lines · 202 files · Browse complete extent
All tests (intent)
6 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: 87 introduced LOC across 18 ranges. Expand a file to inspect source; the > gutter marks introduced lines.

go.temporal.io/server/service/history/workflow/task_refresher.go 84 introduced LOC · 17 ranges

Open complete file

66 mutableState historyi.MutableState,
67 shouldSkipGeneratingCloseTransferTask bool,
68 > ) error { task_refresher.go
69 > // Invalidate all tasks generated for this mutable state before the refresh.
70 > mutableState.GetExecutionInfo().TaskGenerationShardClockTimestamp = r.shard.CurrentVectorClock().GetClock()
71 >
72 > if err := r.PartialRefresh(ctx, mutableState, EmptyVersionedTransition, nil, shouldSkipGeneratingCloseTransferTask); err != nil {
73 return err
74 }
75
76 > if err := mutableState.ChasmTree().RefreshTasks(); err != nil { task_refresher.go
77 return err
78 }
79
80 > if !mutableState.IsWorkflow() && mutableState.GetExecutionState().State == enumsspb.WORKFLOW_EXECUTION_STATE_COMPLETED { task_refresher.go
81 closeTime, err := mutableState.GetWorkflowCloseTime(ctx)
82 if err != nil {
99 previousPendingChildIds map[int64]struct{},
100 shouldSkipGeneratingCloseTransferTask bool,
101 > ) error { task_refresher.go
102 > // CHASM tasks will be replicated as part of ApplyMutation/ApplySnapshot.
103 > // Physical tasks will also be automatically generated upon CloseTransaction.
104 > // So there's no need to do partial refresh for CHASM components.
105 > if !mutableState.IsWorkflow() {
106 return nil
107 }
108
109 > taskGenerator := r.taskGeneratorProvider.NewTaskGenerator( task_refresher.go
110 > r.shard,
111 > mutableState,
112 > )
113 >
114 > if err := RefreshTasksForWorkflowStart(
115 > ctx,
116 > mutableState,
117 > taskGenerator,
118 > minVersionedTransition,
119 > ); err != nil {
120 return err
121 }
122
123 > if err := r.refreshTasksForWorkflowClose( task_refresher.go
124 > ctx,
125 > mutableState,
126 > taskGenerator,
127 > minVersionedTransition,
128 > shouldSkipGeneratingCloseTransferTask,
129 > ); err != nil {
130 return err
131 }
132
133 > if err := r.refreshTasksForRecordWorkflowStarted( task_refresher.go
134 > ctx,
135 > mutableState,
136 > taskGenerator,
137 > minVersionedTransition,
138 > ); err != nil {
139 return err
140 }
141
142 > if err := r.refreshWorkflowTaskTasks( task_refresher.go
143 > mutableState,
144 > taskGenerator,
145 > minVersionedTransition,
146 > ); err != nil {
147 return err
148 }
149
150 > if err := r.refreshTasksForActivity( task_refresher.go
151 > ctx,
152 > mutableState,
153 > taskGenerator,
154 > minVersionedTransition,
155 > ); err != nil {
156 return err
157 }
158
159 > if err := r.refreshTasksForTimer( task_refresher.go
160 > mutableState,
161 > minVersionedTransition,
162 > ); err != nil {
163 return err
164 }
165
166 > if err := r.refreshTasksForChildWorkflow( task_refresher.go
167 > mutableState,
168 > taskGenerator,
169 > minVersionedTransition,
170 > previousPendingChildIds,
171 > ); err != nil {
172 return err
173 }
174
175 > if err := r.refreshTasksForRequestCancelExternalWorkflow( task_refresher.go
176 > ctx,
177 > mutableState,
178 > taskGenerator,
179 > minVersionedTransition,
180 > ); err != nil {
181 return err
182 }
183
184 > if err := r.refreshTasksForSignalExternalWorkflow( task_refresher.go
185 > ctx,
186 > mutableState,
187 > taskGenerator,
188 > minVersionedTransition,
189 > ); err != nil {
190 return err
191 }
192
193 > if err := r.refreshTasksForWorkflowSearchAttr( task_refresher.go
194 > mutableState,
195 > taskGenerator,
196 > minVersionedTransition,
197 > ); err != nil {
198 return err
199 }
200
201 > if err := r.refreshTasksForSubStateMachines( task_refresher.go
202 > mutableState,
203 > minVersionedTransition,
204 > ); err != nil {
205 return err
206 }
207
208 > return r.refreshTasksForTimeSkipping( task_refresher.go
209 > mutableState,
210 > taskGenerator,
211 > minVersionedTransition,
212 > )
213 }
214
go.temporal.io/server/service/history/workflow/noop_chasm_tree.go 3 introduced LOC · 1 range

Open complete file

42 }
43
44 > func (*noopChasmTree) RefreshTasks() error { noop_chasm_tree.go
45 > return nil
46 > }
47
48 func (*noopChasmTree) IsStateDirty() bool {