Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make more use of async/await #305

Merged
merged 8 commits into from Dec 31, 2019
Merged

Make more use of async/await #305

merged 8 commits into from Dec 31, 2019

Conversation

@thomaseizinger
Copy link
Member

thomaseizinger commented Dec 30, 2019

This PR makes better use of async/await inside CCA.

By relying on tokio 0.2 and tokio-compat, we can remove the dependency on async-std and signal-hook.

With this, we also now gain the possibility of cancelling the startup at any time and not just between the individual services.

Fixes #254. (When #254 was created, tokio-compat did not yet exist, hence it was blocked by shiplift transitioning to tokio 0.2)

@thomaseizinger thomaseizinger requested review from D4nte, da-kami and luckysori Dec 30, 2019
@thomaseizinger thomaseizinger self-assigned this Dec 30, 2019
@mergify

This comment has been minimized.

Copy link
Contributor

mergify bot commented Dec 30, 2019

Are you sure the changelog does not need updating?

@thomaseizinger thomaseizinger force-pushed the go-async branch 2 times, most recently from 8eadba0 to 688b2b5 Dec 30, 2019
@D4nte
D4nte approved these changes Dec 30, 2019
Copy link
Member

D4nte left a comment

Cool. I think the comments are worth doing.

@@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Upgrade all examples and new project to `comit-sdk@0.8.0`.
- To create new project, `new` is not needed in arguments anymore: `yarn create comit-app foo`.
- New binary `comit-scripts` to access other create-comit-app features. E.g.: `comit-scripts start-env`.
- Pressing CTRL+C while `start-env` is running is now handled immediately and not just after the current service is fully started.

This comment has been minimized.

Copy link
@D4nte

D4nte Dec 30, 2019

Member

Mention that we do not clean after a panic anymore.

Cargo.toml Outdated Show resolved Hide resolved
build.rs Show resolved Hide resolved
src/env/mod.rs Show resolved Hide resolved
This forces use to drop the compression of the archive that is
included in the binary. Since we only include the source files,
this archive is only 400kb big so no big deal.
- We no longer need to kill the example, 108 is resolved.
- We need to send SIGINT instead of SIGTERM to CCA for it exit with 0.
@thomaseizinger

This comment has been minimized.

Copy link
Member Author

thomaseizinger commented Dec 31, 2019

bors r+

bors bot added a commit that referenced this pull request Dec 31, 2019
Merge #305
305: Make more use of async/await r=thomaseizinger a=thomaseizinger

This PR makes better use of async/await inside CCA.

By relying on tokio 0.2 and tokio-compat, we can remove the dependency on async-std and signal-hook.

With this, we also now gain the possibility of cancelling the startup _at any time_ and not just between the individual services.

Fixes #254. (When #254 was created, `tokio-compat` did not yet exist, hence it was blocked by shiplift transitioning to tokio 0.2)

Co-authored-by: Thomas Eizinger <thomas@eizinger.io>
@bors

This comment has been minimized.

Copy link
Contributor

bors bot commented Dec 31, 2019

Build succeeded

And happy new year from bors! 🎉

  • build (macos)
  • build (ubuntu)
  • build (windows)
  • e2e_test
  • static_analysis
@bors bors bot merged commit cab22b4 into master Dec 31, 2019
9 checks passed
9 checks passed
static_analysis
Details
build (macos)
Details
build (windows)
Details
build (ubuntu)
Details
npm_build
Details
e2e_test
Details
Summary 1 rule matches and 1 potential rule
Details
bors Build succeeded
Details
license/cla Contributor License Agreement is signed.
Details
@mergify mergify bot deleted the go-async branch Dec 31, 2019
@thomaseizinger

This comment has been minimized.

Copy link
Member Author

thomaseizinger commented Dec 31, 2019

Happy new year to you too @bors! 🎉

D4nte added a commit that referenced this pull request Jan 2, 2020
D4nte added a commit that referenced this pull request Jan 2, 2020
@D4nte D4nte mentioned this pull request Jan 2, 2020
bors bot added a commit that referenced this pull request Jan 2, 2020
Merge #309
309: Follow-up 305 r=mergify[bot] a=D4nte

Implement comments I made on #305

Co-authored-by: Franck Royer <franck@coblox.tech>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.