← Back to team overview

nova team mailing list archive

Re: Twisted or Eventlet?

 

Hi Gustavo,

On Wed, Aug 4, 2010 at 2:35 PM, Gustavo Niemeyer <
gustavo.niemeyer@xxxxxxxxxxxxx> wrote:

> > As hazmat points out in the "twisted v. eventlet" thread, you can't use
> pdb
> > with Twisted, while pdb works just as you'd hope in Eventlet.
>
> This seems a bit of a strong statement.  I use pdb with twisted all the
> time.
>

Ah, pardon me!  I took that from hazmat's statement:
">  In twisted pdb is fairly useless, in that any stack trace is shallow to
the reactor across a deferred. "

If I understand that correctly, you can't see the full "stack trace" down
your callback chain, which makes sense since the reactor is doing the
calling of callbacks.  He said that eventlet keeps the stack trace in a
greenlet and pdb can look all the way down.

I should have stayed with his "fairly useless" quote instead of jumping to
conclusions.


>
> > hazmat's experience during his lightning talk (see the same thread) is a
> > good datapoint verifying that people unfamiliar with either project will
> > probably prefer to work with Eventlet over Twisted: good for recruiting.
>
> I can safely argue that there many more Twisted programmers in the
> market than Eventlet ones.
>

Granted.  The lower number of Eventlet programmers is a con, while being
able to offer people the chance to work on a newer technology is a pro.


>
> > It's a weaker argument, but it's really hard to find any comparisons
> between
> > Twisted and Eventlet on the web that say Twisted is preferable (has
> anyone
> > found any?)
>
> This doesn't look like a motivator.  I could argue that you're not
> seeing comparisons because no one uses eventlet, for instance. :-)
>

I don't buy that argument -- if no one uses eventlet then we wouldn't see
any comparisons at all! :)  If Eventlet didn't succeed at solving the same
problem that Twisted solves (in a better way), surely there would be some
posts out there saying "Our project uses Twisted, I heard about Eventlet, I
did a comparison, and here's why we're sticking with Twisted."


> > And as always, there's the argument that Eventlet code is easier to read
> and
> > understand, and therefore to maintain.
> > I'm going to be working on adding the RS API to Nova, and I'm going to
> > proceed in Eventlet.  If anyone feels strongly that we must use Twisted
> > instead, speak up; otherwise, shall we call this decision made?
>
> I'm not actually arguing either way, but if I had to make this
> decision, I'd have a slightly more even comparison between eventlet
> and twisted.  Twisted is stable, well known, has several maintainers,
> and *many* users.  Canonical, Google, Apple, ITA, and many many other
> use Twisted.  You can trust on it being around and well maintained in
> the foreseeable future.
>
> With that in mind, I'd take some additional time discussing the pros
> and cons on both sides, including technical approaches to use them,
> maintenance cost, and so on, before making a big long term commitment.
>

Thank you for speaking up :)

We've spent a week discussing pros and cons, so maybe the next logical step
would be to go do an experiment to get some actual data.  I'll be making an
Eventlet based API Endpoint; if someone wanted to make a Twisted one, we
could then do a review to compare performance, simplicity, maintenance cost,
and any other metric we could think of.  Making both versions public might
even help out other projects that are facing the same situation we are --
others could then review what we made and make their own decisions.  Would
you be interested in building the Twisted version?

Michael


Confidentiality Notice: This e-mail message (including any attached or
embedded documents) is intended for the exclusive and confidential use of the
individual or entity to which this message is addressed, and unless otherwise
expressly indicated, is confidential and privileged information of Rackspace.
Any dissemination, distribution or copying of the enclosed material is prohibited.
If you receive this transmission in error, please notify us immediately by e-mail
at abuse@xxxxxxxxxxxxx, and delete the original message.
Your cooperation is appreciated.


Follow ups

References