search

Home  >  Q&A  >  body text

Lucene - java web Now use the search function, which one is better?

When building a picture browsing site, a picture contains n tags.
It is now divided into a table for pictures, a table for labels, and a table for pictures-labels.

The first thing we did was to use like to query the keywords separated by spaces. For example, the keyword "men's shoes" will query all the keywords with "men" or "shoes". If we query "men's shoes", nothing will appear. result. Now we hope that if we query "men's shoes" or "men's shoes", only those that contain both "men" and "shoes" will appear.

The above examples are for reference only. Keywords may not be included at the same time. Which one is more appropriate? The most commonly seen Java version of the search engine is Lucene. I wonder if it can be integrated with SSM to create a paging query effect?

If you use a word segmenter for word segmentation, what is more suitable?

大家讲道理大家讲道理2750 days ago594

reply all(4)I'll reply

  • 滿天的星座

    滿天的星座2017-05-17 10:11:09

    It is recommended to use elasticsearch for search. If you want to segment words, you can use ik segmenter

    reply
    0
  • PHP中文网

    PHP中文网2017-05-17 10:11:09

    Lucene can use Paoding tokenizer.
    PHP with Sphinx + Coreseek / Xunsearch

    reply
    0
  • 伊谢尔伦

    伊谢尔伦2017-05-17 10:11:09

    Lucene implementation, solr

    reply
    0
  • phpcn_u1582

    phpcn_u15822017-05-17 10:11:09

    There are now very mature solutions of this type, such as solr and elasticsearch, which are open source search engines and can add, delete, modify and check data through simple http requests

    reply
    0
  • Cancelreply