summaryrefslogtreecommitdiffstats
path: root/libnetdata/circular_buffer/README.md
blob: c4738651600b988640b571d5f850cdcb0ac923cf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
<!--
title: "Circular Buffer"
custom_edit_url: https://github.com/netdata/netdata/edit/master/libnetdata/circular_buffer/README.md
sidebar_label: "Circular Buffer"
learn_status: "Published"
learn_topic_type: "Tasks"
learn_rel_path: "Developers/libnetdata"
-->

# Circular Buffer

`struct circular_buffer` is an adaptive circular buffer. It will start at an initial size
and grow up to a maximum size as it fills. Two indices within the structure track the current
`read` and `write` position for data.