mirror of
https://github.com/privacore/open-source-search-engine.git
synced 2025-07-16 02:46:08 -04:00
Remove unused spider status
This commit is contained in:
20
Spider.cpp
20
Spider.cpp
@ -221,10 +221,7 @@ int32_t SpiderReply::print ( SafeBuf *sbarg ) {
|
||||
}
|
||||
|
||||
|
||||
|
||||
int32_t SpiderRequest::printToTable ( SafeBuf *sb , const char *status ,
|
||||
XmlDoc *xd , int32_t row ) {
|
||||
|
||||
int32_t SpiderRequest::printToTable(SafeBuf *sb, const char *status, XmlDoc *xd, int32_t row) {
|
||||
sb->safePrintf("<tr bgcolor=#%s>\n",LIGHT_BLUE);
|
||||
|
||||
// show elapsed time
|
||||
@ -2839,21 +2836,6 @@ bool getSpiderStatusMsg ( CollectionRec *cx , SafeBuf *msg , int32_t *status ) {
|
||||
return msg->safePrintf("Job is initializing.");
|
||||
}
|
||||
|
||||
if ( cx->m_spiderStatus == SP_ROUNDDONE ) {
|
||||
*status = SP_ROUNDDONE;
|
||||
return msg->safePrintf ( "Nothing currently "
|
||||
"available to spider. "
|
||||
"Change your url filters, try "
|
||||
"adding new urls, or wait for "
|
||||
"existing urls to be respidered.");
|
||||
}
|
||||
|
||||
if ( cx->m_spiderStatus == SP_ROUNDDONE ) {
|
||||
*status = SP_ROUNDDONE;
|
||||
return msg->safePrintf ( "Job round completed.");
|
||||
}
|
||||
|
||||
|
||||
if ( ! g_conf.m_spideringEnabled ) {
|
||||
*status = SP_ADMIN_PAUSED;
|
||||
return msg->safePrintf("All crawling temporarily paused "
|
||||
|
20
Spider.h
20
Spider.h
@ -29,16 +29,16 @@ class SpiderColl;
|
||||
|
||||
// . values for CollectionRec::m_spiderStatus
|
||||
// . reasons why crawl is not happening
|
||||
#define SP_INITIALIZING 0
|
||||
//#define SP_UNUSED 1
|
||||
//#define SP_UNUSED 2
|
||||
//#define SP_UNUSED 3
|
||||
#define SP_ROUNDDONE 4 // spider round is done
|
||||
#define SP_NOURLS 5 // initializing
|
||||
#define SP_PAUSED 6 // user paused spider
|
||||
#define SP_INPROGRESS 7 // it is going on!
|
||||
#define SP_ADMIN_PAUSED 8 // g_conf.m_spideringEnabled = false
|
||||
#define SP_COMPLETED 9 // crawl is done, and no repeatCrawl is scheduled
|
||||
#define SP_INITIALIZING 0
|
||||
//#define SP_UNUSED_1 1
|
||||
//#define SP_UNUSED_2 2
|
||||
//#define SP_UNUSED_3 3
|
||||
//#define SP_UNUSED_4 4
|
||||
//#define SP_UNUSED_5 5
|
||||
#define SP_PAUSED 6 // user paused spider
|
||||
#define SP_INPROGRESS 7 // it is going on!
|
||||
#define SP_ADMIN_PAUSED 8 // g_conf.m_spideringEnabled = false
|
||||
//#define SP_UNUSED_9 9
|
||||
|
||||
bool getSpiderStatusMsg ( class CollectionRec *cx ,
|
||||
class SafeBuf *msg ,
|
||||
|
Reference in New Issue
Block a user