def commit(self, sync=False):
        helpers.bulk(self.es, self._queue)
        if sync:
            self.idx_manager.refresh(self.index)
        self._queue = []
If ``sync``, index synchronously, else let Elasticsearch
dataset/ETHPy150Open Net-ng/kansha/kansha/services/search/elasticengine.py/ElasticSearchEngine.commit