The tools
usage:
# activate your python environment
python pip_upgrade.py
Also it adds an option to specify the fields you queried, so to export a much smaller data used to update.
usage:
(1) simply dump the data in or out the elasticsearch engine
python elasticDataHelper.py -i output.mapping -o http://127.0.0.1:9200/newindex/newtype -t mapping
python elasticDataHelper.py -i output.json -o http://127.0.0.1:9200/newindex/newtype -t data
# or
python elasticDataHelper.py --input output.mapping --output http://127.0.0.1:9200/newindex/newtype --type mapping
python elasticDataHelper.py --input output.json --output http://127.0.0.1:9200/newindex/newtype --type data
(2) specify the fields so to update data from source to target
python elasticDataHelper.py -i http://127.0.0.1:9200/newindex/newtype -o http://127.0.0.1:9200/newindex1/newtype1 -t data -f field1 field2 filed3
python elasticDataHelper.py --input http://127.0.0.1:9200/newindex/newtype --output http://127.0.0.1:9200/newindex1/newtype1 --type data --field field1 field2 filed3
The encapsulated classes