def set_last_position(self, last_position):
        """
        Called from the manager, it is in charge of updating the last position of data commited
        by the writer, in order to have resume support
        """
        if last_position:
            if isinstance(last_position, six.string_types):
                last_key = last_position
            else:
                last_key = last_position.get('last_key', '')
            self.last_position = dict(last_key=last_key)
            self.collection_scanner.set_startafter(last_key)
        else:
            self.last_position = {}
Called from the manager, it is in charge of updating the last position of data commited
        by the writer, in order to have resume support