mirror of
https://github.com/discourse/discourse.git
synced 2025-06-02 14:25:08 +08:00
Improvements to mbox importer
* store time it took to index message in DB (to find performance issues) * ignore listserv specific files * better examples for split_regex * first email in mbox shouldn't contain the split string * always lock the DB in exclusive mode * save email within transaction * messages can be grouped by subject and use original order (for Listserv) * adds option to index emails without running the import
This commit is contained in:
@ -13,6 +13,8 @@ module ImportScripts::Mbox
|
||||
attr_reader :trust_level
|
||||
attr_reader :prefer_html
|
||||
attr_reader :staged
|
||||
attr_reader :index_only
|
||||
attr_reader :group_messages_by_subject
|
||||
|
||||
def initialize(yaml)
|
||||
@data_dir = yaml['data_dir']
|
||||
@ -21,6 +23,8 @@ module ImportScripts::Mbox
|
||||
@trust_level = yaml['default_trust_level']
|
||||
@prefer_html = yaml['prefer_html']
|
||||
@staged = yaml['staged']
|
||||
@index_only = yaml['index_only']
|
||||
@group_messages_by_subject = yaml['group_messages_by_subject']
|
||||
end
|
||||
end
|
||||
end
|
||||
|
Reference in New Issue
Block a user