components-contrib icon indicating copy to clipboard operation
components-contrib copied to clipboard

Initial creation of workflows building block

Open RyanLettieri opened this issue 2 years ago • 5 comments

Signed-off-by: Ryan Lettieri [email protected]

Description

Initial Creation of the workflows building block using temporal

Note that due to a merge issue and git confusion, there are a very large amount of go.sum and go.mod files in the "tests" directory edited in this PR. Those can be ignored

Issue reference

We strive to have all PR being opened based on an issue, where the problem or feature have been discussed prior to implementation.

Related Proposal: https://github.com/dapr/dapr/issues/4576

Checklist

Please make sure you've completed the relevant tasks for this PR, out of the following list:

  • [ ] Code compiles correctly
  • [ ] Created/updated tests
  • [ ] Extended the documentation / Created issue in the https://github.com/dapr/docs/ repo: dapr/docs#[issue number]

RyanLettieri avatar Aug 08 '22 21:08 RyanLettieri

Adding the do-not-merge label to make sure no maintainer merges this before the 1.9 release.

berndverst avatar Aug 09 '22 16:08 berndverst

/ok-to-test

RyanLettieri avatar Sep 12 '22 23:09 RyanLettieri

Codecov Report

Merging #1941 (b3e90c2) into master (a20a2b2) will increase coverage by 0.06%. The diff coverage is 0.00%.

@@            Coverage Diff             @@
##           master    #1941      +/-   ##
==========================================
+ Coverage   37.92%   37.98%   +0.06%     
==========================================
  Files         193      193              
  Lines       24566    24584      +18     
==========================================
+ Hits         9316     9338      +22     
+ Misses      14538    14529       -9     
- Partials      712      717       +5     
Impacted Files Coverage Δ
tests/conformance/common.go 16.90% <0.00%> (-0.91%) :arrow_down:
configuration/azure/appconfig/appconfig.go 73.93% <0.00%> (+9.40%) :arrow_up:

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

codecov[bot] avatar Sep 13 '22 15:09 codecov[bot]

/ok-to-test

berndverst avatar Sep 14 '22 20:09 berndverst

Conformance: https://github.com/dapr/components-contrib/actions/runs/3055926528 Certification: https://github.com/dapr/components-contrib/actions/runs/3055926532

berndverst avatar Sep 14 '22 20:09 berndverst

This PR is being held open until the end of 1.9 in-case there're some hidden broken changes. Furthermore, since the API changes are not pushed into master, this isn't a strong need to have this merged into 1.9 The PR will be updated with the latest changes from master to ensure that it is not out of date. Once the code-freeze for 1.9 is complete, this can be merged into 1.10

RyanLettieri avatar Sep 22 '22 17:09 RyanLettieri

/ok-to-test

RyanLettieri avatar Oct 12 '22 22:10 RyanLettieri

Components conformance test

🔗 Link to Action run

Commit ref: 8d5405fcf9ee7835c8a7ca77f24f7779a77b70cd

✅ All conformance tests passed

All tests have reported a successful status

dapr-bot avatar Oct 12 '22 22:10 dapr-bot

Components certification test

🔗 Link to Action run

Commit ref: 8d5405fcf9ee7835c8a7ca77f24f7779a77b70cd

❌ Some certification tests failed

These tests failed:

  • bindings.azure.eventhubs

dapr-bot avatar Oct 12 '22 22:10 dapr-bot

/ok-to-test

RyanLettieri avatar Oct 13 '22 15:10 RyanLettieri

Components certification test

🔗 Link to Action run

Commit ref: 3a26c43127b1a86fa773cce15e4550dd4fdeadee

✅ All certification tests passed

All tests have reported a successful status

dapr-bot avatar Oct 13 '22 15:10 dapr-bot

Components conformance test

🔗 Link to Action run

Commit ref: 3a26c43127b1a86fa773cce15e4550dd4fdeadee

✅ All conformance tests passed

All tests have reported a successful status

dapr-bot avatar Oct 13 '22 15:10 dapr-bot

I'll merge once @cgillum can do another quick check and give an approval.

berndverst avatar Oct 24 '22 19:10 berndverst

I noticed there's a binary in this PR under /.github/infrastructure/conformance/temporal/worker named worker. Is that supposed to be checked into GitHub?

The worker binary definitely needs to be removed @RyanLettieri. Seems your Docker container builds the binary from the source file anyway.

berndverst avatar Oct 24 '22 21:10 berndverst

I was able to verify the workflow locally with:

docker-compose -f ./.github/infrastructure/docker-compose-temporal.yml -p temporal up -d
go test -v -tags=conftests -count=1 ./tests/conformance -run="TestWorkflowsConformance/temporal"
=== RUN   TestWorkflowsConformance
=== RUN   TestWorkflowsConformance/temporal
=== RUN   TestWorkflowsConformance/temporal/init
time="2022-10-27T12:34:28.51554-07:00" level=debug msg="Temporal init start" instance=Bernds-MacBook-Pro.local scope=testLogger type=log ver=unknown
2022/10/27 12:34:28 INFO  No logger configured for temporal client. Created default one.
=== RUN   TestWorkflowsConformance/temporal/start
time="2022-10-27T12:34:28.526645-07:00" level=info msg="Start test running..." instance=Bernds-MacBook-Pro.local scope=workflowsTest type=log ver=unknown
time="2022-10-27T12:34:28.526677-07:00" level=debug msg="starting workflow" instance=Bernds-MacBook-Pro.local scope=testLogger type=log ver=unknown
time="2022-10-27T12:34:28.540806-07:00" level=debug msg="getting workflow data" instance=Bernds-MacBook-Pro.local scope=testLogger type=log ver=unknown
time="2022-10-27T12:34:33.546585-07:00" level=debug msg="getting workflow data" instance=Bernds-MacBook-Pro.local scope=testLogger type=log ver=unknown
time="2022-10-27T12:34:33.55706-07:00" level=debug msg="terminating workflow" instance=Bernds-MacBook-Pro.local scope=testLogger type=log ver=unknown
time="2022-10-27T12:34:33.576683-07:00" level=debug msg="getting workflow data" instance=Bernds-MacBook-Pro.local scope=testLogger type=log ver=unknown
time="2022-10-27T12:34:33.585117-07:00" level=info msg="Start test done." instance=Bernds-MacBook-Pro.local scope=workflowsTest type=log ver=unknown
--- PASS: TestWorkflowsConformance (5.07s)
    --- PASS: TestWorkflowsConformance/temporal (5.07s)
        --- PASS: TestWorkflowsConformance/temporal/init (0.01s)
        --- PASS: TestWorkflowsConformance/temporal/start (5.06s)
PASS
ok  	github.com/dapr/components-contrib/tests/conformance	5.112s

berndverst avatar Oct 27 '22 19:10 berndverst

@RyanLettieri please open a Docs issue to create the new Workfows section in the Docs, and then list the temporal component as Alpha (due to the fact the building block is Alpha)

berndverst avatar Oct 27 '22 20:10 berndverst

@RyanLettieri please open a Docs issue to create the new Workfows section in the Docs, and then list the temporal component as Alpha (due to the fact the building block is Alpha)

@berndverst would this previously created issue suffice: https://github.com/dapr/docs/issues/2798 ?

RyanLettieri avatar Oct 27 '22 22:10 RyanLettieri