Font Size: a A A

Research And Implementation Of Time Series Database Based On Redis

Posted on:2021-03-21Degree:MasterType:Thesis
Country:ChinaCandidate:T T ChengFull Text:PDF
GTID:2428330623468568Subject:Engineering
Abstract/Summary:PDF Full Text Request
In the Internet of Things system,it is often necessary to monitor the connected smart devices,and to store and analyze the data obtained from the monitoring sampling.These data that change with time and can be numerically reflected to the extent of change are called time series data.Due to the large scale of time series data,traditional relational databases have been unable to meet their needs for efficient storage and rapid analysis,so time series databases have emerged at the historic moment.As an open source memorybased non-relational database,Redis has attracted wide attention from the industry.On the one hand,Redis is a high-performance memory database with a built-in rich data structure,making it has natural advantages in real-time data writing and fast querying;On the other hand,Redis does not currently provide a solution specifically for time series data,so research on Redis-based time series databases is an important topic.This thesis studies and implements a Redis-based time series database T-Redis,which is used for the monitoring of Internet of things devices.There are three main areas of research.Firstly,a storage model is designed for storing and managing time series data.According to the characteristics of time series data,a time series object SeriesObject is designed in Redis to manage the storage of time series related data.The thesis provides a pre-aggregation function to increase the speed of aggregation queries,and index data blocks to improve the speed of queries based on time range,indexing dimensional labels to improve the speed of multi-dimensional queries.finally reducing the memory space overhead by reducing the precision storage of time series data and setting a retention policy to automatically clear outdated data.Secondly,implementation of T-Redis time series database.On the basis of native Redis,this thesis implements a time series database,including the creation of time series objects and compression rules,data point writing,multidimensional query,and Gorilla compression algorithm.Thirdly,this thesis tests the functionality of the T-Redis time series database and analyzes and compares the performance of T-Redis and native Redis.First,testing whether T-Redis is available.Then comparing T-Redis and native Redis in three aspects: data write performance,data query performance,and occupation of memory space.The test results show that T-Redis has a decrease in data write performance compared to native databases,but it improves data query speed and reduces memory space consumption.Through the research in this paper,Redis' s ability to process time series data is expanded,existing data structures of Redis are enriched,and it provides some practical experience for the research on storage and query of time series data based on Redis.
Keywords/Search Tags:Redis, time series, data compression
PDF Full Text Request
Related items