Context
The current API does not allow a custom TaskOrchestrationFactory and TaskActivityFactory, when creating a DurableTaskGrpcWorker through:
public DurableTaskGrpcWorker build() {
return new DurableTaskGrpcWorker(this);
}
Proposal
It would be great, if we have a way to add custom factories to load WorkflowActivity or Workflow implementations through other mechanism, like CDI, by example.
Possible implementation
To change the WorkflowRuntimeBuilder builder adding a new method that adds a custom factories.
For example:
public <T extends WorkflowActivity> WorkflowRuntimeBuilder registerTaskActivityFactory(String activityName, TaskActivityFactory taskActivityFactory) {
return null;
}
public <T extends Workflow> WorkflowRuntimeBuilder registerTaskOrchestrationFactory(String orchestrationName, TaskOrchestrationFactory taskOrchestrationFactory) {
return null;
}