SlideShare a Scribd company logo
1 of 8
Download to read offline
Zend
                         and the art of search
                                                             Dave Dash
                                                           Spindrop LLC
                                                          Minneapolis USA




* I’m a symfony evangelist for any who’ll listen
* I write articles and how-tos on spindrop.us
* I’m the lead developer for reviewsby.us
* I’ve worked on a number of symfony sites, many which boast search powered by Zend
you at yo eat y peat ep
                                                                                          urs ours your
                                                                              rse
                                                                         don lf. do elf. d elf.                    s
                                                                                                    on’ don’
                                                                               ’t re n’t
                                                                     rep              pea repe t rep t
                                                                 you eat yo t y                     at y      eat
                                                                                             our
                                                                        rse          urs                our
                                                                 don lf. do elf. d self.                     self




                                                                                                    D RY
                                                                                               on’ don’ .
                                                                         ’t re n’t
                                                              rep
                                                                    eat peat repea t rep t rep
                                                           you                         you t yo eat y
                                                                           you
                                                                rse
                                                                      lf. d rself. rself urse ou
                                                           don                           don . don lf. do
                                                                 ’t re on’t
                                                        rep
                                                             eat peat repea ’t rep ’t rep n
                                                      you                        you t yo eat y eat
                                                                    you
                                                          rse
                                                               lf. d rself. rself urse ours
                                                      don                          don . don lf. do el
                                                           ’t re on’t
                                                    rep          pea repe ’t rep ’t re n’t r
                                                  you eat yo t y                               eat peat e
                                                                                     at y
                                                                 urs ours
                                                     rse                                  our       you       you
                                                         lf. d         elf.         elf.
                                                  don                                         self
                                                                            don don . do rself.
                                                               on’
                                                rep ’t rep t re                                                do
                                                                                   ’t re ’t r          n’t
                                                   eat                     pea
                                                             eat                         pea epea repe
                                                                    you t yo
                                                       you                                   t yo t yo at
                                                             rse                      urs
                                                                           rse
                                                                               lf. d elf. ursel urse
                                                                  lf. d
                                                         you            on’                                       lf
                                                                                               don f. d
                                                                                     on’
                                                               rse           t re                  ’t re on’t
                                                                                         t re
                                                                     lf. d         pea        pea        pea r
                                                                           on’
                                                                                t re t you t you t yo
*
   The core symfony framework can do quite a lot


                                                                                      pea rsel                     u
                                                                                                         rse
*
   The greatest strength of symfony is it’s ability to extend beyond the core

    *
     Plugins

                                                                                          t yo f. do lf. do

    *
     PEAR libraries

    *
     other frameworks?
                                                                                               urs       n’t
*
   In symfony (and other frameworks) we embrace the idea of DRY: Don’t Repeat Yourself

                                                                                                   elf.      rep

    *
     Not just in our applications, or the framework itself, but open source PHP in general

                                                                                                                 e

    *
     If there’s good code available, don’t re-invent the wheel.
bridge = simple

*
   Even without help, Zend and ezComponents are easy to use within symfony
*
   But why not build a bridge
*
   The Bridge is simple, it allows us to call classes from Zend or other frameworks and autoload them
*
   That’s it
lucene




*
      We’re going to specifically look at Zend Search Lucene
*
      Great way to quickly add a powerful search engine to your web app
*
      Apache Lucene is a feature-rich, but easy to use search engine library written in Java

       *
     Ported to C, Ruby and of course PHP
*
      The ports generally use binary compatible libraries, meaning we can write one part of the search in Java and another part in PHP if necessary
*
      PHP isn’t always the best language for heavy server-side lifting, so we can pull out resource-intensive processes that are unbecoming of a PHP script and use Java to take care of
them.   We’ll touch on that later
search = 3 things




*
     We’ve got a bridge, we’ve got a php library, search is a snap, so let’s talk about adding it to our applications
*
     There’s three or four things we do with a search engine

      *
      Index records

      *
      Delete records

      *
      Query records

      *
      We do update, but at least with Lucene that involves deleting and indexing
*
     If you’ve seen the tutorials I have online they are written in a propel-specific manner, this is by no means a requirement, we can very easily use Doctrine or
any type of object we want to index
*
     If we have time, which we might, I’ll show a demo with the code in action if people would like
*
     Since our primary task is searching or querying records we’ll start there

      *
      In either our Peer or Table class for our object which we have indexed we’ll want a query method.

      *
      This method loads the search index and uses the Zend Search Lucene library to query
*
     All these queries will be useless without a built up index

      *
      In our object’s class we override the save method and have it delete all the old records of the object in the index (if any) and create a new one from
scratch using the Zend API

      *
      We store the fields we’d want to search on in the index
*
     Finally we need to override our delete method for our object and make sure it removes its records in the search index upon deletion
extension
questions?
i can has demo?

More Related Content

Recently uploaded

The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsPixlogix Infotech
 
Generative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersGenerative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersRaghuram Pandurangan
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...Rick Flair
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity PlanDatabarracks
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024Lorenzo Miniero
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek SchlawackFwdays
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
What is Artificial Intelligence?????????
What is Artificial Intelligence?????????What is Artificial Intelligence?????????
What is Artificial Intelligence?????????blackmambaettijean
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr BaganFwdays
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLScyllaDB
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteDianaGray10
 
What is DBT - The Ultimate Data Build Tool.pdf
What is DBT - The Ultimate Data Build Tool.pdfWhat is DBT - The Ultimate Data Build Tool.pdf
What is DBT - The Ultimate Data Build Tool.pdfMounikaPolabathina
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024Lonnie McRorey
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxLoriGlavin3
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .Alan Dix
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionDilum Bandara
 
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxLoriGlavin3
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 

Recently uploaded (20)

The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and Cons
 
Generative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersGenerative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information Developers
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity Plan
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
What is Artificial Intelligence?????????
What is Artificial Intelligence?????????What is Artificial Intelligence?????????
What is Artificial Intelligence?????????
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQL
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test Suite
 
What is DBT - The Ultimate Data Build Tool.pdf
What is DBT - The Ultimate Data Build Tool.pdfWhat is DBT - The Ultimate Data Build Tool.pdf
What is DBT - The Ultimate Data Build Tool.pdf
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An Introduction
 
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 

Featured

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by HubspotMarius Sescu
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTExpeed Software
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsPixeldarts
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthThinkNow
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfmarketingartwork
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024Neil Kimberley
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)contently
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024Albert Qian
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsKurio // The Social Media Age(ncy)
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Search Engine Journal
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summarySpeakerHub
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next Tessa Mero
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentLily Ray
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best PracticesVit Horky
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project managementMindGenius
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...RachelPearson36
 

Featured (20)

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 

Zend and the Art of Search

  • 1. Zend and the art of search Dave Dash Spindrop LLC Minneapolis USA * I’m a symfony evangelist for any who’ll listen * I write articles and how-tos on spindrop.us * I’m the lead developer for reviewsby.us * I’ve worked on a number of symfony sites, many which boast search powered by Zend
  • 2. you at yo eat y peat ep urs ours your rse don lf. do elf. d elf. s on’ don’ ’t re n’t rep pea repe t rep t you eat yo t y at y eat our rse urs our don lf. do elf. d self. self D RY on’ don’ . ’t re n’t rep eat peat repea t rep t rep you you t yo eat y you rse lf. d rself. rself urse ou don don . don lf. do ’t re on’t rep eat peat repea ’t rep ’t rep n you you t yo eat y eat you rse lf. d rself. rself urse ours don don . don lf. do el ’t re on’t rep pea repe ’t rep ’t re n’t r you eat yo t y eat peat e at y urs ours rse our you you lf. d elf. elf. don self don don . do rself. on’ rep ’t rep t re do ’t re ’t r n’t eat pea eat pea epea repe you t yo you t yo t yo at rse urs rse lf. d elf. ursel urse lf. d you on’ lf don f. d on’ rse t re ’t re on’t t re lf. d pea pea pea r on’ t re t you t you t yo * The core symfony framework can do quite a lot pea rsel u rse * The greatest strength of symfony is it’s ability to extend beyond the core * Plugins t yo f. do lf. do * PEAR libraries * other frameworks? urs n’t * In symfony (and other frameworks) we embrace the idea of DRY: Don’t Repeat Yourself elf. rep * Not just in our applications, or the framework itself, but open source PHP in general e * If there’s good code available, don’t re-invent the wheel.
  • 3. bridge = simple * Even without help, Zend and ezComponents are easy to use within symfony * But why not build a bridge * The Bridge is simple, it allows us to call classes from Zend or other frameworks and autoload them * That’s it
  • 4. lucene * We’re going to specifically look at Zend Search Lucene * Great way to quickly add a powerful search engine to your web app * Apache Lucene is a feature-rich, but easy to use search engine library written in Java * Ported to C, Ruby and of course PHP * The ports generally use binary compatible libraries, meaning we can write one part of the search in Java and another part in PHP if necessary * PHP isn’t always the best language for heavy server-side lifting, so we can pull out resource-intensive processes that are unbecoming of a PHP script and use Java to take care of them. We’ll touch on that later
  • 5. search = 3 things * We’ve got a bridge, we’ve got a php library, search is a snap, so let’s talk about adding it to our applications * There’s three or four things we do with a search engine * Index records * Delete records * Query records * We do update, but at least with Lucene that involves deleting and indexing * If you’ve seen the tutorials I have online they are written in a propel-specific manner, this is by no means a requirement, we can very easily use Doctrine or any type of object we want to index * If we have time, which we might, I’ll show a demo with the code in action if people would like * Since our primary task is searching or querying records we’ll start there * In either our Peer or Table class for our object which we have indexed we’ll want a query method. * This method loads the search index and uses the Zend Search Lucene library to query * All these queries will be useless without a built up index * In our object’s class we override the save method and have it delete all the old records of the object in the index (if any) and create a new one from scratch using the Zend API * We store the fields we’d want to search on in the index * Finally we need to override our delete method for our object and make sure it removes its records in the search index upon deletion
  • 8. i can has demo?