Adds all of the item in the specified collection to the tail of the Ringbuffer. An add_all is likely to
        outperform multiple calls to add(object) due to better io utilization and a reduced number of executed
        operations. The items are added in the order of the Iterator of the collection.

        If there is no space in the Ringbuffer, the action is determined by overflow policy as :const:`OVERFLOW_POLICY_OVERWRITE`
        or :const:`OVERFLOW_POLICY_FAIL`.

        :param items: (Collection), the specified collection which contains the items to be added.
        :param overflow_policy: (int), the OverflowPolicy to be used when there is no space (optional).
        :return: (long), the sequenceId of the last written item, or -1 of the last write is failed.

def add_all(self, items, overflow_policy=OVERFLOW_POLICY_OVERWRITE):
        """
        Adds all of the item in the specified collection to the tail of the Ringbuffer. An add_all is likely to
        outperform multiple calls to add(object) due to better io utilization and a reduced number of executed
        operations. The items are added in the order of the Iterator of the collection.

        If there is no space in the Ringbuffer, the action is determined by overflow policy as :const:`OVERFLOW_POLICY_OVERWRITE`
        or :const:`OVERFLOW_POLICY_FAIL`.

        :param items: (Collection), the specified collection which contains the items to be added.
        :param overflow_policy: (int), the OverflowPolicy to be used when there is no space (optional).
        :return: (long), the sequenceId of the last written item, or -1 of the last write is failed.
        """
        check_not_empty(items, "items can't be empty")
        if len(items) > MAX_BATCH_SIZE:
            raise AssertionError("Batch size can't be greater than %d" % MAX_BATCH_SIZE)
        for item in items:
            check_not_none(item, "item can't be None")

        item_list = [self._to_data(x) for x in items]
        return self._encode_invoke(ringbuffer_add_all_codec, value_list=item_list, overflow_policy=overflow_policy)