CN109660584A - A kind of method and communication means and communication system of client and the long connection of server foundation - Google Patents

A kind of method and communication means and communication system of client and the long connection of server foundation Download PDF

Info

Publication number
CN109660584A
CN109660584A CN201710949296.5A CN201710949296A CN109660584A CN 109660584 A CN109660584 A CN 109660584A CN 201710949296 A CN201710949296 A CN 201710949296A CN 109660584 A CN109660584 A CN 109660584A
Authority
CN
China
Prior art keywords
long connection
server
module
mobile client
business datum
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201710949296.5A
Other languages
Chinese (zh)
Inventor
杨成旭
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Alibaba Group Holding Ltd
Original Assignee
Alibaba Group Holding Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Alibaba Group Holding Ltd filed Critical Alibaba Group Holding Ltd
Priority to CN201710949296.5A priority Critical patent/CN109660584A/en
Publication of CN109660584A publication Critical patent/CN109660584A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/14Session management
    • H04L67/143Termination or inactivation of sessions, e.g. event-controlled end of session
    • H04L67/145Termination or inactivation of sessions, e.g. event-controlled end of session avoiding end of session, e.g. keep-alive, heartbeats, resumption message or wake-up for inactive or interrupted session

Abstract

The embodiment of the present application provides the method and communication means and communication system of a kind of client and the long connection of server foundation, wherein, when the method is applied to mobile client, the mobile client includes long connection service module and one or more Service Processing Modules, and the long connection service module is communicated with long connection server by long connection communication link;The described method includes: long connection service module receives the business datum that long connection server is sent by long connection communication link, wherein the business datum carries synchronous point information;According to the business datum and corresponding synchronous point information, notification information is generated;The notification information is sent in one or more Service Processing Modules.The embodiment of the present application can receive the business datum of server push based on healthy and strong long connection communication link, mobile client at any time, improve the availability of long connection service.

Description

A kind of method and communication means and communication of client and the long connection of server foundation System
Technical field
This application involves fields of communication technology, establish more particularly to a kind of communication means, a kind of client and server Method, a kind of mobile client, a kind of server, a kind of client and the server of long connection establish long connection device and A kind of communication system.
Background technique
With popularizing for mobile terminal, development of Mobile Internet technology also and then grows up, and mobile Internet refers to internet Technology, platform, business model and application in conjunction with mobile communication technology and the movable general name practiced.
In current mobile Internet solution, in most cases, the client of mobile interchange application program and Server end is communicated by HTTP/HTTPS, and specifically, client initiates HTTP/HTTPS request, and server-side returns to number According to this traditional request-reply mode is exactly that typical short connection has communicated it is characterized in that primary connection is established in primary call Connection breaking in achievement, workflow are as follows: connection -> transmission data -> closing connection.
However, above-mentioned this transmission mode has following defects that
(1) real-time is not high
Because HTTP/HTTPS connection uses the mode of " request-response ", need first to establish connection in request, And after needing user end to server to issue request, server end could reply data.The characteristics of this mode is safety Height, but be first to connect to operate again every time, efficiency is relatively low, is unable to satisfy the relatively high business demand of requirement of real-time.
(2) TCP establishes the loss of connection
For HTTP/HTTPS, just release TCP connection is completed in communication every time, and HTTP/HTTPS request next time arrives When, it re-establishes connection and carries out data transmission, and each TCP connection requires three-way handshake, causes the loss of time and resource.
Summary of the invention
In view of the above problems, it proposes the embodiment of the present application and overcomes the above problem or at least partly in order to provide one kind The method and a kind of corresponding movement of a kind of communication means, a kind of client and the long connection of server foundation that solve the above problems Client, a kind of server, a kind of client and server establish the long device connected and a kind of communication system.
To solve the above-mentioned problems, the embodiment of the present application discloses a kind of communication means, is applied in mobile client, institute Stating mobile client includes long connection service module and one or more Service Processing Modules, the long connection service module with Long connection server is communicated by long connection communication link;The described method includes:
Long connection service module receives the business datum that long connection server is sent by long connection communication link, wherein The business datum carries synchronous point information;
According to the business datum and corresponding synchronous point information, notification information is generated;
The notification information is sent in one or more Service Processing Modules.
Preferably, the industry that long connection server is sent is received by long connection communication link in the long connection service module Before the step of data of being engaged in, further includes:
Data acquisition request is generated, the data acquisition request includes first synchronous point information;
The data acquisition request is sent to long connection server by long connection communication link.
Preferably, the data acquisition request includes multiple business processing requests, wherein the business processing request is used for Corresponding one or more business datums.
Preferably, the method also includes:
The data response message that Service Processing Module is returned based on the notification information is received, the data response message is used The corresponding business datum stored in long connection server is updated processing;
The data response message is sent to long connection server by long connection communication link.
Preferably, the business datum that server is sent is received by long connection communication link in the long connection service module The step of before, further includes:
Carry out long connection service initialisation;
Create the Socket connection between the mobile client and long connection server;
Judge whether the Socket connection is successfully established;
If so, establishing the long connection communication link between the mobile client and long connection server;
Operation is retried if it is not, then executing.
Preferably, described execution the step of retrying operation, includes:
By retrying connection number subtracts one in real time, wherein the initial value for retrying connection number in real time is that preset maximum retries Connection number;
If the connection number that retries in real time is greater than default connection number thresholding, it is determined that delay duration, and according to the delay When long delay after, continue to execute the step of the Socket connection between the creation mobile client and long connection server Suddenly;
If the connection number that retries in real time is less than or equal to default connection number thresholding, determine that current long connection service can not With.
Preferably, in the step for establishing the long connection communication link between the mobile client and long connection server After rapid, further include;
Pass through the long connection server sending device information of the long connection communication chain road direction;
Receive the equipment response message that the long connection server is returned based on the facility information, the equipment response letter Breath is used to indicate the corresponding service server of the facility information and is in active state;
If being not received by the long connection server in first time period is based on the facility information, the equipment of return Response message then determines that the long connection communication link disconnects, and continues to execute the step of execution retries operation.
Preferably, the method also includes:
After receiving the equipment response message, heart beat cycle is determined, and connect to long according to the heart beat cycle Server sends heartbeat message;
When being not received by what long connection server returned in second time period, the heartbeat for the heartbeat message is rung When answering message, then determine that the long connection communication link disconnects, and continue to execute the step of execution retries operation.
Preferably, described the step of carrying out long connection service initialisation, includes one of set forth below or combines:
Create the type of Service Processing Module and the mapping relations of call back function;
Corresponding data decryptor is added for the type of Service Processing Module;
The information of the long connection server of initialization and/or the information of the corresponding application program of the mobile client;
The case where switching to backstage for application program setting is monitored;
It is monitored for application program from setting the case where switching to front end from the background;Or,
Add the monitoring of user's logging state.
Preferably, described according to the business datum and corresponding synchronous point information, the step of generating notification information Before, further includes:
Store the business datum and corresponding synchronous point information.
The embodiment of the present application also discloses a kind of communication means, is applied in server, the server and mobile client End is communicated by long connection communication link;The described method includes:
Business datum is received by long connection communication link;
Generate the corresponding synchronous point information of the business datum;
The business datum and corresponding synchronous point information are sent to mobile visitor by the long connection communication link In the end of family.
Preferably, the business datum and corresponding synchronous point information are passed through into the long connection communication link described It is sent to before the step in mobile client, further includes:
The corresponding synchronous point information of the business datum is stored in the data center.
Preferably, the method also includes:
The data acquisition request that mobile client is sent is received by the long connection communication link, the data acquisition is asked It asks including first synchronous point information;
It based on the first synchronous point information, is compared, judges with the synchronous point information stored in the data center With the presence or absence of not synchronous business datum;
The business datum not synchronized if it exists then sends out the not synchronous business datum and newest synchronous point information It send to the mobile client.
Preferably, the method also includes:
The data response message that mobile client is sent, the data response letter are received by the long connection communication link Breath includes that the Service Processing Module of mobile client obtains the message generated after business datum;
Response message based on the data is updated processing to the corresponding data of data center.
Preferably, the business datum and corresponding synchronous point information are passed through into the long connection communication link described It is sent to before the step in client, further includes:
The facility information that mobile client is sent is received by the long connection communication link;
Based on the facility information, generating device response message, the equipment response message is used to indicate the equipment letter It ceases corresponding service server and is in active state;
The equipment response message is returned to mobile client.
Preferably, the method also includes:
The heartbeat message that mobile client is sent is received by the long connection communication link;
Based on the heartbeat message, corresponding heartbeat response message is returned to mobile client.
The embodiment of the present application also discloses the method for a kind of client and the long connection of server foundation, and the client includes Mobile client, the server include long connection server, which comprises
Carry out long connection service initialisation;
Create the Socket connection between the mobile client and long connection server;
Judge whether the Socket connection is successfully established;
If so, establishing the long connection communication link between the mobile client and long connection server;
Operation is retried if it is not, then executing.
Preferably, described execution the step of retrying operation, includes:
By retrying connection number subtracts one in real time, wherein the initial value for retrying connection number in real time is that preset maximum retries Connection number;
If the connection number that retries in real time is greater than default connection number thresholding, it is determined that delay duration, and according to the delay When long delay after, continue to execute the step of the Socket connection between the creation mobile client and long connection server Suddenly;
If the connection number that retries in real time is less than or equal to default connection number thresholding, determine that current long connection service can not With.
Preferably, described the step of carrying out long connection service initialisation, includes one of set forth below or combines:
Create the type of Service Processing Module and the mapping relations of call back function;
Corresponding data decryptor is added for the type of Service Processing Module;
The information of the long connection server of initialization and/or the information of the corresponding application program of the mobile client;
The case where switching to backstage for application program setting is monitored;
It is monitored for application program from setting the case where switching to front end from the background;Or,
Add the monitoring of user's logging state.
Preferably, described to judge that the step of whether the Socket connection is successfully established includes:
Read the return value that connection is established;
According to the return value, judge whether the Socket connection is successfully established.
Preferably, the method also includes:
Mobile client passes through the long connection server sending device information of the long connection communication chain road direction;
If being not received by the long connection server in first time period is based on the facility information, the equipment of return Response message then determines that the long connection communication link disconnects, and continues to execute the step of execution retries operation.
Preferably, the method also includes:
After receiving the equipment response message, heart beat cycle is determined, and connect to long according to the heart beat cycle Server sends heartbeat message;
When being not received by the heartbeat response message for heartbeat message return in second time period, then determine The long connection communication link disconnects, and continues to execute the step of execution retries operation.
The embodiment of the present application also discloses a kind of mobile client, the mobile client include long connection service module with And one or more Service Processing Modules, the long connection service module and long connection server by long connection communication link into Row communication;
The length connects service module
Business datum receiving submodule, for receiving the business number that long connection server is sent by long connection communication link According to, wherein the business datum carries synchronous point information;
Notification information generates submodule, for generating notice according to the business datum and corresponding synchronous point information Information;
Sending submodule, for the notification information to be sent in one or more Service Processing Modules.
Preferably, the long connection service module further include:
Data acquisition request generates submodule, and for generating data acquisition request, the data acquisition request includes first Synchronous point information;
Data acquisition request sending submodule, for the data acquisition request to be sent to by long connection communication link Long connection server.
A kind of server is also disclosed in the embodiment of the present application, and the server includes long connection server, the long connection clothes Business device is communicated with mobile client by long connection communication link;The length connects server
Business datum receiving module, for receiving business datum by long connection communication link;
Synchronous point generation module, for generating the corresponding synchronous point information of the business datum;
Business datum sending module, for the business datum and corresponding synchronous point information to be passed through the long connection Communication link is sent in mobile client.
Preferably, the server further include:
Synchronous point memory module, for storing the corresponding synchronous point information of the business datum in the data center.
Preferably, the server further include:
Data acquisition request receiving module, for receiving the number that mobile client is sent by the long connection communication link According to acquisition request, the data acquisition request includes first synchronous point information;
Synchronous judgment module, for being based on the first synchronous point information, with the synchronous point stored in the data center Information is compared, and judges whether there is not synchronous business datum;
Non- synchrodata sending module, for when there is not synchronous business datum, then by the not synchronous business Data and newest synchronous point information are sent to the mobile client.
The device of a kind of client and the long connection of server foundation is also disclosed in the embodiment of the present application, and the client includes moving Dynamic client, the server include long connection server, and described device includes:
Initialization module, for carrying out long connection service initialisation;
Socket connection creation module connects for creating the Socket between the mobile client and long connection server It connects;
Judgment module, for judging whether the Socket connection is successfully established, if so, calling long connection communication link Creation module retries module if it is not, then calling;
Long connection communication link establishment module, the long company for establishing between the mobile client and long connection server Connect communication link;
Module is retried, retries operation for executing.
Preferably, the module that retries includes:
Reconnection number of operations submodule, for by retrying connection number subtracts one in real time, wherein described to retry connection number in real time Initial value is that preset maximum retries connection number;
Submodule is retried, if being greater than default connection number thresholding for the connection number that retries in real time, it is determined that delay duration, And after being delayed according to the delay duration, Socket connection creation module is called;
Decision sub-module is serviced, if being less than or equal to default connection number thresholding for the connection number that retries in real time, is sentenced Long connection service is unavailable before settled.
Preferably, described device further include:
Facility information sending module, for passing through the long connection server sending device letter of the long connection communication chain road direction Breath;
First long connection disconnects determination module, if for being not received by the long connection server in first time period Based on the facility information, the equipment response message of return then determines that the long connection communication link disconnects, and calls and retry mould Block.
Preferably, described device further include:
Heartbeat message sending module, for after receive the equipment response message, determining heart beat cycle, and according to The heart beat cycle sends heartbeat message to long connection server;
Second long connection disconnects determination module, is not received by second time period for the heartbeat message for working as When the heartbeat response message of return, then determine that the long connection communication link disconnects, and call and retry module.
The embodiment of the present application also discloses a kind of communication system, including mobile client, service server, long connection service Device, the mobile client include long connection service module and one or more Service Processing Modules, the long connection service Module connect server with the length and is communicated by long connection communication link;
The service server is used for, and sends business datum to long connection server;
The long connection server is used for, and generates the corresponding synchronous point information of the business datum, and by the business number Accordingly and corresponding synchronous point information is sent in long connection service module by long connection communication link;
The long connection service module is used for, and according to the business datum and corresponding synchronous point information, generates notice Information, and, the notification information is sent in one or more Service Processing Modules;
The Service Processing Module is used for, and extracts business datum from the notification information, and to the business datum into Row business processing.
Preferably, the Service Processing Module to the long connection service module by being registered, to use long connection Service.
Preferably, the communication system further include:
Long connection establishment module, the length for establishing between the long connection server and the long connection service module connect Connect communication link.
A kind of device is also disclosed in the embodiment of the present application, comprising:
One or more processors;With
One or more machine readable medias of instruction are stored thereon with, are executed when by one or more of processors When, so that described device executes above-mentioned method.
One or more machine readable medias are also disclosed in the embodiment of the present application, are stored thereon with instruction, when by one or more When a processor executes, so that device executes above-mentioned method.
The embodiment of the present application includes the following advantages:
In the embodiment of the present application, based on healthy and strong long connection communication link, mobile client can receive service at any time The business datum of device push improves the availability of long connection service.
The embodiment of the present application can also carry out mobile client and server to the business datum by synchronous point information Management by synchronization ensure that the synchronous of the data between server and mobile client.
Detailed description of the invention
Fig. 1 is a kind of structural block diagram of communications system embodiment of the application;
Fig. 2 is a kind of step flow chart of communication means embodiment one of the application;
Fig. 3 is a kind of step flow chart of communication means embodiment two of the application;
Fig. 4 is a kind of step flow chart of communication means embodiment three of the application;
Fig. 5 is the step flow chart of a kind of client of the application and the embodiment of the method for the long connection of server foundation;
Fig. 6 is a kind of structural block diagram of mobile client embodiment of the application;
Fig. 7 is a kind of structural block diagram of server example of the application;
Fig. 8 is the structural block diagram of a kind of client of the application and the Installation practice of the long connection of server foundation;
Fig. 9 is a kind of structural schematic diagram of system embodiment of the application.
Specific embodiment
In order to make the above objects, features, and advantages of the present application more apparent, with reference to the accompanying drawing and it is specific real Applying mode, the present application will be further described in detail.
Referring to Fig.1, a kind of structural block diagram of communications system embodiment of the application is shown, which at least can be with Including mobile client, service server, long connection server.Wherein, the mobile client includes long connection service module And one or more Service Processing Modules, the long connection service module connect server with the length and pass through long connection communication Link is communicated.
The service server is used for, and sends business datum to long connection server;
The long connection server is used for, and generates the corresponding synchronous point information of the business datum, and by the business number Accordingly and corresponding synchronous point information is sent in long connection service module by long connection communication link;
The long connection service module is used for, and according to the business datum and corresponding synchronous point information, generates notice Information, and, the notification information is sent in one or more Service Processing Modules;
The Service Processing Module is used for, and extracts business datum from the notification information, and to the business datum into Row business processing.
Specifically, the embodiment of the present application can be applied in the communication of mobile client and server, implement in the application In example, mobile client can be communicated with server by long connection communication link.In the concrete realization, the application is implemented Server in example may include long connection server and service server.Wherein, long connection server and service server Can be shared module, be also possible to separately positioned module, long connection server be mainly responsible for mobile client creation and Keep Socket connection;Service server is mainly responsible for processing with the processing of all business datums of mobile client.
Application program belonging to the mobile client may be mounted in mobile terminal, may include length in mobile client Service module and Service Processing Module are connected, refering to what is shown in Fig. 1, the long connection service of long connection server and mobile client Module is by Socket long connection communication, and in a kind of preferred embodiment of the embodiment of the present application, communication system can also include Long connection establishment module (not shown), the long connection establishment module is for establishing the long connection server and the length even Connect the long connection communication link between service module.
The Service Processing Module of the client such as modules such as message center, stroke and discovery are by servicing mould to the long connection Block is registered, to use long connection service.When there is business demand, service server can call relevant interface, by data It is pushed to long connection server, next data-pushing is serviced mould to long connection by Socket long connection by long connection server Block, finally data broadcasting is notified each Service Processing Module by long connection service module.
The long connection service module of the embodiment of the present application is service server and service customer end (i.e. mobile client) Bridge, function is relatively more, such as: it is mainly communication link initialization, business initializtion and long connection in initial phase Creation;After creating successful connection, this connection is mainly safeguarded with heartbeat, carries each Service Processing Module when sending data Synchronous point information, this is related to the management work of synchronous point information;Before sending data, the compression processing of data is first done, is used to Bandwidth pressure is reduced, finally sends the channel socket by reading and writing logic for data;When receiving data, decompress first Processing, while by business datum storage to database, Service Processing Module processing is notified by data broadcasting, after having handled also There is storage synchronous point information;When build successively lose lose or send data failure when, retry mechanism ensures to improve the available of long connection service Property.
The long connection service module of the embodiment of the present application can be used by multiple business processing module, for example, multiple industry Business processing module may include message box submodule in given client end, discovery module, offline packet update module, patch packet more New module, switchgear distribution module etc., particular condition in use is as described below:
Message box submodule, using long connection communication link, whether real-time informing user has new information,.
Discovery module, whether someone thumbs up, evaluates model etc. real-time informing user.
Offline packet update module is pushed to client when H5 business function changes in real time, executes and updates operation.
Patch packet update module pushes patch packet in real time and is updated as the wired upper crash of iOS client.
Switchgear distribution module, service line have many switch settings, are to obtain switchgear distribution by sending HTTP request before, The embodiment of the present application can pass through long interface channel real time down.Below by way of each specific embodiment to the embodiment of the present application The principle of communication system is illustrated.
Referring to Fig. 2, a kind of step flow chart of communication means embodiment one of the application is shown, the embodiment of the present application can To be applied in mobile client, which is communicated with long connection server by long connection communication link.
The embodiment of the present application can specifically include following steps:
Step 201, long connection service module receives the business number that long connection server is sent by long connection communication link According to, wherein the business datum carries synchronous point information;
The embodiment of the present application can be applied to long connection server and be based on push mode, carry out the scene of data-pushing.
The data that the business datum can send for service server to long connection server, service server are connected to long Server can carry the information such as the user userid of service identification and/or push when sending business datum.
After long connection server receives business datum, the business datum can be stored in the data center, and generate base In the synchronous point information of corresponding Service Processing Module, will be specifically described in next embodiment about synchronous point information.
Then, it is medium to be added to push queue by long connection server for the business datum and corresponding synchronous point information To push data into the long connection service module of mobile client by Socket long connection when taking turns to this message.
It after long connection service module receives data, is parsed, obtains business datum and corresponding synchronous point letter Breath.
In one embodiment, long connection service module can be in the local database to the business datum and synchronization Point information carries out serializing processing, so that it is guaranteed that data increment, order transfer.
Step 202, according to the business datum and corresponding synchronous point information, notification information is generated;
Step 203, the notification information is sent in one or more Service Processing Modules.
After serializing work, the long connection service module of mobile client can generate notice letter according to the business datum It ceases, and sends the notification information to the Service Processing Module of client, business datum is carried out by Service Processing Module subsequent Processing.
In one embodiment, which can be broadcast to the business processing of client by long connection service module In module.
In the embodiment of the present application, based on healthy and strong long connection communication link, mobile client can receive long company at any time The business datum for connecing server push improves the availability of long connection service.
The embodiment of the present application can also carry out mobile client and server by synchronous point information to the business datum Data management by synchronization ensure that the synchronous of the data between server and client.
In view of in mobile terminal network state it is unstable, when long connection server is to user's propelling data, if with The mobile terminal at family is in suspension state, this message will lose.Therefore the arrival rate in order to guarantee propelling data, this Shen Please embodiment provide push and pull two kinds of operating modes, if propelling data fails, user can be under pull mode The long connection server data to be pushed are taken, does so and data arrival rate can be improved.
Pull mode occurs after the long connection of each foundation, and this occasion is special in entire mobile client life cycle It is not more, connection behaviour is established as that can re-execute when app is initially opened the long connection of needs foundation, app does not receive heartbeat response message Make, therefore can still enter pull mode.
Referring to Fig. 3, a kind of step flow chart of communication means embodiment two of the application is shown, the embodiment of the present application can To be applied in mobile client, suitable for the scene of pull mode, it can specifically include following steps:
Step 301, long connection service initialisation is carried out;
In the concrete realization, initial work can be with Exactly-once in the life cycle of entire application program app.
In a kind of preferred embodiment of the embodiment of the present application, initial work can include but is not limited to following one kind Or it combines:
Create the type of Service Processing Module and the mapping relations of call back function;For the type addition of Service Processing Module Corresponding data decryptor;Initialize the information of server and/or the information of the corresponding application program of the mobile client;For Application program switches to the setting of the case where backstage and monitors;It is monitored for application program from setting the case where switching to front end from the background; Or, the monitoring of addition user's logging state.
Specifically, being illustrated below to the case where various initialization:
1) type of Service Processing Module and the mapping relations of call back function are created.
The process for creating the type (type) of Service Processing Module and the mapping relations of call back function is properly termed as service line Initialization a, wherein type represents a Service Processing Module.
For example, if Service Processing Module is message center module, if message center module makes to realize push in real time When with long connection service, can define type is AT_TRIPWMC_NOTIFY, and call back function class is TRIPMsgCenterRPCSyncService realizes call back function processing module in such, when there is new data, long connection Service by socket long connection communication link by newest data-pushing to mobile client, Data will be received in the call back function of TRIPMsgCenterRPCSyncService.
2) corresponding data decryptor is added for the type of Service Processing Module.
After the long connection service module of client obtains data from server by long interface channel, it will be counted to realize According to calling service side is passed to, data decryptor can be added for each type herein, for receiving data, because in 1) It is the binding for realizing type and call back function, thus may be implemented to handle the data received in call back function.
3) information of server and/or the information of the corresponding application program of the mobile client are initialized.
As an example, the information of server can include but is not limited to: server address and port numbers.Using journey The information of sequence can include but is not limited to: Apply Names and application version.
In the embodiment of the present application, setting server address can be used for being arranged with server communication the letter of application program Breath can be used for notifying server with the mobile client of its communication which to be using which version, the purpose for the arrangement is that allowing clothes Business device identifies the identity information of mobile client.
For socket service, it is 443 that its port numbers, which can be set,.
4) the case where switching to backstage for application program setting is monitored.
Monitoring when App cuts backstage is added herein, switches to backstage to detect application program in time.
In the concrete realization, it is monitored due to there is the case where switching to backstage for application program setting, when App is switched to When backstage, can send long connection this long interface channel of server of out code notice first will be closed, to reduce resource Waste, then deletes all data decryptors, prevents system crash crash, this is because after App switches to backstage, the App meeting Fallen by operating system kill, at this time if there are also data decryptor, system is easy crash.
5) it is monitored for application program from setting the case where switching to front end from the background.
Monitoring when addition App arouses to front end herein, is aroused with detecting application program in time to front end.It is implementing In, due to existing for application program from monitoring is arranged the case where switching to front end from the background, when App is aroused again to front end When, long connection communication link can be re-established.
6) monitoring of user's logging state is added.
In the embodiment of the present application, it supports to press User ID PUSH message, therefore, mobile client needs in time step on user Related news whether record are reported to long connection server, add the monitoring of user's logging state thus.
In the concrete realization, since there are the monitorings of user's logging state, when users log on, mobile client can be to The instruction of server end transmission user bound;When user logs off, mobile client can send unbundlings to server-side and refer to It enables, so that server end be allowed to know that the mobile client of this current long connection communication link has logged out login, cannot press again PUSH message is removed according to User ID.
Step 302, the Socket connection between the mobile client and server is created;
In the concrete realization, can call Basic API create Socket, and call Basic API realize data transmission and It receives.
In one embodiment, if the system that mobile client is currently located is iOS system, since iOS system is base In the operating system of FreeBSD (FreeBSD is a type UNIX operating system) exploitation, in FreeBSD operating system, BSD Socket is realized with C language completely, and can be used in Objective-C code, but this primary Socket without Method accesses the included network characteristic (wifi, cellular network) of iOS operating system.If there is no thread accesses bee in iOS system Nest network, it can be automatically closed to save electricity, but primary Socket will not automatically open the wifi of equipment, if long connect The service of connecing is based on primary Socket, with regard to will appear very big problem.
Similar with the Socket socket of Windows system, iOS system provides CFNetwork and carries out Socket communication, CFNetwork is the high performance framework of bottom (framework), and BSD socket is encapsulated and extended, is provided With the function of HTTP/FTP/TCP/DNS server communication, (Cocoa is that Apple Inc. is created by Mac OS X to Cocoa The API of primary object-oriented) in Webkit and NSURL be dependent on CFNetwork.In addition, CFNetwork is integrated with Runloop mechanism, each thread has the run-loop of oneself, therefore the event source in CFNetwork can be added to Processing network event is removed in run-loop, the advantage of doing so is that allow developer without in the case where considering multithreading, it can be with Operate network protocol.Meanwhile CFNetwork is integrated into iOS system, and cellular network can be kept not to be automatically closed, solution Determined BSD Socket the problem of.
In the embodiment of the present application, it can realize that long connection communication for service, CFNetwork are mainly wrapped based on CFNetwork API: the first module for including two modules is CFSocket, and major function is the TCP link of building client and server, and And it is integrated into run-loop;Second module is CFStream, provides a kind of and device-independent data exchange Side is below introduced creation Socket and the Key Functions being written and read.
1, Basic API is called to create Socket
The first, socket is created
In the concrete realization, CFNetwork provides an easily creation function CFStreamCreatePairWithSocketToHost, can be a pair of for given host name and port creation Socket, one is used to read, and one for writing.Call API as follows: CFStreamCreatePairWithSocketToHost(kCFAllocatorDefault,(__bridge CFStringRef) [url host],[[url port]integerValue],&readStream,&writeStream);
Wherein, url represents the address of long connection server, and CFNetwork frame is responsible for host name being converted to IP address, Port numbers are converted into network bytes sequence, readStream represents the byte stream for reading data, and writeStream is represented For writing the byte stream of data.
The second, data flow binds call back function
Data flow is bound into a call back function readSocketCallback, corresponding number can be handled in this function According to API is as follows:
CFStreamClientContext ctx={ 0, (_ _ bridge void*) (self), NULL, NULL, NULL };
CFOptionFlags registeredEvent=(kCFStreamEventHasBytesAvailable | kCFStreamEventEndEncountered|kCFStreamEventErrorOccurred| kCFStreamEventOpenCompleted);
CFReadStreamSetClient(readStream,registeredEvents, readSocketCallback,&ctx));
Wherein, CFReadStreamSetClient indicates the bindings of reading data flow readStream, first ginseng Number represents the stream of generation event, and all each functions for processing stream have the application for being directed toward it;Second parameter generation Table wants the stream event received, and kCFStreamEventHasBytesAvailable representative has the data that can be read, KCFStreamEventErrorOccurred represents operation and mistake occurs, and kCFStreamEventEndEncountered is represented The end of byte stream is reached, kCFStreamEventOpenCompleted indicates that Socket is successfully opened;Third parameter is The call back function of binding, is passed into as event;4th parameter is represented as stream assembly CFStreamClientContext structural body is directed toward oneself info object and call back function come the context pointers created, leads to It can be often a self reference.
For writing data flow writeStream, CFNetwork provides following API:
CFWriteStreamSetClient(writeStream,registeredEvents, writeSocketCallback,& ctx));
Its parameter definition is similar with CFReadStreamSetClient.
Runloop (incident management object) is added in third, data flow
By data flow be added runloop after, client just can in next runloop distribution processor data flow, API is such as Shown in lower:
CFReadStreamScheduleWithRunLoop(readStream,CFRunLoopGetCurrent(), kCFRunLoopCommonModes);
CFWriteStreamScheduleWithRunLoop(writeStream,CFRunLoopGetCurrent(), kCFRunLoopCommonModes);
Wherein, CFRunLoopGetCurrent () returns to current thread default operation circulation, and runloop operational mode is kCFRunLoopCommonModes。
4th, flow data is opened
It needs that CFReadStreamOpen is called to open reading flow before using flow data, calls CFWriteStreamOpen opening writes data flow.
5th, start runloop
It calls CFRunLoopRun (), starts runloop, because being added to read-write data flow in thirdly In runloop, need to do start-up operation in this step.
2, Basic API is called to realize sending and receiving for data
In above-mentioned second point, time data stream readStream is tied up with call back function readSocketCallback It is fixed, write data flow writeStream and call back function writeSocketCallback and bound, it is long connect be successfully established with Afterwards, client will receive data and realize in function readSocketCallback, and wanting to send data to server end need to be It is realized in function writeSocketCallback.
ReadSocketCallback function is as follows:
readSocketCallback(CFReadStreamRef stream,CFStreamEventType event, void*myPtr);
Wherein, parameter stream represents the character stream received, and parameter event represents received stream event, myPtr representative office The object of character stream is managed, myPtr parameter is passed to when calling CFReadStreamSetClient in above-mentioned second point, according to not Same event type has different processing clients.
Specifically, event value is that kCFStreamEventOpenCompleted indicates that long communication channel connects and is successfully established; Event value is that kCFStreamEventHasBytesAvailable expression has the data that can be read at present, connects lower utilization and follows The data of stream are all read local character string by constantly cumulative by ring;Event value is KCFStreamEventEndEncountered is indicated to have read the end of byte stream, is needed to notify upper layer module this time Data are successfully received, and CFReadStreamClose is called to close stream, are called CFReadStreamUnscheduleFromRunLoop takes down stream from runloop.Event value is KCFStreamEventErrorOccurred indicates socket operation failure.The processing client of writeSocketCallback End is similar with readSocketCallback, and details are not described herein.
Step 303, judge whether the Socket connection is successfully established;If so, 304 are thened follow the steps, if it is not, then executing Step 305;
In a kind of preferred embodiment of the embodiment of the present application, step 303 be can further include: read what connection was established Return value;According to the return value, judge whether the Socket connection is successfully established.
Specifically, can judge whether Socket connection is successfully established by the return value that connection is established, for example, if returning Returning value is kCFStreamEventOpenCompleted, then can be determined that bottom Socket long connection creates successfully;If return value For kCFStreamEventErrorOccurred, then it can be determined that bottom Socket long connection creation failure.
Step 304, the long connection communication link between the mobile client and server is established;
When determining that Socket connection is successfully established, mobile client and server can be by<ports IP+>in network The TCP layer of agreement establishes long connection communication link, next can carry out data communication on this link.
Step 305, it executes and retries operation.
In the embodiment of the present application, when determining that Socket connection establishes unsuccessful, it can execute and retry operation.
In a kind of preferred embodiment of the embodiment of the present application, step 305 may include following sub-step: will retry in real time Connection number subtracts one, wherein the initial value for retrying connection number in real time is that preset maximum retries connection number;If the real-time weight Try connection number and be greater than default connection number thresholding, it is determined that delay duration, and according to delay duration delay after, continue to execute institute State step 302;If the connection number that retries in real time is less than or equal to default connection number thresholding, current long connection service is determined not It can use.
In the concrete realization, mobile terminal is to be connected by wireless signal with base station, and base station forwards the information to long connection Server, when meeting the barriers such as high building or switching base station, long connection is easy to break, meanwhile, for long connection service For device, each long connection can occupy a port, and communication failure is also easy when loading excessive, in order to avoid leading to because of network Letter or server health are bad and cause long connection service unavailable, and retry mechanism can be set in the embodiment of the present application, and sets Maximum retries connection number.
Maximum, which retries connection number, indicates the number that can at most retry, for example, it is 15 that maximum, which can be set, to retry connection number.
When determining that Socket connection establishes unsuccessful, start to retry, real-time will retry connection number (when retrying for the first time, Retrying connection number in real time is that maximum retries connection number, i.e., the initial value for retrying connection number in real time is that preset maximum retries connection Number) subtract one, expression, which has wasted, once retries chance, judges to retry whether connection number is greater than default connection in real time after subtracting one Number thresholding (for example, numerical value 0), if it is not, indicating that number of retries has reached upper limit value, this vice-minister connection service is unavailable, if so, really Determine delay duration, and according to delay duration delay after, return to step 302, re-establish socket connection.
In the concrete realization, incremental state can be presented in the delay duration retried each time, such as delay 2S for the first time Execution retries, and second of delay 3S execution retries, etc..
The reason of being delayed herein is: building the major reason successively lost and lost is exactly that server overload is excessively high, this time-frequency Numerous request cannot not only respond, and can aggravate server burden instead, and the success of server response can be improved in delay operation Rate.
Step 306, mobile client passes through the long connection server sending device information of the long connection communication chain road direction;
In the embodiment of the present application, mobile client can send the facility information of local device to long connection server, Connection server long so just knows what concrete property is the equipment for establishing connection with it have.
In one embodiment, the such data of identification device information can be active message.
As the equipment letter that in a kind of preferable example of the embodiment of the present application, mobile client is sent to long connection server Breath can include but is not limited to: operating system, operating system version, app title where mobile client, are set app version number Standby mark, protocol version and network state etc..
For example, the example of a kind of pair of facility information is as follows:
{"osType":"iOS","osversion":"10.2","appName":"ALITRIP","appVer":" 8.1.2",
"dId":"ArweOM01VHF4J79C4etS21nSe0SN9M9IEmlP5gdANG1","network":" wifi","linkExtInfo":"ee3633ab346b358cb1da2bd3f1bd6912","linkVersion":" 2.0.0 ", " action ": " active " },
In order to distinguish different data types, above-mentioned action can be set to active, bottom can do data Compression and encryption.
Step 307, judge whether receive in first time period, the long connection server is based on the facility information The equipment response message of return;If so, thening follow the steps 308 and step 309;If it is not, thening follow the steps 305;In the application reality It applies in example, after sending active data to long connection server, the active data creation active order can be directed to Timer, whether long connection server end has return after which can be used for monitoring sending device information Value, which is equipment response message, wherein equipment response message can serve to indicate that the corresponding business of the facility information Server is in active state.
Specifically, the purpose of active order timer is to guarantee have corresponding service server to handle long link information, The socket long connection of foundation is based on mobile client and long connection server, if not as corresponding service server The service is still unavailable.For this purpose, mobile client connects server uploading device information to long, at the same create timer do it is super When handle, for example, 10S can be set by the timing of active order timer.
If not receiving the return value of long connection server in the timing length of active order timer, illustrate to grow Connection is broken, can execute step 305 at this time.
It should be noted that active order timer only needs to be implemented once in the embodiment of the present application, without repeating Execute, this is because waste a large amount of cpu resources if endless loop will be entered by repeating, build successively lose lose after retry it is primary such as Fruit still fails, and illustrates that long connection server does not have corresponding service server, services unavailable.
If receiving the return value of long connection server in the timing length of active order timer, illustrate following two Point: one, local App and long connection server have created Socket long connection;The second, at the corresponding service server of the App In active state, and service server has been obtained for the facility information of equipment.
When the return value for receiving long connection server in the timing length of active order timer, active can be ordered Enable timer be set to nil (nil is an object value, uses nil if when an object is set as sky).
In the concrete realization, mobile client can be in call back function readSocketCallback Equipment response letter is determined in (CFReadStreamRef stream, CFStreamEventType event, void*myPtr) Breath, event value are that kCFStreamEventEndEncountered expression completely receives an information, first pass through decompression, Then data parse, and distinguish protocol header and message body, last mobile client obtains following returned data:
{"action":"active","connnectCode":
" WIHJc2BxYcDAHTxtEbqYAK ", " keepLiveTime ": " 240 " },
Wherein action field indicates type of message, and connnectCode is generated by long connection server end, for marking Know unique field of equipment and long connection, long connection and facility information can be established mapping table, subsequent shifting by long connection server end The message that dynamic client is sent needs to carry this value, facilitates the identity of long connection server identification client, KeepLiveTime represents heart beat cycle.
In the embodiment of the present application, mobile client can also obtain user's logging state information, and the user is logged in Status information is sent to long connection server, to be bound or be unbinded operation.
Specifically, bind order can be sent to long connection server if mobile client is in logging state, for example, Specific instructions are as follows:
{"connnectCode":"WIHJc2BxYcDAHTxtEbqYAK","action":"bind"," SessionId ": " 3c008beb359660009e459c7bbaf6a721 " },
Wherein, connnectCode is for identifying unique field of equipment and long connection in return value, and action value is Bind, for distinguishing different upstream messages, sessionId is used for identity user userId, when long connection server receives this The corresponding user information of equipment is known that after item order, connection server long in this way can push different for different users Content.
Further, since the monitoring of User Status is added to, when User Status is by being not logged in long connection service initialisation Long connection server will be notified when becoming logging state, bind order be sent, when User Status becomes not step on by having logged in When record, unbind unbundling commands are sent, notify long connection server equipment is in be not logged in state, for pushing by userId Content cannot issue this equipment.
For example, the format of unbind order are as follows:
{"connnectCode":"WIHJc2BxYcDAHTxtEbqYAK","action":"unbind",
" sessionId ": " 3c008beb359660009e459c7bbaf6a721 " }, action unbind is used for area Divide different orders.
For bind/unbind message, response can not be received in time-out time with creation state status timer When, such message can be retransmitted, rather than re-creates Socket connection.
In the embodiment of the present application, when listening to mobile client and being switched to backstage, mobile client can Xiang Changlian It connects server and sends the message that action value is close.This kind of message is for notifying long connection server current device to break Fall long connection, long connection server can sufficiently provide the utilization rate of resource this resource allocation to other equipment.
Step 308, it determines heart beat cycle, and sends heartbeat message to long connection server according to the heart beat cycle, when It is not received by what long connection server returned in the second preset time period, for the heartbeat response message of the heartbeat message When, return to step 305;
In the concrete realization, established long connection communication link may be broken at any time, and therefore, the embodiment of the present application can be with Long interface channel is safeguarded using heartbeat packet.
Specifically, heartbeat timer heratTimer can be created, every a heart beat cycle keepLiveTime to length It connects server and sends heartbeat message, it, will if time-out does not receive the response that long connection server is directed to the heartbeat message Step 305 is executed, to re-establish socket connection, the purpose for the arrangement is that being used to guarantee the long connection with long connection server Channel keeps connection.
In the concrete realization, heart beat cycle can be arranged by long connection server, mobile client can be in call back function Heart beat cycle is parsed in middle state value kCFStreamEventEndEncountered.
For example, mobile client state value kCFStreamEventEndEncountered in call back function indicates complete Ground receives an information, first passes through decompression, and then data parse, and distinguishes protocol header and message body, last client obtains Following returned data " action ": " active ", " connnectCode ":
" WIHJc2BxYcDAHTxtEbqYAK ", " keepLiveTime ": " 240 " }, wherein keepLiveTime is represented Heart beat cycle 240S.
In practice, heart beat cycle can be arranged according to network state in long connection server, if equipment is in wifi state, Heart beat cycle can be set longer, for example, can be set to 240S;If equipment is in 4G/3G, period setting can be with short by one A bit, for example, can be set to 180S;If equipment is in weak net state, value can be smaller, for example, can be set to 120S;That is net A possibility that network state is better, and long connection is broken is smaller, and heart beat cycle can be longer, the period about long wave that can more reduce resource Take.
The plan of establishment of this heart beat cycle of the embodiment of the present application both can efficiently utilize cpu system resource, simultaneously With extensive flexibility, because server end can be modified at any time.
In the embodiment of the present application, heartbeat message does not have special service logic, it is merely meant that a kind of message body, in order to subtract The data volume transmitted less can use certain amount of byte representation.
For example, heartbeat message can use 15 byte representations are as follows: 04,030,000 00,000,030 30,303,030 303030.
At the same time it can also create overtime timer heartbeatTimeoutTimer, for after monitoring transmission heartbeat message Second time period in whether receive heartbeat response message.
The second time period of heartbeatTimeoutTimer setting, can be set longer, example under wifi state Such as, be set as 15S, can be set under other states it is shorter, for example, being set as 10S.
If not receiving heartbeat response message in second time period, step 305 can be entered, to re-create Socket link illustrates that the long connection of bottom keeps good, does not need to weigh again if receiving heartbeat response message in second time period New creation allows the timed task to fail at this point it is possible to which heartbeatTimeoutTimer timer is set to nil.
Step 309, data acquisition request is generated, and the data acquisition request is sent to by long connection communication link Long connection server, wherein the data acquisition request includes first synchronous point information, continues to execute step 310;
Every time when mobile client receives the return value of active message, into data pull mode, at this point, mobile visitor Family end can be generated data acquisition request (pull message), and send pull message to long connection server, which can To include first synchronous point information, it is therefore an objective to tell long connection server, the progress of local client message synchronization.
In the embodiment of the present application, which may include multiple business processing requests, wherein each business Processing request is for corresponding to one or more business datums.That is, the data acquisition request can be for for different business Business processing request merge after obtained message, to reduce request number of times.For example, pull message can indicate Are as follows:
{"action":"pull","sData":[{"type":"AT_PUSH_RC","sKey":0},{"type":"AT_ H5_PUSH","sKey":170150112736000001},{"type":"AT_TRAIN_TK","sKey":0},{"type":" AT_DIS_MSG","sKey":0},{"type":"AT_CONTROL_PUSH_DEVICE","sKey":0},{"type":"AT_ CONTROL_COMMAND_PUSH_DEVICE ", " sKey ": 0 }] }, wherein action is pull, for distinguishing different uplinks Data, sData are the array array comprising the request of multiple business processings, and each business processing request includes corresponding industry Be engaged in line type and synchronous point skey, and such as the AT_H5_PUSH of type type, last time is synchronized to 170150112736000001, service Next data that device returns are counted since last synchronous point, to realize the data transmission of zero defect.
The embodiment of the present application can carry out the data between mobile client and long connection server using synchronization mechanism It is synchronous, it prevents Data duplication from issuing or loss of data, realizes that data orderly accurately reach.
The synchronous point information of the embodiment of the present application can be generated by the sequence number generator of long connection server end, and with Business datum is sent to mobile client, and a Service Processing Module is provided with a synchronous point information.
Step 310, long connection server is received by long connection communication link acquisition request returns based on the data, The business datum of update, the business datum of the update include the synchronous point information updated, continue to execute step 311;
Specifically, mobile client carries each Service Processing Module to the data acquisition request that long connection server is sent First synchronous point information, the first synchronous point information from local data base obtain.
Long connection server end can be by service identification and synchronous point message reference data center, because protecting in data center The data for having stayed the service line to be pushed may determine that corresponding Service Processing Module synchronized according to the first synchronous point information Progress obtains service line data to be pushed (business datum updated), then by the data to be pushed and newest Synchronous point information is pushed to the long connection service module of mobile client by long interface channel.
Step 311, the business datum of the update and the synchronous point letter of corresponding update are stored in the local database Breath, continues to execute step 312;
For the synchronous point information that long connection server-side issues, mobile client needs to carry out serializing processing, in time will The business datum of update and the synchronous point information preservation of corresponding update in the local database, so that it is guaranteed that data increment, Order transfer.
Step 312, the business datum based on the update generates notification information;The notification information is broadcasted to one or In multiple Service Processing Modules, step 313 is continued to execute;
After serializing work, the long connection service module of mobile client can be generated according to the business datum of the update Notification information, and notification information is notified to by way of broadcast the Service Processing Module of mobile client.
Step 313, the data response message that returns based on the notification information of Service Processing Module is received, and by the number Long connection server is sent to according to response message.
After Service Processing Module receives data, a successful data reception can be sent to long connection service module Data response message, this data response message finally reach long connection server by bottom socket connection.
In the embodiment of the present application, which may include the information and synchronous point letter of Service Processing Module Breath, for informing long connection server, client has had received all data of synchronous point position, and long connection server can be with Notification data center carries out the update update operation of data, for example, carrying out the cleaning operation of some data.
Generally speaking, in the embodiment of the present application, the long connection service module of mobile client is sent out to long connection server The message sent may include following five class, be distinguished with field action:
The first kind, active message, this kind of message are used to send the relevant equipment letter of local device to long connection server Breath, connection server long so just know that concrete property is the equipment for establishing connection with it have, and action value is active, right It will create active timer in this category information and retry processing, response is not received in time-out time, is re-created Socket link.
Second class, heartbeat message, this kind of message do not need to transmit other data, and data format is simple.For this kind of message It will create heartbeatTimeoutTimer timer, for whether having response after monitoring transmission heartbeat message, in time-out time Response is not received inside, re-creates Socket connection.
Third class, pull message, this kind of message for notifying long connection server, arrive by a kind of data update of type of service Which step is pull comprising each service line type and synchronous point skey, action value.
4th class, bind/unbind message, this kind of message are for notifying long connection server, and mobile client is stepped on Information is recorded, action value is respectively bind/unbind.
5th class, close message, this kind of message are for notifying length to connect server, and current device will break long connection, Such message is sent when mobile client will be switched to backstage, action value is close.Since long connection is to expend very much clothes Device resource of being engaged in, when backstage will be cut by detecting mobile client, it can notify long connection server, long connection server This resource allocation to other equipment, the utilization rate of resource is sufficiently provided.
Status timer will create for third class and the 4th class message, when not receiving response in time-out time, Such message can be retransmitted, rather than goes creation Socket connection again.
Correspondingly, the response message that the long connection server received returns can also be divided into following five class, field is used ReceiveType is distinguished.
The first kind, active response, corresponding active message.
Second class, heartbeat response message, corresponding heartbeat message, illustrate current long junction in steady when receiving this kind of message Determine state.
Third class, bind/unbind response, corresponding bind/unbind message.
4th class, data response, after mobile client has sent pull message, the data response received contains all The type of service and detailed data that should be updated;When service server has new information to issue, what mobile client received is also Such data first store away synchronous point information after mobile client receives this data, then pass through broadcast Mode notifies that corresponding business is handled.
Based on the embodiment of the present application, can achieve it is following the utility model has the advantages that
1, healthy and strong long connection communication link is provided, realizes mobile client and long connection server end full-duplex communication
The embodiment of the present application is based on socket and creates a long connection, but because base station may break with mobile terminal at any time Chain causes this long connection very unstable, and the embodiment of the present application realizes mobile client and long connection service using heartbeat packet Reliable and stable long connection between device end, is based on this socket long connection, and it is interference-free that both-end can transmit data simultaneously, from And realize full-duplex communication.
2, it reaches in real time
Based on healthy and strong long interface channel, long connection server end can ensure that number at any time by data-pushing to client According to the real-time of arrival, business demand is met.
3, push-and-pull combines, and guarantees arrival rate
Pushed data in real time can be achieved based on long connect, but if the connection of mobile terminal and base station is disconnected at this time, that This data can not be pushed to mobile client certainly, and the embodiment of the present application provides pulling data mode simultaneously, when every time with Long connection server is established after connection, first pulling data, pulls the data that the equipment does not synchronize from long connection server-side. The combination of push-pull mode ensure that the arrival rate of data.
4, retry mechanism promotes the availability of service
Because the communication link of base station and mobile terminal is unstable, in fact it could happen that mobile client is built with long connection server It successively loses and loses or phenomena such as chain rupture or mobile client send data failure to long connection server by long connection, these The occurrence of directly result in that long connection service is unavailable, and the embodiment of the present application has well solved this ask using retry mechanism Topic improves the availability of long connection service.
5, precisely push
The embodiment of the present application is supported to press the accurate push of facility information deviceId or user identifier userId, exist in business When initialization, it is possible to specify be to be pushed by equipment, or pushed by user.It can be connected to long when user logs on or off login Server sends different data commands, allows long connection server end to know client state in which and relevant information, if objective Family end is in logging state, and long connection server can issue the message of specified userId.
6, merge service request, reduce request number of times
Because of a data-pushing, the data of all different business once may be issued, the embodiment of the present application will The data of different business merge, and reduce request number of times.
7, compression processing reduces flow
In application embodiment, in order to reduce the data volume of communication, compression processing has been done to data when sending data, when It when receiving data, first decompresses, then parses again, reduce the flow of user terminal well.
Referring to Fig. 4, a kind of step flow chart of communication means embodiment three of the application is shown, the embodiment of the present application can To be applied in long connection server, the long connection server is led to mobile client by long connection communication link Letter;The embodiment of the present application can specifically include following steps:
Step 401, business datum is received by long connection communication link;
Step 402, the corresponding synchronous point information of the business datum is generated;
Step 403, the business datum and corresponding synchronous point information are sent by the long connection communication link Into mobile client.
In a kind of preferred embodiment of the embodiment of the present application, before step 403, it can also include the following steps:
The corresponding synchronous point information of the business datum is stored in the data center.
In a kind of preferred embodiment of the embodiment of the present application, it can also include the following steps:
The data acquisition request that mobile client is sent is received by the long connection communication link, the data acquisition is asked It asks including first synchronous point information;
It based on the first synchronous point information, is compared, judges with the synchronous point information stored in the data center With the presence or absence of not synchronous business datum;
The business datum not synchronized if it exists then sends out the not synchronous business datum and newest synchronous point information It send to the mobile client.
In a kind of preferred embodiment of the embodiment of the present application, it can also include the following steps:
The data response message that mobile client is sent, the data response letter are received by the long connection communication link Breath includes that the Service Processing Module of mobile client obtains the message generated after business datum;
Response message based on the data is updated processing to the corresponding data of data center.
In a kind of preferred embodiment of the embodiment of the present application, before step 403, it can also include the following steps:
The facility information that mobile client is sent is received by the long connection communication link;
Based on the facility information, generating device response message, the equipment response message is used to indicate the equipment letter It ceases corresponding service server and is in active state;
The equipment response message is returned to mobile client.
In a kind of preferred embodiment of the embodiment of the present application, it can also include the following steps:
The heartbeat message that mobile client is sent is received by the long connection communication link;
Based on the heartbeat message, corresponding heartbeat response message is returned to mobile client.
For the embodiment of Fig. 4, since it is substantially similar to the embodiment of Fig. 2 and Fig. 3, so the comparison of description is simple Single, related place is referring to fig. 2 and the part of the embodiment of Fig. 3 illustrates.
A kind of the step of reference Fig. 5, the client and server for showing the application establish the embodiment of the method for long connection Flow chart, wherein the client may include mobile client, and the server includes long connection server, and the application is real Applying example can specifically include following steps:
Step 501, long connection service initialisation is carried out;
Step 502, the Socket connection between the mobile client and long connection server is created;
Step 503, judge whether the Socket connection is successfully established;If so, 504 are thened follow the steps, if it is not, then executing Step 505;
Step 504, the long connection communication link between the mobile client and long connection server is established;
Step 505, it executes and retries operation.
In a kind of preferred embodiment of the embodiment of the present application, step 505 can further include following sub-step:
By retrying connection number subtracts one in real time, wherein the initial value for retrying connection number in real time is that preset maximum retries Connection number;
If the connection number that retries in real time is greater than default connection number thresholding, it is determined that delay duration, and according to the delay When long delay after, continue to execute the step 502;
If the connection number that retries in real time is less than or equal to default connection number thresholding, determine that current long connection service can not With.
In a kind of preferred embodiment of the embodiment of the present application, step 501 can further include one kind set forth below Or it combines:
Create the type of Service Processing Module and the mapping relations of call back function;
Corresponding data decryptor is added for the type of Service Processing Module;
The information of the long connection server of initialization and/or the information of the corresponding application program of the mobile client;
The case where switching to backstage for application program setting is monitored;
It is monitored for application program from setting the case where switching to front end from the background;Or,
Add the monitoring of user's logging state.
In a kind of preferred embodiment of the embodiment of the present application, step 503 can further include following sub-step:
Read the return value that connection is established;
According to the return value, judge whether the Socket connection is successfully established.
In a kind of preferred embodiment of the embodiment of the present application, it can also include the following steps:
Mobile client passes through the long connection server sending device information of the long connection communication chain road direction;
If being not received by the long connection server in first time period is based on the facility information, the equipment of return Response message then determines that the long connection communication link disconnects, and continues to execute the step of execution retries operation.
In a kind of preferred embodiment of the embodiment of the present application, it can also include the following steps:
After receiving the equipment response message, heart beat cycle is determined, and connect to long according to the heart beat cycle Server sends heartbeat message;
When being not received by the heartbeat response message for heartbeat message return in second time period, then determine The long connection communication link disconnects, and continues to execute the step of execution retries operation.
For the embodiment of Fig. 5, since it is substantially similar to the embodiment of Fig. 2 and Fig. 3, so the comparison of description is simple Single, related place is referring to fig. 2 and the part of the embodiment of Fig. 3 illustrates.
It should be noted that for simple description, therefore, it is stated as a series of action groups for embodiment of the method It closes, but those skilled in the art should understand that, the embodiment of the present application is not limited by the described action sequence, because according to According to the embodiment of the present application, some steps may be performed in other sequences or simultaneously.Secondly, those skilled in the art also should Know, the embodiments described in the specification are all preferred embodiments, and related movement not necessarily the application is implemented Necessary to example.
Referring to Fig. 6, a kind of structural block diagram of mobile client embodiment of the application, the mobile client packet are shown Long connection service module and one or more Service Processing Modules are included, the long connection service module and long connection server are logical Too long connection communication link is communicated;The long connection service module can specifically include following submodule:
Business datum receiving submodule 601, for receiving the industry that long connection server is sent by long connection communication link Business data, wherein the business datum carries synchronous point information;
Notification information generates submodule 602, for generating logical according to the business datum and corresponding synchronous point information Know information;
Sending submodule 603, for the notification information to be sent in one or more Service Processing Modules.
In a kind of preferred embodiment of the embodiment of the present application, the long connection service module can also include such as lower die Block:
Data acquisition request generates submodule, and for generating data acquisition request, the data acquisition request includes first Synchronous point information;
Data acquisition request sending submodule, for the data acquisition request to be sent to by long connection communication link Long connection server.
In a kind of preferred embodiment of the embodiment of the present application, the data acquisition request includes that multiple business processings are asked It asks, wherein the business processing request is for corresponding to one or more business datums.
In a kind of preferred embodiment of the embodiment of the present application, the long connection service module can also include following submodule Block:
Data response message receiving submodule, the data returned for receiving Service Processing Module based on the notification information Response message, the data response message are used to be updated place to the corresponding business datum stored in long connection server Reason;
Data response message sending submodule, for the data response message to be sent to long connection server.
In a kind of preferred embodiment of the embodiment of the present application, the long connection service module can also include such as lower die Block:
Initialization submodule, for carrying out long connection service initialisation;
Socket connection creates submodule, for creating the Socket between the mobile client and long connection server Connection;
Judging submodule, for judging whether the Socket connection is successfully established, if so, calling long connection communication chain Road setting up submodule retries submodule if it is not, then calling;
Long connection communication link establishment submodule, the length for establishing between the mobile client and long connection server Connection communication link;
Submodule is retried, retries operation for executing.
In a kind of preferred embodiment of the embodiment of the present application, the submodule that retries be can further include as placed an order Member:
Reconnection number of operations unit, for by retrying connection number subtracts one in real time, wherein described to retry the first of connection number in real time Initial value is that preset maximum retries connection number;
Subelement is retried, if being greater than default connection number thresholding for the connection number that retries in real time, it is determined that delay duration, And after being delayed according to the delay duration, continue to execute between the creation mobile client and long connection server The step of Socket connection;
Judging unit is serviced, if being less than or equal to default connection number thresholding for the connection number that retries in real time, is determined Current long connection service is unavailable.
In a kind of preferred embodiment of the embodiment of the present application, the long connection service module can also include following submodule Block:
Facility information sending submodule, for connecting server sending device information to long;
Equipment response message receiving submodule connects what server was returned based on the facility information for receiving the length Equipment response message, the equipment response message be used to indicate the corresponding service server of the facility information be in enliven shape State;
First long connection disconnects decision sub-module, if for being not received by the long connection service in first time period Device is based on the facility information, and the equipment response message of return then determines that the long connection communication link disconnects, and continues to execute The step of execution retries operation.
In a kind of preferred embodiment of the embodiment of the present application, the long connection service module can also include following submodule Block:
Heartbeat message sending submodule, for determining heart beat cycle, and press after receiving the equipment response message Heartbeat message is sent to long connection server according to the heart beat cycle;
Second long connection disconnects decision sub-module, disappears for working as to be not received by second time period for the heartbeat When ceasing the heartbeat response message returned, then determine that the long connection communication link disconnects, and call and retry module.
In a kind of preferred embodiment of the embodiment of the present application, the initialization submodule is also used to:
Create the type of Service Processing Module and the mapping relations of call back function;
Corresponding data decryptor is added for the type of Service Processing Module;
The information of the long connection server of initialization and/or the information of the corresponding application program of the mobile client;
The case where switching to backstage for application program setting is monitored;
It is monitored for application program from setting the case where switching to front end from the background;
Or, the monitoring of addition user's logging state.
Referring to Fig. 7, a kind of structural block diagram of server example of the application is shown, the server includes long connection Server, the long connection server are communicated with mobile client by long connection communication link;The long connection service Device may include following module:
Business datum receiving module 701, for receiving business datum by long connection communication link;
Synchronous point generation module 702, for generating the corresponding synchronous point information of the business datum;
Business datum sending module 703, for the business datum and corresponding synchronous point information to be passed through the length Connection communication link is sent in mobile client.
In a kind of preferred embodiment of the embodiment of the present application, the server can also include following module:
Synchronous point memory module, for storing the corresponding synchronous point information of the business datum in the data center.
In a kind of preferred embodiment of the embodiment of the present application, the server can also include following module:
Data acquisition request receiving module, for receiving the number that mobile client is sent by the long connection communication link According to acquisition request, the data acquisition request includes first synchronous point information;
Synchronous judgment module, for being based on the first synchronous point information, with the synchronous point stored in the data center Information is compared, and judges whether there is not synchronous business datum;
Non- synchrodata sending module, for when there is not synchronous business datum, then by the not synchronous business Data and newest synchronous point information are sent to the mobile client.
In a kind of preferred embodiment of the embodiment of the present application, the server can also include following module:
Data response message receiving module, for receiving the data response message of mobile client transmission, the data are rung Answering information includes that the Service Processing Module of mobile client obtains the message generated after business datum;
Data update module is updated place to the corresponding data of data center for response message based on the data Reason.
In a kind of preferred embodiment of the embodiment of the present application, the server can also include following module:
Facility information receiving module, for receiving the facility information of mobile client transmission;
Equipment response message generation module, for being based on the facility information, generating device response message, the equipment is rung It answers information to be used to indicate the corresponding service server of the facility information and is in active state;
Equipment response message sending module, for returning to the equipment response message to mobile client.
In a kind of preferred embodiment of the embodiment of the present application, the server can also include following module:
Heartbeat message receiving module, for receiving the heartbeat message of mobile client transmission;
Heartbeat response message sending module returns to corresponding heartbeat to mobile client for being based on the heartbeat message Response message.
Referring to Fig. 8, a kind of client and server that show the application establish the structure of the Installation practice of long connection Block diagram, the client include mobile client, and the apparatus may include following modules:
Initialization module 801, for carrying out long connection service initialisation;
Socket connection creation module 802, for creating between the mobile client and long connection server Socket connection;
Judgment module 803, for judging whether the Socket connection is successfully established, if so, calling long connection communication Link establishment module 804 retries module 805 if it is not, then calling;
Long connection communication link establishment module 804, for establishing between the mobile client and long connection server Long connection communication link;
Module 805 is retried, retries operation for executing.
In a kind of preferred embodiment of the embodiment of the present application, the module 805 that retries may include following submodule:
Reconnection number of operations submodule, for by retrying connection number subtracts one in real time, wherein described to retry connection number in real time Initial value is that preset maximum retries connection number;
Submodule is retried, if being greater than default connection number thresholding for the connection number that retries in real time, it is determined that delay duration, And after being delayed according to the delay duration, Socket connection creation module is called;
Decision sub-module is serviced, if being less than or equal to default connection number thresholding for the connection number that retries in real time, is sentenced Long connection service is unavailable before settled.
In a kind of preferred embodiment of the embodiment of the present application, the initialization module 801 is also used to:
Create the type of Service Processing Module and the mapping relations of call back function;
Corresponding data decryptor is added for the type of every kind of Service Processing Module;
Initialize the information of server and/or the information of the corresponding application program of the service customer end;
The case where switching to backstage for application program setting is monitored;
It is monitored for application program from setting the case where switching to front end from the background;
Or,
Add the monitoring of user's logging state.
In a kind of preferred embodiment of the embodiment of the present application, the judgment module 803 includes following submodule:
Read the return value that connection is established;
According to the return value, judge whether the Socket connection is successfully established.
In a kind of preferred embodiment of the embodiment of the present application, described device can also include following module:
Facility information sending module, for connecting server sending device information to long;
First long connection disconnects determination module, if for being not received by the long connection server in first time period Based on the facility information, the equipment response message of return then determines that the long connection communication link disconnects, and calls and retry mould Block.
In a kind of preferred embodiment of the embodiment of the present application, described device can also include following module:
Heartbeat message sending module, for after receive the equipment response message, determining heart beat cycle, and according to The heart beat cycle sends heartbeat message to server;
Second long connection disconnects determination module, is not received by second time period for the heartbeat message for working as When the heartbeat response message of return, then determine that the long connection communication link disconnects, and call and retry module.
For mobile client, server and Installation practice, since it is substantially similar to above method embodiment, So being described relatively simple, the relevent part can refer to the partial explaination of embodiments of method.
Embodiment of the disclosure can be implemented as using any suitable hardware, firmware, software, or and any combination thereof into The system of the desired configuration of row.Fig. 9, which is schematically shown, can be used for realizing showing for each embodiment described in the disclosure Example property system (or device) 900.
For one embodiment, Fig. 9 shows exemplary system 900, the system have one or more processors 902, It is coupled to the system control module (chipset) 904 of at least one of (one or more) processor 902, is coupled to and be The system storage 906 for control module 904 of uniting is coupled to the nonvolatile memory (NVM) of system control module 904/deposit Storage equipment 908 is coupled to one or more input-output apparatus 910 of system control module 904, and is coupled to and is The network interface 912 for control module 906 of uniting.
Processor 902 may include one or more single or multiple core processors, processor 902 may include general processor or Any combination of application specific processor (such as graphics processor, application processor, Baseband processor etc.).In some embodiments, System 900 can be as the communication system described in the embodiment of the present application.
In some embodiments, system 900 may include with instruction one or more computer-readable mediums (for example, System storage 906 or NVM/ store equipment 908) and mutually merge with the one or more computer-readable medium and be configured as Execute instruction the one or more processors 902 to realize module thereby executing movement described in the disclosure.
For one embodiment, system control module 904 may include any suitable interface controller, with to (one or It is multiple) at least one of processor 902 and/or any suitable equipment or component that communicate with system control module 904 mentions For any suitable interface.
System control module 904 may include Memory Controller module, to provide interface to system storage 906.Storage Device controller module can be hardware module, software module and/or firmware module.
System storage 906 can be used for for example, load of system 900 and storing data and/or instruction.For a reality Example is applied, system storage 906 may include any suitable volatile memory, for example, DRAM appropriate.In some embodiments In, system storage 906 may include four Synchronous Dynamic Random Access Memory of Double Data Rate type (DDR7SDRAM).
For one embodiment, system control module 904 may include one or more i/o controllers, with to NVM/ stores equipment 908 and (one or more) input-output apparatus 910 provides interface.
For example, NVM/ storage equipment 908 can be used for storing data and/or instruction.NVM/ storage equipment 908 may include appointing It anticipates nonvolatile memory appropriate (for example, flash memory) and/or to may include that any suitable (one or more) is non-volatile deposit Equipment is stored up (for example, one or more hard disk drives (HDD), one or more CD (CD) drivers and/or one or more Digital versatile disc (DVD) driver).
NVM/ storage equipment 908 may include a part for the equipment being physically mounted on as system 900 Storage resource or its can by the equipment access without a part as the equipment.For example, NVM/ storage equipment 908 can It is accessed by network via (one or more) input-output apparatus 910.
(one or more) input-output apparatus 910 can be provided for system 900 interface with other any equipment appropriate Communication, input-output apparatus 910 may include communication component, audio component, sensor module etc..Network interface 912 can be System 900 provides interfaces with by one or more network communications, system 900 can according to one or more wireless network standards and/ Or arbitrary standards in agreement and/or agreement are carried out wireless communication with the one or more components of wireless network, such as are accessed Wireless network based on communication standard, such as WiFi, 2G or 3G or their combination carry out wireless communication.
For one embodiment, at least one of (one or more) processor 902 can be with system control module 904 The logic of one or more controllers (for example, Memory Controller module) is packaged together.For one embodiment, (one Or multiple) at least one of processor 902 can be encapsulated in the logic of one or more controllers of system control module 904 Together to form system in package (SiP).For one embodiment, at least one of (one or more) processor 902 can It is integrated on same mold with the logic of one or more controllers of system control module 904.For one embodiment, (one It is a or multiple) at least one of processor 902 can be integrated with the logic of one or more controllers of system control module 904 To form system on chip (SoC) on same mold.
In various embodiments, system 900 can be, but not limited to be: browser, work station, desk-top calculating equipment or movement It calculates equipment (for example, lap-top computing devices, handheld computing device, tablet computer, net book etc.).In various embodiments, System 900 can have more or fewer components and/or different frameworks.For example, in some embodiments, system 900 includes One or more video cameras, keyboard, liquid crystal display (LCD) screen (including touch screen displays), nonvolatile memory port, Mutiple antennas, graphic chips, specific integrated circuit (ASIC) and loudspeaker.
Wherein, if display includes touch panel, display screen may be implemented as touch screen displays, be used by oneself with receiving The input signal at family.Touch panel includes one or more touch sensors to sense the hand on touch, slide, and touch panel Gesture.The touch sensor can not only sense the boundary of a touch or slide action, but also detect and the touch or sliding Operate relevant duration and pressure.
The embodiment of the present application also provides a kind of non-volatile readable storage medium, be stored in the storage medium one or Multiple modules (programs) when the one or more module is used in terminal device, can make the terminal device execute The instruction (instructions) of each step of the above method in the embodiment of the present application.
A kind of device is provided in one example, comprising: one or more processors;With what is stored thereon has instruction One or more machine readable medias, when by one or more of processors execute when so that described device execute as this Apply for the instruction (instructions) of each step of the above method in embodiment.
All the embodiments in this specification are described in a progressive manner, the highlights of each of the examples are with The difference of other embodiments, the same or similar parts between the embodiments can be referred to each other.
It should be understood by those skilled in the art that, the embodiments of the present application may be provided as client, device or meters Calculation machine program product.Therefore, the embodiment of the present application can be used complete hardware embodiment, complete software embodiment or combine software With the form of the embodiment of hardware aspect.Moreover, it wherein includes computer that the embodiment of the present application, which can be used in one or more, The computer-usable storage medium (including but not limited to magnetic disk storage, CD-ROM, optical memory etc.) of usable program code The form of the computer program product of upper implementation.
The embodiment of the present application is referring to according to the client of the embodiment of the present application, terminal device (system) and computer journey The flowchart and/or the block diagram of sequence product describes.It should be understood that flow chart and/or box can be realized by computer program instructions The combination of the process and/or box in each flow and/or block and flowchart and/or the block diagram in figure.It can provide this A little computer program instructions are to general purpose computer, special purpose computer, Embedded Processor or other programmable data processing terminals The processor of equipment is to generate a machine, so that passing through computer or the processor of other programmable data processing terminal devices The instruction of execution generates for realizing in one or more flows of the flowchart and/or one or more blocks of the block diagram In specify function device.
These computer program instructions, which may also be stored in, is able to guide computer or other programmable data processing terminal devices In computer-readable memory operate in a specific manner, so that instruction stored in the computer readable memory generates packet The manufacture of command device is included, which realizes in one side of one or more flows of the flowchart and/or block diagram The function of being specified in frame or multiple boxes.
These computer program instructions can also be loaded into computer or other programmable data processing terminal devices, so that Series of operation steps are executed on computer or other programmable terminal equipments to generate computer implemented processing, thus The instruction executed on computer or other programmable terminal equipments is provided for realizing in one or more flows of the flowchart And/or in one or more blocks of the block diagram specify function the step of.
Although preferred embodiments of the embodiments of the present application have been described, once a person skilled in the art knows bases This creative concept, then additional changes and modifications can be made to these embodiments.So the following claims are intended to be interpreted as Including preferred embodiment and all change and modification within the scope of the embodiments of the present application.
Finally, it is to be noted that, herein, relational terms such as first and second and the like be used merely to by One entity or operation are distinguished with another entity or operation, without necessarily requiring or implying these entities or operation Between there are any actual relationship or orders.Moreover, the terms "include", "comprise" or its any other variant meaning Covering non-exclusive inclusion, so that process, client, article or terminal device including a series of elements are not only Including those elements, but also including other elements that are not explicitly listed, or further include for this process, client, Article or the intrinsic element of terminal device.In the absence of more restrictions, being limited by sentence "including a ..." Element, it is not excluded that including that there is also other identical in the process of the element, client, article or terminal device Element.
The long method connected and communication means are established to a kind of client and server provided herein above and led to Letter system is described in detail, and specific examples are used herein to illustrate the principle and implementation manner of the present application, The client and its core concept for the application that the above embodiments are only used to help understand;Meanwhile for this field Those skilled in the art, according to the thought of the application, there will be changes in the specific implementation manner and application range, to sum up institute It states, the contents of this specification should not be construed as limiting the present application.

