CN102752847B - A kind of processing method of working application and device - Google Patents

A kind of processing method of working application and device Download PDF

Info

Publication number
CN102752847B
CN102752847B CN201110097758.8A CN201110097758A CN102752847B CN 102752847 B CN102752847 B CN 102752847B CN 201110097758 A CN201110097758 A CN 201110097758A CN 102752847 B CN102752847 B CN 102752847B
Authority
CN
China
Prior art keywords
packet
working application
storage queue
bid
link management
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.)
Active
Application number
CN201110097758.8A
Other languages
Chinese (zh)
Other versions
CN102752847A (en
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.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen Co 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 Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN201110097758.8A priority Critical patent/CN102752847B/en
Publication of CN102752847A publication Critical patent/CN102752847A/en
Application granted granted Critical
Publication of CN102752847B publication Critical patent/CN102752847B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Abstract

The invention discloses the processing method of working application, when each working application in mobile terminal starts, send registration request to the link management instrument in mobile terminal; Link management instrument verifies the BID wherein carried, and verification is passed through, notice working application, and distributes a storage queue for working application; A unique corresponding BID and storage queue of each working application; The packet that the working application that each verification of link management means accepts is passed through is sent, according to the BID wherein carried by the data pack buffer that receives in the storage queue of correspondence; The each storage queue of link management instrument poll, is polled to from each and not for taking out a packet empty storage queue, send to server; What reception server returned returns bag, according to the BID wherein carried, the bag that returns received is sent to corresponding working application.The present invention discloses the processing unit of working application.Apply scheme of the present invention, networking mortality can be reduced.

Description

A kind of processing method of working application and device
Technical field
The present invention relates to network technology, particularly a kind of processing method of working application and device.
Background technology
Along with the mobile terminals such as mobile phone hardware performance from strength to strength and the continuous intellectuality of operating system, the disposal ability of mobile terminal obtains very large lifting, possesses the ability simultaneously running multiple working application, usually, each working application all needs to set up one between the server of network side and links.
And under current wireless network environment, the link number that the gateway of cellular carrier can process simultaneously is limited, therefore possibly cannot meet the increased requirement of working application, thus causes the networking failure of working application, especially in peak period, networking mortality can be increased further.For this problem, in prior art, also there is no a kind of effective settling mode.
Summary of the invention
In view of this, main purpose of the present invention is the processing method providing a kind of working application, can reduce networking mortality.
Another object of the present invention is to the processing unit that a kind of working application is provided, networking mortality can be reduced.
For achieving the above object, technical scheme of the present invention is achieved in that
A processing method for working application, the method comprises:
When each working application in mobile terminal starts, send registration request to the link management instrument in mobile terminal; Link management instrument verifies the identification identifier BID carried in registration request, and verification is passed through, notice working application, and distributes a storage queue for working application; A unique corresponding BID and storage queue of each working application;
The packet that the working application that each verification of link management means accepts is passed through is sent, according to the BID wherein carried by the data pack buffer that receives in the storage queue of correspondence;
The each storage queue of link management instrument poll, is polled to from each and not for taking out a packet empty storage queue, send to server; What reception server returned returns bag, according to the BID wherein carried, the bag that returns received is sent to corresponding working application.
A processing unit for working application, this device is arranged in mobile terminal, comprising:
First processing unit, the registration request sent after starting for each working application in mobile terminal receive, the identification identifier BID wherein carried is verified, verification is passed through, notice working application, and distribute a storage queue for working application, a unique corresponding BID and storage queue of each working application; Receive the packet that working application that each verification passes through is sent, according to the BID wherein carried by the data pack buffer that receives in the storage queue of correspondence;
Second processing unit, for each storage queue of poll, is polled to from each and not for taking out a packet empty storage queue, send to server; What reception server returned returns bag, according to the BID wherein carried, the bag that returns received is sent to corresponding working application.
Visible, adopt technical scheme of the present invention, for each mobile terminal, only need set up one between itself and server to link, multiple working application in mobile terminal share this link, thus the gateway decreasing cellular carrier needs link number to be processed, and then reduce networking mortality, and improve the service efficiency of link; In addition, scheme of the present invention implements simple and convenient, is convenient to popularize.
Accompanying drawing explanation
Fig. 1 is the flow chart of the inventive method embodiment.
Fig. 2 is the composition structural representation of apparatus of the present invention embodiment.
Embodiment
For problems of the prior art, propose the processing scheme of working application after a kind of improvement in the present invention, in the terminal a link management tool software is installed, the forwarding etc. of the foundation of primary responsibility link, maintenance, disconnection and packet; Based on this link management instrument, multiple working application can be realized and share a link.
For make technical scheme of the present invention clearly, understand, to develop simultaneously embodiment referring to accompanying drawing, scheme of the present invention be described in further detail.
Fig. 1 is the flow chart of the inventive method embodiment.As shown in Figure 1, comprise the following steps:
Step 11: when each working application in mobile terminal starts, send registration request to the link management instrument in mobile terminal; Link management instrument verifies the identification identifier carried in registration request (BID, Business Identification), and verification is passed through, notice working application, and distributes a storage queue for working application; A unique corresponding BID and storage queue of each working application.
In actual applications, a fixing BID can be configured, for identifying its identity for each working application in advance, after each working application starts, can register to link management instrument, namely send registration request to link management instrument, wherein carry the BID of self; Link management instrument verifies the BID received, and verification is passed through, notice working application, and distributes a storage queue, initial condition for working application, and storage queue is sky.
If verification is not passed through, link management instrument also needs to notify working application, follow-up, and working application can re-start registration or carry out other process, due to scheme of the present invention without direct relation, therefore not describe in detail.
Step 12: the packet that the working application that each verification of link management means accepts is passed through is sent, according to the BID wherein carried by the data pack buffer that receives in the storage queue of correspondence.
For each working application, the interface of link management instrument is all known, when verification by and when having packets need to send, each working application can call the interface of link management instrument, will need transmission Packet Generation to link management instrument; The BID of self, particular content and the callback interface etc. of self is carried in the packet sent; Link management instrument according to the BID wherein carried, by the data pack buffer that receives in the storage queue of correspondence.
Illustrate:
The BID that working application X is corresponding and storage queue are respectively BID X and storage queue X, when after the packet that link management means accepts sends to working application X, find that the BID that wherein carries is BID X, then by the data pack buffer that receives in storage queue X.
Step 13: each storage queue of link management instrument poll, is polled to from each and not for taking out a packet empty storage queue, send to server.
In this step, link management instrument can according to the distribution time by the order after arriving first, each storage queue of poll successively, and when being polled to each storage queue, if it is not empty, then therefrom take out a packet, send to server, when taking out packet, can according to the principle of first in first out.Like this, can ensure that all working application all have identical chance of giving out a contract for a project.
Illustrate:
Suppose to co-exist in 3 storage queues, be respectively storage queue 1, storage queue 2 and storage queue 3, wherein, storage queue 1 distributes at first, storage queue 3 is last distribution (namely the most newly assigned), in addition, suppose in storage queue 1, to be cached with two packets, be respectively packet 1 and packet 2, packet 1 is cached in storage queue 1 prior to packet 2, storage queue 2 is empty, and being cached with 1 packet in storage queue 3, is packet 3.So, link management instrument is by the order according to storage queue 1, storage queue 2, storage queue 3, the each storage queue of poll successively, when being polled to storage queue 1, therefrom taking out packet 1 and sending to server, when being polled to storage queue 2, because it is empty, skip, when being polled to storage queue 3, taking out packet 3 and sending to server; Afterwards, link management instrument can repeat said process, namely again carries out poll according to the order of storage queue 1, storage queue 2, storage queue 3 and carries out Packet Generation.
In addition, link management instrument is before the Packet Generation that will take out is to server, first can determine whether set up link between self and server, if, then utilize the link of setting up by the Packet Generation that takes out to server, otherwise, first establish the link, then utilize the link of setting up by the Packet Generation that takes out to server.How to establish the link as prior art between link management instrument and server.Follow-up, when sending without any packets need, link management instrument can disconnect linking between server.
Step 14: what link management means accepts server returned returns bag, sends to corresponding working application according to the BID wherein carried by the bag that returns received.
Server receives arbitrary packet that link management instrument sends and after being disposed, correspondingly can return one and return bag, wherein carry BID (identical with the BID carried in the packet received), particular content and server relevant information etc.; After link management means accepts to this time bag, determine the working application of its correspondence according to the BID wherein carried, and according to the callback interface got in step 12, the bag that returns received is sent to the working application determined; Working application can be resolved returning of receiving and be wrapped, thus obtains the information such as particular content wherein.
In actual applications, due to a variety of causes, the packet that server may be caused normally can not to receive link management instrument send, correspondingly, server also just cannot generate corresponding returning and wrap, or time bag that server generates can not normally send to link management instrument.
For above-mentioned both of these case, link management instrument can provide an overtime testing mechanism, for packet X: the timing from packet X is cached in storage queue of link management instrument, if exceed scheduled duration (such as 30 seconds) not receive corresponding with packet X returning yet and wrap, then send a time-out bag to the working application sending packet X, to illustrate that packet X sends unsuccessfully, wherein can carry concrete failure cause, afterwards, the working application sending packet X can according to self needs, again send packet X to link management instrument or carry out other process.
In addition, after have sent time-out bag to the working application sending packet X, link management instrument needs packet X to delete from the storage queue at its place; If link management means accepts has arrived packet X, corresponding returning is wrapped, and so after Jiang Huibao sends to the working application sending packet X, also needs packet X to delete from the storage queue at its place.
It should be noted that, the sequencing that step 11 ~ 14 are not strict when reality performs, the representation in the present embodiment only in order to express easily.In actual applications, each step is likely is executed in parallel, such as link management instrument is while carrying out poll, also may can receive registration request and/or packet that a certain or some working application sends, so, the Packet Generation of link management instrument in the storage queue that will be polled to server while, also need to carry out BID verification and/or by data pack buffer to the medium process of storage queue.
So far, the introduction about the inventive method embodiment is namely completed.
Based on above-mentioned introduction, Fig. 2 is the composition structural representation of apparatus of the present invention embodiment.This device be namely equivalent to embodiment illustrated in fig. 1 in link management instrument, be arranged in mobile terminal.As shown in Figure 2, comprising:
First processing unit 21, the registration request sent after starting for each working application in mobile terminal receive, the BID wherein carried is verified, verification is passed through, notice working application, and distribute a storage queue for working application, a unique corresponding BID and storage queue of each working application; Receive the packet that working application that each verification passes through is sent, according to the BID wherein carried by the data pack buffer that receives in the storage queue of correspondence;
Second processing unit 22, for each storage queue of poll, is polled to from each and not for taking out a packet empty storage queue, send to server; What reception server returned returns bag, according to the BID wherein carried, the bag that returns received is sent to corresponding working application.
Wherein, second processing unit 22 can be further used for, for arbitrary packet X, and timing from packet X is cached in storage queue, if exceed scheduled duration not receive corresponding with packet X returning yet and wrap, then send time-out to the working application sending packet X and wrap.
Second processing unit 22 also can be further used for, after corresponding for packet X returning being wrapped the working application sending to transmission packet X, or, after the working application sending packet X sends time-out bag, packet X is deleted from the storage queue at its place.
The specific works flow process of Fig. 2 shown device please refer to the respective description in embodiment of the method shown in Fig. 1, repeats no more herein.
In a word, adopt technical scheme of the present invention, for each mobile terminal, only need set up one between itself and server to link, multiple working application in mobile terminal share this link, thus the gateway decreasing cellular carrier needs link number to be processed, and then reduce networking mortality, and improve the service efficiency of link.
The foregoing is only preferred embodiment of the present invention, not in order to limit the present invention, within the spirit and principles in the present invention all, any amendment made, equivalent replacement, improvement etc., all should be included within the scope of protection of the invention.

Claims (8)

1. a processing method for working application, is characterized in that, the method comprises:
When each working application in mobile terminal starts, send registration request to the link management instrument in mobile terminal; Link management instrument verifies the identification identifier BID carried in registration request, and verification is passed through, and notice sends the working application of registration request, and distributes a storage queue for the working application of described transmission registration request; A unique corresponding BID and storage queue of each working application;
The packet that the working application that each verification of link management means accepts is passed through is sent, according to the BID wherein carried by the data pack buffer that receives in the storage queue of correspondence;
The each storage queue of link management instrument poll, is polled to from each and not for taking out a packet empty storage queue, send to server; What reception server returned returns bag, according to the BID wherein carried, the bag that returns received is sent to corresponding working application.
2. method according to claim 1, is characterized in that, described in send to server to comprise:
Link management instrument determines whether set up link between self and server, if so, then the link of setting up is utilized by the Packet Generation that takes out to server, otherwise, establish the link, then utilize the link of setting up by the Packet Generation that takes out to server.
3. method according to claim 1, is characterized in that, the method comprises further:
For arbitrary packet X, the timing from packet X is cached in storage queue of link management instrument, does not receive corresponding with packet X returning yet wrap if exceedes scheduled duration, then send time-out to the working application sending packet X and wrap.
4. method according to claim 3, is characterized in that, the method comprises further:
After corresponding for packet X returning being wrapped the working application sending to transmission packet X, or after the working application transmission time-out sending packet X is wrapped, packet X deletes by link management instrument from the storage queue at its place.
5. the method according to claim 1,2 or 3, is characterized in that, each storage queue of described poll comprises: according to the distribution time by the order each storage queue of poll successively after arriving first;
Described from storage queue take out a data handbag draw together: from storage queue, take out a packet according to the principle of first in first out.
6. a processing unit for working application, is characterized in that, this device is arranged in mobile terminal, comprising:
First processing unit, the registration request sent after starting for each working application in mobile terminal receive, the identification identifier BID wherein carried is verified, verification is passed through, notice sends the working application of registration request, and distribute a storage queue, a unique corresponding BID and storage queue of each working application for the working application of described transmission registration request; Receive the packet that working application that each verification passes through is sent, according to the BID wherein carried by the data pack buffer that receives in the storage queue of correspondence;
Second processing unit, for each storage queue of poll, is polled to from each and not for taking out a packet empty storage queue, send to server; What reception server returned returns bag, according to the BID wherein carried, the bag that returns received is sent to corresponding working application.
7. device according to claim 6, it is characterized in that, described second processing unit is further used for, for arbitrary packet X, timing from packet X is cached in storage queue, if exceed scheduled duration not receive corresponding with packet X returning yet and wrap, then send time-out to the working application sending packet X and wrap.
8. device according to claim 7, it is characterized in that, described second processing unit is further used for, after corresponding for packet X returning being wrapped the working application sending to transmission packet X, or, after the working application sending packet X sends time-out bag, packet X is deleted from the storage queue at its place.
CN201110097758.8A 2011-04-19 2011-04-19 A kind of processing method of working application and device Active CN102752847B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201110097758.8A CN102752847B (en) 2011-04-19 2011-04-19 A kind of processing method of working application and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201110097758.8A CN102752847B (en) 2011-04-19 2011-04-19 A kind of processing method of working application and device

Publications (2)

Publication Number Publication Date
CN102752847A CN102752847A (en) 2012-10-24
CN102752847B true CN102752847B (en) 2015-09-02

Family

ID=47032684

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201110097758.8A Active CN102752847B (en) 2011-04-19 2011-04-19 A kind of processing method of working application and device

Country Status (1)

Country Link
CN (1) CN102752847B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106375437B (en) * 2016-08-31 2019-08-27 上海银赛计算机科技有限公司 Data checking method and device

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101094181B (en) * 2007-07-25 2010-12-08 华为技术有限公司 Dispatch device and method of enqueuing and dequeuing message
CN101256578B (en) * 2008-04-08 2010-06-09 中兴通讯股份有限公司 Method for implementing multi-user in internal memory database
CN101448006B (en) * 2008-12-25 2012-01-11 中兴通讯股份有限公司 Method and system for realizing access for a great amount of terminals for streaming media server
CN101902398B (en) * 2010-07-12 2014-12-17 中兴通讯股份有限公司 Method and system for receiving and transmitting data packet

Also Published As

Publication number Publication date
CN102752847A (en) 2012-10-24

Similar Documents

Publication Publication Date Title
CN101909257B (en) Method and system for realizing concurrency access of multiple bearer protocols by M2M platform
CN102196591A (en) Mobile terminal and data parallel transmission method thereof
CN103516673A (en) Network data communication method, network data communication system, network data communication client and network data communication server
CN102625287A (en) Method for downloading mobile phone application software
CN103220292A (en) Cross-safe-area data transmission method and system
GB2589211A (en) Methods and systems of using remote subscriber identification modules at device
CN103535004A (en) Anonymous signalling
CN101977358A (en) Method, device and equipment for transmitting data short messages
CN101778053A (en) Inter-instant messenger communication method and device
CN102612007A (en) Flow control method and device for short messages
CN101631127A (en) File transfer method and clients
CA2533543A1 (en) System and method for managing communication for component applications
CN103250382A (en) Distribution method, apparatus and system
CN103067981B (en) A kind of content caching by-pass method and system
CN102752847B (en) A kind of processing method of working application and device
CN100455059C (en) Short message gateway bridging system, method and short message gateway bridge module
CN102523577A (en) Method and device for updating application service
CN101309458B (en) Short message realizing method between multiple enterprises, system and equipment
CN101510872A (en) Remote customer dialing authentication service client terminal, server and transmission/acceptance method
CN101170734B (en) Method and device for service intercommunication between different networks
CN101150769B (en) Method for sending SMS and SMS platform
CN103312753A (en) Communication method and device of Internet of things
CN103533001A (en) Communication method and communication system based on HTTP multi-proxy, and intermediate proxy server
CN102695154A (en) Base station straight-through architecture-based method, device and system for charging process
CN102497306A (en) Method for realizing data transmission of distribution network substation and system thereof

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant