kunwp1 commented on code in PR #5565:
URL: https://github.com/apache/texera/pull/5565#discussion_r3379336555
##########
frontend/src/app/workspace/service/workflow-result/workflow-result.service.ts:
##########
@@ -95,6 +95,17 @@ export class WorkflowResultService {
return this.operatorResultServices.get(operatorID);
}
+ /**
+ * Drop cached operator results and reset table stats so a re-entered
workflow
+ * doesn't show stale results. resultTableStats is a ReplaySubject, so
+ * reset it to an empty snapshot to avoid replaying stale stats to
subscribers.
+ */
+ public clearResults(): void {
+ this.operatorResultServices.clear();
+ this.paginatedResultServices.clear();
+ this.resultTableStats.next({});
+ }
Review Comment:
Done.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]