7 ms·
Ruby 2.2.0 Released
- deleted 12y ago[deleted]
- briandear 12y agoNo static typing? Lol. Merry Christmas ruby devs!
- mrmondo 12y agoGreat work to the ruby team, the improvements in Ruby's performance since 2.x have been very impressive to say the least. Well done and Merry Christmas to everyone that worked hard on this release.
- kawsper 12y agoIndeed, by upgrading Ruby from 1.9.3 to 2.1.2 we cut the time spent running our specs in half for our Rails project.
- mrmondo 12y agoThat's really impressive!
- briandear 12y agoYou should get another boost with 2.2. This release is much faster, I've noticed.
- ch4s3 12y agoI just popped off a branch of my production Rails 4.1.8 app (Can't quite do 4.2 yet), and upgraded it 2 Ruby 2.2. I ran 271 spec against it 5 times before the upgrade and 16 times after. I should have done more before :( For 2.1.5 AVG: 18.02 MEDIAN: 18.11 MIN: 16.26 MAX: 19.6 For 2.2 AVG: 18.162~ MEDIAN: 15.23 MIN: 14.44 <- nice MAX: 47.03 <- first run, wut? It looks better, but I haven't profiled the app on Passenger yet to see how well it plays with the whole app.
- claudiug 12y agonice! Hope that version 3 will add jit :)
- blacktulip 12y agoGreat work. Thanks for the Christmas gift. btw: anyone else thinks Rails was mentioned too much in the release note?
- danmaz74 12y agoYes I also thought the same thing... on the other hand, it shows dedication to the most important driver of Ruby adoption.
- Argorak 12y agoI'm not sure, most of my Ruby jobs are puppet and chef nowadays.
- Jgrubb 12y agoI promise that puppet and chef are not how the majority of people first hear of Ruby.
- Argorak 12y agoThat really depends on your field of work. For web developers, maybe not, for admins: yes. Also, they might not be the thing people hear about first, but they are still heavily driving actual adoption. (FWIW: I'm chair member of the largest european Ruby non-profit, I speak to a lot of newcomers ;))
- kyllo 12y agoThat's changing. I work at a Fortune 500 company that's strictly a Java shop and will probably never use Rails. Hardly anyone there has even heard of it. But we are using Chef to configure Red Hat VMs and deploy app builds.
- briandear 12y agoRails was mentioned once, unless I missed something.
- hit8run 12y agoRuby seems to continuously move forward. Great to see that they manage to keep this project alive without a python 2vs3 disaster.
- hackerboos 12y agoThat's what happens when you maintain two versions, one of which has fundamental breaking changes. When the Ruby team makes changes the attitude is generally 'deal with it'. Sure they still do point releases on older versions but only for security issues AFAIK. Python moves forward it just does a poor job of dragging everyone with it.
- dagw 12y agoWhen the Ruby team makes changes the attitude is generally 'deal with it' However they complement this attitude by being a lot better at working with big 3rd party library developers and making sure they are on board. To the best of knowledge there has never been a Ruby release that was incompatible with RoR for any period of time. Compare to Python that jumped to python 3 without either numpy or Django on board.
- reledi 12y agoSounds about right. Coming from a Python background to Ruby, I think there's more to it though. For example, Ruby version managers such as rvm and rbenv help a lot with keeping the community moving forward. Python has virtualenv but it always felt awkward to me compared to what Ruby has.
- current_call 12y agoIt's a bit weird that symbols are garbage collected. I wouldn't think it could delete them without making the same symbols unequal some of the time.
- Argorak 12y agoThey are only garbage collected if they were introduced at runtime and there is no reference to them anymore. (detailed explanations can be found in the presentation linked in the announcement) This allows you to symbolize external hash keys without fear of a DOS attack.
- al2o3cr 12y agoThey're only going to get GCed if there aren't any references to them (like everything else) - so the comparison you're talking about is impossible. If you can still compare the symbol to something, it hasn't been GCed...
- rab_oof 12y agoInteresting: vfork support. Vfork in most older systems is like fork except it doesn't deeply duplicate all process state immediately (file handles, memory, such), so it can be faster if all the app wants to do is fork/exec. (We had to implement both fork and vfork in minix 2.x in uni.^) But according to SO, most OSes implement fork lazily, so there's not much point in using it when fork will be just as fast without any change. If there were a slowly-performing platform that has a specific performance issue identified by profiling as caused by fork, then mature optimization could follow. Otherwise, it seems like adding LoC without a clear goal. The Symbol GC sounds good. Maybe this will imply code can associated with classes and modules can be GCed and required anew once all objects are freed (live upgrade apps without restarts). ^ The first thing I did to the Minix codebase was set keyboard repeat rate to the fastest possible values. Everyone else seemed content to waste their life waiting for their editor and debugger to move at a snail's pace. Of course, no else had x86 asm / pc hw io experience.
- jordanthoms 12y agoCopy-on-write fork is much faster than copying everything, but there is still some overhead setting up the copy-on-write state and dealing with the first writes afterwards, I think in cases where you have large amounts of memory vfork can still be useful.
- rab_oof 12y agoThe point isn't to prematurely optimize for edge-cases, but to tackle real, "hair-on-fire" performance bottlenecks head-on. If that means asking large-scale users to run profiling and getting stats of what's using tons of memory, slowing things down, duplicating work or wasting IOPS, go for it. If it's a dubious return/ effort at the expense of complexity, it might not be worth the investment. For example, 'FooBarWidget @ Passenger 5 "Raptor" is a well-crafted, thoughtful achievement in terms of app servers. 2.2 Symbol GC also sounds great. I'm just not convinced there is enough innovation to make Ruby an order-of-magnitude faster, use less memory / return memory back to the system.
- deleted 12y ago[deleted]
- deleted 12y ago[deleted]
- deleted 12y ago[deleted]
- deleted 12y ago[deleted]
- arikrak 12y agoAnyone know how Ruby 2.2 works with Rails on Heroku (with unicorn)? When I switched from 2.0 to 2.1, it caused all sorts of memory problems so I had to switch back.
- joshdotsmith 12y agoRuby 2.2 is available on Heroku https://devcenter.heroku.com/changelog-items/574 https://devcenter.heroku.com/changelog-items/574 As for performance, I think we'll have to wait to hear from adventurous souls who use this, or who have been using the rc's. Hopefully you've been using New Relic and can see how memory usage on your dynos changes.
- pomartel 12y agoI gave Ruby 2.2 a try with Rails 4.2 and the same memory problems that plagued Ruby 2.1 also occurred. I am switching back to Ruby 2.0. Rails 5 will require Ruby 2.2 and higher so I hope someone will find a way to fix this.
- arikrak 12y agoThanks for your answer (here and on SO). I guess I'll wait it out...
- joshdotsmith 12y agoFor rvm users, remember to run rvm get stable before trying to rvm install ruby-2.2.0 You might end up getting preview1 unexpectedly.
- jayroh 12y agoTo the people who maintain the tools and platforms around these large version updates - thank you. rvm, ruby-build, homebrew, heroku - you're all truly generous for having everything ready for us almost immediately (on Christmas morning no less). You're all wonderful- merry Christmas! <3
- Artemis2 12y agoWell, I wouldn't say that Heroku does that out of generosity, but their free tier is pure gold.
- jayroh 12y agoThey certainly didn't have to get the support for 2.2.0 out on Christmas morning, but they (actually, Terence) did. https://twitter.com/hone02/status/548131759762968576 https://twitter.com/hone02/status/548131759762968576 Although with Matz an employee I'm sure they were well ahead of the curve. ;)
- jayroh 12y agoTo the people who maintain the tools and platforms around these large version updates - thank you. rvm, ruby-build, homebrew, heroku - you're all truly generous for having everything ready for us almost immediately (on Christmas morning no less). You're all wonderful- merry Christmas! <3
- xfalcox 12y agoGuys, I made a very simple pull request regarding auto proxy detection on the standard library of ruby, but it still open after a little while. Someone here have some directions on how to contribute correctly to the project?
- shadeslayer 12y agoI contributed a small patch earlier this month, but used their bug tracker to submit patch, turn around time was ~24 hours I think. See bugs.ruby-lang.org/issues/10551 So I think all of their patches need to go through the bug tracker.
- xfalcox 12y agoThank you! Just submitted it at https://bugs.ruby-lang.org/issues/10652 https://bugs.ruby-lang.org/issues/10652 Hope it helps!
- calineczka 12y agoI have problem installing on ubuntu 12.04 : https://gist.github.com/paneq/fee5477fb7ab1ede0104 https://gist.github.com/paneq/fee5477fb7ab1ede0104 . Did any of you experienced that as well?
- elektronaut 12y agoYes, and on 14.04 as well. Try installing the libffi-dev package.
- cmelbye 12y agoNot compatible with Rails 3.2.x, for those still on that version. (And possibly will never be, as 3.2.x only receives security updates now.)
- grandalf 12y agoWhat is the nature of the incompatibility?
- cmelbye 12y agoOne change is that test/unit is now no longer part of the standard library, which Rails requires. The workaround is simple, "test-unit" must be added to the Gemfile. A less easily fixed change is that the following syntax no longer works the same as it did in previous versions of Ruby: def foo(bar = bar) The recommended fix is the following: (I believe) def foo(bar = bar()) Rails uses this syntax occasionally. It's simple to change, but the Rails team refuses to merge in the fixes because it's not a security issue.
- grandalf 12y agoWow that's too bad. Do you know if the Rails team would approve a patch that was submitted? Also, the change of the meaning of the right bar in your example above seems significant. Do you happen to know of any context for that change?
- ehsanu1 12y agoIn case you weren't aware: https://github.com/rails/rails/pull/18160 https://github.com/rails/rails/pull/18160
- andersonmvd 12y agoThe download URL should be HTTPS, but at least they informed the digests.