Information synchronization method and apparatus, computer device, and storage medium

By automatically establishing the optimal communication medium between different terminals through soft bus technology, information synchronization between devices is achieved, solving the problems of low efficiency and poor user experience in existing technologies, and providing an efficient and simple information synchronization solution.

CN119906714BActive Publication Date: 2025-11-28BEIJING XIAOMI MOBILE SOFTWARE CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202311407031.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-10-26
Publication Date
2025-11-28
Estimated Expiration
2043-10-26

AI Technical Summary

Technical Problem

In existing technologies, information synchronization between devices requires manual operation by the user or reliance on communication software, which is inefficient and results in a poor user experience. Existing technologies cannot achieve the universality and convenience of information synchronization between devices.

Method used

Using soft bus technology, the system automatically discovers and establishes the optimal communication medium based on communication factors, enabling information synchronization between different terminals. Notification messages are transmitted through the information transmission channel on the soft bus, and the services running on the terminal directly call the framework interface for information synchronization.

Benefits of technology

It enables information synchronization between different terminals, has high versatility and simplicity, does not require complex software adaptation, and improves the efficiency of information synchronization and user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119906714B_ABST
    Figure CN119906714B_ABST
Patent Text Reader

Abstract

The present disclosure provides an information synchronization method, device, computer equipment and storage medium. The information synchronization method provided by the present disclosure is applied to a first terminal, and the method comprises the following steps: receiving a first notification sent by a first service, wherein the first notification carries to-be-synchronized information; acquiring at least one second terminal of a published notification service on a soft bus, wherein the first terminal has published a notification service on the soft bus, the soft bus is used to determine an optimal communication medium between terminals of the published notification service on the soft bus according to a communication factor in a current environment, and an information transmission channel is established between the terminals of the published notification service based on the optimal communication medium; and sending the first notification to the at least one second terminal based on the soft bus. The present method realizes information synchronization of different terminals on the basis of high universality; meanwhile, the information synchronization function does not need to be complicatedly adapted by software, and the use is simple and the usability is strong.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present disclosure relates to the technical field of information synchronization, and particularly relates to an information synchronization method and device, a computer device and a storage medium. BACKGROUND

[0002] With the popularization of multi-device use scenarios, information synchronization (such as notification messages and user files) between devices has become a basic requirement of users. For example, a user may wish to paste a text copied on a mobile phone on a computer, or synchronize a notification received on one device on all other devices.

[0003] In related technologies, information synchronization between devices usually needs to be completed manually or by means of communication software. For example, the content of a clipboard is sent to another terminal through social software, and then the content of the clipboard sent by the social software is received on the other terminal, so as to realize information synchronization. This solution is inefficient and has poor user experience. SUMMARY

[0004] To overcome the problems in related technologies, the present disclosure provides an information synchronization method and device, a computer device and a storage medium.

[0005] A first aspect of the present disclosure provides an information synchronization method applied to a first terminal, and the method comprises the following steps.

[0006] Receiving a first notification sent by a first service, wherein the first notification carries to-be-synchronized information;

[0007] Obtaining at least one second terminal that has published a notification service on a soft bus, wherein the first terminal has published a notification service on the soft bus, and the soft bus is used to determine an optimal communication medium between terminals that have published a notification service on the soft bus according to a communication factor in a current environment, and establish an information transmission channel between the terminals that have published a notification service based on the optimal communication medium;

[0008] Based on the soft bus, sending the first notification to the at least one second terminal.

[0009] Optionally, the obtaining of the at least one second terminal that has published a notification service on the soft bus comprises the following steps.

[0010] When at least one of the following conditions is met, the at least one second terminal that has published a notification service on the soft bus is obtained.

[0011] The first notification is encrypted by using a preset encryption method;

[0012] The soft bus meets a preset parameter;

[0013] The login user of the first terminal is the user indicated by the first notification.

[0014] Optionally, the acquiring the at least one second terminal publishing the notification service on the soft bus comprises:

[0015] The terminal satisfying at least one of the following conditions in the multiple terminals publishing the notification service on the soft bus is acquired as the second terminal:

[0016] A same service as the first service is running on the terminal;

[0017] The login user is the same as the user logged in the first terminal;

[0018] The target terminal is consistent with the target terminal indicated by the first notification.

[0019] Optionally, the sending the first notification to the at least one second terminal comprises:

[0020] In response to the information transmission channel based on the soft bus between the first terminal and any second terminal of the at least one second terminal, the first notification is sent to the any second terminal through the information transmission channel.

[0021] Optionally, the sending the first notification to the at least one second terminal comprises:

[0022] The first notification is packaged and sent to the at least one second terminal according to a preset protocol provided by the soft bus.

[0023] Optionally, the packaging and sending the first notification to the at least one second terminal comprises:

[0024] The first notification and the notification sent by other services except the first service are packaged and sent to the at least one second terminal, wherein the notification sent by the other services is a concurrent notification of the first notification.

[0025] Optionally, the receiving the first notification sent by the first service comprises:

[0026] The first notification sent by the first service is received, and the first notification is added into a first message queue.

[0027] The sending the first notification to the at least one second terminal comprises:

[0028] The notification contained in the first message queue is sent to the at least one second terminal.

[0029] Optionally, the receiving the first notification sent by the first service and adding the first notification into the first message queue comprises:

[0030] In the case that a plurality of first notifications are received by the first service, the plurality of first notifications are packed and added into the first message queue.

[0031] Optionally, the first notification is sent by the first service calling a preset interface, wherein the preset interface is an interface provided by a framework for executing the information synchronization method.

[0032] The second aspect of the present disclosure provides an information synchronization method applied to a second terminal, the method comprising:

[0033] Based on a soft bus, receiving a first notification sent by a first terminal which has published a notification service on the soft bus, the first notification carrying to-be-synchronized information, the second terminal having published a notification service on the soft bus, the soft bus being used to determine an optimal communication medium between terminals which have published notification services on the soft bus according to communication factors in a current environment, and to establish an information transmission channel between the terminals which have published notification services based on the optimal communication medium;

[0034] Reporting the to-be-synchronized information to a second service, the second service being a service indicated by the first notification.

[0035] Optionally, the reporting the to-be-synchronized information to the second service comprises:

[0036] Adding the first notification into a second message queue;

[0037] Reporting to-be-synchronized information carried by notifications contained in the second message queue to the second service.

[0038] Optionally, the method further comprises:

[0039] According to a preset protocol provided by the soft bus, unpacking the first notification.

[0040] The third aspect of the present disclosure provides an information synchronization device applied to a first terminal, the device comprising:

[0041] A first receiving module, configured to receive a first notification sent by a first service, the first notification carrying to-be-synchronized information;

