Choosing the Right Search for Drupal

Submitted by Jeremy Kleier on 03/12/2013 - 09:43:am

Choosing the right search for your website can be a pretty big architecture decision. Spending some time during the discovery phase weighing your different options is an important step of the process.  Depending on how advanced you're wanting your search, it can add a couple days or even weeks to the scope of your project. 

Option 1: Drupal Default Search

By most standards Drupal's default search is a pretty good way of searching your site. Drupal's default search does have it's share of inadequacies however: it lacks in power and flexibility; and it doesn't look, feel or act like Google, which people are used to. The "advanced" features that it does have are filtering by content types, and searching by words, phrases, or none of these words. There are things you can do to extend these options, but sooner or later you run out of ways to improve the search further.

Best Use-Case:

A smaller content driven site where the search isn't a key part of user experience. 

Option 2: Views Pseudo-Faceted Search

By leveraging Views, one of Drupal's contributed modules, you can create a custom search experience that can give your user a search experience similar to Google, Amazon, or the like.  

Using Views you can create an experience that empowers your user to filter down search results based on the custom categorization of your content. This type of search is great on small e-commerce system where it filters products.

Best Use-Case:

When you need to have full control over your search results. It will give you a full custom search experience for you user. For a demo of how we've used Views to help improve search, check out DemandMetric.com (not for long though, we're hoping to upgrade this to Solr soon enough).

Views search results start to break down when you start to query large or complex databases. We normally tell our clients that anything over around 1000 pages will cause noticeably slower searches (note that this depends on a wide variety of factors). Once you exceed that mark, the load time of the page will considerably drop and you can potentially run into serious site performance issues. 

Example of how demandmetric use views exposed filters

Option 3: Apache Solr Search

By far the best solution for search, but by far the most complex system to setup.  We recommend Apache Solr to our clients when they surpass 1000 page or when performance or faceted search is very important to them. 

Apache Solr boasts a robust search experience. It's ability to cache the items in your database give you some of the fastest search experiences available. Some of Apache Solr's core features: 

  • Advanced full-text search capabilities
  • Optimized for high volume web traffic
  • Near real-time indexing
  • Flexible and adaptable with quick configuration

What this really means in terms of business is that Solr allows us to do just about anything that you've seen on the web with search without sacrificing speed.

One client that we used Apache Solr for is TippyBob.com. Their database consisted of almost 600,000 users that search based on city, state, zip code, and name. With Tippy Bob, Solr allowed us to have great auto complete and to display results almost instantly. Check out tippboby.com for a live example of how Apache Solr works.

Best Use-Case:

The best place to use Apache Solr is on a site that needs to scale quickly and have more than 1000 pieces of content that need to be searchable. Or if your site needs to have a quicker categories search, this is the most enterprise option. If you want the best search results, Solr can help.

blog photo provide by  True New Zealand Adventures