Your SlideShare is downloading. ×
เกี่ยวกับ Apache solr 4.0
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×

Introducing the official SlideShare app

Stunning, full-screen experience for iPhone and Android

Text the download link to your phone

Standard text messaging rates apply

เกี่ยวกับ Apache solr 4.0

778
views

Published on

1. แนะนะเกี่ยวกับ Apache Solr 4.0 …

1. แนะนะเกี่ยวกับ Apache Solr 4.0
2. การใช้งาน Admin
3. การ Scale ระบบงาน
4. เครื่องมือการทดสอบประสิทธิภาพ
5. การ tunning ขั้นพื้นฐาน

Published in: Technology, Education

2 Comments
2 Likes
Statistics
Notes
No Downloads
Views
Total Views
778
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
36
Comments
2
Likes
2
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide

Transcript

  • 1. Apache Solr @somkiat
  • 2. Apache Solr Search server Based on Lucene Full-text search library Java 100% Open source
  • 3. Apache Solr REST API HTTP XML JSON
  • 4. Apache Solr Client supports .NET Java PHP Ruby Python
  • 5. How we implement ?
  • 6. SELECT * FROM product WHERE id LIKE ‘%1%’ AND name LIKE ‘%xxx%’
  • 7. Problems Full table scan = Killer performance RDBMS is not designed for search like that
  • 8. Architecture Query WEB Application Apache Solr Result Update Indexer
  • 9. How to use ? Install Define solrconfig.xml Define schema.xml Deploy to Java Web Server Jetty ( Default ) Apache Tomcat
  • 10. Define schema.xml Structure of data Liked table structure Must have Primary/Unique key Must have _version_ field
  • 11. <field name="id" type="string" indexed="true" stored="true" required="true" /> ! <field name="item_id" type="string" indexed="true" stored="true" required="true" /> <uniqueKey>id</uniqueKey>
  • 12. Solr Administrator http:/ /localhost:8983/solr
  • 13. Dashboard page
  • 14. Add/Update index
  • 15. Add/Update Index http:/ /localhost:8983/solr/ collection1/update?wt=json
  • 16. Delete Index http:/ /localhost:8983/solr/collection1/ update? stream.body=<delete><query>*:*</ query></delete>&commit=true
  • 17. Ping http:/ /localhost:8983/solr/ collection1/admin/ping?wt=json
  • 18. Scaling Solr Scale up CPU, RAM, SSD Scale horizontal (http:/ /wiki.apache.org/solr/DistributedSearch) Scale deep Sharding and Multiple replicate
  • 19. Performance Tools JMeter SolrMeter https:/ /code.google.com/p/ solrmeter/ http:/ /wiki.apache.org/solr/BenchmarkingSolr
  • 20. JMeter
  • 21. SolrMeter
  • 22. Tuning performance http:/ /wiki.apache.org/solr/SolrPerformanceFactors
  • 23. JVM Memory -Xms1024M -Xmx1024M -server
  • 24. Virtual Memory Virtual memory for index Config in solrconfig.xml <directoryFactory/> change from StandardDirectoryFactory to MmapDirectoryFactory
  • 25. Enable http caching Config in solrconfig.xml
  • 26. <httpCaching lastModifiedFrom="openTime" etagSeed="Solr" never304="false"> <cacheControl> max-age=43200, must-revalidate </cacheControl> ! </httpCaching>
  • 27. Q/A