[0042] An obtaining module, configured to obtain at least one second terminal which has published a notification service on a soft bus, the first terminal having published a notification service on the soft bus, the soft bus being used to determine an optimal communication medium between terminals which have published notification services on the soft bus according to communication factors in a current environment, and to establish an information transmission channel between the terminals which have published notification services based on the optimal communication medium;

[0043] The sending module is configured to send the first notification to the at least one second terminal based on the soft bus.

[0044] Optionally, the obtaining module is configured to, when the at least one second terminal that has published the notification service on the soft bus is obtained:

[0045] The at least one second terminal that has published the notification service on the soft bus is obtained when at least one of the following conditions is met:

[0046] The first notification is encrypted by using a preset encryption manner;

[0047] The soft bus meets a preset parameter;

[0048] A login user of the first terminal is a user indicated by the first notification.

[0049] Optionally, the obtaining module is configured to, when the at least one second terminal that has published the notification service on the soft bus is obtained:

[0050] The terminal that meets at least one of the following conditions among the multiple terminals that have published the notification service on the soft bus is obtained as the second terminal:

[0051] A same service as the first service is run;

[0052] A login user is same as a user logged in by the first terminal;

[0053] A target terminal indicated by the first notification is consistent.

[0054] Optionally, the sending module is configured to, when the first notification is sent to the at least one second terminal:

[0055] In response to that there is an information transmission channel based on the soft bus between the first terminal and any second terminal among the at least one second terminal, the first notification is sent to the any second terminal through the information transmission channel.

[0056] Optionally, the sending module is configured to, when the first notification is sent to the at least one second terminal:

[0057] The first notification is packaged and sent to the at least one second terminal according to a preset protocol provided by the soft bus.

[0058] Optionally, the sending module is configured to, when the first notification is packaged and sent to the at least one second terminal according to the preset protocol provided by the soft bus:

[0059] packaging and sending the first notification and a notification sent by a service other than the first service to the at least one second terminal, wherein the notification sent by the other service is a concurrent notification of the first notification.

[0060] Optionally, the first receiving module is configured to, when receiving the first notification sent by the first service, be configured to:

[0061] receive the first notification sent by the first service and add the first notification into a first message queue;

[0062] The sending module is configured to, when sending the first notification to the at least one second terminal, be configured to:

[0063] send the notification contained in the first message queue to the at least one second terminal.

[0064] Optionally, the first receiving module is configured to, when receiving the first notification sent by the first service and adding the first notification into a first message queue, be configured to:

[0065] In a case where a plurality of first notifications sent by the first service are received, the plurality of first notifications are packaged and added into the first message queue.

[0066] Optionally, the first notification is sent by the first service calling a preset interface, wherein the preset interface is an interface provided by a framework for executing the information synchronization method.

[0067] A fourth aspect of the present disclosure provides an information synchronization device, and the device comprises:

[0068] A second receiving module is configured to receive a first notification sent by a first terminal that has published a notification service on a soft bus, based on the soft bus, wherein the first notification carries to-be-synchronized information, the second terminal has published the notification service on the soft bus, and the soft bus is used to determine an optimal communication medium between terminals that have published notification services on the soft bus according to a communication factor in a current environment, and establish an information transmission channel between the terminals that have published notification services based on the optimal communication medium.

[0069] A reporting module is configured to report the to-be-synchronized information to a second service, wherein the second service is a service indicated by the first notification.

[0070] Optionally, the sending module is configured to, when reporting the to-be-synchronized information to the second service, be configured to:

[0071] add the first notification into a second message queue;

[0072] report the to-be-synchronized information carried by the notification contained in the second message queue to the second service.

[0073] Optionally, the apparatus further comprises:

[0074] an unpacking module configured to unpack the first notification according to a preset protocol provided by the soft bus.

[0075] The fifth aspect of the present disclosure provides an information synchronization apparatus, the apparatus comprising:

[0076] a soft bus configured to determine an optimal communication medium between terminals that have published notification services on the soft bus according to communication factors in a current environment, and establish an information transmission channel between the terminals that have published notification services based on the optimal communication medium;

[0077] an information synchronization framework comprising an interface module, a security module and a processing module;

[0078] The interface module is configured to interact with services on the terminal through notifications.

[0079] The security module is configured to verify the legitimacy of at least one of the notification, a user logged in on the terminal and the soft bus.

[0080] The processing module is configured to interact with other terminals that have published notification services on the soft bus through notifications.

[0081] The sixth aspect of the present disclosure provides a computer device, comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor implements the method of any one of the first aspect or the second aspect when executing the program.

[0082] The seventh aspect of the present disclosure provides a computer-readable storage medium having a computer program stored thereon, wherein the program is executable on a processor to implement the method of any one of the first aspect or the second aspect.

[0083] The technical solution provided by the embodiments of the present disclosure can have the following beneficial effects:

[0084] In the embodiments of the present disclosure, based on the soft bus used for establishing a communication connection with a terminal publishing a notification service on the soft bus, information synchronization between services of different terminals is implemented. The information synchronization method provided by the present disclosure receives a first notification carrying to-be-synchronized information sent by a first service, acquires at least one second terminal publishing a notification service on the soft bus, and sends the first notification to the at least one second terminal based on the soft bus; after receiving the first notification, the at least one second terminal reports the first notification to a second service indicated by the first notification, that is, the information synchronization process is completed. In the embodiments of the present disclosure, based on the soft bus used for establishing a communication connection with a terminal publishing a notification service on the soft bus, information synchronization between services of different terminals is implemented. Without a closed-loop software ecology, only by receiving a first notification carrying to-be-synchronized information sent by a service needing information synchronization, information synchronization between different terminals can be implemented, which has high universality. At the same time, the software does not need to be complicatedly adapted to the information synchronization function, and is simple to use and has strong usability.

[0085] It should be understood that the foregoing general description and the following detailed description are only exemplary and explanatory, and cannot limit the present disclosure. BRIEF DESCRIPTION OF DRAWINGS

[0086] The accompanying drawings, which are incorporated into the specification and constitute a part of the present disclosure, illustrate embodiments consistent with the present disclosure and, together with the specification, serve to explain the principles of the present disclosure.

[0087] Figure 1 FIG. 1 is a flowchart of an information synchronization method according to some exemplary embodiments.

[0088] Figure 2 FIG. 2 is a flowchart of another information synchronization method according to some exemplary embodiments.

[0089] Figure 3 FIG. 3 is a flowchart of still another information synchronization method according to some exemplary embodiments.

[0090] Figure 4 FIG. 4 is an interaction diagram of an information synchronization method according to some exemplary embodiments.

[0091] Figure 5 FIG. 5 is a block diagram of an information synchronization apparatus according to some exemplary embodiments.

[0092] Figure 6 FIG. 6 is a block diagram of another information synchronization apparatus according to some exemplary embodiments.

[0093] Figure 7 FIG. 7 is a block diagram of still another information synchronization apparatus according to some exemplary embodiments.

