|
@@ -4,7 +4,7 @@ from content_spider.baseSpider import baseSpider
|
|
from content_spider.baseSpider import baseUpdateSpider
|
|
from content_spider.baseSpider import baseUpdateSpider
|
|
from content_spider.baseSpider import fixChapterSpider
|
|
from content_spider.baseSpider import fixChapterSpider
|
|
from content_spider.baseSpider import baseUpdateBookStatusSpider
|
|
from content_spider.baseSpider import baseUpdateBookStatusSpider
|
|
-
|
|
|
|
|
|
+import time
|
|
import json
|
|
import json
|
|
|
|
|
|
|
|
|
|
@@ -245,32 +245,37 @@ class feiyuyueduProcess():
|
|
|
|
|
|
class feiyuyueduSpider(feiyuyueduProcess,baseSpider):
|
|
class feiyuyueduSpider(feiyuyueduProcess,baseSpider):
|
|
name = name
|
|
name = name
|
|
- allowed_domains = allowed_domains
|
|
|
|
- source = source
|
|
|
|
- source_name = source_name
|
|
|
|
- source_id = source_id
|
|
|
|
|
|
+
|
|
|
|
+ custom_settings = {
|
|
|
|
+ 'DOWNLOAD_DELAY': 0.1,
|
|
|
|
+ 'SOURCE': source,
|
|
|
|
+ 'LOG_FILE': 'content_spider/log/' + name + time.strftime("%Y-%m-%d", time.localtime()) + '.log'
|
|
|
|
+ }
|
|
|
|
|
|
|
|
|
|
class feiyuyueduUpdateSpider(feiyuyueduProcess,baseUpdateSpider):
|
|
class feiyuyueduUpdateSpider(feiyuyueduProcess,baseUpdateSpider):
|
|
name = name + "update"
|
|
name = name + "update"
|
|
- allowed_domains = allowed_domains
|
|
|
|
- source = source
|
|
|
|
- source_name = source_name
|
|
|
|
- source_id = source_id
|
|
|
|
|
|
+ custom_settings = {
|
|
|
|
+ 'DOWNLOAD_DELAY': 0.1,
|
|
|
|
+ 'SOURCE': source,
|
|
|
|
+ 'LOG_FILE': 'content_spider/log/' + name + time.strftime("%Y-%m-%d", time.localtime()) + '.log'
|
|
|
|
+ }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class feiyuyueduFixSpider(feiyuyueduProcess,fixChapterSpider):
|
|
class feiyuyueduFixSpider(feiyuyueduProcess,fixChapterSpider):
|
|
name = name + 'fix'
|
|
name = name + 'fix'
|
|
- allowed_domains = allowed_domains
|
|
|
|
- source = source
|
|
|
|
- source_name = source_name
|
|
|
|
- source_id = source_id
|
|
|
|
|
|
+ custom_settings = {
|
|
|
|
+ 'DOWNLOAD_DELAY': 0.1,
|
|
|
|
+ 'SOURCE': source,
|
|
|
|
+ 'LOG_FILE': 'content_spider/log/' + name + time.strftime("%Y-%m-%d", time.localtime()) + '.log'
|
|
|
|
+ }
|
|
|
|
|
|
|
|
|
|
class feiyuyueduBookInfoSpider(feiyuyueduProcess,baseUpdateBookStatusSpider):
|
|
class feiyuyueduBookInfoSpider(feiyuyueduProcess,baseUpdateBookStatusSpider):
|
|
name = name + "bookinfo"
|
|
name = name + "bookinfo"
|
|
- allowed_domains = allowed_domains
|
|
|
|
- source = source
|
|
|
|
- source_name = source_name
|
|
|
|
- source_id = source_id
|
|
|
|
|
|
+ custom_settings = {
|
|
|
|
+ 'DOWNLOAD_DELAY': 0.1,
|
|
|
|
+ 'SOURCE': source,
|
|
|
|
+ 'LOG_FILE': 'content_spider/log/' + name + time.strftime("%Y-%m-%d", time.localtime()) + '.log'
|
|
|
|
+ }
|