Live data from Hacker News

Turbocharging Solr Index Replication with BitTorrent

codeascraft.etsy.com

1–10 of 14 posts

Re: Turbocharging Solr Index Replication with BitTorrent

#2
Besides being an awesome post on both the business reason for this implementation as well as details on their solution, this is a perfect model for how companies use and contribute to open source software.

Etsy wins, Etsy customers win, and now everyone who uses Solr and ttorrent wins too.

Re: Turbocharging Solr Index Replication with BitTorrent

#5

How does postgresql's search compare to solr? (With postgresql, I think replicating the search index to read-only nodes is a solved problem.)

Well, before Etsy switched to Solr we were using postgres tsearch2, and by the end of that search response times were in the 90 second range. And at the time replication wasn't part of postgres so we had a hacked up buggy in-house replicator.

Re: Turbocharging Solr Index Replication with BitTorrent

#6
post #5

How does postgresql's search compare to solr? (With postgresql, I think replicating the search index to read-only nodes is a solved problem.)

Well, before Etsy switched to Solr we were using postgres tsearch2, and by the end of that search response times were in the 90 second range. And at the time replication wasn't part of postgres so we had a hacked up buggy in-house replicator.

And the results were god-awful

Re: Turbocharging Solr Index Replication with BitTorrent

#7

How does postgresql's search compare to solr? (With postgresql, I think replicating the search index to read-only nodes is a solved problem.)

Depending on your schema, Solr will be much faster than Psql's full text search. Solr's faceted searching is much faster than table JOINs.

But IMHO, the main advantage to use Solr for search instead of Postgres is the query API.

Re: Turbocharging Solr Index Replication with BitTorrent

#8
post #6
post #5

Earlier quoted context omitted.

Well, before Etsy switched to Solr we were using postgres tsearch2, and by the end of that search response times were in the 90 second range. And at the time replication wasn't part of postgres so we had a hacked up buggy in-house replicator.

And the results were god-awful

And we replaced sixteen extremely beefy postgres slaves with four commodity solr boxes with plenty of headroom to spare.

(Of course we now have more than four solr slaves.)

Re: Turbocharging Solr Index Replication with BitTorrent

#10
I've no idea what your constraints are, but splitting the index into more manageable chunks, writing to multiple masters and reading from n slaves off each is an approach that has worked quite well for me (40 million plus records, big lumps of user generated content, total index about 100 GB iirc).

You sacrifice on the accuracy of IDF+, but gain some robustness as result too.

If the BitTorrent approach doesn't work too well, you might consider something similar. I've jotted down a few reading resources for scaling Solr++ but I should probably do a write up of the architecture I built for Boards.ie.

[1] http://wiki.apache.org/solr/DistributedSearch

[2] http://rossduggan.ie/blog/technology/reading-list-for-scalin...

Post reply on HN