Skip to content

Conversation

@tombee
Copy link
Owner

@tombee tombee commented Jan 8, 2026

Summary

  • Add parallel: shorthand syntax for cleaner workflow definitions
  • Add security validations (nesting depth 3 levels, array size 10k, max_concurrency 1-100)
  • Rewrite docs/features/parallel.md documentation with comprehensive examples
  • Add integration tests for parallel execution with timestamp overlap verification

Changes

  • pkg/workflow/definition.go: Add parallel shorthand parsing in UnmarshalYAML()
  • pkg/workflow/validate.go: Add ValidateParallelNestingDepth(), ValidateForeachArraySize(), max_concurrency validation
  • pkg/workflow/executor.go: Add runtime array size check in executeForeach()
  • docs/features/parallel.md: Complete rewrite with shorthand syntax, all options documented
  • docs/features/loops.md: Add cross-reference to parallel.md

Test plan

  • All workflow package tests pass
  • Security validation tests verify limits (nesting depth, array size, max_concurrency)
  • Integration tests verify concurrent execution with timestamp overlap
  • Shorthand syntax produces identical behavior to explicit syntax

Closes SPEC-8

tombee added 2 commits January 8, 2026 15:43
- Add comprehensive docs/features/parallel.md documentation
- Add parallel: shorthand syntax to UnmarshalYAML in definition.go
- Add security validations: array size (10k), nesting depth (3), max_concurrency (1-100)
- Add integration tests for parallel execution
- Update loops.md with cross-reference to parallel.md

Closes #4
- Add TestMaxConcurrencyValidation tests in definition_test.go
- Add TestExecuteForeach_ArraySizeLimit test in executor_parallel_test.go
- Tests cover nesting depth, max_concurrency bounds, array size limits
@tombee tombee merged commit 7559faa into main Jan 8, 2026
2 of 5 checks passed
@tombee tombee deleted the spec/SPEC-8 branch January 8, 2026 16:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants