Andrés Beck-Ruiz created CASSSIDECAR-460:
--------------------------------------------

             Summary: Refactor OperationalJob to have data separate from 
execution logic
                 Key: CASSSIDECAR-460
                 URL: https://issues.apache.org/jira/browse/CASSSIDECAR-460
             Project: Sidecar for Apache Cassandra
          Issue Type: Sub-task
            Reporter: Andrés Beck-Ruiz
            Assignee: Andrés Beck-Ruiz


The {{OperationalJob}} class combines data fields (jobId, status, 
operationType, node lists) with execution logic. This creates two issues:

  1. A {{DurableOperationalJobTracker}} cannot persist a job record before 
execution starts because {{OperationalJobManager}} bundles creation and 
execution in the same mapping function.
  2. Retrieving historical jobs from storage requires extending 
{{OperationalJob}} and stubbing execution methods with 
{{UnsupportedOperationException}}.

In order to resolve these issues, we should extract a data-only interface from 
{{OperationalJob}}, update the {{OperationalJobManager#trySubmitJob}} to 
separate creation from execution, and update {{OperationalJobTracker#get}} 
handlers to use the data interface for read paths. 



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to