| flex:index:create | This rake task reads the configuration flex.ymlfile with your custom mappings, merges it with the internally generated mapping and routings, and creates the index. It is important to run this task when you start a new app, specially if you use theflex-modelsgem with parent/child relationships (see flex-models). Environment variablesThis task can be customized with the following environment variables: 
FORCEDeletes the existing indices before running. Defaultfalse.INDEXString representing one or a list of indices to create. Default:Flex::Configuration.variables[:index]. $ rake flex:index:create INDEX=foo,bar
 | 
  
    | flex:index:delete | Deletes the index/indices. Environment variablesThis task can be customized with the following environment variables: 
INDEXString representing one or a list of indices to delete. Default:Flex::Configuration.variables[:index]. | 
  
    | flex:import | 
This is a specific task provided by the flex-modelsgem. It imports all or any of the models of your application. Environment variablesThis task can be customized with the following environment variables: 
FORCEDeletes the existing indices before reindexing. Defaultfalse.BATCH_SIZEThe batch size used to retrieve the records and bulk post to the elasticsearch server. Default1000.TIMEOUTThe HTTP-client timeout. Default20for this task. (it is usually5for regular queries as set inConfiguration.http_client_options[:timeout]). You might need a higher timeout if you raise theBATCH_SIZE.IMPORT_OPTIONSA query string like string representing a hash of options to be used with thefind_in_batchesmethods.CONFIG_FILEThe configuration file. DefaultFlex::Configuration.config_fileMODELSArray like string representing a list of model classes. DefaultFlex::Configuration.flex_models. $ rake flex:import MODELS=Foo,Bar
 | 
  
    | flex:admin:dump | 
This is a specific task provided by the flex-admingem. It dumps the index/indices to a dump file, which can be feed to the flex:admin:loadtask to reload/restore the index. Environment variablesThis task can be customized with the following environment variables: 
FILEThe path to the dump file. Default:'./flex.dump'INDEXString representing one or a list of indices to dump. Default:Flex::Configuration.variables[:index]TYPEString representing one or a list of types to dump. Default:Flex::Configuration.variables[:type]SCROLLelasticsearch option for the scan_type search performed to retrieve the documents. Default:'5m'SIZERepresents the number of documents per shard dumped at a time. Default:50VERBOSEPrints informations during the process. Default:true | 
  
    | flex:admin:load | 
This is a specific task provided by the flex-admingem. It reload/restore the index by loading a dump file (produced by the the flex:admin:dump) 
Notice: It loads the data into the original index name. If you want to reload the data into another index, you must set the INDEX_MAPvariable. Environment variablesThis task can be customized with the following environment variables: 
FILEThe path to the dump file. Default:'./flex.dump'BATCH_SIZEThe document batch size used to import the dump file to the elasticsearch server. Default1000.INDEX_MAPThe index rename map (example: -m=dumped_index_name:loaded_index_name,a:b).TIMEOUTThe HTTP-client timeout. Default20for this task. (it is usually5for regular queries as set inConfiguration.http_client_options[:timeout]). You might need a higher timeout if you raise theBATCH_SIZE.VERBOSEPrints informations during the process. Default:true |