[nodebb-plugin-dbsearch] DB Search Plugin
-
Hi.. im having some "issues" with searching..
some content isnt showing on the search result.. .. like.. i got a thread with a word that repeats on the content.. but i look for that word.. and i dont get that thread as result...
any thoughts?
agiletesters .com .br -> search for 'cucumber'
-
@baris Hey buddy, I'm unable to re-index my data, there's a lot of it, and it basically brings the server to a standstill, nodebb crashes and nothing appears indexed after a restart. 500 error teaser doesn't exist.
Stats:
28,000 posts
2000 topics from 490 users.While it's indexing I get a 504 Gateway Time-out. Is there a way to break up the indexing?
Just had a thought, it says new content is indexed automatically, if I re-index before I import my data, would that work?
-
Can you update the plugin and nodebb core and give it another try? I reindex 1.6k
topics and 12.5k posts in 30 seconds. I added some logging and timing into reindex so you should see the progress now. Also changed the reindex to use eachLimit so it doesn't try to reindex everything at once.Let me know if it changes anything.
-
@baris What versions have compatibility with 0.5.x?
-
Tried this out (is it the only search plugin?!) for v0.6.x and searches have an issue with broken templates I think?
You get no search results, and a broken page (as above)
As well as a console error in JS of "Uncaught TypeError: Cannot read property 'split' of undefined" but that's probably more a symptom of the template render issue. -
@Drew-Llewellyn said:
Tried this out (is it the only search plugin?!) for v0.6.x and searches have an issue with broken templates I think?
You get no search results, and a broken page (as above)
As well as a console error in JS of "Uncaught TypeError: Cannot read property 'split' of undefined" but that's probably more a symptom of the template render issue.This is my compiled search.tpl file, and I can't seem to find what the problem is:
<ol class="breadcrumb"> <!-- BEGIN breadcrumbs --> <li itemscope="itemscope" itemtype="http://data-vocabulary.org/Breadcrumb" <!-- IF @last -->class="active"<!-- ENDIF @last -->> <!-- IF !@last --><a href="{breadcrumbs.url}" itemprop="url"><!-- ENDIF !@last --> <span itemprop="title"> {breadcrumbs.text} <!-- IF @last --> <!-- IF !feeds:disableRSS --> <!-- IF rssFeedUrl --><a target="_blank" href="{rssFeedUrl}"><i class="fa fa-rss-square"></i></a><!-- ENDIF rssFeedUrl --><!-- ENDIF !feeds:disableRSS --> <!-- ENDIF @last --> </span> <!-- IF !@last --></a><!-- ENDIF !@last --> </li> <!-- END breadcrumbs --> </ol> <div class="search"> <div class="row"> <div class="well col-md-12"> <form id="advanced-search"> <div class="form-group"> <label>[[global:search]]</label> <input type="text" class="form-control" id="search-input" placeholder="[[global:search]]"> </div> <div class="form-group"> <label>[[search:in]]</label> <select class="form-control"> <option value="posts">[[global:posts]]</option> <option value="users">[[global:users]]</option> <option value="tags">[[tags:tags]]</option> </select> </div> <div class="form-group by-container<!-- IF hidePostedBy --> hide<!-- ENDIF hidePostedBy -->"> <label>[[search:by]]</label> <input type="text" class="form-control" id="posted-by-input" placeholder="[[search:posted-by]]"> </div> <button type="submit" class="btn btn-default">[[global:search]]</button> </form> </div> <div id="results" class="col-md-12" data-search-query="{search_query}"> <!-- IF matchCount --> <div class="alert alert-info">[[search:results_matching, {matchCount}, {search_query}, {time}]] </div> <!-- ELSE --> <div class="alert alert-warning">[[search:no-matches]]</div> <!-- ENDIF matchCount --> <!-- BEGIN posts --> <div class="topic-row panel panel-default clearfix"> <div class="panel-body"> <a href="{relative_path}/topic/{posts.topic.slug}/{posts.index}" class="search-result-text"> <h4>{posts.topic.title}</h4> </a> <div class="search-result-text"> {posts.content} <p class="fade-out"></p> </div> <small> <span class="pull-right footer"> <a href="{relative_path}/users/{posts.user.userslug}"><img class="user-img" title="{posts.user.username}" src="{posts.user.picture}"/></a> [[global:posted_in_ago, <a href="{relative_path}/category/{posts.category.slug}"><i class="fa {posts.category.icon}"></i> {posts.category.name}</a>, <span class="timeago" title="{posts.relativeTime}"></span>]] </span> </small> </div> </div> <!-- END posts --> <!-- IF users.length --> <ul id="users-container" class="users-container"> <!-- BEGIN users --> <li class="users-box registered-user" data-uid="{users.uid}"> <a href="{relative_path}/user/{users.userslug}"><img src="{users.picture}" class="img-thumbnail"/></a> <br/> <div class="user-info"> <span> <i class="fa fa-circle status {users.status}" title="[[global:{users.status}]]"></i> <a href="{relative_path}/user/{users.userslug}">{users.username}</a> </span> <br/> <div title="reputation" class="reputation"> <i class='fa fa-star'></i> <span class='formatted-number'>{users.reputation}</span> </div> <div title="post count" class="post-count"> <i class='fa fa-pencil'></i> <span class='formatted-number'>{users.postcount}</span> </div> </div> </li> <!-- END users --> </ul> <!-- ENDIF users.length --> <!-- IF tags.length --> <!-- BEGIN tags --> <h3 class="pull-left tag-container"> <a href="{relative_path}/tags/{tags.value}" data-value="{tags.value}"><span class="tag-item" data-tag="{tags.value}" style="<!-- IF tags.color -->color: {tags.color};<!-- ENDIF tags.color --><!-- IF tags.bgColor -->background-color: {tags.bgColor};<!-- ENDIF tags.bgColor -->">{tags.value}</span><span class="tag-topic-count">{tags.score}</span></a> </h3> <!-- END tags --> <!-- ENDIF tags.length --> </div> </div> </div>