Discussion
Loading...

Post

Log in
  • About
  • Code of conduct
  • Privacy
  • Users
  • Instances
  • About Bonfire
Tyler A. Young 🧑🏻‍💻⚗️
Tyler A. Young 🧑🏻‍💻⚗️
@tylerayoung@fosstodon.org  ·  activity timestamp last week

I'm on a mission to find every Enum.each/2 in the tooling I use and replace it with Task.async_stream/2 😁

https://github.com/nccgroup/sobelow/pull/184/changes#diff-6a33dd30a8a2814c6f96844ab94d04cccda6059424ab7ca5d813ad57db7db3b6

#ElixirLang

  • Copy link
  • Flag this post
  • Block
Jan vom Sesamzoo
Jan vom Sesamzoo
@sesamzoo@mastodon.social replied  ·  activity timestamp last week

@tylerayoung thank you for sharing. Looking forward to see its effect in my project.
I’m just a bit confused after I saw this issue:
“[...] the two maintainers no longer work at NCC Group and due to organization policies, we were inexplicably removed from maintaining this repo with no path forward to continue work here. So we have decided to fork the repo in an organization we actually can manage.”
https://github.com/nccgroup/sobelow/issues/182
Were you aware of that?

Your PR still got feedback from one of them.

  • Copy link
  • Flag this comment
  • Block
Tyler A. Young 🧑🏻‍💻⚗️
Tyler A. Young 🧑🏻‍💻⚗️
@tylerayoung@fosstodon.org replied  ·  activity timestamp last week

@sesamzoo Oh! I did not know this... uh... huh. Yeah, I definitely opened the PR against the wrong one.

  • Copy link
  • Flag this comment
  • Block
J3RN :emacs: :haskell:
J3RN :emacs: :haskell:
@j3rn@fosstodon.org replied  ·  activity timestamp last week

@tylerayoung I believe, like with Stream.each, that you have to get above a certain quantity of data or complexity of operation before you see performance benefits from the change.

  • Copy link
  • Flag this comment
  • Block
Jan vom Sesamzoo
Jan vom Sesamzoo
@sesamzoo@mastodon.social replied  ·  activity timestamp last week

@j3rn Yes, there’s an overhead for Stream module’s functions. The PR is not (mainly) about replacing Lists by Streams, though. It’s about the "async_“ part, i.e. applying the function concurrently instead of sequentially to each of the Enumerable’s elements. Also with overhead but @tylerayoung shared the performance improvements (runtime) he measured in his project, too.

  • Copy link
  • Flag this comment
  • Block
Tyler A. Young 🧑🏻‍💻⚗️
Tyler A. Young 🧑🏻‍💻⚗️
@tylerayoung@fosstodon.org replied  ·  activity timestamp last week

@sesamzoo @j3rn Yeah, I exaggerate when I say “every.” Mostly I’m just finding that a lot of tools have like a top-level collection of independent tasks that they run on the codebase, and they can be pretty trivially parallelized.

  • Copy link
  • Flag this comment
  • Block

bonfire.cafe

A space for Bonfire maintainers and contributors to communicate

bonfire.cafe: About · Code of conduct · Privacy · Users · Instances
Bonfire social · 1.0.1-beta.35 no JS en
Automatic federation enabled
Log in
  • Explore
  • About
  • Members
  • Code of Conduct