[0094] Figure 8These are hardware structure diagrams of a computer device illustrating some exemplary embodiments. Detailed Implementation

[0095] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numerals in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this disclosure. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this disclosure as detailed in the appended claims.

[0096] The terminology used in this disclosure is for the purpose of describing particular embodiments only and is not intended to be limiting of the disclosure. The singular forms “a,” “the,” and “the” as used in this disclosure and the appended claims are also intended to include the plural forms unless the context clearly indicates otherwise. It should also be understood that the term “and / or” as used herein refers to and includes any and all possible combinations of one or more of the associated listed items.

[0097] It should be understood that although the terms first, second, third, etc., may be used in this disclosure to describe various information, such information should not be limited to these terms. These terms are used only to distinguish information of the same type from one another. For example, without departing from the scope of this disclosure, first information may also be referred to as second information, and similarly, second information may also be referred to as first information. Depending on the context, the word "if" as used herein may be interpreted as "when," "when," or "in response to determination."

[0098] With the increasing prevalence of multi-device usage, cross-device information synchronization (such as notification messages and user files) has become a basic user requirement. For example, users may want to be able to paste text copied on their mobile phones onto their computers, or have notifications received on one device synchronized across all other devices.

[0099] Existing solutions are often limited by specific operating systems or device ecosystems. For example, they rely on the closed-loop characteristics of the device ecosystem to achieve information synchronization. These solutions lack universality and require extensive software adaptation to achieve synchronization functionality.

[0100] In view of this, this disclosure provides information synchronization methods, apparatus, computer equipment, and storage media. The concepts involved in this disclosure will now be explained.

[0101] The soft bus is a software bus capable of establishing a communication connection, which can be a distributed soft bus or a self-configuring packaged communication connection framework. Preferably, the soft bus can have the following functions. The soft bus can automatically discover other devices configured with the soft bus and establish a communication connection thereon. Meanwhile, the soft bus is used to determine the optimal communication medium between the terminals that have published notification services on the soft bus (for example, through a Bluetooth connection or through a local area network connection) according to the communication factors in the current environment (for example, the quality of a local area network connection or the quality of a Bluetooth connection), and establish an information transmission channel between the terminals that have published notification services based on the optimal communication medium (preferably, the information transmission channel between each two terminals can be maintained or switched in real time according to the communication factors between the two terminals; for example, device A and device B are decided by an algorithm to be optimal through a local area network, and can select to establish an information transmission channel based on the local area network and perform information synchronization; device A and device C are decided by an algorithm to have an information transmission channel therebetween, and can reuse the information transmission channel; device A and device D are decided by an algorithm to be able to deliver information by multicast at this time, and can select to establish an information transmission channel based on multicast and perform information synchronization; when the local area network connection between device A and device B is disconnected, if device A and device B can be connected through a Bluetooth connection, an information transmission channel based on Bluetooth can be selected to be established and information synchronization can be performed). In addition, the soft bus provides a series of interfaces, and a framework executing the method can obtain the parameters of the soft bus, the devices registering or publishing services (for example, notification services) on the soft bus, and the related parameters of these devices registering or publishing services on the soft bus (for example, the user logging in the device, the business running on the device, etc.) through the interfaces.

[0102] It should be understood that, in order to implement the technical solutions provided by the present disclosure, the "first terminal", "second terminal" and other terminals involved in the present disclosure should publish notification services on the soft bus before the method is executed (for example, a framework executing the method provided by the present disclosure registers cross-device notification message listening on the soft bus, and the business running on the terminal statically registers the soft bus and subscribes to the cross-device notification message of the framework), so that the soft bus can network between the devices that have published notification services on the soft bus, and know the related parameters of the first terminal and the second terminal, and can send notifications to the terminals and the business running on the terminals.

[0103] Next, the embodiments of the present disclosure are described in detail.

[0104] In a first aspect, an information synchronization method applied to a first terminal is provided. As shown in Figure 1 Figure 1 is a flowchart of an information synchronization method according to some embodiments of the present disclosure, comprising the following steps:

[0105] ​In step S101, a first notification sent by a first service is received, the first notification carrying to-be-synchronized information;

[0106] The first notification is a notification message carrying to-be-synchronized information sent by the first service to a framework executing the method based on information synchronization demand. As an example, the first notification can be sent by a module configured by the first service after identifying information synchronization demand (for example, update of the content of a clipboard or addition of a new picture in a gallery); as another example, the framework executing the method can listen to the first service and identify information synchronization demand, and then read to-be-synchronized information of the first service or send an instruction to the first service to acquire to-be-synchronized information. The to-be-synchronized information is information that the first service needs to synchronize to other terminals or other services, for example, the update content of the clipboard or the new picture added in the gallery.

[0107] In some embodiments of the present disclosure, the first notification is sent by the first service calling a preset interface, wherein the preset interface is an interface provided by a framework executing the information synchronization method. That is, the framework executing the method provides a preset interface, and when the first service has information synchronization demand, the first notification is sent to the framework executing the method by directly calling the preset interface, so that cross-terminal information synchronization is achieved, which is highly universal and easy to use, and the first service does not need to make complex adaptation to the method.

[0108] It should be understood that, in addition to the notification message carrying to-be-synchronized information, the first notification can also carry other information, for example, a target terminal of the first notification or a filtering condition for the target terminal, a target service of the first notification or a filtering condition for the target service, a valid time of the first notification, and the like.

[0109] In step S102, at least one second terminal that has published a notification service on a soft bus is acquired, the first terminal having published a notification service on the soft bus, the soft bus being used to determine an optimal communication medium between terminals that have published notification services on the soft bus according to a communication factor in a current environment, and establish an information transmission channel between the terminals that have published notification services based on the optimal communication medium;

[0110] The framework executing the method can call an interface provided by the soft bus or read relevant parameters of the soft bus to learn the terminals that have published notification services on the soft bus. In some embodiments of the present disclosure, step S102 has an additional judgment condition, for example, at least one of the following three judgment conditions, that is, when at least one of the following conditions is met, at least one second terminal that has published a notification service on a soft bus is acquired.

[0111] The first notification is encrypted by using a preset encryption mode.

[0112] The framework for executing the method or the soft bus used by the method can be configured with the preset encryption mode, and the encryption mode and the key used by the encryption mode can be provided only to a service that obtains authentication (for example, a service that has the right of cross-device information synchronization), and in the case where the first notification is encrypted by using the preset encryption mode, it can be confirmed that the first notification is sent by the service that obtains authentication, thereby avoiding that a hacker software or tampered software sends the first notification to the framework for executing the method, and bringing a security risk to other devices or services.

[0113] It should be understood that the present disclosure does not limit the specific encryption mode and the encrypted content, and the encryption by using the preset encryption mode can be that the entire text of the information to be synchronized is encrypted, or a signature is generated by using the preset encryption mode based on the information to be synchronized or other information carried in the first notification, and the signature is included in the first notification.

[0114] The second judgment condition is that the soft bus satisfies a preset parameter.

[0115] In some cases, the soft bus can be configured with a specific feature code (for example, the feature code is calculated based on the related parameters of the communication channel established on the soft bus, or the feature code is calculated based on the user information of the terminal configured with the soft bus logged in, and the calculation method can be based on information digest algorithm or field splicing calculation), at this time, the feature code of the soft bus or the communication channel established on the soft bus can be obtained by calling the interface provided by the soft bus or actively reading the related parameters of the soft bus, and if the user indicated by the feature code is not a user satisfying a preset condition (for example, the terminal performs user switching after publishing the notification service on the soft bus) or the communication channel does not satisfy a preset condition (for example, the communication channel is tampered), it can be considered that the current information synchronization environment has a risk.

[0116] The third judgment condition is that the login user of the first terminal is the user indicated by the first notification.

[0117] The user indicated by the first notification should correspond to the user of the first service, and if this user is not logged in on the terminal for executing the method, it can be considered that the current login user of the first terminal is illegal, and the current information synchronization environment has a risk.

[0118] The above judgment conditions give the judgment conditions of the execution step S102 from multiple dimensions, and when the first service is not trusted, the soft bus is not trusted, and the user logged in on the first terminal is not trusted, the execution of the step is stopped, and the security of information synchronization is maximized.

[0119] In some embodiments of the present disclosure, step S102 has three screening conditions for the at least one second terminal, i.e., obtaining the terminals in the plurality of terminals on the soft bus that have published the notification service and that meet at least one of the following conditions as the second terminal:

[0120] Screening condition 1: running the same service as the first service.

[0121] In daily use, the service that needs information synchronization is usually the same service running on different terminals, so only the terminal running the same service as the first service can be used as the at least one second terminal.

[0122] Screening condition 2: the logged-in user is the same as the user logged in the first terminal.

[0123] In daily use, the terminal that needs information synchronization is usually the terminal logged in by the same user, so only the terminal with the same logged-in user as the first terminal can be used as the at least one second terminal.

[0124] Screening condition 3: consistent with the target terminal indicated by the first notification.

[0125] When the first notification carries the target terminal information or the screening condition for the target terminal, only the terminal consistent with the target terminal indicated by the first notification can be used as the at least one second terminal.

[0126] The above screening conditions avoid the waste of resources or information leakage caused by sending the first notification to the terminal that does not need to receive the to-be-synchronized information, and improve the security and practicability of the method.

[0127] In step S103, the first notification is sent to the at least one second terminal based on the soft bus.

[0128] The soft bus provides an interface or component (such as a distribution executor) for realizing communication connection, so in S103, the interface or component (such as the distribution executor) can be directly called to send the first notification to the at least one second terminal. After the second terminal receives the first notification, the second service indicated by the first notification reports the to-be-synchronized information carried in the first notification, so as to complete the information synchronization process.

[0129] In some embodiments of the present disclosure, the optional way of sending the first notification to the at least one second terminal is to package and send the first notification to the at least one second terminal according to the preset protocol provided by the soft bus. This has the advantage that a unified protocol can be used for sending and receiving notifications, improving the universality and simplicity of the method.

[0130] Specifically, the "packaging and sending" is that the first notification is re-encoded or combined with a preset protocol to generate a new data packet, and the new data packet is sent to the second terminal as the first notification. Wherein, the object of packaging can include the sender of the first notification (i.e. the first service or the first terminal), the characteristic code of the first notification (for example, the hash value generated by using the information digest algorithm to calculate the original first notification), or other related information, in addition to the original first notification or the synchronization information carried by the original first notification, and the present disclosure does not limit this; in addition, when the first terminal receives multiple notifications with consistent target terminals within a preset time range (these notifications may not come from the same service), the multiple notifications can be merged and packaged and sent to the target terminal (i.e. the first notification and the notification sent by other services in addition to the first service are packaged and sent to the at least one second terminal, wherein the notification sent by the other services is the concurrent notification of the first notification), which can improve the timeliness of notification sending and avoid the problem of low efficiency caused by sending notifications one by one.

[0131] In some embodiments of the present disclosure, the optional way of sending the first notification to the at least one second terminal is to send the first notification to any second terminal among the first terminal and the at least one second terminal in response to the information transmission channel based on the soft bus between the first terminal and the second terminal. That is, the existing information transmission channel is used to realize the sending of the first notification. The existing information transmission channel can be an information transmission channel opened by other notifications sent by the first service, or an information transmission channel opened by notifications sent by other services running on the first terminal. Through multiplexing of the information transmission channel, the resource consumption caused by frequent opening and closing of the information transmission channel can be minimized, and the execution efficiency of the method can be improved.

[0132] It should be understood that the information transmission channel described in the present disclosure can be, for example, an information transmission channel established by the soft bus based on the transmission medium determined by the communication factor between the first terminal and the second terminal in the current environment; again, for example, the channel based on the soft bus between the first terminal and the second terminal, which can transmit information, can be regarded as the information transmission channel described in the present disclosure and is applicable to the above channel multiplexing step.

[0133] In some embodiments of the present disclosure, the receiving of the first notification sent by the first service includes:

[0134] receiving the first notification sent by the first service, and adding the first notification into the first message queue;

[0135] The sending of the first notification to the at least one second terminal includes:

[0136] sending the first notification to the at least one second terminal.

[0137] That is, the first notification is processed in the manner of message queue. This optional solution can process the notifications sent by the first service one by one in the concurrent case, avoiding the problem that the processing of the first notification is more chaotic when the number of the first notification is large.

[0138] It should be understood that the action of adding the first notification into the first message queue can be performed before, during and after the execution of step S102, and the present disclosure does not limit this. Meanwhile, when the present method adopts the above optional solution, if step S102 has a condition judgment related to the first notification, the first notification can be taken out from the first message queue and the related judgment can be performed during the execution of S102, and then the first notification is sent to the at least one second terminal in step S103.

[0139] In addition, in the case that the framework executing the present method receives a plurality of first notifications sent by the first service, the plurality of first notifications can be packaged and added into the first message queue; in the case that the framework executing the present method receives a plurality of first notifications sent by a plurality of services, the plurality of notifications can be packaged and added into the first message queue. Meanwhile, different queues can be allocated for the plurality of notifications (for example, different queues are configured according to different second terminals, different queues are configured according to different services on the first terminal, different queues are configured according to hardware resources, queues are randomly allocated, etc.), so as to asynchronously and in parallel process the plurality of notifications, improve the efficiency of notification processing and sending, and thus improve the efficiency of information synchronization, and the present disclosure does not limit this.

[0140] In summary, it can be understood that in the embodiments provided by the present disclosure, the following steps can exist:

[0141] Step 1: judging the security (for example, the above three judgment conditions);

[0142] Step 2: obtaining the terminal of the published notification service on the soft bus (step S102);

[0143] Step 3: screening the terminal (for example, the above three screening conditions);

[0144] Step 4: sending the first notification to the screened terminal.

[0145] The above given execution sequence is only a preferred execution sequence that can save the execution cost of the method. In actual operation, the specific execution time of steps 1 and 3 can be set according to actual conditions, and the present disclosure does not limit this. Specifically, step 3 can be executed during the execution of step 2 (i.e., the terminal meeting the screening condition is taken as the at least one second terminal), can be executed during the execution of step 4 (i.e., the first notification is sent only to the terminal meeting the screening condition in the at least one second terminal), or is executed as an independent step between steps 2 and 4. Similarly, step 1 can be a prerequisite for the execution of step 2 (i.e., step 2 is executed only when at least one of the three judgment conditions is met), can be a prerequisite for the execution of step 4 (i.e., step 4 is executed only when at least one of the three judgment conditions is met), or step 1 is a prerequisite for the execution of step 3 (i.e., step 3 is executed only when at least one of the three judgment conditions is met).

[0146] Correspondingly, the packing processing (i.e., message aggregation) and the adding queue operation of the plurality of notifications of the present disclosure can also be executed at any feasible time in the above steps, and the present disclosure does not limit this.

[0147] The information synchronization method provided by the present disclosure receives a first notification carrying to-be-synchronized information sent by a first service, acquires at least one second terminal of a published notification service on a soft bus, and sends the first notification to the at least one second terminal based on the soft bus. After receiving the first notification, the at least one second terminal reports the first notification to a second service indicated by the first notification, that is, the information synchronization process is completed. In the embodiment of the present disclosure, based on the soft bus for establishing a communication connection with the terminal of the published notification service on the soft bus, the information synchronization between the services of different terminals is realized. Without the closed-loop software ecology, only by receiving the first notification carrying the to-be-synchronized information sent by the service needing information synchronization, the information synchronization of different terminals can be realized, which has high universality. At the same time, without complex adaptation of the software to the information synchronization function, the use is simple and the usability is strong.

[0148] In a second aspect, an information synchronization method applied to a second terminal is provided. Please refer to Figure 2 The information synchronization method shown in the figure includes the following steps:

[0149] S201, receiving, based on a soft bus, a first notification sent by a first terminal which has published a notification service on the soft bus, the first notification carrying to-be-synchronized information, the second terminal having published a notification service on the soft bus, the soft bus being used to determine an optimal communication medium between terminals which have published a notification service on the soft bus according to a communication factor in a current environment, and establish an information transmission channel between the terminals which have published a notification service based on the optimal communication medium;

[0150] After the first terminal receives a first notification sent by a first service running on the first terminal, at least one second terminal which has published a notification service on the soft bus is acquired, and the first notification is sent to the at least one second terminal based on the soft bus. At this time, the second terminal receives a first notification sent by a first terminal which has published a notification service on the soft bus, the first notification carrying to-be-synchronized information.

[0151] S202, reporting the to-be-synchronized information to a second service, the second service being a service indicated by the first notification.

[0152] The to-be-synchronized information is reported to a second service to complete the synchronization process of information, the second service being a service indicated by the first notification. For example, the first notification is a notification carrying copied content of a user on a first terminal sent by a clipboard running on the first terminal, at this time, the second terminal can report the copied content of the user on the first terminal to a clipboard running on the second terminal, so that the content copied by the user can be synchronized from the first terminal to the second terminal. For another example, the first notification is a notification carrying a newly added picture in a gallery sent by a gallery running on the first terminal, at this time, the second terminal can report the newly added picture to a gallery running on the second terminal, so that the picture of the user can be synchronized from the first terminal to the second terminal. For another example, the first terminal is a television, and the second terminal is a mobile phone, when the user watches the television, the mobile phone receives order information of takeout or a car, and the mobile phone synchronizes the message to the television for the user to view in time.

[0153] It should be understood that when the framework executing the method on the second terminal reports the to-be-synchronized information to the second service, it does not necessarily upload only the to-be-synchronized information, but can also include information required by other second services (for example, a source terminal or a source service of the first notification), or directly report the first notification to the second service, so that the second service parses the first notification and learns the to-be-synchronized information.

[0154] In some embodiments of the present disclosure, the reporting of the to-be-synchronized information to the second service comprises:

[0155] adding the first notification into a second message queue;

[0156] reporting the to-be-synchronized information carried by the notification contained in the second message queue to the second service.

[0157] That is, the first notification is processed in the manner of the message queue. This optional solution can process the notifications sent by the first terminal one by one in the concurrent case, avoiding the problem that the processing of the first notification is relatively chaotic when the number of the first notification is large.

[0158] In some embodiments of the present disclosure, the data packet between the first terminal and the second terminal is packaged by the first terminal according to a preset protocol and then sent, and therefore the method can further include Figure 3 the following steps:

[0159] S301, unpacking the first notification according to the preset protocol provided by the soft bus.

[0160] Specifically, unpacking means analyzing or decoding the first notification according to the preset protocol to obtain the content contained in the first notification. It should be understood that the execution time of step S301 can be set by itself according to actual conditions in actual operation. Specifically, the first notification can be unpacked after the first notification is received, or the first notification can be unpacked when the first notification is added to the second message queue, or the first notification can be unpacked when the to-be-synchronized information carried by the notification contained in the second message queue is reported to the second service. In addition, the first notification can be packaged by the first terminal with multiple to-be-synchronized information and then sent, in which case, the second terminal can unpack the first notification to obtain multiple to-be-synchronized information, and report the multiple to-be-synchronized information obtained by unpacking to the corresponding service respectively.

[0161] The information synchronization method provided by the present disclosure receives the first notification carrying the to-be-synchronized information sent by the first service, acquires at least one second terminal of the published notification service on the soft bus, and sends the first notification to the at least one second terminal based on the soft bus; after receiving the first notification, the at least one second terminal reports the first notification to the second service indicated by the first notification, that is, the information synchronization process is completed. In the embodiment of the present disclosure, based on the soft bus for establishing a communication connection with the terminal of the published notification service on the soft bus, the information synchronization between the services of different terminals is realized, without the need of a closed-loop software ecology. Only by receiving the first notification carrying the to-be-synchronized information sent by the service that needs to be synchronized, the information synchronization of different terminals can be realized, which has high universality. At the same time, the software does not need to be complicatedly adapted to the information synchronization function, and is easy to use and has strong usability.

[0162] In combination with the above embodiments, the interaction steps shown in the following can be obtained: Figure 4 the interaction steps shown in the following can be obtained:

[0163] S401, the first terminal receives a first notification sent by a first service;

[0164] At this time, the first terminal can detect whether the first notification is encrypted by using a preset encryption mode, whether the related parameters of the soft bus of the published notification service of the first terminal meet the preset parameters, and whether the login user of the first terminal is the user indicated by the first notification. If the above conditions are not established, step S402 can not be performed.

[0165] S402, the first terminal acquires at least one second terminal of the published notification service on the soft bus;

[0166] The first terminal acquires the terminal running the same service as the first service, the terminal logged in with the same user as the user of the first terminal, and the terminal consistent with the target terminal indicated by the first notification among the multiple terminals of the published notification service on the soft bus, and takes the acquired terminal as at least one second terminal.

[0167] S403, the first terminal sends the first notification to the second terminal;

[0168] The first terminal can package and send the first notification to the at least one second terminal according to the preset protocol provided by the soft bus. In the case that there is an information transmission channel based on the soft bus between the first terminal and any second terminal of the at least one second terminal, the information transmission channel can be multiplexed, that is, the first notification is sent to the any second terminal through the information transmission channel. In the case that there are multiple notifications consistent with the target terminal, the multiple notifications can be packaged and sent to the target terminal.

[0169] S404, the second terminal reports the to-be-synchronized information to the second service.

[0170] The second terminal receives the first notification sent by the first terminal, unpackages the first notification according to the preset protocol provided by the soft bus, and reports the to-be-synchronized information carried in the first notification to the service indicated by the first notification.

[0171] Regarding the second aspect embodiment and Figure 4 The specific step details of the interaction diagram shown are described in the related part of the foregoing embodiment. For example, on the second terminal side, the notification messages from multiple terminals or multiple services can also be distributed into the same or different queues, and the notifications with the same target service are packaged. Details are not repeated here.

[0172] Corresponding to the foregoing method embodiment, the disclosure also provides an embodiment of an apparatus and a terminal to which the apparatus is applied.

[0173] The third aspect of the present disclosure provides an information synchronization device applied to a first terminal, which comprises Figure 5 , and the device comprises:

[0174] A first receiving module 501 is configured to receive a first notification sent by a first service, wherein the first notification carries to-be-synchronized information.

[0175] A obtaining module 502 is configured to obtain at least one second terminal which has published a notification service on a soft bus, wherein the first terminal has published a notification service on the soft bus, and the soft bus is used to determine an optimal communication medium between terminals which have published notification services on the soft bus according to a communication factor in a current environment, and to establish an information transmission channel between the terminals which have published notification services based on the optimal communication medium.

[0176] A sending module 503 is configured to send the first notification to the at least one second terminal based on the soft bus.

[0177] Optionally, when the obtaining module 502 is used to obtain the at least one second terminal which has published a notification service on the soft bus, the obtaining module 502 is configured to:

[0178] The at least one second terminal which has published a notification service on the soft bus is obtained when at least one of the following conditions is met:

[0179] The first notification is encrypted by using a preset encryption method;

[0180] The soft bus meets a preset parameter;

[0181] A login user of the first terminal is a user indicated by the first notification.

[0182] Optionally, when the obtaining module 502 is used to obtain the at least one second terminal which has published a notification service on the soft bus, the obtaining module 502 is configured to:

[0183] The terminals which meet at least one of the following conditions among a plurality of terminals which have published notification services on the soft bus are obtained as the second terminals:

[0184] A same service as the first service is run;

[0185] A login user is same as a user logged in the first terminal;

[0186] A target terminal indicated by the first notification is consistent.

[0187] Optionally, when the sending module 503 is used to send the first notification to the at least one second terminal, the sending module 503 is configured to:

[0188] In response to the fact that there is an information transmission channel based on the soft bus between the first terminal and any one of the at least one second terminal, the first notification is sent to the any one of the at least one second terminal through the information transmission channel.

[0189] Optionally, the sending module 503 is configured to, when the first notification is sent to the at least one second terminal, be configured to:

[0190] The first notification is packaged and sent to the at least one second terminal according to a preset protocol provided by the soft bus.

[0191] Optionally, the sending module 503 is configured to, when the first notification is packaged and sent to the at least one second terminal according to the preset protocol provided by the soft bus, be configured to:

[0192] The first notification and a notification sent by a service other than the first service are packaged and sent to the at least one second terminal, wherein the notification sent by the other service is a concurrent notification of the first notification.

[0193] Optionally, the first receiving module 501 is configured to, when the first notification sent by the first service is received, be configured to:

[0194] The first notification sent by the first service is received, and the first notification is added to a first message queue.

[0195] The sending module 503 is configured to, when the first notification is sent to the at least one second terminal, be configured to:

[0196] The notification contained in the first message queue is sent to the at least one second terminal.

[0197] Optionally, the first receiving module 501 is configured to, when the first notification sent by the first service is received and added to the first message queue, be configured to:

[0198] When a plurality of first notifications sent by the first service are received, the plurality of first notifications are packaged and added to the first message queue.

[0199] Optionally, the first notification is sent by the first service calling a preset interface, wherein the preset interface is an interface provided by a framework for executing the information synchronization method.

[0200] A fourth aspect of the present disclosure provides an information synchronization device, please refer to Figure 6 , the device comprises:

[0201] The second receiving module 601 is configured to receive a first notification sent by a first terminal which has published a notification service on the soft bus, based on the soft bus, the first notification carrying to-be-synchronized information, the second terminal having published the notification service on the soft bus, the soft bus being configured to determine an optimal communication medium between terminals which have published notification services on the soft bus according to communication factors in a current environment, and establish an information transmission channel between the terminals which have published the notification services based on the optimal communication medium.

[0202] The reporting module 602 is configured to report the to-be-synchronized information to a second service, the second service being a service indicated by the first notification.

[0203] Optionally, the sending module 503 is configured to, when reporting the to-be-synchronized information to the second service:

[0204] add the first notification into a second message queue;

[0205] report to-be-synchronized information carried by a notification included in the second message queue to the second service.

[0206] Optionally, the apparatus further includes:

[0207] The unpacking module is configured to unpack the first notification according to a preset protocol provided by the soft bus.

[0208] The fifth aspect of the present disclosure provides an information synchronization apparatus, please refer to Figure 7 , the apparatus includes:

[0209] The soft bus 720 is configured to determine an optimal communication medium between terminals which have published notification services on the soft bus 720 according to communication factors in a current environment, and establish an information transmission channel between the terminals which have published the notification services based on the optimal communication medium.

[0210] The information synchronization framework 710 includes an interface module 711, a security module 712 and a processing module 713.

[0211] The interface module 711 is configured to interact with services on a terminal through notification.

[0212] Specifically, the interface module 711 is configured to provide an interface to services running on a terminal where the information synchronization framework 710 is located, so that the services can send a first notification to the framework by calling the interface, or receive a first notification reported by the framework through the interface module 711; the framework receives the first notification sent by the services through the interface module 711, or sends a first notification to the services.

[0213] The security module 712 is configured to verify the legitimacy of at least one of the notification, a user logged on the terminal, and the soft bus 720.

[0214] Specifically, the security module 712 can be configured to verify the legitimacy of the following dimensions (i.e., whether each dimension meets the corresponding condition described below):

[0215] The first notification is encrypted by using a preset encryption method.

[0216] The soft bus 720 meets a preset parameter.

[0217] The login user of the first terminal is the user indicated by the first notification, where the first terminal is the terminal where the information synchronization device is located.

[0218] In addition, the security module 712 can also screen other terminals that have published notification services on the soft bus 720 to determine a white list for cross-device information synchronization, for example, select a terminal that has the same login user as the login user of the first terminal from the terminals that have published notification services on the soft bus 720 and add the terminal into the white list, and send the devices in the white list to the processing module 713 as optional target devices for sending notifications.

[0219] The processing module 713 is configured to interact with other terminals that have published notification services on the soft bus 720.

[0220] Specifically, the processing module 713 can be configured to select a target terminal of the first notification (for example, a terminal running the same service as the service indicated by the first notification, or a terminal identical to the terminal indicated by the first notification), determine a distribution strategy, and send the first notification to the target terminal based on the soft bus 720, so that the target terminal reports the to-be-synchronized information carried in the first notification to the service indicated by the first notification.

[0221] The determination of the distribution strategy can include the following optional steps:

[0222] In response to the fact that the first terminal and any second terminal of the at least one second terminal have an information transmission channel based on the soft bus 720, the first notification is sent to the any second terminal through the information transmission channel.

[0223] The first notification is packaged and sent to the at least one second terminal according to a preset protocol provided by the soft bus 720.

[0224] The implementation process of the functions and roles of each module in the above device is specifically described in the implementation process of the corresponding steps in the above method, which will not be repeated here.

[0225] For the apparatus embodiments, since they basically correspond to the method embodiments, the relevant parts are referred to the part of the method embodiments. The apparatus embodiments described above are merely illustrative, wherein the modules described as separate components can or can not be physically separated, and the components shown as modules can or can not be physical modules, i.e., can be located in one place or distributed to multiple network modules. Some or all of the modules can be selected to achieve the purposes of the present disclosure according to actual needs. Those skilled in the art can understand and implement without creative effort.

[0226] In a sixth aspect, the embodiments of the information synchronization apparatus provided by the present disclosure can be applied to a computer device. Please refer to the accompanying drawings described above Figure 8 which shows an exemplary schematic diagram of a hardware of a computer device. For example, the device 800 can be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, etc.

[0227] The device 800 can include one or more of the following components: a processing component 801, a memory 802, a power supply component 803, a multimedia component 804, an audio component 805, an input / output (I / O) interface 806, a sensor component 807, and a communication component 808.

[0228] The processing component 801 usually controls overall operations of the device 800, such as operations associated with displaying, making phone calls, data communications, camera operations and recording operations. The processing component 801 can include one or more processors 809 to execute instructions to complete all or part of steps of the methods described above. Further, the processing component 801 can include one or more modules to facilitate the interaction between the processing component 801 and other components. For example, the processing component 801 can include a multimedia module to facilitate the interaction between the multimedia component 804 and the processing component 801.

[0229] The memory 802 is configured to store various types of data to support operations of the device 800. Examples of these data include instructions for any application or methods operating on the device 800, contact data, phonebook data, messages, pictures, videos, etc. The memory 802 can be implemented by any type of volatile or non-volatile storage devices or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk or optical disk.

[0230] Power component 803 provides power to the various components of device 800. Power component 803 can include a power supply management system, one or more power sources, and other components associated with generating, managing, and distributing power for device 800.

[0231] Multimedia component 804 includes a screen providing an output interface between device 800 and a user. In some embodiments, the screen can include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen can be implemented as a touch screen to receive an input signal from a user. The touch panel includes one or more touch sensors to sense a touch, slide, and gesture on the touch panel. The touch sensor can not only sense a boundary of a touching or sliding action, but also detect duration and pressure related to the touching or sliding action. In some embodiments, multimedia component 804 includes a front camera and / or a rear camera. When device 800 is in an operation mode, such as a shooting mode or a video mode, the front camera and / or the rear camera can receive external multimedia data. Each of the front and rear cameras can be a fixed optical lens system or have a focal length and optical zoom capability.

[0232] Audio component 805 is configured to output and / or input an audio signal. For example, audio component 805 includes a microphone (MIC) configured to receive an external audio signal when device 800 is in an operation mode, such as a call mode, a recording mode, and a voice recognition mode. The received audio signal can be further stored in memory 802 or transmitted via communication component 808. In some embodiments, audio component 805 also includes a speaker for outputting an audio signal.

[0233] I / O interface 806 provides an interface between processing component 801 and peripheral interface modules, which can be a keyboard, a click wheel, a button, and the like. The buttons can include, but are not limited to, a home button, a volume button, a start button, and a lock button.

[0234] The sensor component 807 includes one or more sensors for providing status assessments for various aspects of the device 800. For example, the sensor component 807 can detect an open / closed position of the device 800, relative positioning of components, such as a display and keypad of the device 800, changes in position of the device 800 or a component of the device 800, presence or absence of user contact with the device 800, orientation or acceleration / deceleration of the device 800, and temperature changes of the device 800. The sensor component 807 can also include proximity sensor(s) configured to detect presence of nearby objects without any physical contact. The sensor component 807 can further include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor component 807 can also include an acceleration sensor, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.

[0235] The communication component 808 is configured to facilitate wired or wireless communication between the device 800 and another device. The device 800 can access a wireless network based on a communication standard, such as WiFi, 2G or 3G, 4G or 5G, or a combination thereof. In an exemplary embodiment, the communication component 808 receives a broadcast signal or broadcast related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 808 further includes a Near Field Communication (NFC) module to facilitate short-range communication. For example, the NFC module can be implemented based on Radio Frequency Identification (RFID) technology, infrared data association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology and other technology.

[0236] In an exemplary embodiment, the device 800 can be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable gate arrays (FPGAs), controllers, micro-controllers, microprocessors or other electronic elements for performing the above-described method of determining a holding manner of an electronic device.

[0237] In a seventh aspect, the present disclosure also provides, in an exemplary embodiment, a non-transitory computer-readable storage medium including instructions, such as the memory 802 including instructions, which can be executed by the processor 809 of the device 800 to perform the above-described method of determining a holding manner of an electronic device. For example, the non-transitory computer-readable storage medium can be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disc, and an optical data storage device, etc.

[0238] The above describes particular embodiments of the present disclosure. Other embodiments are within the scope of the following claims. In some cases, acts or steps recited in the claims can be performed in a different order and still accomplish the desired results. Additionally, the processes depicted in the figures do not necessarily require the particular order shown or sequential order to achieve the desired results. In certain implementations, multitasking and parallel processing can be advantageous or necessary.

[0239] Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the features of the disclosure as set forth herein. It is intended that the disclosure be construed as including any patent, application, publication, or other disclosure by a third party, to the extent that the disclosure of such third party is herewith incorporated by reference or is not inconsistent with the general inventive concepts ascribed to the present disclosure. It is intended that the disclosure encompass all alternatives, modifications, and equivalents coming within the scope of the following claims.

[0240] It is to be understood that the present disclosure is not limited to the precise construction described above and as shown in the attached drawings, and that various modifications and changes can be made by those skilled in the art without departing from the scope of the present disclosure. The scope of the present disclosure is limited only by the claims that follow.

[0241] The above description is intended to be illustrative and not restrictive. Many other embodiments will be apparent to those of skill in the art upon reviewing the above description. The scope of the disclosure should, therefore, be determined not with reference to the above description, but instead with reference to the appended claims, along with their full scope of equivalents.

Claims

1. An information synchronization method, characterized by, Applied to a first terminal, the method includes: Receive a first notification sent by the first service, the first notification carrying information to be synchronized; The system acquires at least one second terminal that has published a notification service on the soft bus. The first terminal has published a notification service on the soft bus. The soft bus is used to determine the optimal communication medium between the terminals that have published a notification service on the soft bus based on the communication factors in the current environment, and to establish an information transmission channel between the terminals that have published a notification service based on the optimal communication medium. Based on the soft bus, the first notification is sent to the at least one second terminal.

2. The information synchronization method according to claim 1, characterized by, The acquisition of at least one second terminal that has published a notification service on the soft bus includes: At least one second terminal that has published a notification service on the soft bus is acquired when at least one of the following conditions is met: The first notification was encrypted using a preset encryption method; The soft bus meets preset parameters; The logged-in user of the first terminal is the user indicated in the first notification.

3. The information synchronization method according to claim 1, characterized by, The acquisition of at least one second terminal that has published a notification service on the soft bus includes: Among the multiple terminals that have published notification services on the soft bus, the terminal that meets at least one of the following conditions is selected as the second terminal: It runs a service that is the same as the first service; The logged-in user is the same as the user logged in on the first terminal; Consistent with the target terminal indicated in the first notification.

4. The information synchronization method according to claim 1, characterized by, Sending the first notification to the at least one second terminal includes: In response to the existence of an information transmission channel based on the soft bus between the first terminal and any one of the at least one second terminal, the first notification is sent to any one of the second terminals through the information transmission channel.

5. The information synchronization method of claim 1, wherein, Sending the first notification to the at least one second terminal includes: According to the preset protocol provided by the soft bus, the first notification is packaged and sent to the at least one second terminal.

6. The information synchronization method according to claim 5, characterized by, The step of packaging and sending the first notification to the at least one second terminal includes: The first notification and notifications sent by other services besides the first service are packaged and sent to the at least one second terminal, wherein the notifications sent by the other services are concurrent notifications of the first notification.

7. The information synchronization method of claim 1, wherein, The receipt of the first notification sent by the first service includes: Receive the first notification sent by the first service and add the first notification to the first message queue; Sending the first notification to the at least one second terminal includes: Send the notification contained in the first message queue to the at least one second terminal.

8. The information synchronization method according to claim 7, characterized by, The step of receiving the first notification sent by the first service and adding the first notification to the first message queue includes: Upon receiving multiple first notifications from the first service, the multiple first notifications are packaged and added to the first message queue.

9. The information synchronization method of claim 1, wherein, The first notification is sent by the first service calling a preset interface, wherein the preset interface is an interface provided by the framework that executes the information synchronization method.

10. An information synchronization method characterized by comprising: Applied to a second terminal, the method includes: The second terminal receives a first notification sent by a first terminal on a soft bus, the first notification carrying to-be-synchronized information, the second terminal having published a notification service on the soft bus, the soft bus being used to determine an optimal communication medium between terminals having published a notification service on the soft bus according to a communication factor in a current environment, and to establish an information transmission channel between the terminals having published the notification service based on the optimal communication medium; The second terminal reports the to-be-synchronized information to a second service, the second service being indicated by the first notification.

11. The information synchronization method according to claim 10, characterized by, The second terminal reports the to-be-synchronized information to a second service, the second service being indicated by the first notification. The second terminal adds the first notification into a second message queue. The second terminal reports to-be-synchronized information carried by a notification included in the second message queue to a second service.

12. The information synchronization method according to claim 10, characterized by, The method further includes: The second terminal unpacks the first notification according to a preset protocol provided by the soft bus.

13. An information synchronization apparatus, characterized by comprising: The apparatus applied to a first terminal includes: A first receiving module configured to receive a first notification sent by a first service, the first notification carrying to-be-synchronized information; A obtaining module configured to obtain at least one second terminal having published a notification service on a soft bus, the first terminal having published a notification service on the soft bus, the soft bus being used to determine an optimal communication medium between terminals having published a notification service on the soft bus according to a communication factor in a current environment, and to establish an information transmission channel between the terminals having published the notification service based on the optimal communication medium; A sending module configured to send the first notification to the at least one second terminal based on the soft bus.

14. An information synchronization apparatus, characterized by comprising: The apparatus applied to a second terminal includes: A second receiving module configured to receive a first notification sent by a first terminal on a soft bus, the first notification carrying to-be-synchronized information, the second terminal having published a notification service on the soft bus, the soft bus being used to determine an optimal communication medium between terminals having published a notification service on the soft bus according to a communication factor in a current environment, and to establish an information transmission channel between the terminals having published the notification service based on the optimal communication medium; A reporting module configured to report the to-be-synchronized information to a second service, the second service being indicated by the first notification.

15. An information synchronization apparatus, characterized by comprising: The apparatus includes: A soft bus configured to determine an optimal communication medium between terminals having published a notification service on the soft bus according to a communication factor in a current environment, and to establish an information transmission channel between the terminals having published the notification service based on the optimal communication medium; An information synchronization framework including an interface module, a security module, and a processing module; The interface module is configured to perform notification interaction with a service on a terminal, receive a first notification sent by the service, or send a first notification to the service; The security module is configured to verify the legality of at least one of the first notification, a user logged in on the terminal, and the soft bus; The processing module is configured to perform notification interaction with other terminals having published a notification service on the soft bus.

16. A computer device, comprising: A computer program product comprising a storage medium to store the program for a computer, wherein said program - which may be implemented in a processor - realizes the method of any of claims 1 to 12 when the program is executed by the processor.

17. A computer readable storage medium having stored thereon a computer program, characterized in that, The program is executed by a processor to realize the method of any of claims 1 to 12.

Citation Information

Patent Citations

  • Message board implementation method and device, equipment and storage medium

    CN115865946A

  • Multi-device collaboration method, electronic device, and multi-device collaboration system

    US20230345074A1