Ben Tilly expands:
> On Fri, Apr 5, 2013 at 12:04 PM, John Redford <eire...@hotmail.com> wrote:
> > Your writing is FUD.
> 
> Are you reading something into what I wrote that wasn't there?
> Because I'm pretty sure that what I wrote isn't FUD.

It was. Ask anyone. I'm not your English tutor.

> A pull-based system relies on having the job that does the work ask for
work
> when it's ready.  A push-based system relies on pushing to a worker.

So, let's get this straight, pro.

Any given download client would connect to the database, read its table, and
do the work it finds there.  When it eventually completes the work, it calls
back & reports the results.  The client __PULLS__ its workload.  I am not
sure how you missed this.  In no way does the database server block on the
client.  In no way does Alfie block on the client. Alfie, periodically
checks each downloader's queue tables and ensures that any empty queue gets
filled with work.  It doesn't wait for anything.

So, that seems to be pretty pull-like, which you say you like.  I'll leave
it to you to work out how you misread what I wrote after you work out how
you misread what you wrote.

> What makes you think that I don't know how to use a database?  (Here is a
hint:
> a separate table per downloader is not exactly a best
> practice.)  If you'll note, my first suggestion was to implement polling
on the
> database.  That's because I've been there, done that.
> It works and the database gets better throughput than most people realize
it
> can.  In fact it probably gets more than sufficient for this particular
application.

The fact that you don't recognize how to use it.  And, here, the fact that
you appeal to "best practice" as being in conflict with and overriding
efficient use of the database.

A lot of people will espouse best practices, like "normalize your data" and
"have a single-column primary key", which will indeed generally make sense
most of the time, and which are useful for producing an
aesthetically-pleasing data model.  But the ultimate "best practice" is to
solve the problem and to solve it in a way that functions within acceptable
parameters of cost, performance, support, reliability and so forth. Lots of
so-called "best practices" -- in databases and programming languages --
conflict with efficiency.

For example, consider Duff's Device -- it is the programmatic equivalent of
denormalized data -- it obviously violates some best practices; it's clearly
more difficult to read than a simple loop -- and yet even Perl programmers
have been known to understand the benefits of this technique.

When you understand how to use a database, you will understand how to use it
efficiently.

> (That said, Redis is a good piece of software.  Why are you resistant to
learning
> it?)

See http://en.wikipedia.org/wiki/Loaded_question.



_______________________________________________
Boston-pm mailing list
Boston-pm@mail.pm.org
http://mail.pm.org/mailman/listinfo/boston-pm

Reply via email to