论文部分内容阅读
许多网络应用都是以数据采集为基础的,那么一个高效的数据采集模块就非常重要。文中是对Linux下多线程数据采集技术的研究与实现。首先对数据采集中数据存储缓冲区的设置做出分析,并设计出了模型。其次为了实现数据采集的高效性,用到了Linux下的多线程技术,多线程下对共享资源的访问控制又引出了线程同步的问题,并为了实现线程同步引入了互斥锁的应用。最后建立了一个数据采集模块的基本模型。
Many network applications are based on data acquisition, then an efficient data acquisition module is very important. The article is on Linux multi-threaded data acquisition technology research and implementation. First of all, we set up the data storage buffer in data acquisition and make a model. Second, in order to achieve the high efficiency of data acquisition, the multi-threading technology under Linux is used. The access control to shared resources under multi-threading also leads to the problem of thread synchronization. In order to realize thread synchronization, the application of mutual exclusion lock is introduced. Finally, a basic model of data acquisition module is established.