SOLR

4,286 views

Published on

Mike Brevoort at Ignite night at the Denver Open Source Users Group

Published in: Education, Technology
0 Comments
9 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total views
4,286
On SlideShare
0
From Embeds
0
Number of Embeds
969
Actions
Shares
0
Downloads
0
Comments
0
Likes
9
Embeds 0
No embeds

No notes for slide

SOLR

  1. 1. Solr in 5... minutes DOSUG Ignite Night February 2, 2010 Mike Brevoort Avalon Consulting LLC
  2. 2. It was religion... that brought me to Solr
  3. 3. •Created by Yonik Seeley for CNET •Contributed to Apache Jan 2006 •Version 1.4 released Nov 2009
  4. 4. Lucene = engine Lucene is a high- performance text search engine library
  5. 5. Solr = Serverlization of Lucene++ •Exposed over HTTP, REST-like interface •Java Web Application
  6. 6. Basic Config •schema.xml •solrconfig.xml •field types and •Lucene index fields parameters •*dynamic fields •request handler mappings •cache settings •plugins
  7. 7. Indexing Data - HTTP Post •Commit/Rollback •Global modification state
  8. 8. Data Import Handler •Index data from database or HTTP GET •Full and incremental indexing
  9. 9. Index Binary Documents •ExtractingRequestHandler a.k.a. “Solr Cell” •MS Office, PDF, RTF, OpenDocument, Images, MP3, Zip, etc. curl 'http://localhost:8983/solr/update/extract?literal.id=doc1&commit=true' -F "myfile=@resume.pdf"
  10. 10. Searching •http://localhost:8983/solr/select? q=query •&start=50 •&rows=25 •&fq=filter+query •&facet=on&facet.field=category •&sort=dist(2, point1, point2) desc *coming in Solr 1.5
  11. 11. Results •default format is XML •&wt=json •&wt=php •&wt=ruby •&wt=python *wt = writer type
  12. 12. Query Parser •&deftype=lucene (default) • q=title:saint* AND zipcode:[80000 TO 81999] • advanced syntax •&deftype=dismax • q=ipod +shuffle -touch • simplified syntax • ideal for processing query string from user
  13. 13. Facets (guided navigation) &facet=on &facet.field=listingTraditions
  14. 14. Spell Checking Highlighting More Like This q=saint&mlt=true&mlt.fl=title_t for each result, returns similar results based on &mlt.fl
  15. 15. SolrJs •JQuery Widgets Framework •Solr Powered UI
  16. 16. APIs •HTTP GET/POST •JSON •SolrJ (java) •ruby, python, PHP, C# •Integrations: Drupal, Rails, Grails (workin’ on it), etc.
  17. 17. Security •(listen for crickets) •Relies on server and container security •TOTALLY OPEN BY DEFAULT - it’s up to you to secure it •No standard document level security model
  18. 18. Scaling: master/ slave •Index + configuration replication •Load balanced queries •Supported OOTB
  19. 19. Scaling: sharding •Massive Indexes •Relevancy per index and merged •Some features not supported
  20. 20. Resources Resources • http://lucene.apache.org/solr/ • solr-user@lucene.apache.org Mike Brevoort | brevoortm@avalonconsult.com twitter: @mbrevoort

×