Claims (36)

1. a kind of communication means, which is characterized in that be applied in mobile client, the mobile client includes long connection service Module and one or more Service Processing Modules, the long connection service module and long connection server pass through long connection communication Link is communicated;The described method includes:
Long connection service module receives the business datum that long connection server is sent by long connection communication link, wherein described Business datum carries synchronous point information;
According to the business datum and corresponding synchronous point information, notification information is generated;
The notification information is sent in one or more Service Processing Modules.
2. the method according to claim 1, wherein passing through long connection communication chain in the long connection service module Road received before the step of business datum that long connection server is sent, further includes:
Data acquisition request is generated, the data acquisition request includes first synchronous point information;
The data acquisition request is sent to long connection server by long connection communication link.
3. according to the method described in claim 2, it is characterized in that, the data acquisition request includes that multiple business processings are asked It asks, wherein the business processing request is for corresponding to one or more business datums.
4. method according to claim 1-3, which is characterized in that further include:
Receive the data response message that returns based on the notification information of Service Processing Module, the data response message is used for pair The corresponding business datum stored in long connection server is updated processing;
The data response message is sent to long connection server by long connection communication link.
5. method according to claim 1-3, which is characterized in that connected in the long connection service module by long Before the step of connecing the business datum that communication link reception server is sent, further includes:
Carry out long connection service initialisation;
Create the Socket connection between the mobile client and long connection server;
Judge whether the Socket connection is successfully established;
If so, establishing the long connection communication link between the mobile client and long connection server;
Operation is retried if it is not, then executing.
6. according to the method described in claim 5, it is characterized in that, the execution includes: the step of retrying operation
By retrying connection number subtracts one in real time, wherein the initial value for retrying connection number in real time is that preset maximum retries connection Number;
If the connection number that retries in real time is greater than default connection number thresholding, it is determined that delay duration, and according to the delay duration After delay, described the step of creating the mobile client and the long Socket connection connected between server is continued to execute;
If the connection number that retries in real time is less than or equal to default connection number thresholding, determine that current long connection service is unavailable.
7. according to the method described in claim 5, it is characterized in that, establishing the mobile client and long connection service described After the step of long connection communication link between device, further include;
Pass through the long connection server sending device information of the long connection communication chain road direction;
The equipment response message that the long connection server is returned based on the facility information is received, the equipment response message is used Active state is in the corresponding service server of the instruction facility information;
If being not received by the long connection server in first time period is based on the facility information, the equipment of return is responded Information then determines that the long connection communication link disconnects, and continues to execute the step of execution retries operation.
8. the method according to the description of claim 7 is characterized in that further include:
After receiving the equipment response message, heart beat cycle is determined, and service to long connection according to the heart beat cycle Device sends heartbeat message;
When being not received by what long connection server returned in second time period, the heartbeat response for the heartbeat message disappears When breath, then determine that the long connection communication link disconnects, and continue to execute the step of execution retries operation.
9. according to the method described in claim 5, it is characterized in that, described the step of carrying out long connection service initialisation include with One of listed by lower or combine:
Create the type of Service Processing Module and the mapping relations of call back function;
Corresponding data decryptor is added for the type of Service Processing Module;
The information of the long connection server of initialization and/or the information of the corresponding application program of the mobile client;
The case where switching to backstage for application program setting is monitored;
It is monitored for application program from setting the case where switching to front end from the background;Or,
Add the monitoring of user's logging state.
10. the method according to claim 1, wherein described according to the business datum and corresponding same Before the step of point information, generation notification information, further includes:
Store the business datum and corresponding synchronous point information.
11. a kind of communication means, which is characterized in that be applied in server, the server and mobile client are connected by long Communication link is connect to be communicated;The described method includes:
Business datum is received by long connection communication link;
Generate the corresponding synchronous point information of the business datum;
The business datum and corresponding synchronous point information are sent to mobile client by the long connection communication link In.
12. according to the method for claim 11, which is characterized in that described by the business datum and corresponding synchronization Point information is sent to before the step in mobile client by the long connection communication link, further includes:
The corresponding synchronous point information of the business datum is stored in the data center.
13. according to the method for claim 12, which is characterized in that further include:
The data acquisition request that mobile client is sent, the data acquisition request packet are received by the long connection communication link Include first synchronous point information;
Based on the first synchronous point information, it is compared, judges whether with the synchronous point information stored in the data center In the presence of not synchronous business datum;
The not synchronous business datum and newest synchronous point information are then sent to by the business datum not synchronized if it exists The mobile client.
14. according to the method for claim 12, which is characterized in that further include:
The data response message that mobile client is sent, the data response message packet are received by the long connection communication link The Service Processing Module for including mobile client obtains the message generated after business datum;
Response message based on the data is updated processing to the corresponding data of data center.
15. the described in any item methods of 1-14 according to claim 1, which is characterized in that it is described by the business datum and Corresponding synchronous point information is sent to before the step in client by the long connection communication link, further includes:
The facility information that mobile client is sent is received by the long connection communication link;
Based on the facility information, generating device response message, the equipment response message is used to indicate the facility information pair The service server answered is in active state;
The equipment response message is returned to mobile client.
16. according to the method for claim 15, which is characterized in that further include:
The heartbeat message that mobile client is sent is received by the long connection communication link;
Based on the heartbeat message, corresponding heartbeat response message is returned to mobile client.
17. a kind of method that client and server establish long connection, which is characterized in that the client includes mobile client End, the server include long connection server, which comprises
Carry out long connection service initialisation;
Create the Socket connection between the mobile client and long connection server;
Judge whether the Socket connection is successfully established;
If so, establishing the long connection communication link between the mobile client and long connection server;
Operation is retried if it is not, then executing.
18. according to the method for claim 17, which is characterized in that described execution the step of retrying operation includes:
By retrying connection number subtracts one in real time, wherein the initial value for retrying connection number in real time is that preset maximum retries connection Number;
If the connection number that retries in real time is greater than default connection number thresholding, it is determined that delay duration, and according to the delay duration After delay, described the step of creating the mobile client and the long Socket connection connected between server is continued to execute;
If the connection number that retries in real time is less than or equal to default connection number thresholding, determine that current long connection service is unavailable.
19. method described in 7 or 18 according to claim 1, which is characterized in that described the step of carrying out long connection service initialisation Including one of set forth below or combination:
Create the type of Service Processing Module and the mapping relations of call back function;
Corresponding data decryptor is added for the type of Service Processing Module;
The information of the long connection server of initialization and/or the information of the corresponding application program of the mobile client;
The case where switching to backstage for application program setting is monitored;
It is monitored for application program from setting the case where switching to front end from the background;Or,
Add the monitoring of user's logging state.
20. according to the method for claim 17, which is characterized in that described to judge whether the Socket connection is successfully established The step of include:
Read the return value that connection is established;
According to the return value, judge whether the Socket connection is successfully established.
21. according to the method for claim 17, which is characterized in that the method also includes:
Mobile client passes through the long connection server sending device information of the long connection communication chain road direction;
If being not received by the long connection server in first time period is based on the facility information, the equipment of return is responded Information then determines that the long connection communication link disconnects, and continues to execute the step of execution retries operation.
22. according to the method for claim 21, which is characterized in that the method also includes:
After receiving the equipment response message, heart beat cycle is determined, and service to long connection according to the heart beat cycle Device sends heartbeat message;
When being not received by the heartbeat response message for heartbeat message return in second time period, then described in judgement Long connection communication link disconnects, and continues to execute the step of execution retries operation.
23. a kind of mobile client, which is characterized in that the mobile client includes long connection service module and one or more A Service Processing Module, the long connection service module are communicated with long connection server by long connection communication link;
The length connects service module
Business datum receiving submodule, for receiving the business datum that long connection server is sent by long connection communication link, Wherein, the business datum carries synchronous point information;
Notification information generates submodule, for generating notification information according to the business datum and corresponding synchronous point information;
Sending submodule, for the notification information to be sent in one or more Service Processing Modules.
24. mobile client according to claim 23, which is characterized in that the long connection service module further include:
Data acquisition request generates submodule, and for generating data acquisition request, the data acquisition request includes formerly synchronous Point information;
Data acquisition request sending submodule, for the data acquisition request to be sent to long company by long connection communication link Connect server.
25. a kind of server, which is characterized in that the server includes long connection server, and the length connects server and moves Dynamic client is communicated by long connection communication link;The length connects server
Business datum receiving module, for receiving business datum by long connection communication link;
Synchronous point generation module, for generating the corresponding synchronous point information of the business datum;
Business datum sending module, for the business datum and corresponding synchronous point information to be passed through the long connection communication Link is sent in mobile client.
26. server according to claim 25, which is characterized in that further include:
Synchronous point memory module, for storing the corresponding synchronous point information of the business datum in the data center.
27. server according to claim 26, which is characterized in that further include:
Data acquisition request receiving module is obtained for receiving the data that mobile client is sent by the long connection communication link Request is taken, the data acquisition request includes first synchronous point information;
Synchronous judgment module, for being based on the first synchronous point information, with the synchronous point information stored in the data center It is compared, judges whether there is not synchronous business datum;
Non- synchrodata sending module, for when there is not synchronous business datum, then by the not synchronous business datum And newest synchronous point information is sent to the mobile client.
28. the device that a kind of client and server establish long connection, which is characterized in that the client includes mobile client End, the server include long connection server, and described device includes:
Initialization module, for carrying out long connection service initialisation;
Socket connection creation module, for creating the Socket connection between the mobile client and long connection server;
Judgment module, for judging whether the Socket connection is successfully established, if so, calling long connection communication link establishment Module retries module if it is not, then calling;
Long connection communication link establishment module, the long connection for establishing between the mobile client and long connection server are logical Believe link;
Module is retried, retries operation for executing.
29. device according to claim 28, which is characterized in that the module that retries includes:
Reconnection number of operations submodule, for by retrying connection number subtracts one in real time, wherein described to retry the initial of connection number in real time Value is that preset maximum retries connection number;
Submodule is retried, if being greater than default connection number thresholding for the connection number that retries in real time, it is determined that delay duration, and press After delay duration delay, Socket connection creation module is called;
Decision sub-module is serviced, if being less than or equal to default connection number thresholding for the connection number that retries in real time, judgement is worked as Preceding long connection service is unavailable.
30. device according to claim 28, which is characterized in that described device further include:
Facility information sending module, for passing through the long connection server sending device information of the long connection communication chain road direction;
First long connection disconnects determination module, if being based on for being not received by the long connection server in first time period The facility information, the equipment response message of return then determine that the long connection communication link disconnects, and call and retry module.
31. device according to claim 30, which is characterized in that described device further include:
Heartbeat message sending module, for determining heart beat cycle, and according to described after receiving the equipment response message Heart beat cycle sends heartbeat message to long connection server;
Second long connection disconnects determination module, returns for working as to be not received by second time period for the heartbeat message Heartbeat response message when, then determine that the long connection communication link disconnects, and call and retry module.
32. a kind of communication system, which is characterized in that including mobile client, service server, long connection server, the shifting Dynamic client includes long connection service module and one or more Service Processing Modules, the long connection service module with it is described Long connection server is communicated by long connection communication link;
The service server is used for, and sends business datum to long connection server;
The long connection server is used for, and generates the corresponding synchronous point information of the business datum, and by the business datum with And corresponding synchronous point information is sent in long connection service module by long connection communication link;
The long connection service module is used for, and according to the business datum and corresponding synchronous point information, generates notification information, And the notification information is sent in one or more Service Processing Modules;
The Service Processing Module is used for, and business datum is extracted from the notification information, and carry out industry to the business datum Business processing.
33. communication system according to claim 32, which is characterized in that the Service Processing Module to the length by connecting It connects service module to be registered, to use long connection service.
34. communication system according to claim 32, which is characterized in that further include:
Long connection establishment module, the long connection for establishing between the long connection server and the long connection service module are logical Believe link.
35. a kind of device characterized by comprising
One or more processors;With
One or more machine readable medias of instruction are stored thereon with, when being executed by one or more of processors, are made It obtains described device and executes such as communication means of claim 1-10 and/or 11-16 one or more and/or 17-22 mono- or more The method that a client and server establishes long connection.
36. one or more machine readable medias, are stored thereon with instruction, when executed by one or more processors, so that Device executes such as the communication means of claim 1-10 and/or 11-16 one or more and/or the visitor of 17-22 one or more The method that family end and server establish long connection.
CN201710949296.5A 2017-10-12 2017-10-12 A kind of method and communication means and communication system of client and the long connection of server foundation Pending CN109660584A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710949296.5A CN109660584A (en) 2017-10-12 2017-10-12 A kind of method and communication means and communication system of client and the long connection of server foundation

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710949296.5A CN109660584A (en) 2017-10-12 2017-10-12 A kind of method and communication means and communication system of client and the long connection of server foundation

