What is the best way to handle a "search" in a REST API? What about the sphinx?

When there are many results and they always change - what is the best way to handle the “search” in the REST API?

Background: I have a community website that lists free local items for churches, community groups, or families with problems, so we have a lot of listings, usually from donors or scanned on other sites. Ideally, the REST API for this site called lists based on certain criteria that we describe in the methods. But there can be many results, and they always change!

Something like Sphinx search? We allow remote search (all records are geo-referenced). I saw that Sphinx Search has a built-in quick search function and also caches search queries - is it typical to include some type of search engine in the REST API? I assume this will be the interface between the API and another application on the server, such as Sphinx ...

+3
source share
1 answer

I'm not quite sure I understand your question. Your main problem is that the data changes frequently, but this happens on many search engines. Consider StackOverflow, they allow you to get a search result using the following:

http://stackoverflow.com/search?q=foo

, . , , . , , , , - .

, - .

0

Source: https://habr.com/ru/post/1794068/


All Articles