extract methods from pipeline; move mongodb settings to settins.py