I am so happy that Github have hired Tenderlove to go nuts with these type of projects. His talks are always extremely fun and interesting. I run Ruby with jemalloc, and I know that samsaffron have tried to include it within the Ruby releases (like Redis does), but progress seems to have been stalled https://bugs.ruby-lang.org/issues/9113
Reducing Memory Usage in Ruby
31–40 of 58 posts
Re: Reducing Memory Usage in Ruby
#32Earlier quoted context omitted.
You can do all of that with really easy to write crystal macros.
You can dynamically build at runtime an HTTP client from an OpenAPI spec (unavailable until runtime, to be clear), method-by-method, using macros? Tell me more.
You can build your code at runtime from the spec and then compile it at runtime to get pretty good performance.
Re: Reducing Memory Usage in Ruby
#33Ruby seems to have a footprint on Hacker News disproportionate to its general popularity and TIOBE index. Why?
Re: Reducing Memory Usage in Ruby
#34Ruby seems to have a footprint on Hacker News disproportionate to its general popularity and TIOBE index. Why?
It also has an amazing testing framework in the form of rspec, which can be used for much more than just testing Ruby code.
Re: Reducing Memory Usage in Ruby
#35Earlier quoted context omitted.
You can dynamically build at runtime an HTTP client from an OpenAPI spec (unavailable until runtime, to be clear), method-by-method, using macros? Tell me more.
Although it probably does not fit your use case something like Common Lisp would shine in a situation like this. You can build your code at runtime from the spec and then compile it at runtime to get pretty good performance.
Re: Reducing Memory Usage in Ruby
#36Ruby seems to have a footprint on Hacker News disproportionate to its general popularity and TIOBE index. Why?
TIOBE index is a junk metric (I'm surprised so many technical people seem to buy into it; it's the worst kind of easy to get a precise number, hard to demonstrate that that number has any more than a very distant relationship to anything meaningful, kind of metric that, IME, tech people mock bad managers for buying into.)
That said, Ruby’s got (via Rails and other web frameworks, and via various testing and admin tools) a very strong footprint in use even if it's no longer the hype-of-the-month.
Re: Reducing Memory Usage in Ruby
#37Ruby seems to have a footprint on Hacker News disproportionate to its general popularity and TIOBE index. Why?
Not only due to the popularity of Rails, Ruby has become popular for sysadmins as config management solutions such as puppet and chef are built on top of it. The resulting syntax is very ruby like, and in some cases you are even required to write a few ruby blocks here and there. It also has an amazing testing framework in the form of rspec, which can be used for much more than just testing Ruby code.
Re: Reducing Memory Usage in Ruby
#38Ruby seems to have a footprint on Hacker News disproportionate to its general popularity and TIOBE index. Why?
TIOBE has it's issues but as a rough guide to what the industry is actually using I think it's in the ballpark.
Re: Reducing Memory Usage in Ruby
#39Earlier quoted context omitted.
Got me there. First time I've ever in my life heard of a legitimate example where you really do need dynamic methods.
If you're doing stuff with OpenAPI (as I've been doing over the last few weeks), it becomes a pressing thing. =( Generated clients usually are pretty awful, you usually have to generate your own (because they don't publish gems when their APIs change, which is why I've written online-generated ones!), and once you've completed the bootstrap process for an HTTP client, it's as fast as any other Ruby thing. Which is no…
https://github.com/amberframework/granite-orm https://github.com/sam0x17/crystal-mongo-orm
Re: Reducing Memory Usage in Ruby
#40Earlier quoted context omitted.
Exactly. As a Ruby developer, Crystal makes me itch . It jettisons exactly what Ruby is valuable to me for: quickly and dynamically building fluent-feeling libraries and tools. It's fast, but I don't need fast--if I don't need Ruby's metaprogramming, I have other, better, established languages to use for those tasks. (Kotlin, C#, Rust, whatever.) Elixir is kind-of in the same boat for me. I think it's neat and has it…
Have you used a recent (2017) version of Crystal? Quickly building fluent-feeling libraries and tools is exactly my use case for Crystal. For me, everything that Ruby is valuable for is retained. I'm able to do all the things I did in Ruby just fine, and it prevents me from doing a lot of things I shouldn't have been doing. We recently migrated our app from Rails to Crystal (using the Amber framework) and our code ba…