Font Size: a A A

Design And Implementation Of Android Instant Messaging System Based On Adaptive Heartbeat

Posted on:2022-05-08Degree:MasterType:Thesis
Country:ChinaCandidate:H Y QiaoFull Text:PDF
GTID:2518306575966569Subject:Computer technology
Abstract/Summary:PDF Full Text Request
With the rapid development of technology,instant communication technology has changed people's lifestyles completely.The core of instant messaging is that the real-time nature of the messages between the two parties in communication.This requires that the mobile terminal and server to maintain a real-time communication link,that is,long connection.The heartbeat mechanism is currently the mainstream way for instant messaging applications to maintain a long connection between the two parties.However,the traditional heartbeat mechanism has the disadvantages of consumption of client traffic,power,and CPU resources excessively due to send heartbeat packets periodically.So how to adjust the heartbeat interval dynamically to optimize the heartbeat mechanism is urgently needed.The main contents of this thesis are as follows:1.This thesis mainly analyzes and studies the problems such as poor adaptability of heartbeat mechanism of instant messaging applications on Android platform and serious waste of mobile device resources,studies heartbeat mechanism and related machine learning algorithms,analyzes its basic principles and specific application scenarios,and provides a theoretical basis for proposing a new algorithm model.2.This thesis focuses on comparing the traditional BP neural network algorithm with the genetic algorithm optimized BP neural network algorithm and the error degree of the LSTM algorithm in network quality prediction.The experimental results show that compared with the classic BP algorithm and LSTM algorithm,the BP algorithm optimized by the genetic algorithm has higher prediction accuracy.Therefore,the algorithm can be used to predict the current network traffic trend in time,and it can be better for adjusting the heartbeat interval dynamically.To a certain extent,it can improve the flexibility and robustness of the heartbeat mechanism.Because the time sequence and long-term performance of the network traffic,This thesis proposes an adaptive heartbeat strategy which uses genetic BP algorithm to predict the bandwidth occupancy rate of the current network,and then dynamically adjusts the heartbeat interval according to the prediction results combined with dichotomy.3.This thesis studies the core mechanism of instant communication application on Android platform,and designs and implements the Android instant communication system based on adaptive heartbeat according to the project requirements,and compares it with the application of instant communication which adopts traditional heartbeat mechanism.The experimental results show that the application based on the adaptive heartbeat strategy can reduce the consumption of resources such as client traffic,power,and CPU to a certain extent.
Keywords/Search Tags:Heartbeat mechanis, BP neural network, Genetic algorithm, Dichotomy, Adaptive
PDF Full Text Request
Related items