WO2012016503A1 - 一种文件同步方法、电子设备和同步系统 - Google Patents

一种文件同步方法、电子设备和同步系统 Download PDF

Info

Publication number
WO2012016503A1
WO2012016503A1 PCT/CN2011/077845 CN2011077845W WO2012016503A1 WO 2012016503 A1 WO2012016503 A1 WO 2012016503A1 CN 2011077845 W CN2011077845 W CN 2011077845W WO 2012016503 A1 WO2012016503 A1 WO 2012016503A1
Authority
WO
WIPO (PCT)
Prior art keywords
file
processing program
operation content
buffer area
application
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.)
Ceased
Application number
PCT/CN2011/077845
Other languages
English (en)
French (fr)
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.)
Lenovo Beijing Ltd
Beijing Lenovo Software Ltd
Original Assignee
Lenovo Beijing Ltd
Beijing Lenovo Software 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 Lenovo Beijing Ltd, Beijing Lenovo Software Ltd filed Critical Lenovo Beijing Ltd
Priority to US13/813,027 priority Critical patent/US9361309B2/en
Publication of WO2012016503A1 publication Critical patent/WO2012016503A1/zh
Anticipated expiration legal-status Critical
Ceased legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/17Details of further file system functions
    • G06F16/178Techniques for file synchronisation in file systems
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/17Details of further file system functions
    • G06F16/1734Details of monitoring file system events, e.g. by the use of hooks, filter drivers, logs

Definitions

  • the present invention relates to computer storage technology, and more particularly to a file synchronization method, an electronic device, and a synchronization system. Background technique
  • hybrid technology when using two or more systems at the same time, providing real-time synchronization for files in use gives users a very good experience; for example, When the main system of the first system is processing the file, for some reason, it is necessary to immediately switch to the second system. At this time, the user still wants to continue the current file processing work, and it is necessary to manually save all the files currently opened by the main system. Or rely on the timed automatic save function to save.
  • the inventor has found that at least the following problems exist in the prior art: During the synchronization process, even if the user uses the prior art such as automatic file saving and automatic synchronization, the user cannot save the currently updated content, and cannot update the updated content perfectly. Go to the second system. Specifically, the existing file synchronization technology supports the synchronization function based on the saved file, but if the automatic storage interval is too long, it may affect the system performance; therefore, it is impossible to record any modification at any moment, so that no real implementation is achieved.
  • An object of the present invention is to provide a file synchronization method, an electronic device, and a synchronization system for solving a file on one of the systems when two or more systems share the same file or files in the prior art. After being modified, it is not possible to save and display the defects of the currently updated content in real time on other systems.
  • the present invention provides a file synchronization method, the file synchronization method being applied to a hybrid system having a first system and a second system, the method comprising: the first system monitoring the first system a first buffer area, wherein the first buffer area stores a first file corresponding to the first file stored in the non-volatile memory of the first system opened by the first file processing program in the first system
  • the first file processing program is passed through the data information channel between the first system and the second system when the first data in the first buffer area is changed.
  • the operation content performed on the first file is sent to the second system; and the second file processing program in the second system synchronizes the second file according to the operation content; the second file Is a file corresponding to the first file in the second system, the second file being stored in a non-volatile memory of the second system.
  • the operation content is an application interface that is invoked when the first file processing program updates the first file, an operation parameter of the application program interface, and a current assignment of the working parameter.
  • the operation content includes: a first number before the change occurs, an application program interface that is invoked when the first file processing program updates the first file, and an operating parameter of the application program interface. And the current assignment of the working parameter; or, the operation content includes: a structural parameter of the first file, an application program interface that is invoked by the first file processing program to perform the newer file on the first file, The working parameters of the application interface and the current assignment of the working parameters.
  • the operation content is sent in a first predetermined time interval; wherein, the first predetermined time interval is much smaller than The automatic save time interval of the first system and/or the second system.
  • the first buffer area is a volatile memory of the first system.
  • the present invention also provides a file synchronization system, including a first system and a second system; wherein, the first system: monitoring a first buffer area of the first system, and storing the first buffer area Decoding, by the first file processing program in the first system, the first data corresponding to the first file stored in the non-volatile memory of the first system; when monitoring the location in the first buffer area Transmitting the first number, according to the number information channel between the first system and the second system, sending the operation content performed by the first file processing program to the first file Go to the second system; the second file processing program in the second system performs the synchronization processing on the second file, and the second file is in the second system A file corresponding to a file, the second file being stored in a non-volatile memory of the second system.
  • the operation content is an application interface that is invoked when the first file processing program updates the first file, an operating parameter of the application program interface, and the working parameter.
  • the operation content includes: the first data before the change occurs, the application program interface that is invoked when the first file processing program updates the first file, the working parameter of the application program interface, and
  • the operation content includes: a structure parameter of the first file, an application program interface that is invoked when the first file processing program updates the first file, and the application program interface The working parameters, as well as the current value of the working parameters.
  • the first buffer area is a volatile memory of the first system.
  • the present invention also provides an electronic device, including: a first system and a second system; wherein: the first system: monitoring a first buffer area of the first system, where the first buffer area is stored The first file corresponding to the first file stored in the non-volatile memory of the first system opened by the first file processing program in the first system; when the first buffer area is When the first data is changed, the operation content performed by the first file processing program on the first file is sent to the second by using a data information channel between the first system and the second system a second file processing program of the second system performs synchronization processing on the second file according to the operation content, where the second file is a file corresponding to the first file in the second system, The second file is stored in a non-volatile memory of the second system.
  • the electronic device further includes: a first plug-in application service logic in the first system, configured to record a structural parameter of the first file, and record the execution of the first file by the first file processing program And operating a second plug-in application service logic located in the second system to establish and maintain a data information channel; and send the operation content performed on the first file and/or the structural parameters of the first file to a second plug-in application business logic located in the second system; a second plug-in application business logic in the second system, configured to record structural parameters of the second file, and recording the second file processing program An operation content performed by the second file; and establishing and maintaining a data information channel with the first plug-in application business logic located in the first system; an operation content to be performed on the second file and/or the second file
  • the structural parameters are sent to the first plug-in application business logic located in the first system.
  • the first buffer area is a volatile memory of the first system.
  • the present invention also provides an electronic device, including a first system; wherein, the first system monitors a first buffer area of the first system, and the first buffer area stores the first system a first number corresponding to the first file stored in the non-volatile memory of the first system opened by the first file processing program, according to; when the first data in the first buffer area is changed Transmitting, by the number of information channels between the first system and the second system, the operation content performed by the first file processing program on the first file to the second system, where Synchronizing the second file according to the operation content by the second file processing program in the second system; the second file is a file corresponding to the first file in the second system, The second file is stored in a non-volatile memory of the second system, and the second system is located on another electronic device.
  • the electronic device further includes: a plug-in application business logic, configured to record a structural parameter of the first file, and record an operation content performed by the first file processing program on the first file.
  • a plug-in application business logic configured to record a structural parameter of the first file, and record an operation content performed by the first file processing program on the first file.
  • the first buffer area is a volatile memory of the first system.
  • FIG. 1 is a schematic flowchart of a file synchronization method according to an embodiment of the present invention
  • FIG. 2 is a schematic diagram of a synchronous working principle between a first system and a second system according to an embodiment of the present invention
  • FIG. 3 is a schematic structural diagram of an electronic device according to an embodiment of the present invention. detailed description
  • a real-time synchronization technology of the file based on the memory mode is realized.
  • a file stored in a non-volatile memory such as a hard disk
  • a file processing program under the operating system - that is, the corresponding data of the file on the hard disk is written into the system.
  • the volatile memory Has data corresponding to the file.
  • the embodiment provided by the present invention is to monitor the operation content of the first data corresponding to the first file by the user on the volatile memory in real time, and send the operation content to the second system, according to the second system.
  • the operation content synchronizes the second file corresponding to the first file.
  • a file synchronization method is provided, the file synchronization method being applied to a hybrid system having a first system and a second system, the first system including a first hardware system and based on the first hardware a first operating system of the system, the second system comprising a second hardware system and a second operating system based on the second hardware system; the method comprising:
  • Step 101 Monitor, in the first system, a first buffer area of the first system, where the first file processing program stored in the first system is stored in the first buffer area. First data corresponding to the first file in a non-volatile memory of the system;
  • Step 102 When the first data in the first buffer area is changed, the first file processing program is used by using a data information channel between the first system and the second system. The operation content of the first file execution is sent to the second system;
  • Step 103 The second file processing program in the second system performs synchronization processing on the second file according to the operation content, where the second file is corresponding to the first file in the second system.
  • a file and the second file is stored in a non-volatile memory (eg, a hard disk) of the second system.
  • the first hardware system includes the first buffer area, the first file processing program is operated based on the first operating system, and the second hardware system includes the second buffer area, the second The file handler runs based on the second operating system.
  • the second data corresponding to the second file opened by the second file processing program is stored in the second buffer area in the second system.
  • the first system state and the second system state are consistent.
  • the first system is in a state in which the first file is opened by the first file processing program; the second system is in a state in which the second file is opened by the second file processing program.
  • the operation content that causes the first file to be updated can be sent to the second system in real time, and the second file processing program performs the update on the second file according to the operation content, because the operation content It is to multiply the buffer area in the memory, and the operation content can be detected and sent to the second system at the moment when the operation occurs, and the second file processing program root
  • the same operation is performed on the second file in real time, so the above process is real-time, and real-time synchronous update of the same file can be realized in different systems without manual/automatic saving; and in the first system
  • the operation content in the second system is consistent, and the first file and the second file are also consistent, so that the updated first file and the second file are also guaranteed to be consistent.
  • the operation content from the first system can be real-time based on The second file is more new, so it is necessary to separately set the plug-in application business logic in the first system and the second system.
  • the first plug-in application service logic is set in the first system
  • the second plug-in application service logic is set in the second system.
  • the first plug-in application business logic in the first system is used to:
  • the operational content performed on the first file and/or the structural parameters of the first file are sent to a second plug-in application business logic located in the second system.
  • the second plug-in application business logic in the second system is used to:
  • the operational content performed on the second file and/or the structural parameters of the second file are sent to the first plug-in application business logic located in the first system.
  • the user opens the first file by using the first file processing program, and the first buffer stores the first data corresponding to the first file processing program to open the first file, that is, the first file is The number on the hard disk is written to the memory.
  • the plug-in application business logic of the first system is activated, and the plug-in application business logic of the first system performs the following steps:
  • the update operation is initiated by the first file processing program, recording the operation content performed by the first file processing program on the first file, the operation content indicating that the user is in the first Modifying the opened first file under a system;
  • the plug-in application business logic of the second system performs the following steps:
  • the update operation is initiated by the second file processing program, recording the operation content performed by the second file processing program on the second file, the operation content indicating that the user is in the first
  • the second file is modified under the second system
  • the first plug-in application business logic and the second plug-in application business logic have the same function, so in the synchronization process, the second plug-in application business logic root can be specified in advance. According to the operation content pair from the first plug-in application business logic The second file is updated.
  • the plug-in of the second system applies the business logic, and performs the following steps:
  • the result of the modification made by the first plug-in application business logic may be notified. If the update operation error occurs, the corresponding error message can be generated.
  • the file synchronization between the first system and the second system may result in different synchronization situations according to actual needs, including:
  • the second file processing program in the second system is in an active state, and the second file has been activated.
  • the operation content includes: an application interface invoked when the first file processing program updates the first file, an operating parameter of the application program interface, and a current threshold value of the working parameter, the second file
  • the processing program can ensure that the update operation is performed on the second file according to the action content in real time, and the second file after the update operation is consistent with the updated first file, that is, the second data in the second buffer area and the first buffer area. The first data in the agreement is consistent.
  • the operation content includes: a first data before an update operation occurs, an application interface invoked when the first file processing program updates the first file, an operating parameter of the application interface, and the working parameter
  • the current assignment for example, if the application interface is a write function sys_write (int fd, void *buffer, int length), then the working parameters of the application interface are parameters: int fd, void *buffer, int length Where int fd is the file index number, void ⁇ buffer is the pointer to the buffer, and int length is the length of the buffer.
  • the operation content includes: a structural parameter of the first file, and an application program interface that is invoked when the first file processing program updates the first file, an operating parameter of the application program interface, and the working parameter Current assignment.
  • the operation content includes: the first number after the update is performed.
  • the second file processing program can also ensure real-time An update is performed on the second file based on these operational contents.
  • the second file handler in the second system is in an active state, but the second file is not activated.
  • the second file processing program searches for the second file and the first file according to the file identification index. Corresponding second file, and activating the second file. Thereafter, the second file processing program performs an update operation consistent with the first case.
  • the second file processing program in the second system is in a non-working state, and the second file is activated in time after receiving the operation content from the first system.
  • the second file processing program After the second plug-in application business logic B 103 receives the operation content from the first system, the second file processing program is started, the second file processing program file identification index first finds the corresponding second file, and the second file is activated. file. Thereafter, the second file processing program performs an update operation consistent with the first case.
  • the second file processing program in the second system is in a non-working state, and after receiving the operation content from the first system, it takes a time interval to activate the second file.
  • the second file processing program After the second plug-in application business logic B 103 receives the operation content from the first system, the second file processing program is not started immediately, but the second plug-in application business logic B 103 needs to be started after a time interval for other reasons.
  • the second file processing program first finds the corresponding second file according to the file identification index by the second file processing program, and activates the second file. Thereafter, the second file handler executes an update operation that is consistent with the first scenario.
  • the second plug-in application business logic B 103 creates a second file in the second system according to the first data before the update operation in the operation content. And performing an update operation on the second file after the second file is created.
  • the operation content includes: first data before the update operation occurs, and an application program interface that is invoked when the first file processing program updates the first file, an operating parameter of the application program interface, and the work The current assignment of the parameter.
  • the operation content may also be the first number after the update operation is performed.
  • the data information channel between the systems updates the third file corresponding to the first file and the second file stored by the system, including: Step 201:
  • the plug-in application service logic is set in the first system, the second system, and the third system, where the plug-in application service logic records the structural parameters of the first file in real time in the first system, and records the first An operation content performed by the file processing program on the first file; wherein, the file to be referred to is referred to as a first file in the first system, a second file in the second system, and a third file in the third system;
  • Step 202 The plug-in application service logic located in each system respectively establishes a data information channel between the first system and the second system; and establishes a data information channel between the second system and the third system; and, establishes the first A data information channel between the system and the third system.
  • Step 203 When the first file in the first system is modified, send the operation content in the first system to the second system through the data information channel in a first predetermined time interval after the update operation occurs. And, the first system sends the operation content through the number. According to the information channel, it is sent to the third system.
  • the first predetermined time interval is usually a fine-grained time interval, such as an interval of milliseconds or even microseconds. Generally, the first predetermined time interval is smaller than the automatically saved time interval, so that each system can be guaranteed. File synchronization can meet real-time performance.
  • the plug-in application business logic can detect the update operation of the corresponding file processing program to the buffer area by monitoring the file processing program - the first file processing program / the second file processing program, because: no matter what kind of file processing program performs the file When processing, the original read and write functions provided by the operating system/database system are finally called. Therefore, when the plug-in application business logic can monitor these original read/write functions, it is possible to know in real time whether the file processing program is The file has been updated. Considering the simplicity of the technology implementation and the private protection of the system source code by the existing system provider, it is not suitable to provide its own read/write function in the plug-in application business logic, but the file processing program is notified by the plug-in application business logic.
  • the file processing program implements the update operation on the file; or the plug-in application business logic can also implement the operation on the data in the buffer area by calling the read/write function included in the file processing program.
  • the operation content is an application program interface
  • the entire process of updating the first file by the first file processing program is monitored by the first plug-in application business logic, and the plug-in application business logic is In the first system, not only can the structural parameters of the first file be recorded, and Recording the operation content performed by the first file processing program on the first file, that is, recording the application program interface, the working parameters of the application program interface, and the current assignment of the working parameter, so the second system is receiving After the above-mentioned operation content as an application interface, the second file can be updated.
  • the operation content may include first data before the change occurs, an application program interface that is invoked when the first file processing program updates the first file, an operation parameter of the application program interface, and a current assignment of the work parameter;
  • the operation content is the first data after the update operation is performed.
  • the process of directly obtaining the first data in the buffer area may be implemented by using a read function that accesses the buffer area. At this time, a lock is added in front of and behind the read function, so that the operation of the read function forms a non- Split atomic operations, lock specifics can be exclusive locks.
  • the first data corresponding to the first file is still in the buffer area and has not been saved to the non-volatile storage medium, so for other systems other than the first system,
  • the content in the buffer is updated in real time for the second file.
  • the file on the non-volatile storage medium specifically refers to a hard disk, a USB flash drive, a Nand Flash, and the like.
  • the first predetermined time interval can be specifically customized.
  • the synchronization process is usually stored in the non-volatile storage medium after the update operation on the first file is completed on the first system, and then taken out from the non-volatile storage medium by the second system;
  • the first predetermined time interval in the time period is within a time period in which the first file is in the buffer area.
  • the following describes the strategy used in the file synchronization process, and updates the second file of the second system according to the operation content.
  • This update process is also called synchronization.
  • a synchronization policy needs to be determined, which determines which system is to perform file synchronization based on the update of another system.
  • the system includes: a first system ⁇ 104 and a second system ⁇ 104.
  • the first system A104 includes: a first file ⁇ 101, a first file processing program ⁇ 102, a first plug-in application service logic A103, a buffer unit ⁇ 105, and a third file A106.
  • the second system B104 includes: a second file ⁇ 101
  • the first file A101 and the second file B 101 are backups of the same file in different systems; the third file A106 is the first file ⁇ 101 after the update is completed, and the fourth file B106 is the second file after the update is completed. ⁇ 101.
  • the first file processing program A102 opens the first file A101 and The update is performed by the user, and the buffer unit A105 is a buffer area managed by the first system A104.
  • the update of the first file A101 to the first file A101 is reflected in the buffer unit A105 in real time, and the first plug-in application is applied.
  • the business logic A103 records the structural parameters of the first file A101 in the first system, and records the operation content performed by the first file processing program A102 on the first file A101.
  • a common office program-first file processing program A102 specifically a Word program
  • the operation of the first file A 101 by Word is reflected in the buffer unit in real time.
  • the data of the first system A104 stored in the buffer unit A105 is stored on the non-volatile storage medium, and the user performs a storage operation on Word - for example, Ctrl+S
  • the first system A104 also stores the data stored in the buffer unit A105 in the corresponding third file A106 in the non-volatile storage medium.
  • the first plug-in application service logic A103 records the structural parameters of the first file A101, and records the first file processing program A102.
  • the operation content corresponding to the update operation performed by the first file A101, that is, the application program interface, the working parameters of the application program interface, and the current assignment of the work parameter are recorded; in the second system, the second file processing program B102 is opened.
  • the second file B 101, the second plug-in application service logic B103 receives the operation content from the first plug-in application service logic A103 through the data information channel C101.
  • the second plug-in application business logic B103 notifies the second file processing program B 102, and the second file processing program B 102 performs an update operation on the second file B 101 from the operation content of the first plug-in application service logic A103. After the update operation is completed, the second data located in the buffer unit B105 changes.
  • the first plug-in application service logic A103 detects the content of the operation of the first file A101, and then sends the data to the second plug-in application service logic B103 through the data information channel C101 in real time. And the second plug-in application business logic B103 notifies the second file processing program B 102 of the update operation of the second file B 101 in real time, thereby ensuring that the processes of the file and the application program interface are substantially the same.
  • the operation content includes: a structural parameter of the first file
  • the first file processing program A102 If the synchronization is achieved by the full copy of the first buffer area, the operation content includes: the first data after the update operation is performed.
  • the first plug-in application service logic A103 monitors the first file processing program A102 in real time.
  • a data information channel C101 is established with the second system B104.
  • the first file A101 and the second file B101 are backups of the same file in different systems, and the data located in the buffer unit B 105 corresponds to the second file B 101, when passing through the buffer unit A105
  • the file processing program B102 since the file processing program B102 updates the second file B 101 by the data in the real-time root buffer unit B105, the second file B101 presented to the user is also Real-time change, obviously, the above process is implemented by the sync buffer unit A105 and the buffer unit B105.
  • the buffer area specifically refers to a buffer area located on a volatile storage medium in different systems; in data transmission, a storage device used to compensate for the processing speed difference between different components in the system is called a buffer area.
  • the technique of storing data in the buffer is called buffering.
  • the first buffer area specifically refers to a space opened and managed by the first system in the memory, occupied and locked by the current first file, and the first data corresponding to the first file is stored, because the logical address is known. And always being continuous, so the first data corresponding to the first file in the first buffer area can be directly obtained by the plug-in application business logic according to the logical address.
  • the first buffer area actually stores all current modified update contents of the first file; before the modified update content stored in the buffer area is saved in the second file in the second system, the modification The updated content is the content difference between the first file and the second file. If the timeline identifier is used, the modified update content is the latest difference between the first file and the second file.
  • the second file is a file corresponding to the first file in the second system.
  • the data information channel can specifically use existing data channels, such as serial port (SATA), I2C, USB, BlueTooth, and the like.
  • the present invention further provides a file synchronization system, as shown in FIG. 2, including a first system A104 and a second system B104; wherein, the first file processing program is the first file processing program in the figure. A102, the second file processing program is the file processing program B 102 in the figure, the first buffer area is the buffer area unit A105 in the figure, and the second buffer area is the buffer area unit B 105 in the figure;
  • the first system A104 includes a first hardware system and a first operating system based on the first hardware system;
  • the second system B 104 includes a second hardware system and a second operating system based on the second hardware system;
  • the first system A104 monitors the first buffer area-buffer area unit A105, and the first file processing program stores the first data corresponding to the first file A101 opened by the first file processing program A102. ;
  • the first system A104 is configured to pass the information channel between the first system A104 and the second system B 104 when the first data in the first buffer area is changed. Transmitting the operation content performed by the first file processing program to the first file A101 to the second system B 104, and notifying the second file processing program in the second system B104, the second file processing program
  • the second file B 101 is processed in accordance with the contents of the action.
  • the file synchronization system also includes:
  • a first plug-in application business logic A103 configured to record, in the first system A104, a structural parameter of the first file, and record an operation content performed by the first file processing program on the first file; Establishing and maintaining a data information channel with the plug-in application business logic B103 located in the second system; transmitting the operation content performed on the first file and/or the structural parameter of the first file to the second system
  • the second plugin applies business logic B 103.
  • a second plug-in application business logic B 103 configured to record, in the second system B104, a structural parameter of the second file, and record an operation content performed by the second file processing program on the second file; Establishing and maintaining a data information channel with the plug-in application business logic A103 located in the first system; transmitting the operation content performed on the second file and/or the structural parameters of the second file to the first system
  • the first plugin applies business logic A103.
  • the operation content that causes the first file to be updated can be sent to the second system in real time, and the second file processing program performs the update on the second file according to the operation content, because the operation content Is to operate on the buffer area in the memory, and the operation content can be detected and sent to the second system at the moment of the operation, by the second file processing program root
  • the same operation is performed on the second file in real time, so the above process is real-time, and real-time synchronous update of the same file can be realized in different systems without manual/automatic saving; and in the first system
  • the operation content in the second system is consistent, and the first file and the second file are also consistent, so that the updated first file and the second file are also guaranteed to be consistent.
  • the content of the application is an application interface that is invoked when the first file processing program updates the first file, an operating parameter of the application program interface, and a current assignment of the working parameter; or
  • the operation content includes: a first data before the change occurs, an application program interface that is invoked when the first file processing program updates the first file, an operation parameter of the application program interface, and a current assignment of the work parameter; Or the operation content includes: a structure parameter of the first file, an application program interface invoked when the first file processing program updates the first file, an operating parameter of the application program interface, and the working The current assignment of the parameter.
  • the first system and the second system may be located in the same housing.
  • the first system may also be located separately in the first housing, and the second system may also be separately located in the second housing.
  • the first system located in the first housing can be used alone, and the second system located in the second housing can also be used alone.
  • the first system located in the first housing and the second system located in the second housing may be combined by a structural member to form a hybrid system, the structural member including the first system and the second system being combined A physical structural component and a hardware interface that implements mutual data transmission between the first system and the second system.
  • the present invention further provides an electronic device having the function of implementing file synchronization in different systems, including a first system A104 and a second system B.104;
  • the first system A104 includes a first hardware system and a first operating system based on the first hardware system;
  • the second system B 104 includes a second hardware system and a second operating system based on the second hardware system;
  • the first system A104 monitors the first buffer area, and the first buffer area stores the first data corresponding to the first file A101 opened by the first file processing program A102, and the first file A101 is stored in the first file.
  • the non-volatile memory of system A104 In the non-volatile memory of system A104;
  • the first system A104 is further configured to: when the first data in the first buffer area is changed Transmitting, by the data information channel between the first system A104 and the second system B104, the operation content performed by the first file processing program A102 on the first file A101 to the second System B 104, by the second file processing program B102 in the second system B104, the second file processing program B 102 processes the second file B101 according to the operation content, and the second file B 101 is stored in the A file corresponding to the first file in the non-volatile memory of the second system B 104.
  • the electronic device also includes:
  • a first plug-in application business logic A103 configured to record, in the first system A104, a structural parameter of the first file, and record an operation content performed by the first file processing program A102 on the first file; Establishing and maintaining a data information channel with the plug-in application business logic B103 located in the second system; transmitting the operation content performed on the first file and/or the structural parameters of the first file to the second system
  • the second plugin applies business logic B 103.
  • the present invention further provides an electronic device having a function of implementing file synchronization in different systems, as shown in FIG. 3, including a first system A104; the first system A104 includes a first hardware system and a The first operating system of the first hardware system; wherein, the first buffer area is the buffer area unit A105 in the figure;
  • the first system A104 monitors the first buffer area, and the first buffer area stores the first number corresponding to the first file A101 opened by the first file processing program A102.
  • the first file processing program A102 is configured by the data information channel between the first system A104 and the second system B104.
  • the operation content performed by a file A101 is sent to the second system B104, and the second file processing program B102 of the second system B104, the second file processing program B102 pairs the second file B 101 according to the operation content.
  • Process The second system B 104 is located on another electronic device (not shown), and the second system B 104 includes a second hardware system and a second operating system based on the second hardware system.
  • the structure of another electronic device is the same as that of the electronic device shown in FIG. 3 and will not be described in detail herein.
  • the electronic device also includes:
  • a first plug-in application business logic A103 configured to record, in the first system A104, a structural parameter of the first file, and record an operation content performed by the first file processing program A102 on the first file; Establishing and maintaining a data information channel with the plug-in application business logic B 103 located in the second system; transmitting the operation content performed on the first file and/or the structural parameters of the first file to the second system The second plug-in application business logic B 103.
  • the first system A104/the second system B104 may further include:
  • An update data obtaining unit configured to acquire a start position and an end position of a logical address of the first file A101, and call a function to access and copy a number between the start position and the end position in the buffer area, And transmitted to the data information channel.
  • the embodiment of the present invention has the following beneficial effects: when the first file is updated, the operation content that causes the first file to be updated can be sent to the second system in real time, and the second file processing program executes the second file according to the operation content. Update, since the operation content is to operate the buffer area in the memory, and the operation content can be detected and sent to the second system at the moment of the operation, the second file processing program roots the operation content in real time.
  • the same operation is performed on the second file, so the above process is real-time, and real-time synchronization of the same file can be realized in different systems without manual/automatic saving; and since in the first system and the second The operation contents in the system are consistent, and the first file and the second file are also consistent, so that the updated first file and the second file are also guaranteed to be consistent.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

本发明提供一种文件同步方法、电子设备和同步系统,方法包括:在具有第一系统和第二系统的混合系统中,在第一系统中监控第一缓存区,第一缓存区中存有第一系统中的第一文件处理程序打开的第一文件所对应的第一数据;当第一缓存区中的第一数据发生改变时,通过第一系统与第二系统之间的数据信息通道,将第一文件处理程序对第一文件执行的操作内容发送到第二系统中;其中,由第二系统中的第二文件处理程序根据操作内容对第二文件进行同步处理;第二文件是第二系统中与第一文件对应的文件。应用上述技术方案,由于设置有插件应用业务逻辑,且该插件应用业务逻辑能够实时访问缓存区,因此能够在不同的系统中对相同文件实现实时同步更新。

Description

一种文件同步方法、 电子设备和同步系统 技术领域
本发明涉及计算机存储技术, 特别是指一种文件同步方法、 电子设 _备和同 步系统。 背景技术
随着混合计算机 (Hybrid)技术的发展,在同时使用两个或两个以上系统时, 为正在使用中的文件提供实时的同步功能 (Updating)会给用户带来非常好的体 验; 例如, 在作为第一系统的主系统正在处理文件时, 因为某种原因需要立即 切换到第二系统, 这时用户仍希望继续当前的文件处理工作, 就需要对主系统 当前打开的所有文件进行手动保存, 或者依赖定时自动保存功能进行保存。
发明人发现现有技术中至少存在如下问题: 在同步过程中, 用户即使使用 了文件自动保存和自动同步等现有技术, 还是无法保存当前即时更新的内容, 无法将更新的内容完美的同步更新到第二系统上。 具体而言, 现有的文件同步 技术虽然支持基于保存的文件实现同步功能, 但如果自动保存间隔时间太^ , 则可能影响系统性能; 因此无法记录每时每刻的任意修改, 从而没有真正实现 实时同步; 并且由于现有技术中, 同步功能是基于保存在非易失性存储介质上 文件实现的, 因而同步功能的实现必然依赖自动保存功能, 如果没有即时保存 文件则会实际影响实时同步的结果; 且自动同步过程一般需要一定时间完成, 无法实现真正意义上的实时同步。 发明内容
本发明的目的是提供一种文件同步方法、 电子设备和同步系统, 用于解决 现有技术中, 在两个或者多个系统共享同一个或多个文件时, 当其中的一个系 统上的文件被修改之后,无法在其他系统上实时保存并显示当前更新的内容的 缺陷。
本发明提出了一种文件同步方法,所述文件同步方法应用于具有第一系统 和第二系统的混合系统中, 所述方法包括: 所述第一系统监控所述第一系统的 第一緩存区,所述第一緩存区中存有所述第一系统中的第一文件处理程序打开 的存储在所述第一系统的非易失性存储器中的第一文件所对应的第一数.据; 当 所述第一缓存区中的所述第一数据发生改变时,通过所述第一系统与所述第二 系统之间的数据信息通道,将所述第一文件处理程序对所述第一文件执行的操 作内容发送到所述第二系统中;以及所述第二系统中的第二文件处理程序根据 所述操作内容对第二文件进行同步处理;所述第二文件是所述第二系统中与所 述第一文件相对应的文件,所述第二文件存储在所述第二系统的非易失性存储 器中。
上述的方法中,所述操作内容为所述第一文件处理程序对所述第一文件进 行更新时调用的应用程序接口、 所述应用程序接口的工作参数、 以及所述工作 参数的当前赋值。
上述的方法中, 所述操作内容包括: 发生改变前的第一数 ¾、 所述第一文 件处理程序对所述第一文件进行更新时调用的应用程序接口、所述应用程序接 口的工作参数、 以及所述工作参数的当前赋值; 或者, 所述操作内容包括: 第 一文件的结构参数、所述第一文件处理程序对所述第一文件进行更.新时调用的 应用程序接口、所述应用程序接口的工作参数、以及所述工作参数的当前赋值。
上述的方法中, 当所述第一緩存区中的所述第一数†居发生改变时, 在第一 预定时间间隔内发送所述操作内容; 其中, 所述第一预定时间间隔远小于所述 第一系统和 /或第二系统的自动保存时间间隔。
在上述的方法中, 所述第一缓存区是所述第一系统的易失性存储器。
本发明还提出了一种文件同步系统, 包括第一系统和第二系统; 其中, 所 述第一系统: 监控所述第一系统的第一缓存区, 所述第一緩存区中存有所述第 一系统中的第一文件处理程序打开的存储在所述第一系统的非易失性存储器 中的第一文件所对应的第一数据; 当监控到所述第一緩存区中的所述第一数,据 发生改变时, 通过所述第一系统与所述第二系统之间的数.据信息通道, 将所述 第一文件处理程序对所述第一文件执行的操作内容发送到所述第二系统;所述 第二系统中的第二文件处理程序根^ ^所述操作内容对第二文件进行同步处理, 所述第二文件是所述第二系统中与所述第一文件相对应的文件,所述第二文件 存储在所述第二系统的非易失性存储器中。 在所述的文件同步系统中,所述操作内容为所述第一文件处理程序对所述 第一文件进行更新时调用的应用程序接口、 所述应用程序接口的工作参数、 以 及所述工作参数的当前赋值; 或者, 所述操作内容包括: 发生改变前的第一数 据、 第一文件处理程序对所述第一文件进行更新时调用的应用程序接口、 所述 应用程序接口的工作参数、 以及所述工作参数的当前赋值; 或者, 所述操作内 容包括: 第一文件的结构参数、 所述第一文件处理程序对所述第一文件进行更 新时调用的应用程序接口、 所述应用程序接口的工作参数、 以及所述工作参数 的当前 ϋ武值。
在所述的文件同步系统中,所述第一緩存区是所述第一系统的易失性存储 器。
本发明还提出了一种电子设备, 包括: 包括第一系统和第二系统; 其中, 所述第一系统: 监控所述第一系统的第一緩存区, 所述第一缓存区中存有所述 第一系统中的第一文件处理程序打开的存储在所述第一系统的非易失性存储 器中的第一文件所对应的第一数据; 当所述第一緩存区中的所述第一数据发生 改变时, 通过所述第一系统与所述第二系统之间的数据信息通道, 将所述第一 文件处理程序对所述第一文件执行的操作内容发送给所述第二系统;所述第二 系统的第二文件处理程序根据所述操作内容对第二文件进行同步处理,所述第 二文件是所述第二系统中与所述第一文件相对应的文件,所述第二文件存储在 所述第二系统的非易失性存储器中。
所述的电子设备还包括: 第一系统中的第一插件应用业务逻辑, 用于记录 所述第一文件的结构参数,并记录下所述第一文件处理程序对所述第一文件执 行的操作内容; 以及, 与位于第二系统中的第二插件应用业务逻辑建立并维护 一个数据信息通道; 将对所述第一文件执行的操作内容和 /或所述第一文件的 结构参数发送给位于第二系统中的第二插件应用业务逻辑;第二系统中的第二 插件应用业务逻辑, 用于记录所述第二文件的结构参数, 并记录下所述第二文 件处理程序对所述第二文件执行的操作内容; 以及, 与位于第一系统中的第一 插件应用业务逻辑建立并维护一个数据信息通道;将对所述第二文件执行的操 作内容和 /或所述第二文件的结构参数发送给位于第一系统中的第一插件应用 业务逻辑。 在所述的电子设备中, 所述第一缓存区是所述第一系统的易失性存储器。 本发明还提出了一种电子设备, 包括第一系统; 其中, 所述第一系统监控 所述第一系统的第一缓存区,所述第一缓存区中存有所述第一系统中的第一文 件处理程序打开的存储在所述第一系统的非易失性存储器中的第一文件所对 应的第一数,据; 当所述第一缓存区中的所述第一数据发生改变时, 通过所述第 一系统与第二系统之间的数 ^ ^居信息通道,将所述第一文件处理程序对所述第一 文件执行的操作内容发送到所述第二系统, 其中, 由所述第二系统中的第二文 件处理程序根据所述操作内容对第二文件进行同步处理;所述第二文件是所述 第二系统中与所述第一文件相对应的文件,所述第二文件存储在所述第二系统 的非易失性存储器中, 所述第二系统位于另一电子设备上。
所述的电子设备还包括: 插件应用业务逻辑, 用于记录所述第一文件的结 构参数, 并记录下所述第一文件处理程序对所迷第一文件执行的操作内容。
在所述的电子设备中, 所述第一緩存区是所述第一系统的易失性存储器。 应用上述技术方案, 由于设置有插件应用业务逻辑, 且该插件应用业务逻 辑能够实时访问緩存区, 因此, 无需手动 /自动保存第一文件, 能够在不同的 系统中对该第一文件实现实时同步更新。 附图说明
图 1 为本发明实施例一种文件同步方法流程示意图;
图 2为本发明实施例在第一系统与第二系统间同步工作原理示意图; 图 3为本 明实施例电子设备结构示意图。 具体实施方式
为使本发明的目的、技术特征和实施效果更加清楚, 下面将结合附图及具 体实施例对本发明的技术方案进行详细描述。
本发明提供的实施例中, 在既有的文件同步技术基础上, 实现了基于内存 方式的文件实时同步技术。 换言之, 是在一个系统中, 将非易失存储器(例如 硬盘上) 存储的一个文件, 在操作系统下用文件处理程序打开-即将该文件在 硬盘上对应的数据写入到该系统中的易失性存储器上。那么易失性存储器上就 具有与该文件对应的数据。本发明提供的实施例是通过实时监控该易失性存储 器上用户对与第一文件对应的第一数据所做的操作内容,并将该操作内容发送 给第二系统,由第二系统根据所述操作内容对与第一文件对应的第二文件进行 同步处理。 如图 1所示, 提供一种文件同步方法, 所述文件同步方法应用于具 有第一系统和第二系统的混合系统中,所述第一系统包括第一硬件系统和基于 所述第一硬件系统的第一操作系统,所述第二系统包括第二硬件系统和基于所 述第二硬件系统的第二操作系统; 所述方法包括:
步驟 101, 在所述第一系统中监控所述第一系统的第一緩存区, 所述第一 缓存区中存有所述第一系统中的第一文件处理程序打开的存储在所述第一系 统的非易失性存储器中的第一文件所对应的第一数据;
步骤 102, 当所述第一緩存区中的所述第一数据发生改变时, 通过所述第 一系统与所述第二系统之间的数据信息通道,将所述第一文件处理程序对所述 第一文件执行的操作内容发送到所述第二系统中;
步骤 103 , 所述第二系统中的第二文件处理程序根据所述操作内容对第二 文件进行同步处理; 其中, 所述第二文件是所述第二系统中与所述第一文件对 应的文件, 并且所述第二文件存储在所述第二系统的非易失性存储器 (例如, 硬盘) 中。
其中, 所述第一硬件系统包括所述第一緩存区, 所述第一文件处理程序基 于所述第一操作系统运行, 所述第二硬件系统包括所述第二缓存区, 所述第二 文件处理程序基于所述第二操作系统运行。
更进一步, 为了提高同步的及时性和实时性, 在第二系统中的第二緩存区 中存有第二文件处理程序打开的第二文件所对应的第二数据。这样保.证第一系 统状态和第二系统状态一致。换言之, 第一系统处于通过第一文件处理程序打 开第一文件的状态; 第二系统处于通过第二文件处理程序打开第二文件的状 态。
应用上述技术方案, 在第一文件发生更新时, 能够实时的将导致第一文件 发生更新的操作内容发送给第二系统,第二文件处理程序根据操作内容对第二 文件执行更新, 由于操作内容是对内存中的缓存区进行^ ί乘作, 且这一操作发生 的瞬间就能够检测到所述操作内容并发送给第二系统,由第二文件处理程序根 据该操作内容实时的对第二文件进行同样的操作, 因此上述过程是实时的, 且 能够在不同的系统中无需手动 /自动保存就对同一文件实现实时同步更新; 又 由于在第一系统中和第二系统中的所述操作内容是一致的,而第一文件和第二 文件也是一致的, 因此能够保证更新后的第一文件和第二文件也是一致的。
在实现上述技术方案的过程中, 为保证第一系统中, 能够实时的检测到所 述操作内容并发送给第二系统, 并且在第二系统中, 能够实时的根据来自第一 系统的操作内容对第二文件进行更.新,因此需要在第一系统和第二系统中分别 设置插件应用业务逻辑。 其中, 第一系统中设置有第一插件应用业务逻辑, 第 二系统中设置有第二插件应用业务逻辑。
第一系统中的第一插件应用业务逻辑用于:
记录所述第一文件的结构参数 ,并记录下所述第一文件处理程序对所述第 一文件执行的操.作内容;
与位于第二系统中的第二插件应用业务逻辑建立并维护一个数据信息通 道; 以及
将对所述第一文件执行的操作内容和 /或所述第一文件的结构参数发送给 位于第二系统中的第二插件应用业务逻辑。
第二系统中的第二插件应用业务逻辑用于:
记录所述第二文件的结构参数.,并记录下所述第二文件处理程序对所述第 二文件执行的操作内容;
与位于第一系统中的第一插件应用业务逻辑建立并维护一个数据信息通 道; 以及
将对所述第二文件执行的操作内容和 /或所述第二文件的结构参数发送给 位于第一系统中的第一插件应用业务逻辑。
具体而言, 在第一系统中, 用户通过第一文件处理程序打开第一文件, 第 一緩冲区存储第一文件处理程序打开第一文件所对应的第一数据, 即, 第一文 件在硬盘上的数.据被写入到了内存中。 此时, 激活第一系统的插件应用业务逻 辑, 第一系统的插件应用业务逻辑执行如下步骤:
(1) , 记录第一文件的结构参^:;
(2) , 与第二系统中的第二插件应用业务逻辑建立一个数据信息通道, 并 在关闭该数据信息通道之前,与第二插件应用业务逻辑共同维护该数据信息通 道。
(3) , 监控是否存在对第一緩冲区内的第一数据的更新操作;
(4) , 如果存在对第一数据的更新操作, 该更新操作是由第一文件处理程 序发起的, 则记录第一文件处理程序对第一文件执行的操作内容, 此操作内容 表明用户在第一系统下对打开的第一文件进行修改;
(5) , 发送所述操作内容给第二系统中的第二插件应用业务逻辑。 此时, 第二插件应用业务逻辑得知需要根据接收到的来自第一系统的操作内容对第 二文件进行更新操作。
第二系统的插件应用业务逻辑执行如下步骤:
(1) , 记录第二文件的结构参数;
(2) , 与第一系统中的第一插件应用业务逻辑建立一个数据信息通道, 并 在关闭该数据信息通道之前,与第一插件应用业务逻辑共同维护该数据信息通 道。
(3) , 监控是否存在对第二緩冲区内的第二数^ ^居的更新操作;
(4) , 如果存在对第二数据的更新操作, 该更新操作是由笫二文件处理程 序发起的, 则记录第二文件处理程序对第二文件执行的操作内容, 此操作内容 表明用户在第二系统下对打开的第二文件进行修改;
(5), 发送所述操作内容给第一系统中的第一插件应用业务逻辑。 此时, 第一插件应用业务逻辑得知需要根据接收到的来自第二系统的操作内容对第 一文件进行更新操作。
显然, 第一插件应用业务逻辑和第二插件应用业务逻辑具有相同的功能, 因此在同步过程中,可以预先指定由第二插件应用业务逻辑根.据来自第一插件 应用业务逻辑的操作内容对第二文件进行更新。
此时, 在第二系统中, 第二系统的插件应用业务逻辑, 执行如下步骤:
(1) , 记录第二文件的结构参数;
(2) , 与第一系统中的第一插件应用业务逻辑建立一个数据信息通道, 并 在关闭该数,据信息通道之前,与第一插件应用业务逻辑共同维护该数据信息通 道。 (3) , 监控是否存在来自第一插件应用业务逻辑的操作内容;
(4), 如果存在, 则通知第二文件处理程序, 由第二文件处理程序对第二 文件执行来自第一插件应用业务逻辑的操作内容;
(5) , 可以在对第二文件执行来自第一插件应用业务逻辑的操作内容之后 , 通知第一插件应用业务逻辑所作修改的结果。 如杲更新操作出错, 则可以生成 相应的错误信息。
第一系统与第二系统之间的文件同步,根据实际需要可以出现不同的同步 情形, 这包括:
第一情形, 第二系统中的第二文件处理程序处于工作状态, 并且已经激活 了第二文件。 此时, 如果操作内容包括: 第一文件处理程序对所述第一文件进 行更新时调用的应用程序接口、该应用程序接口的工作参数、 以及该工作参数. 的当前陚值,则第二文件处理程序能够保证实时的根据这些搡作内容对第二文 件执行更新操作, 更新操作后的第二文件与更新后的第一文件一致, 即第二緩 存区中的第二数据与第一緩存区中的第一数据一致。
所述操作内容包括: 发生更新操作前的第一数^据、 第一文件处理程序对所 述第一文件进行更新时调用的应用程序接口、 该应用程序接口的工作参数、 以 及所述工作参 的当前赋值; 例如,如果所述应用程序接口是写函数 sys— write (int fd, void *buffer, int length), 则该应用程序接口的工作参数是参数: int fd, void *buffer, int length. 其中, int fd是文件索引编号, void ^buffer是緩存区的 指针, int length是緩存区的长度。
或者, 所述操作内容包括: 第一文件的结构参数, 以及第一文件处理程序 对所述第一文件进行更新时调用的应用程序接口, 该应用程序接口的工作参 数, 以及所述工作参数的当前赋值。
或者, 如果.直接通过对第一緩存区的全拷贝实现同步, 则所述操作内容包 括: 被执行更新 ·ί喿.作后的第一数.据, 第二文件处理程序同样能够保证实时的根 据这些操作内容对第二文件执行更新。
第二情形, 第二系统中的第二文件处理程序处于工作状态, 但没有激活第 二文件。
此时,第二文件处理程序根据文件识别索引寻找到第二系统上与第一文件 对应的第二文件, 并且激活该第二文件。 之后, 第二文件处理程序执行与第一 情形中一致的更新操作。
第三情形, 第二系统中的第二文件处理程序处于非工作状态, 并且在接到 来自第一系统的操作内容后会及时激活第二文件。
在第二插件应用业务逻辑 B 103接到来自第一系统的操作内容后, 启动第 二文件处理程序,由第二文件处理程序文件识别索引首先寻找到对应的第二文 件, 并且激活该第二文件。 之后, 第二文件处理程序执行与第一情形中一致的 更新操作。
第四情形, 第二系统中的第二文件处理程序处于非工作状态, 在接到来自 第一系统的操作内容后, 需要经过一个时间间隔才激活第二文件。
在第二插件应用业务逻辑 B 103接到来自第一系统的操作内容后, 不即刻 启动第二文件处理程序, 但是该第二插件应用业务逻辑 B 103由于其他原因需 要在经过一个时间间隔后启动第二文件处理程序,由第二文件处理程序根据文 件识别索引首先寻找到对应的第二文件, 并且激活该第二文件。 之后, 第二文 件处理程序执行与第一情形中一致的更新操作。
第五情形, 当第二系统中不存在第二文件时, 由第二插件应用业务逻辑 B 103 根据操.作内容中的更新操作前的第一数据在第二系统中建立一个第二文 件, 并在建立第二文件后对该第二文件执行更新操作。 此时, 所述操作内容包 括: 发生更新操作前的第一数据, 以及第一文件处理程序对所述第一文件进行 更新时调用的应用程序接口, 该应用程序接口的工作参数, 以及该工作参数的 当前赋值。 所述操.作内容也可以是被执行更新操作后的第一数.据。
为充分描述多系统间的文件同步过程, 在上述技术方案的基础上, 不仅可 以在第一系统与第二系统之间实现对文件的实时更新, 对于更多的系统, 也可 以基于同样的工作原理进行更新, 不失.一般.性, 以三个系统为例, 在提供的应 用场景中, 第一系统是计算机、 第二系统是数居库, 第三系统是移动终端; 贝 'J , 用户在第一系统-计算机上对第一文件进行了修改, 因此, 作为第二系统的数 据库中也需要对该第一文件对应的第二文件进行实时更新,继而第三系统通过 其与第二系统之间的数据信息通道对自身存放的与第一文件和第二文件对应 的第三文件进行更新, 包括: 步骤 201 ,在第一系统、第二系统和第三系统中设置有插件应用业务逻辑, 所述插件应用业务逻辑在第一系统中实时记录第一文件的结构参数,并记录下 所述第一文件处理程序对所述第一文件执行的操作内容; 其中, 所针对的文件 在第一系统称为第一文件, 在第二系统称为第二文件, 在第三系统称为第三文 件;
步驟 202 , 位于各个系统中的插件应用业务逻辑分别建立第一系统与第二 系统之间的数据信息通道; 以及, 建立第二系统与第三系统之间的数据信息通 道; 以及, 建立第一系统与第三系统之间的数据信息通道。
步骤 203 , 当所述第一系统中的第一文件被修改时, 在更新操作发生之后 的第一预定时间间隔内,将第一系统中的操作内容通过所述数据信息通道发往 第二系统; 以及, 第一系统将操作内容通过所述数.据信息通道发往第三系统。 其中, 第一预定时间间隔通常是一个细粒度的时间间隔, 例如毫秒甚至微秒级 别的间隔, 一般而言, 该第一预定时间间隔小于自动保存的时间间隔, 如此则 能够保证各个系统之间的文件同步能够满足实时性。
以下对于所提供的技术方案中所涉及的具体技术特征进行详细描述,以帮 助技术人员实现。
插件应用业务逻辑, 能够通过监控文件处理程序 -第一文件处理程序 /第二 文件处理程序来发现对应的文件处理程序对緩存区的更新操作, 这是因为: 无 论何种文件处理程序对文件进行处理时, 最终都需要调用操作系统 /数据库系 统等所提供的原有的读写函数,因此当插件应用业务逻辑能够监控这些原有的 读写函数时, 就可以实时的得知文件处理程序是否对文件进行了更新操作。 其 中, 考虑到技术实现的简便以及现有的系统提供商对于系统源代码的私有保 护, 在插件应用业务逻辑中不适宜提供自有的读写函数, 而是由插件应用业务 逻辑通知文件处理程序, 由文件处理程序实现对文件的更新操作; 或者插件应 用业务逻辑通过调用文件处理程序中包含的读写函数也可以实现对緩存区中 数据的操作。
当操作内容为应用程序接口时, 由于在第一系统中, 第一文件处理程序对 所述第一文件进行更新的整个过程是可以被第一插件应用业务逻辑监控的,而 插件应用业务逻辑在第一系统中, 不仅能够记录所述第一文件的结构参数, 并 记录下所述第一文件处理程序对所述第一文件执行的操作内容,即记录下这些 应用程序接口、 该应用程序接口的工作参数、 以及该工作参数的当前赋值, 因 此第二系统在接收到上述作为应用程序接口的操作内容之后,能够对第二文件 进行更新。
所述操作内容可以包括发生改变前的第一数据、第一文件处理程序对所述 第一文件进行更新时调用的应用程序接口、该应用程序接口的工作参数、 以及 该工作参数的当前賦值;或者,所述操作内容为被执行更新操作后的第一数据。 直接获取緩存区中的第一数据的过程具体可以是通过采用一个访问该缓存区 的读函数实现的, 此时, 在该读函数的前面和后面加锁, 使得该读函数的操作 形成一个不可分割的原子操作,锁具体可以是排他锁。在锁定的这一段时间内 , 第一文件对应的第一数据还在緩存区中, 还没保存到非易失性存储介质里, 因 此对于第一系统之外的其他系统而言,采.用緩存区中的内容对第二文件进行更 新则为实时更新。 其中, 非易失性存储介质上文件具体是指硬盘、 U盘、 Nand Flash等。
第一预定时间间隔具体可以定制。 现有技术中, 同步过程通常是在第一系 统上完成对第一文件的更新操作之后存入非易失性存储介质,再由第二系统从 非易失性存储介质中取出;而本发明中的第一预定时间间隔则是在第一文件处 于緩存区的时间段之内的。
以下对于文件同步过程中所采用的策略进行详细描述,根据操作内容对第 二系统的第二文件进行更新, 这一更新的过程又被称为同步。 在同步过程中, 需要确定同步策略,该同步策略决定了具体由哪一个系统根据另一个系统的更 新 ·ί喿.作执行文件同步。 以如图 2所示的两个系统为例, 包括: 第一系统 Α104、 第二系统 Β 104。 其中, 第一系统 A104中包括: 第一文件 Α101、 第一文件处 理程序 Α102、第一插件应用业务逻辑 A103、緩存区单元 Α105、第三文件 A106; 第二系统 B104中包括: 第二文件 Β101、 文件处理程序 Β 102、 第二插件应用 业务逻辑 Β 103、 缓存区单元 Β 105、 第四文件 Β 106。 其中, 第一文件 A101与 第二文件 B 101 是同一个文件在不同系统中的备份; 第三文件 A106是完成更 新之后的第一文件 Α101, 第四文件 B 106是完成更新之后的第二文件 Β 101。
在第一系统 A104 中, 第一文件处理程序 A102打开了第一文件 A101 并 由用户进行更新,緩存区单元 A105则是第一系统 A104所管理的一段緩存区, 第一文件处理程序 A102对于第一文件 A101 的更新会实时反映在緩存区单元 A105 中, 并且第一插件应用业务逻辑 A103在第一系统中会记录所述第一文 件 A101 的结构参数, 并记录下第一文件处理程序 A102对第一文件 A101执 行的操作内容。例如,以常用的办公程序 -第一文件处理程序 A102具体是 Word 程序为例, 在处理第一文件 A 101 时, 在通过 Word对第一文件 A 101 的操.作 会实时反映在緩存区单元 A105中, 但是只有当每过一个预定时间间隔, 緩存 区单元 A105中存放的第一系统 A104的数据会存入非易失性存储介质上, 这 用户在 Word上执行存放操作 -例如 Ctrl+S时,第一系统 A104也会将緩存区单 元 A105中存放的数据存入非易失性存储介质中对应的第三文件 A106上。
以下针对操作内容所包含的信息的类别分别进行描述:
当操作内容包含发生更新操作前的第一数据以及应用程序接口时,第一系 统 A104中, 第一插件应用业务逻辑 A103记录第一文件 A101 的结构参数, 并记录下第一文件处理程序 A102对第一文件 A101执行的更新操作对应的操 作内容, 即记录下这些应用程序接口、 该应用程序接口的工作参数、 以及该工 作参数的当前赋值; 第二系统中, 第二文件处理程序 B102 会打开第二文件 B 101 , 第二插件应用业务逻辑 B103通过数据信息通道 C101接收到来自第一 插件应用业务逻辑 A103的操作内容。 第二插件应用业务逻辑 B103通知第二 文件处理程序 B 102,由第二文件处理程序 B 102根^ ^居来自第一插件应用业务逻 辑 A103的操作内容对第二文件 B 101进行更新操作, 该更新操作完成之后, 位于緩存区单元 B105中的第二数据会发生改变。
如此, 则在第一文件 A101 内容更新时, 由于第一插件应用业务逻辑 A103 检测到对第一文件 A101 的操作内容之后, 实时的通过数据信息通道 C101发 送给了第二插件应用业务逻辑 B103 ,且第二插件应用业务逻辑 B103实时的通 知第二文件处理程序 B 102对第二文件 B 101进行更新操作, 因此保证了文件 以及应用程序接口时的过程基本一致。
当所述操作内容包括: 第一文件的结构参数、 第一文件处理程序 A102对 如果直接通过对第一缓存区的全拷贝实现同步, 则所述操作内容包括: 被 执行更新操作后的第一数据, 此时, 第一插件应用业务逻辑 A103实时监控第 一文件处理程序 A102对位于緩存区单元 A105 中的对应于第一文件 A101 的 第一数据的修改。 建立与第二系统 B104之间的数据信息通道 C101。 由于第一 文件 A101 与第二文件 B101是同一个文件在不同系统中的备份, 且位于緩存 区单元 B 105 中的数据是对应于第二文件 B 101 的, 因此当将通过来自緩存区 单元 A105的数据覆盖位于缓存区单元 B 105 中的第二数据时, 由于文件处理 程序 B102会实时根 緩存区单元 B105中的数据更新第二文件 B 101 , 因此呈 现在用户面前的第二文件 B101也会实时改变, 显然, 上述过程是通过同步緩 存区单元 A105与緩存区单元 B105实现的。
技术方案中,緩存区具体是指不同系统中的位于易失性存储介质上的緩存 区; 在数据传输中, 用来弥补系统中不同元器件对数据的处理速率速度差距的 存储装置叫做緩存区, 把数据存放到緩存区中的技术叫做緩冲。 其中, 第一緩 存区具体是指第一系统在内存中开辟并进行管理的一段空间,由当前的第一文 件占用并锁定, 存放第一文件对应的第一数据, 由于其逻辑地址是可知的, 并 且总是连续的,因此由插件应用业务逻辑根据该逻辑地址就可以直接获取所述 第一緩存区中的第一文件对应的第一数据。 具体而言, 该第一緩存区实际保存 有第一文件的当前所有修改更新内容;在没有将此緩存区中存放的修改更新内 容保存到第二系统中的第二文件中之前,所述修改更新内容即为第一文件和第 二文件的内容区别, 如果采用时间轴标识, 则所述修改更新内容为第一文件和 第二文件之间的最新区别。 其中, 第二文件是第二系统中对应于第一文件的文 件。
数据信息通道具体可以采用现有的数据通道,例如串口(SATA), I2C, USB, BlueTooth等。 对应的, 本发明还提供一种文件同步系统, 如图 2 所示, 包括第一系统 A104和第二系统 B104; 其中, 第一文件处理程序即图中的第一文件处理程序 A102 , 第二文件处理程序即图中的文件处理程序 B 102, 第一緩存区即图中的 缓存区单元 A105 , 第二缓存区即图中的缓存区单元 B 105;
所述第一系统 A104包括第一硬件系统和基于所述第一硬件系统的第一操 作系统;
所述第二系统 B 104包括第二硬件系统和基于所述第二硬件系统的第二操 作系统;
所述第一系统 A104监控第一緩存区 -緩存区单元 A105 , 所述第一緩存区 中存有第一文件处理程序 -第一文件处理程序 A102打开的第一文件 A101所对 应的第一数据;
所述第一系统 A104用于当监控到第一緩存区中的所述第一数据发生改变 时, 通过所述第一系统 A104与所述第二系统 B 104之间的数.据信息通道, 将 所述第一文件处理程序对所述第一文件 A101执行的操作内容发送到所述第二 系统 B 104, 通知所述第二系统 B104中的第二文件处理程序,该第二文件处理 程序根据所述喿作内容对第二文件 B 101进行处理。
文件同步系统中还包括:
第一插件应用业务逻辑 A103 , 用于在第一系统 A104 中, 记录所述第一 文件的结构参数,并记录下所述第一文件处理程序对所述第一文件执行的操作 内容; 以及, 与位于第二系统中的插件应用业务逻辑 B103建立并维护一个数 据信息通道; 将对所述第一文件执行的操作内容和 /或所述第一文件的结构参 :发送给位于第二系统中的第二插件应用业务逻辑 B 103。
第二插件应用业务逻辑 B 103, 用于在第二系统 B104中,记录所述第二文 件的结构参数,并记录下所述第二文件处理程序对所述第二文件执行的操作内 容; 以及, 与位于第一系统中的插件应用业务逻辑 A103建立并维护一个数据 信息通道; 将对所述第二文件执行的操作内容和 /或所述第二文件的结构参数 发送给位于第一系统中的第一插件应用业务逻辑 A103。
应用上述技术方案, 在第一文件发生更新时, 能够实时的将导致第一文件 发生更新的操作内容发送给第二系统,第二文件处理程序根据操作内容对第二 文件执行更新, 由于操作内容是对内存中的缓存区进行操作, 且这一操作发生 的瞬间就能够检测到所述操作内容并发送给第二系统,由第二文件处理程序根 据该操作内容实时的对第二文件进行同样的操作, 因此上述过程是实时的, 且 能够在不同的系统中无需手动 /自动保存就对同一文件实现实时同步更新; 又 由于在第一系统中和第二系统中的所述操作内容是一致的,而第一文件和第二 文件也是一致的, 因此能够保证更新后的第一文件和第二文件也是一致的。
其中, 喿作内容为所述第一文件处理程序对所述第一文件进行更新时调用 的应用程序接口、 所述应用程序接口的工作参数、 以及所述工作参数的当前赋 值; 或者, 所述操作内容包括: 发生改变前的第一数据、 第一文件处理程序对 所述第一文件进行更新时调用的应用程序接口、 所述应用程序接口的工作参 数、 以及所述工作参数的当前赋值; 或者, 所述操作内容包括: 第一文件的结 构参数、所述第一文件处理程序对所述第一文件进行更新时调用的应用程序接 口、 所述应用程序接口的工作参数、 以及所述工作参数的当前赋值。
所述第一系统和所述第二系统可以位于同一个壳体内, 当然, 所述第一系 统也可以单独的位于第一壳体内, 所述第二系统也可以单独的位于第二壳体 内, 位于第一壳体的第一系统可以单独使用, 位于第二壳体内的第二系统同样 也可以单独使用。 当然, 位于第一壳体内的第一系统和位于第二壳体内的第二 系统可以通过一结构件组合在一起组成混合系统,所述结构件包括将第一系统 和第二系统结合在一起的物理结构件以及实现第一系统和第二系统相互数据 传输的硬件接口。 对应的, 本发明还提供一种电子设备, 具有在不同的系统中实现文件同步 的功能, 包括第一系统 A104和第二系统 B .104;
所述第一系统 A104包括第一硬件系统和基于所述第一硬件系统的第一操 作系统;
所述第二系统 B 104包括第二硬件系统和基于所述第二硬件系统的第二操 作系统;
所述第一系统 A104监控第一緩存区, 所述第一缓存区中存有第一文件处 理程序 A102打开的第一文件 A101 所对应的第一数据, 第一文件 A101存储 在所述第一系统 A104的非易失性存储器中;
所述第一系统 A104, 还用于当所述第一缓存区中的所述第一数据发生改 变时, 通过所述第一系统 A104与所述第二系统 B104之间的数据信息通道, 将所述第一文件处理程序 A102对所述第一文件 A101执行的操作内容发送到 所述第二系统 B 104, 由所述第二系统 B104中的第二文件处理程序 B102, 该 第二文件处理程序 B 102根据所述操作内容对第二文件 B101进行处理, 第二 文件 B 101是存储在所述第二系统 B 104的非易失性存储器中的与第一文件相 对应的文件。
电子设备中还包括:
第一插件应用业务逻辑 A103 , 用于在第一系统 A104 中, 记录所述第一 文件的结构参数, 并记录下所述第一文件处理程序 A102对所述第一文件执行 的操作内容; 以及, 与位于第二系统中的插件应用业务逻辑 B103建立并维护 一个数据信息通道; 将对所述第一文件执行的操作内容和 /或所述第一文件的 结构参数发送给位于第二系统中的第二插件应用业务逻辑 B 103。
第二插件应用业务逻辑 B 103, 用于在第二系统 B104中,记录所述第二文 件的结构参^:, 并记录下所述第二文件处理程序 B102对所述第二文件执行的 操作内容; 以及, 与位于第一系统中的插件应用业务逻辑 A103 ,建立并维护一 个数据信息通道; 将对所述第二文件执行的操作内容和 /或所述第二文件的结 构参数发送给位于第一系统中的第一插件应用业务逻辑 A 103。 对应的, 本发明还提供一种电子设备, 具有在不同的系统中实现文件同步 的功能, 如图 3所示, 包括第一系统 A104; 所述第一系统 A104 包括第一硬 件系统和基于所述第一硬件系统的第一操作系统; 其中, 第一緩存区即图中的 緩存区单元 A105;
所述第一系统 A104监控第一缓存区, 所述第一缓存区中存有第一文件处 理程序 A102打开的第一文件 A101所对应的第一数,据;
当所述第一缓存区中的所述第一数据发生改变时, 通过所述第一系统 A104与第二系统 B104之间的数据信息通道, 将所述第一文件处理程序 A102 对所述第一文件 A101 执行的操作内容发送到所述第二系统 B104, 由所述第 二系统 B104中的第二文件处理程序 B102, 该第二文件处理程序 B102根据所 述操作内容对第二文件 B 101进行处理; 其中, 所述第二系统 B104位于另一电子设备(未示出)上, 且所述第二 系统 B 104包括第二硬件系统和基于所述第二硬件系统的第二操作系统。 另一 电子设备的结构与图 3所示的电子设备相同, 在此不进行详细描述。
电子设备中还包括:
第一插件应用业务逻辑 A103 , 用于在第一系统 A104 中, 记录所述第一 文件的结构参数, 并记录下所述第一文件处理程序 A102对所述第一文件执行 的操作内容; 以及, 与位于第二系统中的插件应用业务逻辑 B 103建立并维护 一个数据信息通道; 将对所述第一文件执行的操作内容和 /或所述第一文件的 结构参数发送给位于第二系统中的第二插件应用业务逻辑 B 103。
优选的, 所述第一系统 A104/第二系统 B104中还可以包括:
更新数据获取单元, 用于获取所述第一文件 A101的逻辑地址的起始位置 以及结束位置,调用函数访问并拷贝所述緩存区中所述起始位置与结束位置之 间的数.据, 并传输到所述数据信息通道。
本发明的实施例具有以下有益效果, 在第一文件发生更新时, 能够实时的 将导致第一文件发生更新的操作内容发送给第二系统,第二文件处理程序根据 操作内容对第二文件执行更新, 由于操作内容是对内存中的緩存区进行操作, 且这一操作发生的瞬间就能够检测到所述操作内容并发送给第二系统,由第二 文件处理程序根 ί居该操作内容实时的对第二文件进行同样的操作,因此上述过 程是实时的, 且能够在不同的系统中无需手动 /自动保存就对同一文件实现实 时同步更.新; 又由于在第一系统中和第二系统中的所述操作内容是一致的, 而 第一文件和第二文件也是一致的,因此能够保证更新后的第一文件和第二文件 也是一致的。
应当说明的是, 以上实施例仅用以说明本发明的技术方案而非限制, 所有 的参数取值可以根据实际情况调整, 且在该权利保护范围内。 本领域的普通技 术人员应当理解, 可以对本.发明的技术方案进行修改或者等同替换, 而不脱离 本发明技术方案的精神范围, 其均应涵盖在本发明的权利要求范围当中。

Claims

权 利 要 求 书
1. 一种文件同步方法, 其特征在于, 所述文件同步方法应用于具有第一 系统和第二系统的混合系统中, 所述方法包括:
所述第一系统监控所述第一系统的第一缓存区,所述第一缓存区中存有所 述第一系统的第一文件处理程序打开的存储在所述第一系统的非易失性存储 器中的第一文件所对应的第一数据;
当所述第一緩存区中的所述第一数据发生改变时,通过所述第一系统与所 述第二系统之间的数据信息通道,将所述第一文件处理程序对所述第一文件执 行的操作内容发送到所述第二系统中; 以及
所述第二系统中的第二文件处理程序根据所述操作内容对第二文件进行 同步处理; 所述第二文件是所述第二系统中与所述第一文件相对应的文件, 所 述第二文件存储在所述第二系统的非易失性存储器中。
2. 根据权利要求 1 所述的方法, 其特征在于, 所述操作内容为所述第一 文件处理程序对所述第一文件进行更新时调用的应用程序接口、所述应用程序 接口的工作参数、 以及所述工作参数的当前赋值。
3. 根据权利要求 1 所述的方法, 其特征在于, 所述操作内容包括: 发生 改变前的第一数据、所述第一文件处理程序对所述第一文件进行更新时调用的 应用程序接口、所述应用程序接口的工作参数、以及所述工作参数的当前赋值; 或者,
所述操作内容包括: 第一文件的结构参数、 所述第一文件处理程序对所述 第一文件进行更新时调用的应用程序接口、 所述应用程序接口的工作参数、 以 及所述工作参数的当前赋值。
4. 根据权利要求 1 所述的方法, 其特征在于, 当所述第一缓存区中的所 述第一数据发生改变时, 在第一预定时间间隔内发送所述操作内容; 其中, 所 述第一预定时间间隔远小于所述第一系统和 /或第二系统的自动保存时间间 隔。
5. 根据权利要求 1-4之一所述的方法, 其特征在于, 所述第一緩存区是 所述第一系统的易失性存储器。
6. 一种文件同步系统, 其特征在于, 包括第一系统和第二系统; 其中, 所述第一系统:
监控所述第一系统的第一缓存区,所述第一緩存区中存有所述第一系统中 的第一文件处理程序打开的存储在所述第一系统的非易失性存储器中的第一 文件所对应的第一数据;
当监控到所述第一緩存区中的所述第一数据发生改变时,通过所述第一系 统与所述第二系统之间的数.据信息通道,将所述第一文件处理程序对所述第一 文件执行的操作内容发送到所述第二系统;
所述第二系统中的第二文件处理程序根据所述操作内容对第二文件进行 同步处理, 所述第二文件是所述第二系统中与所述第一文件相对应的文件, 所 述第二文件存储在所述第二系统的非易失性存储器中。
7. 根^ ί居权利要求 6所述的文件同步系统, 其特征在于,
所述操作内容为所述第一文件处理程序对所述第一文件进行更新时调用 的应用程序接口、 所述应用程序接口的工作参教、 以及所述工作参数的当前赋 值;
或者,
所述操作内容包括: 发生改变前的第一数据、 第一文件处理程序对所述第 一文件进行更新时调用的应用程序接口、 所述应用程序接口的工作参数、 以及 所述工作参数的当前赋值;
或者,
所迷操作内容包括: 第一文件的结构参数、 所述第一文件处理程序对所述 第一文件进行更.新时调用的应用程序接口、 所述应用程序接口的工作参数、 以 及所述工作参数的当前赋值。
8. 根据权利要求 6或 7所述的文件同步系统, 其特征在于, 所述第一緩 存区是所述第一系统的易失性存储器。
9. 一种电子设备, 其特征在于, 包括:
包括第一系统和第二系统;
其中, 所述第一系统:
监控所述第一系统的第一緩存区,所述第一緩存区中存有所述第一系统中 的第一文件处理程序打开的存储在所述第一系统的非易失性存储器中的第一 文件所对应的第一数据;
当所述第一緩存区中的所述第一数据发生改变时,通过所述第一系统与所 述第二系统之间的数据信息通道,将所述第一文件处理程序对所述第一文件执 行的操作内容发送给所述第二系统;
所述第二系统的第二文件处理程序根据所述操作内容对第二文件进行同 步处理, 所述第二文件是所述第二系统中与所述第一文件相对应的文件, 所述 第二文件存储在所述第二系统的非易失性存储器中。
10. 根^权利要求 9所述的电子设备, 其特征在于, 还包括:
第一系统中的第一插件应用业务逻辑, 用于记录所述第一文件的结构参 数, 并记录下所述第一文件处理程序对所述第一文件执行的操作内容;
以及,与位于第二系统中的第二插件应用业务逻辑建立并维护一个数^信 息通道;
将对所述第一文件执行的操作内容和 /或所述第一文件的结构参数发送给 位于第二系统中的第二插件应用业务逻辑;
第二系统中的第二插件应用业务逻辑, 用于记录所述第二文件的结构参 数, 并记录下所述第二文件处理程序对所述第二文件执行的操作内容;
以及,与位于第一系统中的第一插件应用业务逻辑建立并维护一个数据信 息通道;
将对所述第二文件执行的操作内容和 /或所述第二文件的结构参数发送给 位于第一系统中的第一插件应用业务逻辑。
11. 根居权利要求 9或 10所述的电子设备, 其特征在于, 所述第一緩存 区是所述第一系统的易失性存储器。
12.一种电子设备, 其特征在于, 包括第一系统;
其中, 所述第一系统监控所述第一系统的第一緩存区, 所述第一緩存区中 存有所述第一系统中的第一文件处理程序打开的存储在所述第一系统的非易 失性存储器中的第一文件所对应的第一数据;
当所述第一緩存区中的所述第一数据发生改变时 ,通过所述第一系统与第 二系统之间的数据信息通道,将所述第一文件处理程序对所述第一文件执行的 操作内容发送到所述第二系统, 其中, 由所述第二系统中的第二文件处理程序 根据所述操作内容对第二文件进行同步处理;所述第二文件是所述第二系统中 与所述第一文件相对应的文件,所述第二文件存储在所述第二系统的非易失性 存储器中, 所述第二系统位于另一电子设备上。
13. 根据权利要求 12所述的电子设备, 其特征在于, 还包括:
第一插件应用业务逻辑,用于记录所述第一文件的结构参数, 并记录下所 述第一文件处理程序对所述第一文件执行的操作内容;
以及,与位于第二系统中的第二插件应用业务逻辑建立并维护一个数据信 息通道;
将对所述第一文件执行的操作内容和 /或所述第一文件的结构参数发送给 位于第二系统中的第二插件应用业务逻辑。
14. 根据权利要求 12或 13所述的电子设备, 其特征在于, 所述第一緩存 区是所述第一系统的易失性存储器。
21
更正页 (细则第 91条)
PCT/CN2011/077845 2010-08-02 2011-08-01 一种文件同步方法、电子设备和同步系统 Ceased WO2012016503A1 (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
US13/813,027 US9361309B2 (en) 2010-08-02 2011-08-01 File synchronization method, electronic device and synchronization system

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201010243573.9A CN102346740B (zh) 2010-08-02 2010-08-02 一种文件同步方法、电子设备和同步系统
CN201010243573.9 2010-08-02

Publications (1)

Publication Number Publication Date
WO2012016503A1 true WO2012016503A1 (zh) 2012-02-09

Family

ID=45545425

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2011/077845 Ceased WO2012016503A1 (zh) 2010-08-02 2011-08-01 一种文件同步方法、电子设备和同步系统

Country Status (3)

Country Link
US (1) US9361309B2 (zh)
CN (1) CN102346740B (zh)
WO (1) WO2012016503A1 (zh)

Families Citing this family (17)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102629221B (zh) * 2012-02-28 2014-11-19 华为技术有限公司 用于分布式共享存储的任务同步方法、装置及系统
CN103368900A (zh) * 2012-03-26 2013-10-23 联想(北京)有限公司 网络同步设置的方法、装置及系统
CN104008116B (zh) * 2013-02-27 2018-06-01 联想(北京)有限公司 一种文件同步方法及电子设备
CN104679661B (zh) 2013-11-27 2019-12-10 阿里巴巴集团控股有限公司 混合存储的控制方法及混合存储系统
EP3012744B1 (en) 2014-03-19 2022-12-21 Huawei Device Co., Ltd. Method and device for synchronizing application data
CN104657213B (zh) * 2015-02-13 2018-04-10 深圳酷派技术有限公司 一种系统间应用切换的方法和终端
CN106570045B (zh) * 2015-10-13 2020-12-08 腾讯科技(深圳)有限公司 一种数据操作控制方法及其系统、用户终端
CN106980625B (zh) 2016-01-18 2020-08-04 阿里巴巴集团控股有限公司 一种数据同步方法、装置及系统
WO2018027744A1 (zh) * 2016-08-11 2018-02-15 王志远 保持进度时的信息推送方法和保存系统
CN108388524A (zh) * 2016-12-21 2018-08-10 伊姆西Ip控股有限责任公司 用于缓存数据的方法和设备
CN106850770B (zh) * 2017-01-11 2020-08-18 杨立群 基于云计算服务的高效传输方法
CN106940867B (zh) * 2017-02-24 2020-11-20 深圳国泰安教育技术有限公司 一种金融交易方法及装置
CN109033116B (zh) * 2018-03-20 2021-07-09 广州中国科学院软件应用技术研究所 一种基于数据血统的信息数据回流系统及方法
CN113704212B (zh) * 2020-05-22 2024-08-16 深信服科技股份有限公司 服务器的数据同步方法、装置、设备及计算机存储介质
CN116070598B (zh) * 2021-11-04 2025-11-25 北京字跳网络技术有限公司 内容更新方法、装置、电子设备、介质及程序产品
CN114741142A (zh) * 2022-03-16 2022-07-12 维沃移动通信有限公司 屏幕控制方法、装置、电子设备及存储介质
CN115934664B (zh) * 2022-12-13 2026-01-06 北京数码大方科技股份有限公司 文件同步方法、装置、存储介质及电子设备

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040054854A1 (en) * 2002-09-17 2004-03-18 Pirasenna Thiyagaranjan Hybrid system and method for updating remote cache memory
US7266644B2 (en) * 2003-10-24 2007-09-04 Hitachi, Ltd. Storage system and file-reference method of remote-site storage system
CN101187948A (zh) * 2007-12-20 2008-05-28 中国科学院计算技术研究所 一种持续数据保护系统及其实现方法

Family Cites Families (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6101497A (en) * 1996-05-31 2000-08-08 Emc Corporation Method and apparatus for independent and simultaneous access to a common data set
US6199068B1 (en) * 1997-09-11 2001-03-06 Abb Power T&D Company Inc. Mapping interface for a distributed server to translate between dissimilar file formats
US20080288578A1 (en) * 2004-04-01 2008-11-20 Nokia Corporation Method, a Device, and a System for Enabling Data Synchronization Between Multiple Devices
US7096392B2 (en) * 2004-05-07 2006-08-22 Asempra Technologies, Inc. Method and system for automated, no downtime, real-time, continuous data protection
US20070038642A1 (en) * 2004-09-15 2007-02-15 Scott Durgin Method for providing extensible software components within a distributed synchronization system
US7720890B2 (en) * 2005-02-22 2010-05-18 Microsoft Corporation Ghosted synchronization
US8166263B2 (en) * 2008-07-03 2012-04-24 Commvault Systems, Inc. Continuous data protection over intermittent connections, such as continuous data backup for laptops or wireless devices
CN101771548A (zh) * 2008-12-29 2010-07-07 深圳市维信联合科技有限公司 文件同步方法及系统
CN101702732A (zh) * 2009-09-23 2010-05-05 中兴通讯股份有限公司 一种文件同步方法及文件同步系统

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040054854A1 (en) * 2002-09-17 2004-03-18 Pirasenna Thiyagaranjan Hybrid system and method for updating remote cache memory
US7266644B2 (en) * 2003-10-24 2007-09-04 Hitachi, Ltd. Storage system and file-reference method of remote-site storage system
CN101187948A (zh) * 2007-12-20 2008-05-28 中国科学院计算技术研究所 一种持续数据保护系统及其实现方法

Also Published As

Publication number Publication date
US20130132340A1 (en) 2013-05-23
CN102346740B (zh) 2016-08-10
US9361309B2 (en) 2016-06-07
CN102346740A (zh) 2012-02-08

Similar Documents

Publication Publication Date Title
WO2012016503A1 (zh) 一种文件同步方法、电子设备和同步系统
US8490092B2 (en) Combined live migration and storage migration using file shares and mirroring
KR101644666B1 (ko) 장치와 웹 서비스 간에 브라우저 캐시를 동기화하는 프로그래밍 모델
JP5481308B2 (ja) データ制御装置及びプログラム
CN106357703B (zh) 集群切换方法与设备
CN103412822B (zh) 操作非易失性内存和数据操作的方法和相关装置
CN104252284A (zh) 文件显示方法及装置
WO2012103827A2 (zh) 一种容器状态的保存和恢复的方法及装置
WO2014023000A1 (zh) 分布式数据处理方法及装置
WO2013017019A1 (zh) 一种图片编辑动作共享的方法、共享平台及系统
CN108664229B (zh) 传屏方法、装置、电子设备及计算机可读存储介质
CN105718272B (zh) 一种终端恢复出厂设置的方法及终端
KR101590947B1 (ko) 데이터 공유 방법, 장치, 프로그램 및 기록매체
CN103309754A (zh) 终端和数据分区管理方法
US8296367B2 (en) Synchronizing shared files during communication sessions
CN115203141A (zh) 分布式存储系统、元数据管理方法、设备及存储介质
CN111722909A (zh) 一种虚拟机迁移方法、系统、设备及存储介质
CN106844012A (zh) 一种非共享存储动态迁移虚拟机的方法及系统
CN104517067B (zh) 访问数据的方法、装置及系统
WO2020113478A1 (zh) 地址信息处理方法、装置、电子设备及存储介质
JP2012506593A (ja) 同期に基づく知識を有する破棄項目
WO2011143851A1 (zh) 数据库服务器操作控制系统、方法及设备
CN107992626A (zh) 缓存清理方法、装置、终端及存储介质
CN115408011A (zh) 基于屏保的系统优化方法、装置、终端设备和存储介质
WO2017096889A1 (zh) 系统升降级的方法和装置

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 11814086

Country of ref document: EP

Kind code of ref document: A1

WWE Wipo information: entry into national phase

Ref document number: 13813027

Country of ref document: US

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 11814086

Country of ref document: EP

Kind code of ref document: A1