java web 搜索一般用什么,是不是用搜索引擎,数据量一百万左右
还没到一百万条记录,也就十几万,肯能回到八九十万
直接SQL语句 LIKE
有问题没
还有,比如搜索某一个词 动漫
是不是应该把这个结构存起来,其他用户来搜索就不用再进数据库啦,一般怎么做
迷茫2017-04-17 13:18:42
Hundreds of thousands is not a big problem. Of course, it also depends on whether your function is important or not, and whether there are many users. Solr is the most used JAVA. If you don’t use a search engine, you can cache popular searches.
Don’t mess around until you encounter performance problems.
I recommend Sphinx, it is simple and easy to use, has about 500W data, specializes in searching, and the performance is very good
黄舟2017-04-17 13:18:42
Sphinx is sufficient, and the amount of data does not seem to be exaggerated. There should be no problem in executing like
directly from SQL, just feel free to do it.
巴扎黑2017-04-17 13:18:42
It is recommended to use elasticsearch. It is very convenient. Operating this thing is as easy as operating a database. And without some troublesome configuration, coding can be achieved.