Publications (1)

Publication Number Publication Date
CN109660584A true CN109660584A (en) 2019-04-19

Family

ID=66109042

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710949296.5A Pending CN109660584A (en) 2017-10-12 2017-10-12 A kind of method and communication means and communication system of client and the long connection of server foundation

Country Status (1)

Country Link
CN (1) CN109660584A (en)

Cited By (29)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110071981A (en) * 2019-04-30 2019-07-30 广东电网有限责任公司 A method of keeping websocket long connection under no business data exchange
CN110519341A (en) * 2019-08-09 2019-11-29 西藏宁算科技集团有限公司 A kind of anti-method and system of wandering away based on cloud computing
CN110572442A (en) * 2019-08-15 2019-12-13 上海易点时空网络有限公司 Method and system for configuring file path
CN110620761A (en) * 2019-08-02 2019-12-27 重庆爱奇艺智能科技有限公司 Method and device for realizing multi-person virtual interaction
CN110661848A (en) * 2019-08-28 2020-01-07 视联动力信息技术股份有限公司 Message pushing method, device, equipment and medium based on video network
CN110753086A (en) * 2019-09-12 2020-02-04 华为技术有限公司 Heartbeat awakening method for application and terminal equipment
CN111092939A (en) * 2019-12-04 2020-05-01 深圳市机场股份有限公司 Message processing method and device based on machine position distribution and electronic equipment
CN111262773A (en) * 2020-01-21 2020-06-09 香港乐蜜有限公司 Message synchronization method and data center
CN111614752A (en) * 2020-05-19 2020-09-01 北京百度网讯科技有限公司 Method and device for data transmission
CN111669438A (en) * 2020-05-27 2020-09-15 北京百度网讯科技有限公司 Live broadcast message transmission method and device, electronic equipment and medium
CN111726413A (en) * 2020-06-28 2020-09-29 北京百度网讯科技有限公司 Equipment connection method and device
CN111737029A (en) * 2020-06-23 2020-10-02 中国建设银行股份有限公司 Server, data pushing method and data pushing system
CN112019614A (en) * 2020-08-25 2020-12-01 苏州挚途科技有限公司 Method, system and processor for communication and communication synchronization between two systems
CN112181915A (en) * 2019-07-03 2021-01-05 成都华为技术有限公司 Method, device, terminal and storage medium for executing service
CN112448978A (en) * 2019-08-30 2021-03-05 中国移动通信集团河北有限公司 Data management method and system
CN112714079A (en) * 2020-12-14 2021-04-27 成都安思科技有限公司 Target service identification method under VPN environment
CN113037834A (en) * 2021-03-05 2021-06-25 中国工商银行股份有限公司 Web page state updating method and device based on distributed instant push
CN113079220A (en) * 2021-04-15 2021-07-06 深圳市万为物联科技有限公司 Method for remotely controlling control machine in power exchange cabinet
CN113127732A (en) * 2021-03-23 2021-07-16 金蝶蝶金云计算有限公司 Method and device for acquiring service data, computer equipment and storage medium
CN113420941A (en) * 2021-07-16 2021-09-21 湖南快乐阳光互动娱乐传媒有限公司 Risk prediction method and device for user behavior
CN113542359A (en) * 2021-06-17 2021-10-22 聚好看科技股份有限公司 Terminal state updating method and device in online conference and electronic equipment
CN113645308A (en) * 2021-08-18 2021-11-12 平安普惠企业管理有限公司 Mobile terminal TCP communication, device, equipment and storage medium
CN113762677A (en) * 2020-10-29 2021-12-07 北京京东振世信息技术有限公司 Service processing method and device
CN113836153A (en) * 2021-08-16 2021-12-24 紫光云(南京)数字技术有限公司 Method and system for instantly updating enterprise address book at mobile terminal
CN113923249A (en) * 2021-10-12 2022-01-11 工银科技有限公司 High-performance network long connection establishing method and device
CN114222062A (en) * 2021-12-13 2022-03-22 杭州萤石软件有限公司 Stream taking method, low-power-consumption battery equipment, client, stream taking system and equipment
CN115334144A (en) * 2022-06-29 2022-11-11 上海万物新生环保科技集团有限公司 Method, device and system for processing service state change notification
CN116361038A (en) * 2023-06-02 2023-06-30 山东浪潮科学研究院有限公司 Acceleration computing management method, system, equipment and storage medium
CN116708533A (en) * 2022-10-31 2023-09-05 荣耀终端有限公司 Connection switching method, server stopping method, terminal equipment and server

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101610225A (en) * 2008-06-20 2009-12-23 华为技术有限公司 A kind of synchronization processing method, system and device
CN101685523A (en) * 2008-09-27 2010-03-31 北京掌易迅移动软件技术有限责任公司 Service processing system for clients at mobile phone terminals
CN102932352A (en) * 2012-11-02 2013-02-13 北京奇虎科技有限公司 Method and server for communicating with client
CN104820701A (en) * 2015-05-11 2015-08-05 北京瑞星信息技术有限公司 Method and system for recording and synchronizing data
CN106657174A (en) * 2015-10-28 2017-05-10 阿里巴巴集团控股有限公司 Data synchronizing and updating methods and data synchronizing and updating devices
CN106714334A (en) * 2016-12-22 2017-05-24 网易(杭州)网络有限公司 Disconnection reconnection method, device and system
CN106850745A (en) * 2016-12-23 2017-06-13 北京五八信息技术有限公司 A kind of real-time synchronization method and device

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101610225A (en) * 2008-06-20 2009-12-23 华为技术有限公司 A kind of synchronization processing method, system and device
CN101685523A (en) * 2008-09-27 2010-03-31 北京掌易迅移动软件技术有限责任公司 Service processing system for clients at mobile phone terminals
CN102932352A (en) * 2012-11-02 2013-02-13 北京奇虎科技有限公司 Method and server for communicating with client
CN104820701A (en) * 2015-05-11 2015-08-05 北京瑞星信息技术有限公司 Method and system for recording and synchronizing data
CN106657174A (en) * 2015-10-28 2017-05-10 阿里巴巴集团控股有限公司 Data synchronizing and updating methods and data synchronizing and updating devices
CN106714334A (en) * 2016-12-22 2017-05-24 网易(杭州)网络有限公司 Disconnection reconnection method, device and system
CN106850745A (en) * 2016-12-23 2017-06-13 北京五八信息技术有限公司 A kind of real-time synchronization method and device

