Meeting notes: July 6, 2010 -- each, LogSubscriber, Rails 3, BodyParts, database alterations, etc.

조회수 8회
읽지 않은 첫 메시지로 건너뛰기

Igal Koshevoy

읽지 않음,
2010. 7. 7. 오전 3:27:4910. 7. 7.
받는사람 Portland Ruby Brigade
We had a nice, small meeting with lots of good content:

1. Markus Roberts presented a real mind-bender of a Hangman puzzle.

2. Rein Henrichs presented "Each: A Brief History of Iteration", which provided lots of interesting details using iteration and blocks. He posted very complete slides for his talk at: http://reinh-each.heroku.com/

3. Justin George talked about his work on adding Rails 3 support to New Relic RPM (http://newrelic.com/), a plugin that collects performance metrics analytics in Rails and other applications. He discussed changes that make Rails 3 more modular and extensible, including the new LogSubscriber mechanism for efficiently handling logging data: http://guides.rails.info/initialization.html#require-railslog-subscriber

4. Max Ogden presented his new BodyParts gem, which "splits the body of replied email messages into the actual new message and the included reply chain": http://github.com/maxogden/bodyparts

5. Bryan Stearns talked about a system he developed for his Rails application for safely applying and tracking non-migration database changes, e.g., correcting an error which involves loading a set of ActiveRecord instances and making changes to them. An example of a change can be seen at http://gist.github.com/466200 and the transactional wrapper which logs auditing data and checks all objects in the database for validity is at http://gist.github.com/466192 . He was curious to hear how others were coping with this need. Many just applyed these sorts of changes directly from the console to the production database. Some suggesting adding an admin UI for performing these sorts of operations if they happen more than once, e.g., adding a free account, correcting a balance, etc.

6. Justin George explained in detail and with benchmarks why `yield` was more efficient than `to_proc` by ~3x. This isn't a big deal if you're using `to_proc` in something like a `users.map(&:username)` over a few records, but it can get slow if you're processing tens of thousands of records.

7. Max Ogden asked for advise on colorizing arbitrarily nested datastructures, as seen in his blog post at http://maxogden.com/ . Markus Roberts suggested reviewing the work he and Jesse Hallett did on ZAML, a fast YAML serializer, which recursively produces text by walking data structures: http://github.com/hallettj/zaml/blob/master/lib/zaml.rb

And much more.

-igal

Sam Livingston-Gray

읽지 않음,
2010. 7. 7. 오후 12:25:3910. 7. 7.
받는사람 pdx...@googlegroups.com
On Wed, Jul 7, 2010 at 12:27 AM, Igal Koshevoy <ig...@pragmaticraft.com> wrote:
> 2. Rein Henrichs presented "Each: A Brief History of Iteration", which
> provided lots of interesting details using iteration and blocks. He posted
> very complete slides for his talk at: http://reinh-each.heroku.com/

Rein's talk reminded me of something my undergrad advisor introduced
me to: the concept of traits. A trait is a small bundle of methods,
all implemented in terms of some minimum API, that gets composed into
an object using some sort of multiple inheritance. Which sounds
*remarkably* like Enumerable.

This is really interesting stuff that gives you new ways of composing
behaviors in a reusable way.

For those of you with the inclination to wade through an academic
paper or two, here are two links. (Caveat: I read the first one a
few years back, and haven't read the second one at all. I generally
find Andrew's writing accessible, though, so check 'em out if you're
curious.)

1) http://scg.unibe.ch/archive/papers/Scha03aTraits.pdf
2) http://www.cs.pdx.edu/~black/publications/refactoringsACM.pdf

Cheers,
-Sam

Erik Hollensbe

읽지 않음,
2010. 7. 7. 오후 12:33:4310. 7. 7.
받는사람 pdx...@googlegroups.com
Here's an implementation of traits from Ramaze (via Innate, the microframework that powers it):

http://github.com/manveru/innate/blob/master/lib/innate/traited.rb

> --
> You received this message because you are subscribed to the Google Groups "pdxruby" group.
> To post to this group, send email to pdx...@googlegroups.com.
> To unsubscribe from this group, send email to pdxruby+u...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/pdxruby?hl=en.
>

Eric Davis

읽지 않음,
2010. 7. 7. 오후 12:36:2210. 7. 7.
받는사람 pdx...@googlegroups.com
Igal Koshevoy wrote:

> We had a nice, small meeting with lots of good content:

Thanks for the notes Igal, it was an interesting meeting and definitely
added things to my "to try out list".

If you're still going to give your presentation on Rack middleware and
Engines, I'd be happy to look over any notes you have. I've written
more than my fair share of Rails Engines and have found many of the tar
pits (and paved over a few with patterns).

--
Eric Davis
Little Stream Software
Redmine Custom Development and Support Services
http://www.LittleStreamSoftware.com

Jesse Hallett

읽지 않음,
2010. 7. 7. 오후 12:44:2510. 7. 7.
받는사람 pdx...@googlegroups.com
Maybe this is a bit off topic; but there is an interesting
implementation of traits in JavaScript: http://traitsjs.org/

I actually have some slides online on that implementation:
http://docs.google.com/present/view?id=0AcEHtxZZUtqiYWg4OXd6YzhkNjZqXzY4Y2M4OHhjaGg&hl=en

전체답장
작성자에게 답글
전달
새 메시지 0개