//replace with your own css styling if desired //unnecessary if jquery is already loaded
Company
Company Find Us The Gander Express Company Newsletter Events
Products
Jobs
Blog
Gander

Riparian Data

Company
Company Find Us The Gander Express Company Newsletter Events
Products
Jobs
Blog
Gander

Elastic Gander: How Elasticsearch Helped Us Build a Better Email App

So, we've probably mentioned that we're using ElasticSearch to power Gander. What we haven't talked about so much is why, and how we're using it under the hood. When we were building out the back end for Gander, the very first thing we wanted to know is what search platform would meet our needs best. It needed to be powerful and it needed to be fast.  If it had a great API to work against and was easy to set up, well, that's just gravy on top. ElasticSearch had these qualities in spades. The other major platform we looked at was Solr, which, like ElasticSearch, is built on top of Lucene. The two are actually somewhat similiar, with Solr being older and designed more for standard search applications. ElasticSearch is newer, and its API, setup and underlying model reflect this. For the kind of application we're building, ElasticSearch is the better fit.

Elasticsearch works by creating indexes over whatever one is trying to search. These indexes track a subset of the data we want to search, and are organized in such a way so that these searches will be fast. To actually keep track of our data, we store it all in CouchDB. However, we still needed to get our data to Elasticsearch so that it could create indexes over that data. Luckily, there's a pretty smooth way to do it.  CouchDb has a concept called rivers where any changes made to the underlying data show up as a change on the river. The changes go downstream along the river, one might say. Elasticsearch has a river plugin for reading these changes. With the right configuration, any changes to the data we want to search will automatically be propagated to Elasticsearch and reindexed, so our search results will always be up to date.

Gander is primarily Ruby on Rails, and it is there that we create new search requests and display our search results. It needs to be able to interact with Elasticsearch, too. Elasticsearch has a pretty great client-side API, but we didn't want to reinvent the wheel, or tire, so to speak. We're using the Tire gem instead. It lets us make requests and display their results with a minimum amount of fuss. Basically, when a user enters a new query that they want to search, we can parse that query and pass it to Tire. Tire will then use the Elasticsearch API to make the search request on our behalf. It then will return us the search results in a nice format, which we then display to the user on the page. Easy peasy, lemon squeezy.

And that's pretty much it. Elasticsearch is an easy search platform to work with - besides some distributable aspects, this is a basic overview of our entire search architecture. Questions? Comments? Want to know about some specifics? Contact us!

Newer:Sanebox and Riparian Data Present: Third Party Solutions to Enterprise Email WoesOlder:HTML5 on a Mobile Device: 4 Design Maxims
PostedSeptember 5, 2012
AuthorNick
CategoriesGeneral Development, Mobile Email, Search
Tagscouchdb, couchdb rivers, elasticsearch, lucene, river plugin, Ruby on Rails, solr, tire gem
Search
 
  • Mobile Advertising (1)
  • Email Design (2)
  • Network Analysis (2)
  • Intern Diaries (3)
  • Search (3)
  • Uncategorized (3)
  • Day in the Life of an Inbox (4)
  • Information Visualization (4)
  • New York Big Data (4)
  • Timberwolf (4)
  • Hadoop (5)
  • Mobile design (5)
  • Email Analytics (6)
  • Email Habits (7)
  • Mo' Data Mo' Problems (7)
  • Startup talk (8)
  • Behind the Data (10)
  • Boston Big Data (10)
  • Mobile Email (10)
  • Email Overload (15)
  • General Development (17)
  • Big Data (25)
  • Events (32)
 
  • awayfind
  • cloudera
  • contactually
  • couchdb
  • data science
  • Datameer
  • elasticsearch
  • email analytics
  • encryption
  • enron
  • gander
  • Hadoop
  • HBase
  • hdfs
  • hive
  • inbox love
  • java
  • mapreduce
  • MEC
  • Microsoft Exchange
  • microsoft exchange conference
  • programming internship
  • Project Management
  • ruby
  • Ruby on Rails
  • sanebox
  • sendgrid
  • solr
  • strata conference
  • Trello
  • twitter
  • Ubuntu
  • December 2012 (1)
  • November 2012 (11)
  • October 2012 (12)
  • September 2012 (11)
  • August 2012 (8)
  • July 2012 (11)
  • June 2012 (13)
  • May 2012 (11)
  • April 2012 (8)
  • March 2012 (11)
  • February 2012 (19)
  • ad min (2)
  • Cameron (2)
  • christina (3)
  • Claire Willett (75)
  • dmitri leonov (1)
  • elise (1)
  • Jim Stallings (5)
  • Nick (7)
  • paula (2)
  • ramon (1)
  • Scott (3)
  • sean (8)
  • wihl (6)

Copyright 2012 © Riparian Data. All Rights Reserved.