Cited By (41)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110071981A (en) * 2019-04-30 2019-07-30 广东电网有限责任公司 A method of keeping websocket long connection under no business data exchange
CN112181915A (en) * 2019-07-03 2021-01-05 成都华为技术有限公司 Method, device, terminal and storage medium for executing service
CN112181915B (en) * 2019-07-03 2023-12-08 成都华为技术有限公司 Method, device, terminal and storage medium for executing service
CN110620761A (en) * 2019-08-02 2019-12-27 重庆爱奇艺智能科技有限公司 Method and device for realizing multi-person virtual interaction
CN110519341A (en) * 2019-08-09 2019-11-29 西藏宁算科技集团有限公司 A kind of anti-method and system of wandering away based on cloud computing
CN110572442A (en) * 2019-08-15 2019-12-13 上海易点时空网络有限公司 Method and system for configuring file path
CN110661848A (en) * 2019-08-28 2020-01-07 视联动力信息技术股份有限公司 Message pushing method, device, equipment and medium based on video network
CN110661848B (en) * 2019-08-28 2022-02-22 视联动力信息技术股份有限公司 Message pushing method, device, equipment and medium based on video network
CN112448978A (en) * 2019-08-30 2021-03-05 中国移动通信集团河北有限公司 Data management method and system
CN112448978B (en) * 2019-08-30 2022-11-29 中国移动通信集团河北有限公司 Data management method and system
CN110753086A (en) * 2019-09-12 2020-02-04 华为技术有限公司 Heartbeat awakening method for application and terminal equipment
CN111092939A (en) * 2019-12-04 2020-05-01 深圳市机场股份有限公司 Message processing method and device based on machine position distribution and electronic equipment
CN111262773A (en) * 2020-01-21 2020-06-09 香港乐蜜有限公司 Message synchronization method and data center
CN111614752A (en) * 2020-05-19 2020-09-01 北京百度网讯科技有限公司 Method and device for data transmission
US11750541B2 (en) 2020-05-27 2023-09-05 Beijing Baidu Netcom Science And Technology Co., Ltd. Method for transmitting live message, apparatus, electronic device and medium
CN111669438A (en) * 2020-05-27 2020-09-15 北京百度网讯科技有限公司 Live broadcast message transmission method and device, electronic equipment and medium
CN111737029A (en) * 2020-06-23 2020-10-02 中国建设银行股份有限公司 Server, data pushing method and data pushing system
CN111726413A (en) * 2020-06-28 2020-09-29 北京百度网讯科技有限公司 Equipment connection method and device
CN112019614A (en) * 2020-08-25 2020-12-01 苏州挚途科技有限公司 Method, system and processor for communication and communication synchronization between two systems
CN112019614B (en) * 2020-08-25 2023-02-17 苏州挚途科技有限公司 Method, system and processor for communication and communication synchronization between two systems
CN113762677A (en) * 2020-10-29 2021-12-07 北京京东振世信息技术有限公司 Service processing method and device
CN113762677B (en) * 2020-10-29 2023-11-03 北京京东振世信息技术有限公司 Service processing method and device
CN112714079A (en) * 2020-12-14 2021-04-27 成都安思科技有限公司 Target service identification method under VPN environment
CN112714079B (en) * 2020-12-14 2022-07-12 成都安思科技有限公司 Target service identification method under VPN environment
CN113037834A (en) * 2021-03-05 2021-06-25 中国工商银行股份有限公司 Web page state updating method and device based on distributed instant push
CN113127732A (en) * 2021-03-23 2021-07-16 金蝶蝶金云计算有限公司 Method and device for acquiring service data, computer equipment and storage medium
CN113127732B (en) * 2021-03-23 2024-02-20 金蝶蝶金云计算有限公司 Service data acquisition method, device, computer equipment and storage medium
CN113079220A (en) * 2021-04-15 2021-07-06 深圳市万为物联科技有限公司 Method for remotely controlling control machine in power exchange cabinet
CN113079220B (en) * 2021-04-15 2022-07-15 深圳市万为物联科技有限公司 Method for remotely controlling control machine in power exchange cabinet
CN113542359A (en) * 2021-06-17 2021-10-22 聚好看科技股份有限公司 Terminal state updating method and device in online conference and electronic equipment
CN113542359B (en) * 2021-06-17 2023-09-05 聚好看科技股份有限公司 Terminal state updating method and device in online conference and electronic equipment
CN113420941A (en) * 2021-07-16 2021-09-21 湖南快乐阳光互动娱乐传媒有限公司 Risk prediction method and device for user behavior
CN113836153A (en) * 2021-08-16 2021-12-24 紫光云(南京)数字技术有限公司 Method and system for instantly updating enterprise address book at mobile terminal
CN113645308B (en) * 2021-08-18 2022-09-16 平安普惠企业管理有限公司 Mobile terminal TCP communication, device, equipment and storage medium
CN113645308A (en) * 2021-08-18 2021-11-12 平安普惠企业管理有限公司 Mobile terminal TCP communication, device, equipment and storage medium
CN113923249A (en) * 2021-10-12 2022-01-11 工银科技有限公司 High-performance network long connection establishing method and device
CN114222062A (en) * 2021-12-13 2022-03-22 杭州萤石软件有限公司 Stream taking method, low-power-consumption battery equipment, client, stream taking system and equipment
CN115334144A (en) * 2022-06-29 2022-11-11 上海万物新生环保科技集团有限公司 Method, device and system for processing service state change notification
CN116708533A (en) * 2022-10-31 2023-09-05 荣耀终端有限公司 Connection switching method, server stopping method, terminal equipment and server
CN116361038A (en) * 2023-06-02 2023-06-30 山东浪潮科学研究院有限公司 Acceleration computing management method, system, equipment and storage medium
CN116361038B (en) * 2023-06-02 2023-09-08 山东浪潮科学研究院有限公司 Acceleration computing management method, system, equipment and storage medium

