nativelink icon indicating copy to clipboard operation
nativelink copied to clipboard

Create unique id for the action not just the job so api's outside the scheduler can talk about a specific action

Open allada opened this issue 1 year ago • 0 comments

Currently only the scheduler is allowed to perform mutation actions on actions. We need a way to hand a token out that is unique to when the add_action was performed. Naturally Arc<ActionInfo> can be used, but this seems dangerous because ActionInfoHashKey can be used to reference items in the hashmap that have the key of AsRef<ActionInfo>.

I suggest using ActionId that is a uuid to talk about unique actions and hand out to components and clients.

Think of it this way: ActionInfoHashKey = key used to reference an action that has is not queued, running or completed. ActionId = key used to talk about an action that has started running or queued or somehow been processed by the scheduler at some point.

allada avatar Apr 15 '24 20:04 allada