WordPress.org

Ready to get started?Download WordPress

Forums

Relevanssi - A Better Search
Relevanssi search speed - 3x-4x slower than WP (11 posts)

  1. archon810
    Member
    Posted 1 year ago #

    Short of going full Solr, I found Relevanssi and decided to give it a try. It turned out to be actually really well made and satisfies most of my desires in improving search, including search result highlights.

    Unfortunately, the speed of search suffers greatly. Regular WP search pages are generated in about 1-1.5s on my site (4400 articles or so, lots of tags). Relevanssi does 5-6s, and sometimes over 20s. Unfortunately, that's not good enough, but without going to full Solr I'm not sure can be improved. I'd welcome feedback, however, especially from the authors.

    http://wordpress.org/extend/plugins/relevanssi/

  2. Mikko Saari
    Member
    Plugin Author

    Posted 1 year ago #

    Regular WordPress search is, what, a single MySQL query? MySQL is a professional, highly efficient database engine.

    Relevanssi search is several MySQL queries, lots of looping and computing, and the whole system is created by one non-professional programmer as a hobby project. So, yes, it's bound to be less effective and fast.

    Have you enabled the limit option? If you haven't, try it, and set the limit to something like 100-200. That should help.

  3. archon810
    Member
    Posted 1 year ago #

    I didn't mean to put you down at all, but rather identify an issue and see if there is a solution. I did try both Solr plugins for WP, and while they were much faster to search, the relevancy was much worse. So, I'd really love to get Relevanssi to work.

    Let me try a smaller limit and report back. Thanks for the suggestion.

    Any other things I can try?

  4. archon810
    Member
    Posted 1 year ago #

    Turned it down to 100, which knocked the search speed down to 1.7s from 5+, but now a sample search returns 4 results. 200 returned 10 results. 500 returned 23 results. This solution doesn't work for me since it loses a ton of relevant search results. :-/

  5. archon810
    Member
    Posted 1 year ago #

    Perhaps the queries could be optimized more with indices or clever rewriting. Do you think there's room for improvement there?

  6. Mikko Saari
    Member
    Plugin Author

    Posted 1 year ago #

    Optimization patches to the plugin are most welcome. Unfortunately the plugin is pretty much as optimized as my skills allow. Adding indices, maybe, though then people will start complaining about how much space the database tables take (they are already rather large).

    But feel free to try to fix this and let me know if something helps.

    I wonder how the limit performs that way - it should always include the most relevant posts in any way, so it shouldn't cause such a drastic loss of results. I'll have to see if it's working properly.

  7. danteand
    Member
    Posted 1 year ago #

    What about caching?
    Have you tried turning it on?
    I have been meaning to experiment with it to see if it improves response time with common searches. The option says it might not be useful and could be harmful, so I'm a bit wary.

  8. archon810
    Member
    Posted 1 year ago #

    @danteand Caching is barely helpful since the first search will take a long time - people hardly search for exactly the same keywords.

  9. danteand
    Member
    Posted 1 year ago #

    One blog I have only gets updated every few weeks and a few searches are pretty common, at least according to the search log. So I might try to set the cache to live for a week and see how often it's hit.
    But if your content is updated frequently, and searches are usually unique, I guess it won't help at all.

  10. archon810
    Member
    Posted 1 year ago #

    Yeah, we have about 15-20 posts a day and hundreds of different searches. :(

  11. Mikko Saari
    Member
    Plugin Author

    Posted 1 year ago #

    Yeah, the caching takes plenty of database space and is only really useful if you get lots and lots of repeated searches with the same search terms.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic