[go: up one dir, main page]

CN103001990A - Data relay method and data relay system - Google Patents

Data relay method and data relay system Download PDF

Info

Publication number
CN103001990A
CN103001990A CN201110276203XA CN201110276203A CN103001990A CN 103001990 A CN103001990 A CN 103001990A CN 201110276203X A CN201110276203X A CN 201110276203XA CN 201110276203 A CN201110276203 A CN 201110276203A CN 103001990 A CN103001990 A CN 103001990A
Authority
CN
China
Prior art keywords
data
original data
current service
service
server
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
CN201110276203XA
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.)
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 CN201110276203XA priority Critical patent/CN103001990A/en
Publication of CN103001990A publication Critical patent/CN103001990A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The invention discloses a data relay method. The method includes: after a current service request is triggered, when a current service needs to be switched to other services, submitting original data of the current service needing to retain transmission to a relay server be stored; and when other services need to be switched back to the current service again, acquiring the stored original data from the relay server, and continuing to execute the current service according to the original data. The invention further discloses a data relay system comprising a data submitting unit and the relay server, wherein the data submitting unit is used for submitting the original data of the current service needing to retain transmission to the relay server when the current service needs to be switched to other services after the current service request is triggered; and the relay server is used for storing the original data submitted by the data submitting unit. By the method and the system, carrying of mass data content can be realized, and data sharing transmission is achieved.

Description

Data transfer method and system
Technical Field
The invention relates to a data sharing technology, in particular to a data transfer method and a data transfer system during switching of different service requests of a wireless application protocol (WAP, Wireless application Protoco1) webpage.
Background
In the prior art, when a WAP page is browsed and automatic skip is performed by switching different service requests, the way of submitting WAP page data includes two implementation ways. The first realization mode is as follows: each service submits data in a GET mode so as to achieve the purpose of carrying out data sharing transmission in a plurality of services. The second implementation manner is as follows: and submitting data in a POST mode so as to achieve the purpose of carrying out data sharing transmission in a plurality of services.
For the first implementation, submitting data in the GET mode refers to a data transmission mode in which data is delivered after being appended to a Uniform Resource Locator (URL). The disadvantages of this approach are: since the GET method is a method of transmitting data after attaching the data to a URL, and the length of a general URL is limited by an upper limit, the size of data to be submitted in the GET method is limited when browsing a WAP web page, and the size of data to be carried in each service request is limited inevitably when the data size is large, so that a large amount of data content cannot be carried in data transmission.
For the second implementation, submitting data in a POST manner refers to a data transmission manner in which data is placed in a data area of a submission form for transmission. The disadvantages of this approach are: by using the POST method, in the process of executing switching of different service requests, data used by each service involved needs to be uniformly embedded into a form code for submitting data in the POST method, that is, data used by all services needs to be uniformly collected, some data need to be shared, and some data need to be exclusively used by each service, so that, for each service, although the data volume is not limited, the difficulty of subsequent data modification and maintenance is inevitably caused, and the independence of execution of each service is also influenced by the fact that the shared data is not required to be transmitted together.
In summary, no effective solution exists at present for how to ensure that a large amount of data content can be carried and achieve the purpose of data sharing transmission in the case of automatic skip when different service requests are switched when browsing a WAP webpage.
Disclosure of Invention
In view of the above, the main objective of the present invention is to provide a data transfer method and system, which can carry a large amount of data content, so as to achieve the purpose of data sharing transmission.
In order to achieve the purpose, the technical scheme of the invention is realized as follows:
the invention provides a data transfer method, which comprises the following steps:
after a current service request is triggered, when the current service needs to be switched to other services, original data which need to be transmitted by the current service are submitted to a transfer server for storage;
and when the current service needs to be switched back again, acquiring the stored original data from the transit server, and continuously executing the current service according to the original data.
In the above solution, when switching to the other service, the method further includes: and when the other services are executed, the stored original data are obtained from the transit server for use, or the original data are modified and then are submitted to the transit server for storage again.
In the above solution, after the original data is modified and then submitted to the transit server for storage, the method further includes: and when the current service needs to be switched back again, acquiring the stored data submitted after modification from the transfer server, and continuously executing the current service according to the data submitted after modification.
In the above scheme, the number of the transit servers is one or more. When the transfer server is multiple, the method further comprises: and positioning different transit servers by performing a modulo operation on the user login number.
The method further comprises the following steps: the original data which needs to be transmitted or the data submitted after modification are correspondingly stored in the same transfer server which is positioned based on the same user login number by different services based on the same user login number.
The present invention also provides a data transfer system, including: the system comprises a data submitting unit, a transfer server and a service execution unit; wherein,
the data submitting unit is used for submitting the original data which needs to be transmitted by the current service to the transfer server when the current service needs to be switched to other services after the current service request is triggered;
the transfer server is used for storing the original data submitted by the data submitting unit;
and the service execution unit is used for acquiring the stored original data from the transit server when the current service needs to be switched back again, and continuously executing the current service according to the original data.
In the above scheme, the data submitting unit is further configured to, when the other service is executed, submit the modified original data to the transit server again for storage;
the service execution unit is further configured to obtain the stored original data from the transit server for use when executing the other service.
In the foregoing solution, the service execution unit is further configured to, after the original data is modified and resubmitted in the transit server for storage, obtain, when a current service needs to be switched back to, the stored modified and resubmitted data from the transit server, and continue to execute the current service according to the modified and resubmitted data.
In the foregoing solution, the data submitting unit is further configured to, when there are multiple transit servers, submit the original data or the data submitted after modification after positioning different transit servers by performing a modulo operation on the user login number.
In the above scheme, the transfer server is further configured to store original data corresponding to different services based on the same user login number or data submitted after modification after being located according to the same user login number.
After a current service request is triggered, when the current service needs to be switched to other services, original data which need to be transmitted by the current service are submitted to a transfer server for storage; and when the current service needs to be switched back again, acquiring the stored original data from the transit server, and continuously executing the current service according to the original data.
The invention stores the data to be transmitted in the transfer server for use in the following service execution, and the transfer server has larger storage capacity than URL and is easier to manage than form, thereby realizing the carrying of a large amount of data contents and achieving the purpose of data sharing transmission.
Drawings
Fig. 1 is a schematic step diagram of a data relay method according to an embodiment of the present invention;
fig. 2 is a flowchart of an implementation of a data relay method according to an embodiment of the present invention;
fig. 3 is a structural framework diagram of the data relay system according to the embodiment of the present invention.
Detailed Description
The following describes the embodiments in further detail with reference to the accompanying drawings.
As shown in fig. 1, a data relay method includes the following steps:
step 101, after triggering the current service request, when the current service needs to be switched to other services, submitting the original data which needs to be transmitted by the current service to a transit server for storage.
And 102, when the current service needs to be switched back, acquiring the stored original data from the transfer server, and continuously executing the current service according to the original data.
Further, when the current service is switched to the other service, the method further comprises: and when the other services are executed, the stored original data are obtained from the transit server for use, or the original data are modified and then are submitted to the transit server for storage again.
Here, the beneficial effects that the original data or the modified submitted data can be stored in the transit server are as follows: compared with the existing GET mode, the original data needing to be shared and transmitted or the data submitted after modification are stored in the transfer server, the method has the advantages that the URL upper limit is easy to achieve, a large amount of data cannot be carried, and the data irrelevant to the current service execution in the existing POST mode also needs to be carried, so that the complexity and the coupling of the service are reduced, the independence of the data during the execution of each service is ensured while the data is shared, and the data only needs to be acquired from the transfer server when the data is needed during the execution of the service. In addition, the storage form of the transit server is not limited by the inherent limit of a specific browser protocol (such as a WAP protocol), so that the data transmission among different services and even among different pages can get rid of the inherent limit of the browser protocol and is more free.
Further, after the original data is modified and then is resubmitted to the transit server for storage, the method further includes: and when the current service needs to be switched back again, acquiring the stored data submitted after modification from the transfer server, and continuously executing the current service according to the data submitted after modification.
The transit server may be one or more.
When a plurality of transit servers are provided, which may also be called as distributed transit servers, the method further applies a distributed service access technique, that is: and positioning different transit servers by performing a modulo operation on the user login number. Here, the modulo operation is a remainder operation. "Mod" is the transliteration of "Mod", which means complementation, e.g., 11Mod 2 results in 1. Modulus operations have wide application in both number theory and programming.
Further, the method further comprises: the original data which needs to be transmitted or the data submitted after modification are correspondingly stored in the same transfer server which is positioned based on the same user login number by different services based on the same user login number.
Further, the storage mode of the transit server is a short-time cache mode. The short-time caching mode means that the data is not permanently stored in the transit server, but the data stored in the transit server is cleared when the preset upper limit time is reached after the upper limit time for clearing the cache is set.
It should be noted that the present invention adopts the distributed service access technique and the short-time caching technique, considering that the transit service is a single-point service in a complete flow, and therefore, the storage capacity and the access amount of the transit service must be reasonably controlled.
The beneficial effects of adopting the distributed service modulo access technology to control the storage quantity and the access quantity are as follows: the transit servers are distributed, and can locate corresponding transit services by performing a modulo operation on a user's login number, such as an MSN number. The method can ensure that the login number of the same user corresponds to the same transfer server, thereby ensuring the single-point characteristic of the transfer service in a complete process, reducing the storage pressure of the transfer server compared with the method of storing all data by adopting one transfer server, dispersing the users to different transfer servers by using a distributed service access technology, and well controlling the pressure of the access amount.
The beneficial effects of adopting the short-time caching technology to control the storage capacity are as follows: the storage mode of the data in the transit server selects a local short-time cache, the local short-time cache can ensure simple realization of read-write performance, and the local short-time cache can ensure timely removal after a normal data sharing process is completed, so that the pressure of the storage capacity is reduced.
The invention is illustrated below.
The method comprises the following steps: the service switching execution flow comprises three services, wherein the services 1 to 3 are services which need automatic jump switching. The transit server is not a plurality of servers which exist in a distributed mode, but is an integrated server, and the transit server stores shared data among various services, and the shared data can comprise original data submitted initially or modified submitted data submitted again after modification.
As shown in fig. 2, the transit flow of the data transferred between the services in this embodiment includes the following steps:
step 201, as the service 1 initiating the service, submitting the original data to be transmitted in the automatic service process to the transit server for storage.
Step 202, after the data storage is finished, the service 1 starts to perform an automatic skip process, and the skip is switched to the service 2.
Step 203, service 2 executes internal logic.
Here, in this process, the service 2 may obtain the original data stored in the service 1 from the transit server, or may modify the data, and then resubmit the modified data back to the transit server for storage.
Step 204, the service 2 starts an automatic skip process, and the skip is switched to the service 3.
Step 205, service 3 executes internal logic.
Here, in this process, the service 3 may obtain the original data stored in the service 1 from the transit server, or may modify the data, and resubmit the modified data back to the transit server for storage.
Step 206, the service 3 starts the automatic skip process, and the skip is switched back to the original service (service 1).
Step 207-step 208, after receiving the jump request returned by the service 3, the service 1 requests the transit server to acquire the original data or the data which is submitted after being modified by the service 2-service 3; and the transfer server finishes the jump switching among different services after returning the requested data.
And step 209, after the jump switching is finished, clearing the data stored locally in the transit server when the set local short-time cache upper limit time is reached.
The services to which the invention relates are illustrated here as follows:
the service of the invention is based on various services used by the WAP webpage, such as sending pictures, characters, or sending the position information of the user in a microblog.
When a WAP webpage request is sent among different services to request for executing switching, data can be uploaded to a transfer server to be stored, if the service 1 is a microblog editing character and the service 2 is a microblog uploading picture.
A data relay system, as shown in fig. 3, comprising: the system comprises a data submitting unit, a transit server and a service executing unit. The data submitting unit is used for submitting original data which needs to be transmitted by the current service to the transit server when the current service needs to be switched to other services after the current service request is triggered; the transfer server is used for storing the original data submitted by the data submitting unit; and the service execution unit is used for acquiring the stored original data from the transit server when the current service needs to be switched back again, and continuously executing the current service according to the original data.
Further, the data submitting unit is further configured to, when the other service is executed, submit the modified original data to the transit server for storage again.
Further, the service execution unit is further configured to obtain the stored raw data from the transit server for use when executing the other service.
Further, the service execution unit is further configured to, after the original data is modified and resubmitted in the transit server for storage, acquire the stored modified and resubmitted data from the transit server when the current service needs to be switched back, and continue to execute the current service according to the modified and resubmitted data.
Further, the transit servers are one or more.
Further, the data submitting unit is further configured to, when there are a plurality of transit servers, submit the original data or the data submitted after modification after positioning different transit servers by performing a modulo operation on the user login number.
Furthermore, the transit server is further used for storing original data corresponding to different services based on the same user login number or data submitted after modification after positioning according to the same user login number.
The above description is only a preferred embodiment of the present invention, and is not intended to limit the scope of the present invention.

Claims (12)

1. A data transfer method is characterized by comprising the following steps:
after a current service request is triggered, when the current service needs to be switched to other services, original data which need to be transmitted by the current service are submitted to a transfer server for storage;
and when the current service needs to be switched back again, acquiring the stored original data from the transit server, and continuously executing the current service according to the original data.
2. The method of claim 1, wherein when switching to the other service, the method further comprises: and when the other services are executed, the stored original data are obtained from the transit server for use, or the original data are modified and then are submitted to the transit server for storage again.
3. The method of claim 2, wherein after modifying the original data and resubmitting the modified original data to the transit server storage, the method further comprises: and when the current service needs to be switched back again, acquiring the stored data submitted after modification from the transfer server, and continuously executing the current service according to the data submitted after modification.
4. The method of claim 1 or 2, wherein the transit server is one or more.
5. The method of claim 4, wherein when there are a plurality of transit servers, the method further comprises: and positioning different transit servers by performing a modulo operation on the user login number.
6. The method of claim 5, further comprising: the original data which needs to be transmitted or the data submitted after modification are correspondingly stored in the same transfer server which is positioned based on the same user login number by different services based on the same user login number.
7. A data relay system, comprising: the system comprises a data submitting unit, a transfer server and a service execution unit; wherein,
the data submitting unit is used for submitting the original data which needs to be transmitted by the current service to the transfer server when the current service needs to be switched to other services after the current service request is triggered;
the transfer server is used for storing the original data submitted by the data submitting unit;
and the service execution unit is used for acquiring the stored original data from the transit server when the current service needs to be switched back again, and continuously executing the current service according to the original data.
8. The system of claim 7, wherein the data submitting unit is further configured to, when executing the other service, revise the original data and then submit the modified original data to the transit server storage;
the service execution unit is further configured to obtain the stored original data from the transit server for use when executing the other service.
9. The system of claim 8, wherein the service execution unit is further configured to, after the original data is modified and resubmitted in the transit server for storage, obtain the stored modified and submitted data from the transit server when a new switch back to the current service is required, and continue to execute the current service according to the modified and submitted data.
10. The system of claim 7 or 8, wherein the transit server is one or more.
11. The system of claim 10, wherein the data submitting unit is further configured to, when there are multiple transit servers, submit the original data or the modified submitted data after locating different transit servers by performing a modulo operation on the user login number.
12. The system of claim 11, wherein the transit server is further configured to store original data or modified submitted data corresponding to different services based on the same user login number after being located according to the same user login number.
CN201110276203XA 2011-09-16 2011-09-16 Data relay method and data relay system Pending CN103001990A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201110276203XA CN103001990A (en) 2011-09-16 2011-09-16 Data relay method and data relay system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201110276203XA CN103001990A (en) 2011-09-16 2011-09-16 Data relay method and data relay system

Publications (1)

Publication Number Publication Date
CN103001990A true CN103001990A (en) 2013-03-27

Family

ID=47930130

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201110276203XA Pending CN103001990A (en) 2011-09-16 2011-09-16 Data relay method and data relay system

Country Status (1)

Country Link
CN (1) CN103001990A (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1383068A (en) * 2001-04-27 2002-12-04 邵通 Device and method for changing state of computing equipment
CN1735250A (en) * 2004-08-10 2006-02-15 谢成火 Method and equipment for providing memory space for mobile terminal
CN1901476A (en) * 2006-07-12 2007-01-24 中国移动通信集团公司 Network journal information processing device and method
CN101335762A (en) * 2007-06-25 2008-12-31 株式会社日立制作所 Method for reflecting historical usage behavior of webpage, and server, terminal and system
CN101355470A (en) * 2007-07-26 2009-01-28 华为技术有限公司 System, method and device for realizing business continuity in home network environment
CN102104632A (en) * 2005-01-24 2011-06-22 茨特里克斯系统公司 Systems and methods for performing caching of dynamically generated objects in a network

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1383068A (en) * 2001-04-27 2002-12-04 邵通 Device and method for changing state of computing equipment
CN1735250A (en) * 2004-08-10 2006-02-15 谢成火 Method and equipment for providing memory space for mobile terminal
CN102104632A (en) * 2005-01-24 2011-06-22 茨特里克斯系统公司 Systems and methods for performing caching of dynamically generated objects in a network
CN1901476A (en) * 2006-07-12 2007-01-24 中国移动通信集团公司 Network journal information processing device and method
CN101335762A (en) * 2007-06-25 2008-12-31 株式会社日立制作所 Method for reflecting historical usage behavior of webpage, and server, terminal and system
CN101355470A (en) * 2007-07-26 2009-01-28 华为技术有限公司 System, method and device for realizing business continuity in home network environment

Similar Documents

Publication Publication Date Title
US11349940B2 (en) Server side data cache system
JP6007246B2 (en) Predictive multi-layer cache architecture
US9336146B2 (en) Accelerating cache state transfer on a directory-based multicore architecture
US20130117252A1 (en) Large-scale real-time fetch service
CN104572293B (en) The implementation method of medical image diagosis system based on BS structures
US8069406B2 (en) Method and system for improving user experience while browsing
CN103765419B (en) System and method for providing offline access in main frame document services
US8458727B2 (en) Asynchronous client to server updates
CN102387220A (en) Offline downloading method and system based on cloud storage
JP5863388B2 (en) Information processing system, control method therefor, and program
CN102647634A (en) A method and device for playing multi-slice video based on HTML5video
KR20140102220A (en) Application-driven cdn pre-caching
CN106294365A (en) The page data processing method of a kind of single page web application and equipment
CN108920703A (en) A kind of HTTP cache optimization method and device
CN104144202A (en) Hadoop distributed file system access method, system and device
CN105095220B (en) A browser implementation method, terminal and virtualized proxy device
CN104376122A (en) Method for browser client to obtain static file and server
CN105389096A (en) Browser based data interaction method and apparatus
US11755534B2 (en) Data caching method and node based on hyper-converged infrastructure
CN103379163A (en) Service object determination method and determination device
CN103001990A (en) Data relay method and data relay system
CN105144099A (en) Communication system
DE112009000579T5 (en) Shared access to a storage device
US8595612B1 (en) Display of web page with available data
JP2015207027A (en) Web page cache device, web page cache method, program and integrated circuit

Legal Events

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

Application publication date: 20130327

RJ01 Rejection of invention patent application after publication