This article studies and introduces the internal implementation details of BTrDB, an open-source time series database for IoT.