public IndexingResults bulkIndex(final List<MessageWithIndex> messageList) {
        return bulkIndex(messageList, false, null);
    }
@Test
    public void bulkIndexingShouldAccountMessageSizes() throws IOException {
        when(messagesAdapter.bulkIndex(any())).thenReturn(IndexingResults.empty());
        final IndexSet indexSet = mock(IndexSet.class);
        final List<MessageWithIndex> messageList = List.of(
                new MessageWithIndex(wrap(messageWithSize(17)), indexSet),
                new MessageWithIndex(wrap(messageWithSize(23)), indexSet),
                new MessageWithIndex(wrap(messageWithSize(42)), indexSet)
        );
        when(messagesAdapter.bulkIndex(any())).thenReturn(IndexingResults.create(createSuccessFromMessages(messageList), List.of()));

        messages.bulkIndex(messageList);

        verify(trafficAccounting, times(1)).addOutputTraffic(82);
        verify(trafficAccounting, never()).addSystemTraffic(anyLong());
    }