Don't fail ContinueAsNew command if parent namespace doesn't exist
@@ -779,11 +779,10 @@ func (handler *workflowTaskHandlerImpl) handleCommandContinueAsNewWorkflow(
if handler.mutableState.HasParentExecution() {
parentNamespaceID := namespace.ID(handler.mutableState.GetExecutionInfo().ParentNamespaceId)
parentNamespaceEntry, err := handler.namespaceRegistry.GetNamespaceByID(parentNamespaceID)
- if err != nil {
- return err
- }
+ if err == nil {
parentNamespace = parentNamespaceEntry.Name()
}
+ }
_, newStateBuilder, err := handler.mutableState.AddContinueAsNewEvent(
handler.workflowTaskCompletedID,