Similar Documents

Publication Publication Date Title
CN109660584A (en) A kind of method and communication means and communication system of client and the long connection of server foundation
CN102880475B (en) Based on the real-time event disposal system of cloud computing and method in computer software
US11314539B2 (en) Cloud storage based data processing method and system
CN104253704B (en) A kind of methods, devices and systems of reporting terminal daily record
CN105407180A (en) Server message pushing method and device
CN105681454A (en) Method and system for self-adaptively connecting cloud desktop
US20220209878A1 (en) Method, system and device for pushing information, and storage medium thereof
TWI742131B (en) Method and device for upgrading virtual switch
CN103096271A (en) Information pushing system and information pushing method
CN110868278B (en) Method for dual-computer redundancy of communication front-end processor of rail transit comprehensive monitoring system
CN109039881A (en) A kind of intelligent power distribution monitoring management system and information-pushing method
CN110493028A (en) A kind of clustered deploy(ment) method, system, device and computer readable storage medium
CN104243259B (en) Collaboration method and system in distributed elastic network interconnection system
CN105323272A (en) Method, terminal and system for managing clipboard
CN102111436B (en) Storage device and method for accessing storage device through internet small computer system interface (iSCSI)
KR20070024183A (en) Method for controlling data transmission and network apparatus transmitting data by using the same
CN110913013A (en) Multi-screen interaction method and system
CN103051484B (en) Session service processing method, system and Session Border Controll
CN116192863B (en) Micro-service flow processing method, DPU service grid deployment method and system
CN109298931B (en) Buffer on-demand release method and network equipment
CN110674221A (en) Spatial data synchronization method, terminal and computer readable storage medium
CN114301880B (en) Three-dimensional data transmission method, electronic equipment and signaling server
CN113053374B (en) Large screen control system
CN116048538A (en) Service grid deployment method and device for DPU
CN114050986B (en) Signaling tracking method, device, equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20190419

RJ01 Rejection of invention patent application after publication