Victor
Victor

Reputation: 13378

Is this a better way to index with Thinking Sphinx?

There has been a post about setting cron job to index: Use a Cron Job to Automate Sphinx Index Refresh from Rails Rake Task

The author shares the same technique to invoke the indexer through Thinking Sphinx. But in the comment, there is a second method shared, which claimed to be better in easing the server load by calling the indexer directly from Sphinx:

Call the sphinx indexer directly, also eases the load (you don’t need to fire up rails), eg:

/usr/local/bin/indexer –config /data/releases/site/current/config/production.sphinx.conf –all –rotate

Wondering if this is actuall a better option...

Upvotes: 1

Views: 159

Answers (1)

James Healy
James Healy

Reputation: 15168

I use the direct indexer method in my cron jobs and think it's a better technique.

There's no need to load the full rails stack just to shell out to another process.

Upvotes: 1

Related Questions