Skip to content

Commit

Permalink
Fuzzy workflow generation (#37)
Browse files Browse the repository at this point in the history
First pass - not all features are implemented by generator or workflows
  • Loading branch information
Sushisource committed Nov 23, 2023
1 parent 71bf631 commit 4ebaa81
Show file tree
Hide file tree
Showing 39 changed files with 9,666 additions and 865 deletions.
3 changes: 3 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
workers/python/protos/*pb2.py* linguist-generated=true
loadgen/kitchensink/kitchen_sink.pb.go linguist-generated=true
loadgen/kitchensink/temporal/** linguist-generated=true
34 changes: 32 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,38 @@ jobs:
- name: Run local scenario with worker
run: ./temporal-omes run-scenario-with-worker --scenario workflow_with_single_noop_activity --log-level debug --language python --embedded-server --iterations 5
- name: Build worker image
run: ./temporal-omes build-worker-image --language python --version 1.2.0 --tag-as-latest
run: ./temporal-omes build-worker-image --language python --version 1.4.0 --tag-as-latest
- name: Run worker image
run: docker run --rm --detach -i -p 10233:10233 omes:python-1.2.0 --scenario workflow_with_single_noop_activity --log-level debug --language python --run-id {{ github.run_id }} --embedded-server-address 0.0.0.0:10233
run: docker run --rm --detach -i -p 10233:10233 omes:python-1.4.0 --scenario workflow_with_single_noop_activity --log-level debug --language python --run-id {{ github.run_id }} --embedded-server-address 0.0.0.0:10233
- name: Run scenario against image
run: ./temporal-omes run-scenario --scenario workflow_with_single_noop_activity --log-level debug --server-address 127.0.0.1:10233 --run-id {{ github.run_id }} --connect-timeout 1m --iterations 5

build-ks-gen-and-ensure-protos-up-to-date:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v2
with:
submodules: 'true'
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: 1.74.0
override: true
- name: Install protoc
uses: arduino/setup-protoc@v2
with:
version: '25.1'
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: Setup Go
uses: actions/setup-go@v2
with:
go-version: "^1.20"
- name: Install protoc-gen-go
run: go install google.golang.org/protobuf/cmd/protoc-gen-go@v1.31.0
- name: Build kitchen-sink-gen
working-directory: ./loadgen/kitchen-sink-gen
run: cargo build
- name: Check diff
run: |
[[ -z $(git status --porcelain loadgen/kitchensink/ workers/python/protos/) ]] || (git diff; echo "Protos changed"; exit 1)
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@
.mypy_cache
go.work
go.work.sum
.idea/
.idea/
/loadgen/kitchen-sink-gen/target/
1 change: 1 addition & 0 deletions cmd/run_scenario.go
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,7 @@ func (r *scenarioRunner) run(ctx context.Context) error {
},
ScenarioOptions: scenarioOptions,
Namespace: r.clientOptions.Namespace,
RootPath: rootDir(),
}
err = scenario.Executor.Run(ctx, scenarioInfo)
if err != nil {
Expand Down
20 changes: 15 additions & 5 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,14 @@ module github.com/temporalio/omes
go 1.20

require (
github.com/golang/protobuf v1.5.3
github.com/prometheus/client_golang v1.16.0
github.com/spf13/cobra v1.7.0
github.com/spf13/pflag v1.0.5
github.com/stretchr/testify v1.8.4
github.com/temporalio/features v0.0.0-20230825203822-22c291e343bd
github.com/temporalio/features v0.0.0-20231117211247-ca7959c1fe2c
go.temporal.io/api v1.24.0
go.temporal.io/sdk v1.24.0
go.temporal.io/sdk v1.25.0
go.uber.org/zap v1.25.0
golang.org/x/mod v0.12.0
golang.org/x/sys v0.11.0
Expand All @@ -25,13 +26,13 @@ require (
)

require (
github.com/cpuguy83/go-md2man/v2 v2.0.2 // indirect
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/facebookgo/clock v0.0.0-20150410010913-600d898af40a // indirect
github.com/gogo/googleapis v1.4.1 // indirect
github.com/gogo/protobuf v1.3.2 // indirect
github.com/gogo/status v1.1.1 // indirect
github.com/golang/mock v1.6.0 // indirect
github.com/golang/protobuf v1.5.3 // indirect
github.com/google/uuid v1.3.1 // indirect
github.com/grpc-ecosystem/go-grpc-middleware v1.4.0 // indirect
github.com/grpc-ecosystem/grpc-gateway v1.16.0 // indirect
Expand All @@ -40,10 +41,19 @@ require (
github.com/pborman/uuid v1.2.1 // indirect
github.com/pmezard/go-difflib v1.0.0 // indirect
github.com/robfig/cron v1.2.0 // indirect
github.com/russross/blackfriday/v2 v2.1.0 // indirect
github.com/stretchr/objx v0.5.1 // indirect
github.com/temporalio/features/features v1.0.0 // indirect
github.com/temporalio/features/harness/go v1.0.0 // indirect
github.com/twmb/murmur3 v1.1.8 // indirect
github.com/uber-go/tally/v4 v4.1.7 // indirect
github.com/urfave/cli/v2 v2.25.7 // indirect
github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 // indirect
go.temporal.io/sdk/contrib/tally v0.2.0 // indirect
go.uber.org/atomic v1.11.0 // indirect
go.uber.org/multierr v1.11.0 // indirect
golang.org/x/net v0.14.0 // indirect
golang.org/x/sync v0.5.0 // indirect
golang.org/x/text v0.12.0 // indirect
golang.org/x/time v0.3.0 // indirect
google.golang.org/genproto v0.0.0-20230822172742-b8732ec3820d // indirect
Expand All @@ -57,6 +67,6 @@ require (
// This is dumb, but necesary because Go (for some commands) can't figure out the transitive
// local-replace inside of the features module itself, so we have to help it.
replace (
github.com/temporalio/features/features => github.com/temporalio/features/features v0.0.0-20230825203822-22c291e343bd
github.com/temporalio/features/harness/go => github.com/temporalio/features/harness/go v0.0.0-20230825203822-22c291e343bd
github.com/temporalio/features/features => github.com/temporalio/features/features v0.0.0-20231117211247-ca7959c1fe2c
github.com/temporalio/features/harness/go => github.com/temporalio/features/harness/go v0.0.0-20231117211247-ca7959c1fe2c
)
Loading

0 comments on commit 4ebaa81

Please sign in to comment.