Gmail Calendar Documents Reader Web more »
Recently Visited Groups | Help | Sign in
Google Groups Home
Delayed Deltas
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  3 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Pat Allan  
View profile  
 More options Jan 2, 1:05 pm
From: Pat Allan <p...@freelancing-gods.com>
Date: Sat, 3 Jan 2009 01:05:46 +0700
Local: Fri, Jan 2 2009 1:05 pm
Subject: Delayed Deltas
Well, it's been a long time coming, but there's finally support for  
delayed deltas, using delayed_job (fittingly). It is an internal copy  
of dj, and I've not tested it with apps that also use the dj plugin,  
but it should play nicely. Please do test, though.

How to make it work?

In your define_index block:
set_property :delta => :delayed

To get the background task running:
rake thinking_sphinx:delta
or
rake ts:delta

I'm not convinced about the task name, so you're warned it may change  
(especially when deltas-by-timestamps is added - soon!).

I've tested it on various Rails versions (including 1.2.6), and as far  
as I can tell, it works as it should. I've added cucumber features to  
test it too, so I'm pretty happy with how it runs. That said, would  
appreciate hearing how it works for everyone else :)

Get the code from Github:
http://github.com/freelancing-god/thinking-sphinx/tree/master

Enjoy

--
Pat
e: p...@freelancing-gods.com    || m: +614 1327 3337
w: http://freelancing-gods.com || t: twitter.com/pat
discworld: http://ausdwcon.org || skype: patallan


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Pat Allan  
View profile  
 More options Jan 2, 10:11 pm
From: Pat Allan <p...@freelancing-gods.com>
Date: Sat, 3 Jan 2009 10:11:46 +0700
Local: Fri, Jan 2 2009 10:11 pm
Subject: Re: [ts] Delayed Deltas
Oh, and the other step - not a problem for those already using  
delayed_job - is to create the delayed_jobs table:

create_table :delayed_jobs, :force => true do |table|
   table.integer  :priority, :default => 0
   table.integer  :attempts, :default => 0
   table.text     :handler
   table.string   :last_error
   table.datetime :run_at
   table.datetime :locked_at
   table.datetime :failed_at
   table.string   :locked_by
   table.timestamps
end

Cheers

--
Pat

On 03/01/2009, at 1:05 AM, Pat Allan wrote:


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Pat Allan  
View profile  
 More options Jan 3, 9:40 am
From: Pat Allan <p...@freelancing-gods.com>
Date: Sat, 3 Jan 2009 21:40:54 +0700
Local: Sat, Jan 3 2009 9:40 am
Subject: Re: [ts] Re: Delayed Deltas
Okay, I changed the name of the rake task:

rake thinking_sphinx:delayed_delta
rake ts:dd

Of course, if you're already using delayed_job, the delta requests  
will get processed by the normal queue task.

--
Pat

On 03/01/2009, at 10:11 AM, Pat Allan wrote:


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »

Create a group - Google Groups - Google Home - Terms of Service - Privacy Policy
©2009 Google