WO2023011645A1 - 数据处理方法及装置、电子设备及存储介质 - Google Patents

数据处理方法及装置、电子设备及存储介质 Download PDF

Info

Publication number
WO2023011645A1
WO2023011645A1 PCT/CN2022/110633 CN2022110633W WO2023011645A1 WO 2023011645 A1 WO2023011645 A1 WO 2023011645A1 CN 2022110633 W CN2022110633 W CN 2022110633W WO 2023011645 A1 WO2023011645 A1 WO 2023011645A1
Authority
WO
WIPO (PCT)
Prior art keywords
management item
entity object
management
data processing
processing method
Prior art date
Application number
PCT/CN2022/110633
Other languages
English (en)
French (fr)
Inventor
吴原野
Original Assignee
北京字跳网络技术有限公司
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 北京字跳网络技术有限公司 filed Critical 北京字跳网络技术有限公司
Publication of WO2023011645A1 publication Critical patent/WO2023011645A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/10Office automation; Time management
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/10Office automation; Time management
    • G06Q10/101Collaborative creation, e.g. joint development of products or services
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/10Office automation; Time management
    • G06Q10/105Human resources

Definitions

  • Embodiments of the present disclosure relate to a data processing method, a data processing device, electronic equipment, and a storage medium.
  • Data structures are the way computers store and organize data.
  • a data structure is a collection of data elements that have one or more specific relationships with each other. Often, well-chosen data structures can lead to higher operational or storage efficiency.
  • the selected data structure and the relationship between data structures affect the operating efficiency or flexibility of the upper-layer application based on the data structure.
  • At least one embodiment of the present disclosure provides a data processing method, the data processing method includes: creating a first management item for a first entity object and binding the first entity object to the first management item, the first entity object A management item includes first change information of the first entity object; creating at least one second management item for at least one second entity object and binding the at least one second entity object to the at least one first entity object respectively Two management items, the at least one second management item respectively includes the second change information of the corresponding at least one second entity object; based on the logic between the first entity object and the at least one second entity object relationship, establishing a first hierarchical relationship between the first management item and the at least one second management item; and according to the logical relationship between the first entity object and the at least one second entity object , maintaining the first-level relationship.
  • At least one embodiment of the present disclosure further provides a data processing device, the data processing device includes a first management item processing unit, a second management item processing unit, a hierarchical relationship establishment unit, and a hierarchical relationship maintenance unit;
  • the first management item processing The unit is configured to: create a first management item for the first entity object and bind the first entity object to the first management item, the first management item includes first change information of the first entity object
  • the second management item processing unit is configured to: respectively create at least one second management item for at least one second entity object and bind the at least one second entity object to the at least one second management item,
  • the at least one second management item respectively includes second change information of the corresponding at least one second entity object;
  • the hierarchical relationship establishment unit is configured to: based on the first entity object and the at least one second entity A logical relationship between objects, establishing a first hierarchical relationship between the first management item and the at least one second management item;
  • the hierarchical relationship maintenance unit is configured to: according to the first entity object and
  • At least one embodiment of the present disclosure also provides an electronic device, the electronic device includes a processor and a memory; the memory includes one or more computer-executable instructions; the one or more computer-executable instructions are stored in the stored in the memory and configured to be executed by the processor, the one or more computer-executable instructions are used to implement the data processing method described in any embodiment of the present disclosure.
  • At least one embodiment of the present disclosure further provides a storage medium for storing non-transitory computer-executable instructions, and any embodiment of the present disclosure can be implemented when the non-transitory computer-executable instructions are executed by a processor The data processing method described.
  • FIG. 1 is a system that can be used to implement the data processing method provided by an embodiment of the present disclosure
  • FIG. 2A is a schematic flowchart of a data processing method provided by some embodiments of the present disclosure
  • FIG. 2B is an exemplary schematic diagram of a client operation interface in some embodiments of the present disclosure.
  • Fig. 3 is a schematic diagram of a data structure provided by some embodiments of the present disclosure.
  • FIG. 4 is a schematic flowchart of another data processing method provided by some embodiments of the present disclosure.
  • Fig. 5 is a schematic diagram of another data structure provided by some embodiments of the present disclosure.
  • Fig. 6 is a schematic diagram of updating the second serial number of the target second management item provided by some embodiments of the present disclosure
  • FIG. 7 is a schematic flowchart of another data processing method provided by some embodiments of the present disclosure.
  • FIG. 8 is a schematic flowchart of a specific example of a data processing method provided by some embodiments of the present disclosure.
  • FIG. 9 is a schematic flowchart of step S51 in a data processing method provided by some embodiments of the present disclosure.
  • FIG. 10 is a schematic flowchart of another data processing method provided by some embodiments of the present disclosure.
  • Fig. 11 is a schematic diagram of another data structure provided by some embodiments of the present disclosure.
  • FIG. 12 is a schematic flowchart of step S65 in a data processing method provided by some embodiments of the present disclosure.
  • Fig. 13 is a schematic block diagram of a data processing device provided by some embodiments of the present disclosure.
  • Fig. 14 is a schematic block diagram of an electronic device provided by some embodiments of the present disclosure.
  • Fig. 15 is a schematic block diagram of another electronic device provided by some embodiments of the present disclosure.
  • Fig. 16 is a schematic diagram of a storage medium provided by some embodiments of the present disclosure.
  • the term “comprise” and its variations are open-ended, ie “including but not limited to”.
  • the term “based on” is “based at least in part on”.
  • the term “one embodiment” means “at least one embodiment”; the term “another embodiment” means “at least one further embodiment”; the term “some embodiments” means “at least some embodiments.” Relevant definitions of other terms will be given in the description below.
  • the relationship between users needs to be organized according to a certain level, for example, users are organized into groups, and users in the group, that is, group members, can exchange information with each other.
  • groups can also be organized as a team or a part of the team, and users in the group are also users in the team, that is, group members are also team members of the team.
  • the relationship between groups and teams can be changed.
  • the group to which it belongs can be added or deleted.
  • At least one embodiment of the present disclosure provides a data processing method, the data processing method includes: creating a first management item for a first entity object and binding the first entity object to the first management item, the first management item includes the first The first change information of the entity object; creating at least one second management item for at least one second entity object and binding the at least one second entity object to the at least one second management item respectively, and the at least one second management item respectively includes The second change information of the corresponding at least one second entity object; based on the logical relationship between the first entity object and the at least one second entity object, establish a first level between the first management item and the at least one second management item relationship; and maintaining the first hierarchical relationship according to the logical relationship between the first entity object and at least one second entity object.
  • the first management item and the second management item respectively store the first change information of the first entity object and the second change information of the second entity object, thus based on The first change information and the second change information respectively recorded in the first management item and the second management item can accurately and efficiently obtain the current version information of the corresponding first entity object and the second entity object, thereby helping to realize Processing operations such as organizing, storing, calling, and updating the data of the first entity object and the data of the second entity object stored in different terminals.
  • FIG. 1 is a system that can be used to implement the data processing method provided by the embodiment of the present disclosure.
  • the system 100 may include a user terminal 110 , a network 120 , a server 130 and a database 140 .
  • the system 100 can be used to implement the data processing method described in any embodiment of the present disclosure.
  • the user terminal 110 is, for example, a computer 110-1 or a mobile phone 110-2. It can be understood that the user terminal 110 may be any other type of electronic device capable of performing data processing, which may include but not limited to desktop computers, notebook computers, tablet computers, smart phones, smart home devices, wearable devices, vehicle electronic equipment, monitoring equipment, etc. The user terminal 110 may also be any equipment provided with electronic equipment, such as a vehicle, a robot, and the like.
  • the user can operate the application program installed on the user terminal 110 , the application program transmits the user behavior data to the server 130 through the network 120 , and the user terminal 110 can also receive the data transmitted by the server 130 through the network 120 .
  • the user terminal 110 may implement the data processing method provided by the embodiments of the present disclosure by running a program or a thread, for example, running a client part.
  • the user terminal 110 can utilize its built-in application program to execute the data processing method.
  • the user terminal 110 may execute the data processing method by invoking an application program stored externally on the user terminal 110 .
  • Network 120 may be a single network, or a combination of at least two different networks.
  • the network 120 may include but not limited to one or a combination of a local area network, a wide area network, a public network, a private network, and the like.
  • the server 130 can implement the data processing method provided by the embodiments of the present disclosure by running a program or a thread, and it can be a single server, or a server group (such as a cloud service), and each server in the server group is connected through a wired connection. or wireless network connection.
  • a server farm can be centralized, such as a data center, or distributed.
  • Server 130 may be local or remote.
  • the server 130 may communicate with the user terminal 110 through a wired or wireless network.
  • the server 130 can run the server in social software or online office software, centrally manage user data and be responsible for information transmission, etc., and for users to use the above social software or online office software through different user terminals
  • the server on the server 130 may also be responsible for partially synchronizing or fully synchronizing the user data recorded by the clients on these different user terminals 110, so that the user data recorded by the clients on these different user terminals 110 are exactly the same or are the same for at least part of the time period, so that it is convenient for users to use.
  • the database 140 may generally refer to a device having a storage function.
  • the database 140 is mainly used to store various data utilized, generated and output by the user terminal 110 and the server 130 in their work.
  • Database 140 may be local or remote.
  • the database 140 may include corresponding software and hardware, such as various memories, such as Random Access Memory (Random Access Memory, RAM), Read Only Memory (Read Only Memory, ROM) and the like.
  • RAM Random Access Memory
  • ROM Read Only Memory
  • the storage devices mentioned above are just some examples, and the storage devices that can be used by the system 100 are not limited thereto.
  • the database 140 may be connected or communicated with the server 130 or a part thereof via the network 120 , or be directly connected or communicated with the server 130 , or a combination of the above two methods.
  • database 140 may be a stand-alone device. In some other examples, the database 140 may also be integrated in at least one of the user terminal 110 and the server 130 . For example, the database 140 may be set on the user terminal 110 or on the server 130 . For another example, the database 140 may also be distributed, a part of which is set on the user terminal 110, and another part is set on the server 130, for example, it may also be a database running on the cloud.
  • Fig. 2A is a schematic flowchart of a data processing method provided by some embodiments of the present disclosure.
  • This data processing method can be applied to, for example, a server or a client.
  • the server runs on the server 130 in the system 100 shown in FIG.
  • the terminal 110 accesses the server and operates through the operation interface provided by the client on the user terminal 110 .
  • the data processing method can be applied to social applications, online office and other applications. Since the server centrally manages user data and is responsible for information transmission, etc., the following uses the data processing method applied to the server as an example to illustrate, and when it involves synchronization with the client, the corresponding description for the client is added.
  • the data processing method provided by the embodiment of the present disclosure includes step S11 to step S14 .
  • Step S11 Create a first management item for the first entity object and bind the first entity object to the first management item, where the first management item includes first change information of the first entity object.
  • Step S12 Create at least one second management item for at least one second entity object and bind at least one second entity object to at least one second management item, and at least one second management item includes at least one corresponding The second change information of the second entity object.
  • Step S13 Based on the logical relationship between the first entity object and at least one second entity object, establish a first hierarchical relationship between the first management item and the at least one second management item.
  • Step S14 Maintain the first hierarchical relationship according to the logical relationship between the first entity object and at least one second entity object.
  • the first hierarchical relationship is maintained according to the logical relationship between the first entity object and at least one second entity object, in some embodiments, based on the first hierarchical relationship, the first entity can be implemented on the client.
  • the visual presentation of objects and second entity objects and their logical relationships will be described in detail later.
  • Fig. 3 is a schematic diagram of a data structure provided by some embodiments of the present disclosure.
  • the data structure includes the first entity object, the second entity object, the first management item, the second management item, etc. in the above steps S11 to S14.
  • Each step in the data processing method shown in FIG. 2A will be described below in conjunction with the data structure shown in FIG. 3 .
  • the first entity object UT1 may be various appropriate types of entity objects, for example, it may be a collection of objects in social software or online office software, or it may be other entity objects, such as documents , schedule, etc.
  • the second entity object UT2 can be various appropriate types of entity objects, for example, it can be a collection of objects in social software or online office software, or it can be other entity objects, such as documents, schedules, etc.
  • the collection of objects in social software or online office software is a collection of multiple users, that is, multiple users, and these users are organized together for mutual information exchange and data sharing.
  • a certain association relationship may be established between different object sets, for example, the second object set may be subordinate to the first object set.
  • the second object set "belongs to" the first object set, which may mean that the operation authority that the second object set can perform is limited to the operation authority that the first object set can perform, or it can also mean that the second object set
  • the information transmission boundary or transmission range of is limited within the information transmission boundary or transmission range of the first object set.
  • a user may refer to a real person or entity who uses related equipment or network services, that is, a real user; Computer programs such as chatbots or service assistants used to provide services.
  • the first entity object UT1 is the "first object collection” and the second entity object UT2 is the "second object collection” as an example, wherein, logically, the second entity object UT2 is based on ( or subordinate to) the first entity object UT1.
  • the "first collection of objects” may represent or be understood as a “team” including multiple users; the “second collection of objects” may represent or be understood as a “group” including multiple users; ", for example, a chat group for the multiple users to exchange information such as text, pictures, voice, video, network links and other instant messaging in the group.
  • a "first user set” or “team” is created, which includes all employees of a company, and one or more “second user sets” or “groups” are created
  • groups in the company for example, the "company chat group” created by the general manager's office that includes all employees “Human resources group” of company employees, or for example, a "marketing department group” established by the marketing department including only marketing department members, a “technical department group” established by the technical department including only marketing department members, etc.
  • These groups belong to the team of the company, and in these groups, the respective members can chat, share information, etc.
  • the new employee when an employee resigns from the company, he will be deleted from all groups belonging to the company, or when a new employee enters the marketing department, the new employee will be added to the "company chat" which includes all employees of the company Group” and "Human Resources Group”, and will also be added to the "Marketing Group", but will not be added to the "Technical Group” and so on.
  • the team of the company defines the information exchange boundary of each group belonging to the company, for example, may further define the authority boundary of each group belonging to the company.
  • multiple "first user sets” or “teams” are created in the technical department, including the "product 1 team” of all employees who develop product 1, including all employees who develop product 2 Employee's "Product 2 Team” etc.
  • the "daily communication group” of all employees for example, corresponding to the team's default communication group), including the "module 1 communication group” of employees who develop module 1, the "module 2 communication group” of employees who develop module 2, etc. .
  • Employees in a technical department can belong to one or more teams in the corresponding online office software, and can belong to one or more groups within a certain team.
  • the one or more teams and one or more groups under each team can be listed at the same time, and corresponding information exchange can be carried out in these groups , share, etc. Since different employees may belong to different teams or belong to different groups in a certain team, different employees get different user interfaces when using the online office software.
  • FIG. 2B shows an example of a client operation interface of at least one embodiment of the present disclosure, and takes the aforementioned "product 1 team” and “product 2 team” as examples.
  • the operation page has a "team” operation tab (tab) for operating the team, and the teams to which the user belongs and the groups in each team are shown on the left side of the page.
  • the user belongs to at least "product 1 team” and “product 2 team", and "product 1 team” has “daily communication group", “module 1 communication group”, and “module 2 communication group”.
  • the “daily communication group” is selected (displayed in gray), and the chat window CHT corresponding to the "daily communication group” is shown on the right side of the page.
  • the upper side of the chat window CHT displays past information, such as the group For the information sent by other users USR1 and USR2 in the chat window, the input box INPT is displayed on the lower side of the chat window for users to input.
  • each team has one or more team administrators.
  • the team administrator is one of the team members and has various rights to manage the team, including adding and reducing team members, disbanding the team, and creating one or more groups in the team. Groups, for example, can also dissolve groups in the team, and for example, can have the permission to set a certain team member, etc.
  • the status of a team administrator can be transferred, that is, transferred to other team members in the team. Team members can perform various personalized settings for the team they belong to, such as setting a certain team to the top, setting the do not disturb function, and so on.
  • each group can have one or more group administrators.
  • the group administrator is one of the group members and has various rights to manage the group, but the rights of the management group are different in different application scenarios or requirements. Can be different. For example, in a situation where group members need to be the same as team members in the team they belong to (for example, group members are bound to team members), the group administrator does not have the right to add or delete group members.
  • the status of group administrator can be transferred, that is, transferred to other group members in the group.
  • Group members can be set to have different permissions for the group they belong to, such as the right to listen to information, send information, send network links, initiate online meetings, and share schedules, etc.; in addition, each group member can also perform Various personalized settings, such as pinning a certain group to the top (for example, pinning a certain group within a certain team), setting the do-not-disturb function, etc.
  • the first management item ITM1 includes the first change information of the first entity object UT1, for example, the first change information may include the current version information (version), historical version information, version change information, etc. of the first entity object UT1, so that Based on the first change information recorded in the first management item ITM1, it is used to assist in updating the data of the first entity object UT1.
  • the second management item ITM2 includes the second change information of the second entity object UT2, for example, the second change information may include the current version information, historical version information, version change information, etc. of the second entity object UT2, so it can be based on the second
  • the second change information recorded in the management item ITM2 is used to assist in updating the data of the second entity object UT2.
  • step S13 by establishing the first hierarchical relationship between the first management item ITM1 and the second management item ITM2, a data structure with the first management item ITM1 and the second management item ITM2 as data elements can be constructed. Moreover, since the first hierarchical relationship is established based on the logical relationship between the first entity object UT1 and the second entity object UT2, the hierarchical relationship or association relationship between the first entity object UT1 and the second entity object UT2 is also It can be reflected by the established first-level relationship.
  • the first hierarchical relationship between the first management item ITM1 and the second management item ITM2 may be the subordination relationship shown in FIG. 3, that is, the second management item ITM2 is subordinate to the first management item ITM1, thus forming the The tree structure shown in , with the first management item ITM1 and the second management item ITM2 as the parent node and child node respectively.
  • the first-level relationship between the first management item ITM1 and the second management item ITM2 can also be a parallel relationship, a link relationship, etc. , so that the first management item ITM1 and the second management item ITM2 form other types of data structures.
  • Fig. 3 shows two second entity objects UT2 and two second management items ITM2 created for the two second entity objects UT2, and these two second management items ITM2 are subordinate to The first management item ITM1.
  • the number of the second entity object UT2 and the corresponding second management item ITM2 may also be 1, 3, 4 or more, and multiple second management items ITM2
  • the hierarchical relationship between each and the first management item ITM1 may be the same as or different from each other, which is not specifically limited in the embodiments of the present disclosure.
  • step S14 after establishing the data structure with the first management item ITM1 and the second management item ITM2 as data elements respectively, it can be based on the change of the logical relationship between the first entity object UT1 and the second entity object UT2 , modify the first hierarchical relationship, so that the first hierarchical relationship between the first management item ITM1 and the second management item ITM2 is consistent with the logical relationship between the first entity object UT1 and the second entity object UT2 .
  • the data processing method there is no need to directly establish a hierarchical relationship or an association relationship between the first entity object UT1 and the second entity object UT2, but in the first entity object UT1 bound to the first entity object UT1 Establish a first hierarchical relationship between a management item ITM1 and a second management item ITM2 bound to the second entity object UT2, and then establish and manage the relationship between the first entity object UT1 and the second entity object UT2 through the first hierarchical relationship association.
  • the second entity object UT2 subordinate to the first entity object UT1 as an example, when the logical relationship between the first entity object UT1 and the second entity object UT2 changes, for example, the second entity object UT2 is no longer subordinate to the first entity object
  • an entity object UT1 for the situation of directly establishing a hierarchical relationship between the first entity object UT1 and the second entity object UT2
  • the above-mentioned access update operation may generate a large amount of data calculation, resulting in a serious reduction in data processing speed and processing efficiency.
  • the data processing method provided by the embodiment of the present disclosure, when the logical relationship between the first entity object UT1 and the second entity object UT2 changes, you can modify the relationship between the first management item ITM1 and the second management item ITM2
  • the first hierarchical relationship between the first entity object UT1 and the second entity object UT2 is implemented to change the hierarchical relationship or association relationship between the first entity object UT1 and the second entity object UT2 without accessing or modifying the data of the first entity object UT1 and/or the second entity object UT2, Therefore, the required calculation amount is reduced, and the data processing speed and data processing efficiency are improved.
  • the first management item ITM1 and the second management item ITM2 respectively store the first change information of the first entity object UT1 and the second change information of the second entity object UT2 , based on the first change information and second change information respectively recorded in the first management item ITM1 and the second management item ITM2, the corresponding first entity object UT1 and second entity object UT2, for example version change information, so as to reduce the amount of calculation required for updating the first entity object UT1 and the second entity object UT2.
  • the first entity object UT1 and the first management item ITM1 are stored separately from each other, that is, the first management item ITM1 is stored independently of the first entity object UT1 and has different storage addresses; the second entity object UT2 and the second The management items ITM2 are stored separately from each other, that is, the second management item ITM2 is stored independently of the second entity object UT2 and has different storage addresses.
  • the first entity object corresponds to "team”
  • it can be stored and processed by the same team service module (providing team management services, for example, it can also be called a team server) with other entity objects corresponding to "team”
  • the second entity object corresponds to "group”
  • it can be stored by the same group service module (providing group management service, for example, it can also be called a group server) with other entity objects corresponding to "group”. and processed;
  • the first management item and the second management item may be stored and processed together with other management items by a management item service module (providing management item services, for example, may also be called a management item server).
  • the team service module, the group service module and the management item service module may run on different device hardware, or run on the same hardware device.
  • the server can also include a message gateway (im-gateway), which is used to receive messages from the client, or distribute server messages from the server to the client, to achieve data exchange and synchronization between the server and the client, such as server The message includes update information, user operation instruction feedback, and the like.
  • the client may also include a message gateway, which is used to receive messages from the server, or send client messages from the client to the server, where the client messages include operations input by the user through the operation interface on the client Instructions, these operating instructions include input information, sending picture information, creating groups, setting user attributes, etc.
  • an SDK Software Development Kit, software development kit
  • a server and/or client may be provided at the server and/or client to implement a corresponding data processing method.
  • the data of the first management item ITM1 and the data of the second management item ITM2 need to be modified.
  • the first entity object UT1 and the second entity When the logical relationship between objects UT2 changes, it is only necessary to access, call or modify the corresponding data of the first management item ITM1 and the second management item ITM2, thereby reducing the amount of calculation required and improving the data processing speed and data processing efficiency.
  • the embodiments of the present disclosure do not specifically limit the data type, storage structure, and stored data content of the first entity object UT1, the second entity object UT2, the first management item ITM1, and the second management item ITM2.
  • each of the first management item ITM1 and the second management item ITM2 may have these attributes: self identification number (id), bound entity object ID (entity_id), bound entity object type (entity_type), parent node Identification number (parent_id), status (status or is_deleted), etc.
  • the status value of the management item is changed, for example, 0 means valid and 1 means deleted.
  • the first entity object UT1 corresponds to a team, and it can have these attributes: the team's own identification number (team_id), and other attributes related to the team;
  • the second entity object UT2 corresponds to a group, and it can have these attributes: group The group's own identification number (chat_id), and other attributes related to the group.
  • each of the first entity object UT1 and the second entity object UT2 may correspond to one of the social application programs containing multiple user members group.
  • the first entity object UT1 may be a first user group including multiple user members
  • the second entity object UT2 may be a second user group including multiple user members.
  • the second user group is a subset of the first user group, that is, all user members of the second user group are included in the Within the user membership of a user group.
  • the type of the first entity object UT1 may be different from the type of the second entity object UT2.
  • the establishment and maintenance of the association relationship or hierarchical relationship between different types of entity objects can be optimized, reducing the need for different
  • the amount of calculation required for accessing, calling or modifying the data of a type of entity object improves the data processing speed and data processing efficiency.
  • the second entity object UT2 is subordinate to the first entity object UT1 .
  • the first management item ITM1 serves as a parent node
  • the second management item ITM2 is a child node of the parent node.
  • the entity_id of the first management item ITM1 is changed to the team_id of the first entity object UT1
  • the entity_type of the first management item ITM1 is changed to This is the type of the first entity object UT1, namely the team.
  • the entity_id of the second management item ITM2 is changed to the chat_id of the second entity object UT2, and the entity_type of the second management item ITM2 is changed to the second The type of entity object UT2, that is, group.
  • the parent_id of the second management item ITM2 is changed to the id of the first management item ITM1.
  • some embodiments of the present disclosure take the tree structure composed of the first management item ITM1 and the second management item ITM2 shown in FIG. illustrate.
  • the data processing method provided by the embodiment of the present disclosure further includes the following step S21.
  • Step S21 Update the first change information of the first management item.
  • the current version information, historical version information, or version change information of the first entity object can be recorded in the first management item by updating the first change information, so as to facilitate Subsequently, the first entity object is updated based on the first change information.
  • the data processing method provided by the embodiment of the present disclosure further includes the following step S22.
  • Step S22 updating the second change information of the second management item.
  • the current version information, historical version information, or version change information of the second entity object can be recorded in the second management item by updating the second change information, so as to facilitate Subsequently, the second entity object is updated based on the second change information.
  • the first change information includes a first sequence number for recording version change information of the first entity object
  • the second change information includes a second sequence number for recording version change information of the second entity object.
  • the above-mentioned first serial number and second serial number may be a number or a group of numbers used to reflect the change information of the corresponding entity object, such as a version number, a change operation number, or a number of changes.
  • the first serial number and the second serial number may include numbers, letters, identifiers and the like.
  • the above step S21 may include: performing an increment operation on the first serial number to update the first serial number. For example, when the first entity object is changed, an incremental operation is performed on the first sequence number, such as adding 1 to the first sequence number, thereby improving the update efficiency of the first change information, improving data processing speed and data processing efficiency .
  • step S22 may include the following steps S221 and S222.
  • Step S221 Determine the currently updated target second management item.
  • Step S222 Incrementing the second serial number of the target second management item to update the second serial number of the target second management item.
  • the second management item is the target second management item.
  • the second sequence number of the corresponding target second management item can be increased by incrementing the second sequence number of the corresponding target second management item, for example, adding 1 to the second sequence number. Change the update efficiency of information, thereby improving data processing speed and data processing efficiency.
  • the second serial numbers of multiple second management items are different from each other and are not reused.
  • the second serial number of the target second management item is different from the second serial number of any other second management item.
  • the second serial number of the target second management item is incremented according to the preset increment value, if the second serial number of the target second management item after the increment operation is the same as any other second management item If the second serial number of the target second management item is the same, continue to increment the second serial number of the target second management item until it is different from the second serial number of any other second management item.
  • Fig. 4 is a schematic flowchart of another data processing method provided by some embodiments of the present disclosure. It should be noted that, except for step S34, steps S31 to S33 and step S35 are basically the same as or similar to steps S11 to S14 in the data processing method shown in FIG. Reference may be made to the relevant descriptions corresponding to steps S11 to S14 shown in FIG. 2A in the above embodiment of the data processing method, and repeated descriptions will not be repeated.
  • Fig. 5 is a schematic diagram of another data structure provided by some embodiments of the present disclosure. It should be noted that, except for the change information management item ITMLST, the data structure shown in FIG. 5 is basically the same or similar to the data structure shown in FIG. 3 , and repeated descriptions will not be repeated.
  • the data processing method includes the following steps S31 to S35.
  • Step S31 Create a first management item for the first entity object and bind the first entity object to the first management item, where the first management item includes first change information of the first entity object.
  • Step S32 Create a plurality of second management items for the plurality of second entity objects and bind the plurality of second entity objects to the plurality of second management items respectively.
  • the plurality of second management items respectively include corresponding plurality of second management items.
  • Step S33 Based on the logical relationship between the first entity object and the multiple second entity objects, establish a first hierarchical relationship between the first management item and the multiple second management items.
  • Step S34 Create a change information management entry for the first management item, the change information management entry includes a change sequence number, and the change sequence number represents the largest second sequence number among the second sequence numbers of multiple second management items.
  • Step S35 Maintain the first hierarchical relationship according to the logical relationship between the first entity object and multiple second entity objects.
  • a change information management entry ITMLST may be created for the first management item ITM1, To record the largest second serial number among the second serial numbers of multiple second management items ITM2, so that when updating the second serial number of the target second management item, it can be based on the change information in the management entry ITMLST to optimize the specific operation process for performing incremental operations on the second serial number of the target second management item.
  • the change information management entry corresponding to each management item can also be stored and managed separately.
  • the change information management entry can include these attributes: the corresponding management item ID (item_id), the version of the management item itself (version), the maximum version (Max_version) of the sub-node of the management item, etc.; here, when the management item corresponding to the change information management entry has no sub-node, the maximum version (Max_version) of the sub-node of the management item can be absent or set to the default value (eg 0).
  • the first serial number of the first management item and the second serial number of the second management item correspond to the version (version) attribute of the management item itself, for example, a natural number (for example, int64 type).
  • Fig. 6 is a schematic diagram of updating a second serial number of a target second management item provided by some embodiments of the present disclosure.
  • the first management item ITM1 includes a first serial number N1
  • the two second management items ITM21 and ITM22 include second serial numbers N21 and N22 that are different from each other
  • the change information management item ITMLST includes a change sequence No. NCG.
  • the change sequence number NCG of the above-mentioned change information management entry ITMLST corresponds to the maximum version (Max_version) of the above-mentioned management item sub-node, for example, a natural number (for example, int64 type).
  • the increment operation on the second serial number of the target second management item in the above step S222 may include the following step S2221 .
  • Step S2221 Obtain the change sequence number NCG, and update the second sequence number N21 of the target second management item ITM21 to the sum of the change sequence number NCG and a predetermined increment.
  • the second sequence numbers N21 and N22 of the second management items ITM21 and ITM22 are 1 and 2 respectively, and the change sequence numbers NCG of the change information management entry ITMLST are 1 and 2.
  • the largest second serial number of which is 2.
  • the increment operation on the second serial number of the target second management item in the above step S222 further includes the following step S2222.
  • Step S2222 After updating the second serial number N21 of the target second managed item ITM21, update the changed serial number NCG to the second serial number N21 of the target second managed item ITM21.
  • the change sequence number NCG is also updated to 3, so that the change sequence number NCG can always be consistent with the second management item
  • the largest second serial number among the second serial numbers N21 and N22 of items ITM21 and ITM22 is consistent.
  • the first sequence number N1 of the first management item ITM1 is 1.
  • the first serial number N1 of the first management item ITM1 does not need to change accordingly.
  • the first serial number N1 of the first management item ITM1 there is no direct relationship between the first serial number N1 of the first management item ITM1 and the second serial number N21 of the second management item ITM21 or the second serial number N22 of the second management item ITM22, so the first management item ITM1
  • the first serial number N1 of the first management item ITM1 does not need to respond to the update of the second serial number N21 or N22, and in the process of numbering the first serial number N1 of the first management item ITM1, the second serial number N21 or N22 can be used same number.
  • the above data processing methods may be applied to the server and the client respectively.
  • the server records and maintains the user's full amount of data on the first entity object, the second entity object, the first management item, the second management item, etc.
  • a client of the user records and maintains The copy of the client for the first entity object, the second entity object, the first management item, the second management item, etc. is maintained. Realize data transmission between the server and the client through the network, and realize the synchronous update of the data stored on the server and the client about the first entity object, the second entity object, the first management item, the second management item, etc. . Therefore, even when users use corresponding software through different clients, they can obtain all past historical information or a selected part of historical information.
  • Fig. 7 is a schematic flowchart of another data processing method provided by some embodiments of the present disclosure. It should be noted that, except for steps S44 to S47, steps S41 to S43 and step S48 are basically the same as or similar to steps S11 to S14 in the data processing method shown in FIG. 2A respectively. Regarding steps S41 to S43 and step S48 For specific descriptions, reference may be made to the relevant descriptions corresponding to steps S11 to S14 shown in FIG. 2A in the above embodiment of the data processing method, and repeated descriptions will not be repeated.
  • the data processing method includes the following steps S41 to S48.
  • Step S41 Create a first management item for the first entity object and bind the first entity object to the first management item, where the first management item includes first change information of the first entity object.
  • Step S42 Create a plurality of second management items for the plurality of second entity objects and bind the plurality of second entity objects to the plurality of second management items respectively, and the plurality of second management items respectively include corresponding plurality of second management items The second change information of the entity object.
  • Step S43 Based on the logical relationship between the first entity object and the multiple second entity objects, establish a first hierarchical relationship between the first management item and the multiple second management items.
  • Step S44 Process the first entity object, the first management item, the second entity object, the second management item, and the first hierarchical relationship through the server.
  • Step S45 The client processes the copy of the first entity object, the copy of the first management item, the copy of the second entity object, the copy of the second management item and the copy of the first hierarchical relationship.
  • Step S46 allowing the client to provide the received instruction to the server for updating the first entity object, the first management item, the second entity object, the second management item or the first hierarchical relationship through the server.
  • Step S47 Allow the client to request synchronization from the server to update the copy of the first entity object, the copy of the first management item, the copy of the second entity object, the copy of the second management item and the first level A copy of the relationship.
  • Step S48 Maintain the first hierarchical relationship according to the logical relationship between the first entity object and multiple second entity objects.
  • the server stores the first entity object, the first management item, the second entity object, the second management item, and the first hierarchical relationship, that is, stores information about the first entity object, The first management item, the second entity object, the second management item, and the first data of the first hierarchical relationship;
  • the client stores a copy of the first entity object, a copy of the first management item, a copy of the second entity object,
  • the copy of the second management item and the copy of the first hierarchical relationship store the second data about the first entity object, the first management item, the second entity object, the second management item and the first hierarchical relationship.
  • the client receives an update instruction
  • the client updates the stored second data, and provides the received update instruction to the server, so that the server updates the stored first data synchronously, so that the service
  • the first data on the client is consistent with the second data on the client.
  • the client may perform the above operations by running a program or thread, or may use its built-in application or call an application stored externally on the client to perform the above operations, which is not specifically limited in the embodiments of the present disclosure.
  • steps S44 to S47 may also be performed after step S48, so that the first data on the server and the second data on the client can be kept in sync.
  • Fig. 8 is a schematic flowchart of a specific example of a data processing method provided by some embodiments of the present disclosure.
  • the server SERV includes a first entity object service module SERV1 , a second entity object service module SERV2 and a management item service module SERV3 .
  • the first entity object service module SERV1 sends a first creation request RQ1 to the management item service module SERV3, and the management item service module SERV3 creates a first management item for the first entity object in response to the first creation request RQ1 and binds the first entity object To the first management item, that is, to execute, for example, step S11 shown in FIG. 2A above.
  • the second entity object service module SERV2 sends a second creation request RQ2 to the management item service module SERV3, and the management item service module SERV3 creates a second management item for the second entity object in response to the second creation request RQ2 and binds the second entity object To the second management item, that is, to execute, for example, step S12 shown in FIG. 2A above.
  • the management item service module SERV3 establishes and maintains the first hierarchical relationship based on the logical relationship between the first entity object and the second entity object, that is, executes steps S13 and S14 shown in FIG. 2A , for example.
  • the client can implement local data management and maintenance on the client through the first entity object service module SERV1, the second entity object service module SERV2, and the management item service module SERV3 corresponding to the server .
  • the client and the server when synchronizing between the client and the server, in response to the fact that the first management item is the parent node of the second management item in the first hierarchical relationship, firstly synchronize the first management item with the second management item A copy of the management item, and then synchronize the copy of the second management item with the second management item. That is, when the first hierarchical relationship between the first management item and the second management item is, for example, the second management item as shown in FIG. The item is synchronized with the copy of the first management item stored on the client, and then the second management item stored on the server is synchronized with the copy of the second management item stored on the client.
  • the data processing operation can be optimized processes to improve data processing efficiency.
  • the synchronization order of the multiple child nodes may be determined according to data of multiple second entity objects corresponding to the multiple child nodes. For example, taking the first entity object bound to the first management item as the above-mentioned team as an example, the default communication group of the team is a second entity object, and the second entity object (also That is, the sub-nodes corresponding to the default communication group) are synchronized.
  • the data processing method further includes the following step S51.
  • Step S51 Synchronize the client based on the change information management entry.
  • the first sequence number N1 of the copy of the first management item ITM1 stored on the client and the first management item ITM1 stored on the server The first sequence number N1 of the item ITM1, after synchronizing the copy of the first management item ITM1 with the first management item ITM1, if the change sequence number NCG in the copy of the change information management item ITMLST stored on the client is the same as that on the server
  • the change sequence number NCG in the stored change information management entry ITMLST is the same, then there is no need to update the copy of the second management item ITM2 stored on the client and the second management item ITM2 stored on the server;
  • the change sequence number NCG in the copy of the change information management entry ITMLST is different from the change sequence number NCG in the change information management entry ITMLST stored on the server, so it needs to be based on the change sequence in the change information management entry ITMLST stored on the server NCG and the second change sequence number of the copy of
  • the second modification sequence number is the second management item ITM2 of 4, and synchronously update the copy of the corresponding second management item ITM2 on the client, without synchronously updating the copies of other second management item ITM2 on the client, Furthermore, the operation process of data processing is optimized, and the efficiency of data processing is improved.
  • the second change serial number of the copy of the corresponding second management item ITM2 becomes 4, and accordingly, the change information management entry stored on the client
  • the change sequence number NCG in the copy of the ITMLST also becomes 4, that is, it is the same as the change sequence number NCG in the change information management entry ITMLST stored on the server.
  • Fig. 9 is a schematic flowchart of step S51 in a data processing method provided by some embodiments of the present disclosure.
  • the above step S51 includes the following steps S511 to S513.
  • Step S511 Determine the current target client for synchronization.
  • Step S512 Accept the target client's request for first synchronization.
  • Step S513 After the first synchronization is performed on the target client from the server, the server records the change sequence number sent by the server to the target client in the first synchronization as the latest change sequence number of the client, and records the change sequence number of the target client on the target client.
  • the change sequence number sent by the server to the target client in a synchronization is recorded as the maximum change sequence number of the client.
  • the server when data synchronization is performed between the server and multiple clients through the network, it is necessary to determine among the multiple clients that the current synchronization client is the target client. For example, when the server only needs to maintain data synchronization with one client, then in response to the first synchronization request of the one client, it is determined that the one client is the target client.
  • the target client performs the first synchronization based on the change information management entries currently stored on the server.
  • the server records the change sequence number sent to the target client in the first synchronization as the latest change sequence number MAXCLT of the client, and the target client records the change sequence number sent by the server in the first synchronization as Client maximum change sequence number MAX.
  • step S51 further includes the following steps S514 to S518 .
  • Step S514 Accept the target client's request for second synchronization, where the second synchronization is adjacent to the first synchronization in time.
  • Step S515 Send the client terminal's most recently changed serial number and the server's changed serial number when accepting the second synchronization request from the server to the target client.
  • Step S516 The target client compares the latest serial number of the client with the maximum serial number of the client.
  • Step S517 Perform second synchronization on the target client according to the maximum change sequence number of the client and the change sequence number sent by the server.
  • Step S518 The target client is not limited to the maximum change sequence number of the client to perform the second synchronization.
  • the second synchronization is close to the first synchronization in time, that is, between the first synchronization and the second synchronization, no other data synchronization has been performed between the target client and the server.
  • the server accepts the second synchronization request from the target client, the server sends the stored target client’s latest change sequence number MAXCLT to the target client, and the target client combines the stored client maximum change sequence number MAX with The client's latest change sequence number MAXCLT sent by the server is compared.
  • step S517 is performed, and the second synchronization is carried out according to the current change sequence numbers on the server and the target client; if the latest change sequence number MAXCLT of the client is equal to If the maximum change sequence number MAX of the client is different, step S518 is executed, for example, according to the current change sequence number on the server, the copy of each second management item on the client is globally synchronized, that is, the copy of the second management item on the client is The copies of each second managed item are synchronized to avoid data loss or errors on the client.
  • Fig. 10 is a schematic flowchart of another data processing method provided by some embodiments of the present disclosure. It should be noted that, except steps S64 and S65, steps S61 to S63 and step S66 are basically the same as or similar to steps S11 to S14 in the data processing method shown in FIG. For specific descriptions, reference may be made to the relevant descriptions corresponding to steps S11 to S14 shown in FIG. 2A in the above embodiment of the data processing method, and repeated descriptions will not be repeated.
  • Fig. 11 is a schematic diagram of another data structure provided by some embodiments of the present disclosure. It should be noted that, except for the first sequence entry ITMORD and the change information management entry ITMLST, the data structure shown in FIG. 11 is basically the same or similar to the data structure shown in FIG. 3 , or, except for the first sequence entry ITMORD, the The data structure shown in 11 is basically the same or similar to the data structure shown in FIG. 5 , and repeated descriptions will not be repeated here.
  • the data processing method includes the following steps S61 to S64 and step S66.
  • Step S61 Create a first management item for the first entity object and bind the first entity object to the first management item, where the first management item includes first change information of the first entity object.
  • Step S62 Create a plurality of second management items for the plurality of second entity objects and bind the plurality of second entity objects to the plurality of second management items respectively, and the plurality of second management items respectively include corresponding plurality of second management items The second change information of the entity object.
  • Step S63 Based on the logical relationship between the first entity object and the multiple second entity objects, establish a first hierarchical relationship between the first management item and the multiple second management items.
  • Step S64 Create a plurality of first order entries for the plurality of second management items, for recording the first order information among the plurality of second management items.
  • Step S66 Maintain the first hierarchical relationship according to the logical relationship between the first entity object and multiple second entity objects.
  • the data processing method further includes the following step S65.
  • Step S65 Perform a first sort among the multiple second management items according to the multiple first sequence entries.
  • the first sequence entry ITMORD may include the first sorting type information and/or the first sorting weight information of the corresponding second management item ITM2, so that according to different actual needs, according to the first
  • the information in the first sequence entry ITMORD of the second management item ITM2 adopts a different ordering method for the second management item ITM2.
  • the first sorting can be performed according to the creation time of the second management item ITM2, or according to the weight of the second entity object UT2 corresponding to the second management item ITM2
  • the first sorting, etc., are not specifically limited in the embodiments of the present disclosure.
  • Fig. 12 is a schematic flowchart of step S65 in a data processing method provided by some embodiments of the present disclosure.
  • the above step S65 may include the following step S651.
  • Step S651 Based on the first sorting type information and/or the first sorting weight information corresponding to the multiple second management items, perform a first sorting among the multiple second management items.
  • the first sorting type information in step S651 may include the creation time, name character or update time of the second management item.
  • step S65 may also include the following step S652.
  • Step S652 assigning sequential identification numbers to each of the multiple second management items after the first sorting, and at least two of the multiple sequential identification numbers corresponding to the multiple second management items after the first sorting are not sequentially incremented.
  • the multiple sequence identification numbers corresponding to the multiple second management items are incremented according to a predetermined interval, and the predetermined interval is greater than 1.
  • the above step S65 may further include the following step S653.
  • Step S653 After re-performing the first sort, determine the arithmetic difference between the sequence identification numbers of the new second management item and the two immediately adjacent second management items in the first sort.
  • the sequence identification number of the new second management item is determined as the sequence identification number of the immediately preceding second management item in the first sorting and the predetermined sum of offsets.
  • the predetermined offset is greater than or equal to 1 and smaller than the predetermined interval.
  • the sequence identification numbers set for the second management item can be processed at certain predetermined intervals, for example, the sequence identification numbers of multiple second management items can be set to 0, 1024, 2048, 3072, etc., and so on. In this way, when a new second management item is inserted between two adjacent second management items, it is only necessary to mark the sequence identification number of the newly inserted second management item as, for example, 512, thereby reducing the required calculations volume to improve data processing efficiency.
  • sequence identification numbers between two adjacent second management items are already occupied, for example, take the sequence identification numbers 0, 1, 2, 8, 256, 512 as an example, where between 0 and 2 are Unable to add new sequence ID's. If it is necessary to insert a new second management item between the two second management items corresponding to sequence identification numbers 0 and 1, all second management items after the second management item corresponding to sequence identification number 0 need to be Offset performs an offset operation, and the predetermined offset is greater than or equal to 1 and smaller than the predetermined interval.
  • the sequence identification numbers of the second management items that need to be offset are sequentially incremented according to the predetermined offset until the next If the difference between the sequence identification number and the current sequence identification number is less than the predetermined offset, the above offset operation may be repeated.
  • the generated new sequence identification numbers are: 0, 8, 16, 24, 32, 256, 512.
  • the data processing method further includes the following step S71.
  • Step S71 Create a plurality of second order entries for the plurality of second management items respectively, for recording second order information among the plurality of second management items, the second order information being different from the first order information.
  • the data processing method further includes the following step S72.
  • Step S72 Perform a second sort among the multiple second management items according to the multiple second sequence entries.
  • the plurality of second sequence entries respectively include second sorting type information and/or second sorting weight information of the corresponding second management item. Therefore, based on the second sorting information different from the first sorting information, a second sorting can be performed among multiple second order items to obtain a different order from that after the first sorting, thereby improving multiple second order items.
  • the flexibility and diversity of the sorting methods between items can meet different actual needs and be applicable to different application scenarios.
  • the above step S72 may include: performing a second sort among the multiple second management items based on the second sort type information and/or the second sort weight information corresponding to the multiple second management items. In this way, a plurality of second management items after the second sorting is obtained.
  • the second management item includes node identification information
  • the node identification information may be used to represent the first hierarchical relationship between the second management item and the first management item, for example It is used to indicate that the second management item is subordinate to the first management item.
  • the node identification information may include structural information that the second management item points to the first management item.
  • the data processing method further includes: in response to establishing the first hierarchical relationship between the first management item and the second management item, updating the node identification information of the second management item to point to The first management item.
  • the first hierarchical relationship is recorded with the node identification information passing through the second management item.
  • the node identification information can also be updated to realize the change of the first hierarchical relationship.
  • the above step S11 shown in FIG. 2A may include the following step S110.
  • Step S110 Create a first management item based on the data of the first entity object according to a predetermined management item template.
  • the above step S12 shown in FIG. 2A may include the following step S120.
  • Step S120 Create a second management item based on the data of the second entity object according to a predetermined management item template.
  • the management item template includes identification information items and type information items, etc., which may correspond to the above-mentioned identification number (id) and the bound entity object type (entity_type) respectively, and the identification information items are used to record the information bound to the management item.
  • the identification information of the entity object, and the type information item is used to record the type information of the entity object bound to the management item.
  • the management item template may also include data items corresponding to the bound entity object ID (entity_id), parent node identification number (parent_id), status (status or is_deleted), and so on.
  • the management item service module uses the management item template to generate a new management item and assigns a value to the newly generated management item. associated.
  • the above step S14 shown in FIG. 2A may include the following step S141.
  • Step S141 Modify the first hierarchical relationship.
  • the first level relationship between the first management item and the second management item can be modified to achieve The change of the hierarchical relationship or association relationship between entity objects does not need to access or modify the data of the first entity object and/or the second entity object, thereby reducing the required calculation amount and improving the data processing speed and data processing efficiency.
  • the logical relationship change may include that the first entity object is deleted, so that there is no association relationship between the first entity object and the second entity object, for example, the logical relationship change may also include that each second entity object is deleted, so that There is no association relationship between the first entity object and any second entity object.
  • modifying the first hierarchical relationship in the above step S141 may include: canceling the first hierarchical relationship.
  • the release of the association relationship or hierarchical relationship between the first entity object and the second entity object can be realized without modifying the data of the first entity object and the second entity object, thereby reducing the distance between different entity objects. It improves the speed and efficiency of data processing, and also helps to optimize the data structure.
  • the above step S14 shown in FIG. 2A may include the following step S142.
  • Step S142 Update the first-level relationship.
  • the number of second entity objects increases, by creating corresponding second management items for the newly added second entity objects, and establishing a first-level relationship between the second management items, it is possible to implement An update of the data structure formed by the first management item and the second management item.
  • the number of second entity objects decreases, for example, when a certain second entity object is deleted, release the second management item corresponding to the second entity object (for example, the second management item to be operated) from the first management
  • the first hierarchical relationship between the items is deleted, and the corresponding second management item is deleted, thereby realizing the update of the data structure formed by the first management item and the second management item.
  • the data processing method further includes: modifying the first Data of entity objects such that the second set of objects is a subset of the first set of objects.
  • each of the first entity object and the second entity object may correspond to a set including multiple user members in the social application program.
  • the first entity object may be a first user collection including multiple user members, that is, the first object collection;
  • the second entity object may be a second user collection including multiple user members, that is, the second object gather.
  • the second user set is a subset of the first user set, that is, all user members of the second user set are included in the user members of the first user set Inside.
  • members of a first set of objects may remain the same as members of a second set of objects.
  • the flow of the data processing method provided in the foregoing embodiments of the present disclosure may include more or less operations, and these operations may be executed sequentially or in parallel.
  • the flow of the data processing method described above includes multiple operations appearing in a specific order, it should be clearly understood that the sequence of the multiple operations is not limited.
  • the data processing method described above may be performed once, or may be performed multiple times according to predetermined conditions.
  • At least one embodiment of the present disclosure further provides a data processing device, the data processing device includes a first management item processing unit, a second management item processing unit, a hierarchical relationship establishment unit, and a hierarchical relationship maintenance unit; the configuration of the first management item processing unit To: create a first management item for the first entity object and bind the first entity object to the first management item, the first management item includes the first change information of the first entity object; the second management item processing unit is configured to: Create at least one second management item for at least one second entity object and bind at least one second entity object to at least one second management item respectively, at least one second management item respectively includes corresponding at least one second entity object The second change information; the hierarchical relationship establishment unit is configured to: establish a first hierarchical relationship between the first management item and at least one second management item based on the logical relationship between the first entity object and at least one second entity object The hierarchical relationship maintenance unit is configured to: maintain the first hierarchical relationship according to the logical relationship between the first entity object and at least one second entity
  • the data processing device binds the first entity object to the first management item independent of the first entity object, and binds the second entity object to the second management item independent of the second entity object. item, and establish a first-level relationship between the first management item and the second management item, so that the change of the association relationship between the first entity object and the second entity object can be modified by modifying the first-level relationship Realization, thereby reducing the amount of calculation required when the logical relationship between different entity objects changes, improving data processing speed and data processing efficiency, and also helping to optimize the data structure and improve the flexibility of upper-layer applications.
  • Fig. 13 is a schematic block diagram of a data processing device provided by some embodiments of the present disclosure.
  • the data processing apparatus 600 includes a first management item processing unit 601 , a second management item processing unit 602 , a hierarchical relationship establishment unit 603 and a hierarchical relationship maintenance unit 604 .
  • the first management item processing unit 601 is configured to: create a first management item for the first entity object and bind the first entity object to the first management item, where the first management item includes first change information of the first entity object.
  • the first management item processing unit 601 may execute step S11 in the data processing method shown in FIG. 2A .
  • the second management item processing unit 602 is configured to: respectively create at least one second management item for at least one second entity object and bind the at least one second entity object to at least one second management item, and the at least one second management item The second change information of the corresponding at least one second entity object is respectively included.
  • the second management item processing unit 602 may execute step S12 in the data processing method shown in FIG. 2A .
  • the hierarchical relationship establishing unit 603 is configured to: establish a first hierarchical relationship between the first management item and at least one second management item based on the logical relationship between the first entity object and at least one second entity object. For example, the hierarchical relationship establishing unit 603 may execute step S13 in the data processing method shown in FIG. 2A .
  • the hierarchical relationship maintaining unit 604 is configured to: maintain the first hierarchical relationship according to the logical relationship between the first entity object and at least one second entity object. For example, the hierarchical relationship maintenance unit 604 may execute step S14 in the data processing method shown in FIG. 2A.
  • the first management item processing unit 601, the second management item processing unit 602, the hierarchical relationship establishment unit 603 and the hierarchical relationship maintenance unit 604 include codes and programs stored in memory; the processor can execute the codes and programs to implement the above Some or all of the functions of the first management item processing unit 601 , the second management item processing unit 602 , the hierarchical relationship establishment unit 603 and the hierarchical relationship maintenance unit 604 .
  • the first management item processing unit 601, the second management item processing unit 602, the hierarchical relationship establishment unit 603, and the hierarchical relationship maintenance unit 604 may be dedicated hardware devices, which are used to implement the above-mentioned first management item processing unit 601, Some or all of the functions of the second management item processing unit 602 , the hierarchical relationship establishing unit 603 and the hierarchical relationship maintaining unit 604 .
  • the first management item processing unit 601, the second management item processing unit 602, the hierarchical relationship establishment unit 603, and the hierarchical relationship maintenance unit 604 may be a circuit board or a combination of multiple circuit boards for realizing the functions described above .
  • the circuit board or a combination of multiple circuit boards may include: (1) one or more processors; (2) one or more non-transitory memories connected to the processors; and (3) Processor-executable firmware stored in memory.
  • Step S11 to Step S14 shown in 2A the data processing device can achieve technical effects similar to those of the aforementioned data processing method, which will not be repeated here.
  • At least one embodiment of the present disclosure further provides an electronic device, where the electronic device includes a processor and a memory.
  • the memory includes one or more computer-executable instructions.
  • One or more computer-executable instructions are stored in the memory and configured to be executed by the processor, and the one or more computer-executable instructions are used to implement the data processing method provided by any embodiment of the present disclosure.
  • Fig. 14 is a schematic block diagram of an electronic device provided by some embodiments of the present disclosure.
  • the electronic device 300 includes a processor 310 and a memory 320 , which can be used to implement a client or a server to respectively implement corresponding methods.
  • the memory 320 is used for non-transitory storage of computer-executable instructions (eg, one or more computer program modules).
  • the processor 310 is used to run the computer-executable instructions. When the computer-executable instructions are executed by the processor 310, one or more steps in the above-mentioned data processing method can be executed, thereby realizing the above-mentioned data processing method.
  • the memory 320 and the processor 310 may be interconnected by a bus system and/or other forms of connection mechanisms (not shown).
  • the processor 310 may be a central processing unit (CPU), a graphics processing unit (GPU), or other forms of processing units having data processing capabilities and/or program execution capabilities.
  • the central processing unit (CPU) may be of X86 or ARM architecture and the like.
  • the processor 310 can be a general-purpose processor or a special-purpose processor, and can control other components in the electronic device 300 to perform desired functions.
  • memory 320 may include any combination of one or more computer program products, which may include various forms of computer-readable storage media, such as volatile memory and/or nonvolatile memory.
  • the volatile memory may include random access memory (RAM) and/or cache memory (cache), etc., for example.
  • Non-volatile memory may include, for example, read-only memory (ROM), hard disks, erasable programmable read-only memory (EPROM), compact disk read-only memory (CD-ROM), USB memory, flash memory, and the like.
  • One or more computer program modules can be stored on the computer-readable storage medium, and the processor 310 can run one or more computer program modules to realize various functions of the electronic device 300 .
  • Various application programs, various data, and various data used and/or generated by the application programs can also be stored in the computer-readable storage medium.
  • Fig. 15 is a schematic block diagram of another electronic device provided by some embodiments of the present disclosure.
  • the electronic device 400 is, for example, suitable for implementing the data processing method provided by the embodiment of the present disclosure.
  • the electronic device 400 may be a terminal device, etc., and may be used to implement a client or a server.
  • the electronic device 400 may include, but is not limited to, mobile phones, notebook computers, digital broadcast receivers, PDAs (Personal Digital Assistants), PADs (Tablet Computers), PMPs (Portable Multimedia Players), vehicle-mounted terminals (such as vehicle-mounted navigation terminals), Mobile terminals such as wearable electronic devices and the like and stationary terminals such as digital TVs, desktop computers, smart home devices and the like.
  • PDAs Personal Digital Assistants
  • PADs Tablett Computers
  • PMPs Portable Multimedia Players
  • vehicle-mounted terminals such as vehicle-mounted navigation terminals
  • Mobile terminals such as wearable electronic devices and the like and stationary terminals such as digital TVs, desktop computers,
  • the electronic device 400 may include a processing device (such as a central processing unit, a graphics processing unit, etc.) 410, which may be randomly accessed according to a program stored in a read-only memory (ROM) 420 or loaded from a storage device 480. Various appropriate actions and processes are executed by programs in the memory (RAM) 430 . In the RAM 430, various programs and data necessary for the operation of the electronic device 400 are also stored.
  • the processing device 410, the ROM 420 and the RAM 430 are connected to each other through a bus 440.
  • An input/output (I/O) interface 450 is also connected to bus 440 .
  • I/O interface 450 input devices 460 including, for example, a touch screen, touchpad, keyboard, mouse, camera, microphone, accelerometer, gyroscope, etc.; including, for example, a liquid crystal display (LCD), speaker, vibration an output device 470 such as a computer; a storage device 480 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 490 .
  • the communication means 490 may allow the electronic device 400 to perform wireless or wired communication with other electronic devices to exchange data.
  • FIG. 15 shows electronic device 400 having various means, it should be understood that it is not required to implement or have all of the means shown, and electronic device 400 may alternatively implement or have more or fewer means.
  • the data processing method described above can be implemented as a computer software program.
  • embodiments of the present disclosure include a computer program product including a computer program carried on a non-transitory computer readable medium, where the computer program includes program code for executing the above data processing method.
  • the computer program may be downloaded and installed from a network via communication means 490, or installed from storage means 480, or installed from ROM 420.
  • the processing device 410 When the computer program is executed by the processing device 410, the functions defined in the data processing method provided by the embodiments of the present disclosure can be realized.
  • Fig. 16 is a schematic diagram of a storage medium provided by some embodiments of the present disclosure.
  • the storage medium 500 may be a non-transitory computer-readable storage medium for storing non-transitory computer-executable instructions 501 .
  • the non-transitory computer-executable instructions 501 are executed by the processor, the data processing methods described in the embodiments of the present disclosure can be realized.
  • the non-transitory computer-executable instructions 501 are executed by the processor, the above One or more steps in the data processing method described above.
  • the storage medium 500 may be applied to the above-mentioned electronic device, for example, the storage medium 500 may include a memory in the electronic device.
  • the storage medium may include a memory card of a smartphone, a storage unit of a tablet computer, a hard disk of a personal computer, random access memory (RAM), read only memory (ROM), erasable programmable read only memory (EPROM), Portable compact disc read-only memory (CD-ROM), flash memory, or any combination of the above-mentioned storage media may also be other applicable storage media.
  • RAM random access memory
  • ROM read only memory
  • EPROM erasable programmable read only memory
  • CD-ROM Portable compact disc read-only memory
  • flash memory or any combination of the above-mentioned storage media may also be other applicable storage media.
  • the description of the storage medium 500 reference may be made to the description of the memory in the embodiments of the electronic device, and repeated descriptions will not be repeated.
  • the description of the memory in the embodiments of the electronic device reference may be made to the description of the memory in the embodiments of the electronic device, and repeated descriptions will not be repeated.
  • specific functions and technical effects of the storage medium 500 reference may be made to the above description about the data processing method, and details are not repeated here.
  • a computer-readable medium may be a tangible medium that may contain or store information for use by or in conjunction with an instruction execution system, device, or device. program.
  • a computer readable medium may be a computer readable signal medium or a computer readable storage medium or any combination of the two.
  • a computer-readable storage medium may be, for example, but not limited to: an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or device, or any combination thereof.
  • Computer-readable storage media may include, but are not limited to, electrical connections with one or more wires, portable computer diskettes, hard disks, random access memory (RAM), read-only memory (ROM), erasable Programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination of the above.
  • a computer-readable storage medium may be any tangible medium that contains or stores a program that can be used by or in conjunction with an instruction execution system, apparatus, or device.
  • a computer-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave carrying computer-readable program code therein.
  • Such propagated data signals may take many forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the foregoing.
  • a computer-readable signal medium may also be any computer-readable medium other than a computer-readable storage medium, which can transmit, propagate, or transmit a program for use by or in conjunction with an instruction execution system, apparatus, or device .
  • Program code embodied on a computer readable medium may be transmitted by any appropriate medium, including but not limited to wires, optical cables, RF (radio frequency), etc., or any suitable combination of the above.
  • the client and the server can communicate with any currently known or future developed network protocols such as HTTP (HyperText Transfer Protocol, Hypertext Transfer Protocol), and can communicate with any form or medium of digital Data communication (eg, communication network) interconnections.
  • network protocols such as HTTP (HyperText Transfer Protocol, Hypertext Transfer Protocol)
  • Examples of communication networks include local area networks (“LANs”), wide area networks (“WANs”), internetworks (e.g., the Internet), and peer-to-peer networks (e.g., ad hoc peer-to-peer networks), as well as any currently known or future developed network of.
  • the above-mentioned computer-readable medium may be included in the above-mentioned electronic device, or may exist independently without being incorporated into the electronic device.
  • Computer program code for carrying out operations of the present disclosure may be written in one or more programming languages, or combinations thereof, including but not limited to object-oriented programming languages such as Java, Smalltalk, C++, and Included are conventional procedural programming languages, such as the "C" language or similar programming languages.
  • the program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server.
  • the remote computer may be connected to the user computer through any kind of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (such as through an Internet connection).
  • LAN local area network
  • WAN wide area network
  • each block in a flowchart or block diagram may represent a module, program segment, or portion of code that contains one or more logical functions for implementing specified executable instructions.
  • the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or they may sometimes be executed in the reverse order, depending upon the functionality involved.
  • each block of the block diagrams and/or flowchart illustrations, and combinations of blocks in the block diagrams and/or flowchart illustrations can be implemented by a dedicated hardware-based system that performs the specified functions or operations , or may be implemented by a combination of dedicated hardware and computer instructions.
  • the units involved in the embodiments described in the present disclosure may be implemented by software or by hardware. Wherein, the name of a unit does not constitute a limitation of the unit itself under certain circumstances.
  • FPGAs Field Programmable Gate Arrays
  • ASICs Application Specific Integrated Circuits
  • ASSPs Application Specific Standard Products
  • SOCs System on Chips
  • CPLD Complex Programmable Logical device
  • a data processing method includes: creating a first management item for a first entity object and binding the first entity object to the first management item, wherein the The first management item includes the first change information of the first entity object; at least one second management item is respectively created for at least one second entity object and the at least one second entity object is respectively bound to the at least one A second management item, wherein the at least one second management item respectively includes the second change information of the corresponding at least one second entity object; based on the first entity object and the at least one second entity object Establish a first hierarchical relationship between the first management item and the at least one second management item; and according to the relationship between the first entity object and the at least one second entity object The logical relationship maintains the first hierarchical relationship.
  • the at least one second entity object is subordinate to the first entity object, and in the first hierarchical relationship, the first management item serves as a parent node, the The at least one second management item is respectively at least one child node of the parent node.
  • the first entity object and the first management item are stored separately from each other, and the at least one second entity object and the corresponding at least one second management item stored separately from each other.
  • the data processing method further includes: updating the first change information of the first management item in response to the change of the first entity object; and/or responding to the at least one The respective changes of the second entity objects update the respective second change information of the at least one second management item.
  • the first change information includes a first serial number for recording version change information of the first entity object, and the first change information of the first management item is updated,
  • the method includes: performing an increment operation on the first serial number to update the first serial number.
  • the second change information includes a second sequence number used to record version change information of the corresponding second entity object, and each of the at least one second management item is updated.
  • the second change information includes: determining the currently updated target second management item in the at least one second management item, and performing an increment operation on the second serial number of the target second management item to update the The second serial number of the target second management item.
  • the at least one second entity object includes multiple second entity objects, and the corresponding at least one second management item includes multiple second management items, and the multiple first The second serial numbers of the two management items are different from each other and are not reused.
  • the data processing method further includes: creating a change information management entry for the first management item, wherein the change information management entry includes a change sequence number, and the change sequence number represents the The largest second serial number among the second serial numbers of the at least one second management item.
  • performing an increment operation on the second serial number of the target second management item to update the second serial number of the target second management item includes: acquiring the change A serial number, updating the second serial number of the target second management item to the sum of the changed serial number and a predetermined increment.
  • performing an increment operation on the second serial number of the target second management item to update the second serial number of the target second management item further includes: updating the second serial number of the target second management item After the second serial number of the target second management item is changed, the changed serial number is updated to the second serial number of the target second management item.
  • the data processing method further includes: processing the first entity object, the first management item, the at least one second entity object, the at least one second managing items and the first hierarchical relationship; and processing the copy of the first entity object, the copy of the first management item, the copy of the at least one second entity object, the at least one A copy of the second management item and a copy of the first hierarchical relationship; wherein, the at least one client provides the received instruction to the server for updating the first entity object through the server , the first management item, the at least one second entity object, the at least one second management item, or the first hierarchical relationship; the at least one client requests synchronization from the server to update the The copy of the first entity object, the copy of the first management item, the copy of the at least one second entity object, the copy of the at least one second management item, and the copy of the at least one client respectively processed by the at least one client A copy of the first-level relationship.
  • the server includes a first entity object server, a second entity object server, and a management item server;
  • the first entity object server communicates with the management item server Sending a first creation request, the management item server creates the first management item for the first entity object in response to the first creation request and binds the first entity object to the first management item;
  • the second entity object server sends a second creation request to the management item server, and the management item server creates the at least one second entity object respectively in response to the second creation request at least one second management item and binding the at least one second entity object to the at least one second management item;
  • the management item server is based on the first entity object and the at least one second entity
  • the logical relationship between objects is to establish and maintain the first hierarchical relationship.
  • the parent node of the item when the at least one client is synchronized with the server, responding to the first management item being the at least one second management item in the first hierarchical relationship
  • the parent node of the item first synchronizes the first management item with the copy of the first management item, and then synchronizes the at least one second management item with the copy of the at least one second management item.
  • the data processing method further includes: synchronizing the at least one client based on the change information management entry created for the first management item.
  • synchronizing the at least one client based on the change information management entry includes: determining a current target client for synchronization among the at least one client; accepting the The target client performs the first synchronization request; and after the first synchronization is performed on the target client from the server, the server sends the server in the first synchronization to The changed serial number of the target client is recorded as the latest changed serial number of the client, and the changed serial number sent by the server to the target client in the first synchronization is recorded in the target client as the client Maximum change sequence number.
  • synchronizing the at least one client based on the change information management entry further includes: accepting a second synchronization request from the target client, wherein the first The second synchronization is adjacent to the first synchronization in time, and the latest change sequence number of the client and the change sequence of the server when the second synchronization request is accepted are sent from the server to the target client number, the target client compares the latest serial number of the client with the maximum serial number of the client, and in response to the latest serial number of the client being equal to the maximum serial number of the client, the The target client performs the second synchronization according to the maximum change sequence number of the client and the change sequence number sent by the server, and in response to the difference between the latest change sequence number of the client and the maximum change sequence number of the client etc.
  • the target client is not limited to the maximum change sequence number of the client to perform the second synchronization.
  • the data processing method further includes: respectively creating at least one first sequence entry for the at least one second management item, for recording the at least one second management item First sort information.
  • the data processing method further includes: performing a first sort among the at least one second management item according to the at least one first sequence entry.
  • the at least one first sequence entry respectively includes first sorting type information and/or first sorting weight information of the corresponding second management item, and according to the at least one first A sequence entry, performing the first sorting among the at least one second management item, including: based on the first sorting type information corresponding to the at least one second management item and/or the first sorting Weight information, performing the first sorting among the at least one second management item.
  • the first sorting type information includes: creation time, name character or update time of the second management item.
  • the at least one second management item includes a plurality of second management items, and according to the at least one first sequence entry, the at least one second management item performs all operations between the at least one second management item.
  • the first sorting further includes: assigning sequence identification numbers to each of the multiple second management items after the first sorting, wherein the multiple second management items after the first sorting correspond to At least two of the multiple sequential identification numbers for are not sequentially increasing.
  • the multiple sequence identification numbers corresponding to the multiple second management items are incremented according to a predetermined interval, and the predetermined interval is greater than 1.
  • Performing the first sorting among the management items further includes: after re-performing the first sorting in response to inserting a new second management item, determining that the new second management item is different from that in the first sorting The arithmetic difference between the sequence identification numbers of two immediately adjacent second management items, if the arithmetic difference is less than or equal to the predetermined interval and greater than the predetermined offset, the new second management item
  • the sequence identification number of is determined as the sum of the sequence identification number of the immediately preceding second management item in the first sorting and the predetermined offset, wherein the predetermined offset is greater than or equal to 1 and less than the predetermined interval.
  • the data processing method further includes: respectively creating at least one second sequence entry for the at least one second management item, so as to record the information between the at least one second management item Second sorting information, wherein the second sorting information is different from the first sorting information.
  • the data processing method further includes: performing a second sort among the at least one second management item according to the at least one second sequence entry.
  • the at least one second sequence entry respectively includes second sorting type information and/or second sorting weight information of the corresponding second management item, and according to the at least one first Two sequence entries, performing the second sorting among the at least one second management item, including: based on the second sorting type information and/or the second sorting corresponding to the at least one second management item Weight information, performing the second sorting among the at least one second management item.
  • the at least one second management item includes node identification information
  • the data processing method further includes: in response to establishing the relationship between the first management item and the at least one second management item The first hierarchical relationship between items is updated, and the node identification information of the at least one second managed item is updated to point to the first managed item.
  • maintaining the first hierarchical relationship according to the logical relationship between the first entity object and the at least one second entity object includes: responding to the first entity object The change of the logical relationship between an entity object and the at least one second entity object modifies the first hierarchical relationship.
  • the change of the logical relationship includes deleting the first entity object so that there is no association relationship between the first entity object and the at least one second entity object, modifying The first hierarchical relationship includes: releasing the first hierarchical relationship.
  • the change of the logical relationship includes deleting each of the at least one second entity object, so that there is no relationship between the first entity object and the at least one second entity object Having an association relationship
  • modifying the first hierarchical relationship includes: canceling the first hierarchical relationship
  • maintaining the first hierarchical relationship according to the logical relationship between the first entity object and the at least one second entity object includes: responding to the at least one An increase or decrease in the quantity of a second entity object updates the first hierarchical relationship.
  • the first entity object corresponds to a first object set
  • the at least one second entity object corresponds to at least one second object set respectively
  • the data processing method further includes: In response to the at least one second entity object being subordinate to the first entity object, modifying data of the first entity object such that the at least one second set of objects is a subset of the first set of objects.
  • members of the first object set remain the same as members of the second object set.
  • the type of the first entity object is different from the type of the at least one second entity object.
  • creating the first management item for the first entity object includes: creating the first management item based on the data of the first entity object according to a predetermined management item template item; respectively creating the at least one second management item for the at least one second entity object includes: creating the at least one second management item based on the data of the at least one second entity object according to the predetermined management item template Two management items.
  • the management item template includes an identification information item and a type information item
  • the identification information item is used to record the identification information of the entity object bound to the management item
  • the type information item It is used to record the type information of the entity object bound to the management item.
  • an electronic device includes a processor and a memory; the memory includes one or more computer-executable instructions; wherein the one or more computer-executable instructions are stored in The memory is configured to be executed by the processor, and the one or more computer-executable instructions are used to implement the data processing method described in any embodiment of the present disclosure.
  • a storage medium is used for storing non-transitory computer-executable instructions, and any embodiment of the present disclosure can be implemented when the non-transitory computer-executable instructions are executed by a processor The data processing method described.
  • the at least one second entity object includes a plurality of second entity objects
  • the change of the logical relationship includes deleting a part of the second entity objects in the plurality of second entity objects , so that the hierarchical relationship between the first management item and the second management item corresponding to the part of the second entity objects is released, and the hierarchical relationship between the first management item and the other part of the second entity corresponding to the plurality of second entity objects
  • the hierarchical relationship between the second management items of the objects is still maintained, and modifying the first hierarchical relationship includes: releasing the hierarchy between the first management item and the second management items corresponding to the part of the second entity objects relationship, retaining the hierarchical relationship between the first management item and the second management item corresponding to the other part of the second entity object.
  • the method includes at least one of the following: updating the first hierarchical relationship in response to an increase in the number of the at least one second entity object, including: The object creates a new second management item and binds the added second entity object to the new second management item; and establishes a relationship between the first management item and the new second management item Hierarchical relationship; in response to the decrease in the number of the at least one second entity object, updating the first hierarchy relationship includes: determining a second management item to be operated corresponding to the reduced second entity object; and releasing the second entity object A hierarchical relationship between a management item and the second management item to be operated.
  • updating the first hierarchical relationship in response to an increase in the quantity of the at least one second entity object further includes: managing entries based on change information of the first management item, Updating the second change information of the new second management item; in response to the decrease in the number of the at least one second entity object, updating the first hierarchical relationship, further comprising: after releasing the first management item from the Before the hierarchical relationship between the second management items to be operated, the second change information of the second management items to be operated is updated, so as to update the change information management entries of the first management items.
  • updating the first hierarchical relationship in response to the decrease in the quantity of the at least one second entity object further includes: deleting the second management item to be operated.
  • the first entity object corresponds to a first object set
  • the members of the first object set are users
  • the at least one second entity object corresponds to at least one second An object collection, the members of the second object collection are users.
  • the members of the second object collection are correspondingly added, and/or by adding the first object
  • the reduction operation of the user of the collection correspondingly performs the reduction operation on the members of the second object collection.
  • a data processing device includes: a first management item processing unit configured to: create a first management item for a first entity object and bind the first entity object to The first management item, wherein the first management item includes the first change information of the first entity object; the second management item processing unit is configured to: respectively create at least one first change information for at least one second entity object two management items and bind the at least one second entity object to the at least one second management item respectively, wherein the at least one second management item respectively includes the corresponding first entity object of the at least one second entity object 2.
  • Change information a hierarchical relationship establishing unit configured to: establish the first management item and the at least one second management item based on the logical relationship between the first entity object and the at least one second entity object a first hierarchical relationship between them; and a hierarchical relationship maintaining unit configured to: maintain the first hierarchical relationship according to the logical relationship between the first entity object and the at least one second entity object.

Landscapes

  • Business, Economics & Management (AREA)
  • Engineering & Computer Science (AREA)
  • Human Resources & Organizations (AREA)
  • Entrepreneurship & Innovation (AREA)
  • Strategic Management (AREA)
  • Operations Research (AREA)
  • Economics (AREA)
  • Marketing (AREA)
  • Data Mining & Analysis (AREA)
  • Quality & Reliability (AREA)
  • Tourism & Hospitality (AREA)
  • Physics & Mathematics (AREA)
  • General Business, Economics & Management (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

一种数据处理方法及装置、电子设备及存储介质,该数据处理方法包括:为第一实体对象创建第一管理项且将第一实体对象绑定至第一管理项,第一管理项包括第一实体对象的第一变更信息(S11);为至少一个第二实体对象分别创建至少一个第二管理项且将至少一个第二实体对象分别绑定至至少一个第二管理项,至少一个第二管理项分别包括对应的至少一个第二实体对象的第二变更信息(S12);基于第一实体对象与至少一个第二实体对象之间的逻辑关系,建立第一管理项与至少一个第二管理项之间的第一层级关系(S13);以及根据第一实体对象与至少一个第二实体对象之间的逻辑关系,维护第一层级关系(S14)。该数据处理方法有利于第一层级关系的维护,提升数据处理效率。

Description

数据处理方法及装置、电子设备及存储介质
本申请要求于2021年8月6日递交的中国专利申请第202110903063.8号的优先权,该中国专利申请的全文以引入的方式并入以作为本申请的一部分。
技术领域
本公开的实施例涉及一种数据处理方法、数据处理装置、电子设备及存储介质。
背景技术
数据结构是计算机存储、组织数据的方式。数据结构是指相互之间存在一种或多种特定关系的数据元素的集合。通常情况下,精心选择的数据结构可以带来更高的运行或者存储效率。
对于社交网络或线上办公应用等上层应用而言,选用的数据结构和数据结构之间的关系,影响着基于该数据结构的上层应用的运行效率或灵活性。
发明内容
本公开至少一个实施例提供一种数据处理方法,该数据处理方法包括:为第一实体对象创建第一管理项且将所述第一实体对象绑定至所述第一管理项,所述第一管理项包括所述第一实体对象的第一变更信息;为至少一个第二实体对象分别创建至少一个第二管理项且将所述至少一个第二实体对象分别绑定至所述至少一个第二管理项,所述至少一个第二管理项分别包括对应的所述至少一个第二实体对象的第二变更信息;基于所述第一实体对象与所述至少一个第二实体对象之间的逻辑关系,建立所述第一管理项与所述至少一个第二管理项之间的第一层级关系;以及根据所述第一实体对象与所述至少一个第二实体对象之间的所述逻辑关系,维护所述第一层级关系。
本公开至少一个实施例还提供一种数据处理装置,该数据处理装置包括第一管理项处理单元、第二管理项处理单元、层级关系建立单元和层级关系维护单元;所述第一管理项处理单元配置为:为第一实体对象创建第一管理项且将所述第一实体对象绑定至所述第一管理项,所述第一管理项包括所述第一实体对象的第一变更信息;所述第二管理项处理单元配置为:为至少一个第二实体对象分别创建至少一个第二管理项且将所述至少一个第二实体对象分别绑定至所述至少一个第二管理项,所述至少一个第二管理项分别包括对应的所述至少一个第二实体对象的第二变更信息;所述层级关系建立单元配置为:基于所述第一实体对象与所述至少一个第二实体对象之间的逻辑关系,建立所述第一管理项与所述至少一个第二管理项之间的第一层级关系;所述层级关系维护单元配置为:根据所述第一实体对象与所述至少一个第二实体对象之间的所述逻辑关系,维护所述第一层级关系。
本公开至少一个实施例还提供一种电子设备,该电子设备包括处理器和存储器;所述存储器包括一个或多个计算机可执行指令;所述一个或多个计算机可执行指令被存储在所述存储器中并被配置为由所述处理器执行,所述一个或多个计算机可执行指令用于实现本公开任一实施例所述的数据处理方法。
本公开至少一个实施例还提供一种存储介质,该存储介质用于存储非暂时性计算机可执行指令,当所述非暂时性计算机可执行指令由处理器执行时可以实现本公开任一实施例所述的数据处理方法。
附图说明
为了更清楚地说明本公开实施例的技术方案,下面将对实施例的附图作简单地介绍,显而易见地,下面描述中的附图仅仅涉及本公开的一些实施例,而非对本公开的限制。
图1为一种可用于实施本公开实施例提供的数据处理方法的系统;
图2A为本公开一些实施例提供的一种数据处理方法的示意性流程图;
图2B为本公开一些实施例中客户端操作界面的示例性示意图;
图3为本公开一些实施例提供的一种数据结构的示意图;
图4为本公开一些实施例提供的另一种数据处理方法的示意性流程图;
图5为本公开一些实施例提供的另一种数据结构的示意图;
图6为本公开一些实施例提供的一种对目标第二管理项的第二序列号进行更新的示意图;
图7为本公开一些实施例提供的再一种数据处理方法的示意性流程图;
图8为本公开一些实施例提供的一种数据处理方法的具体示例的示意性流程图;
图9为本公开一些实施例提供的一种数据处理方法中的步骤S51的示意性流程图;
图10为本公开一些实施例提供的再一种数据处理方法的示意性流程图;
图11为本公开一些实施例提供的再一种数据结构的示意图;
图12为本公开一些实施例提供的一种数据处理方法中的步骤S65的示意性流程图;
图13为本公开一些实施例提供的一种数据处理装置的示意框图;
图14为本公开一些实施例提供的一种电子设备的示意框图;
图15为本公开一些实施例提供的另一种电子设备的示意框图;以及
图16为本公开一些实施例提供的一种存储介质的示意图。
具体实施方式
下面将参照附图更详细地描述本公开的实施例。虽然附图中显示了本公开的某些实施例,然而应当理解的是,本公开可以通过各种形式来实现,而且不应该被解释为限于这里阐述的实施例,相反提供这些实施例是为了更加透彻和完整地理解本公开。应当理解的是,本公开的附图及实施例仅用于示例性作用,并非用于限制本公开的保护范围。
应当理解,本公开的方法实施方式中记载的各个步骤可以按照不同的顺序执行,和/ 或并行执行。此外,方法实施方式可以包括附加的步骤和/或省略执行示出的步骤。本公开的范围在此方面不受限制。
本文使用的术语“包括”及其变形是开放性包括,即“包括但不限于”。术语“基于”是“至少部分地基于”。术语“一个实施例”表示“至少一个实施例”;术语“另一实施例”表示“至少一个另外的实施例”;术语“一些实施例”表示“至少一些实施例”。其他术语的相关定义将在下文描述中给出。
需要注意,本公开中提及的“第一”、“第二”等概念仅用于对不同的装置、模块或单元进行区分,并非用于限定这些装置、模块或单元所执行的功能的顺序或者相互依存关系。
需要注意,本公开中提及“一个”、“多个”的修饰是示意性而非限制性的,本领域技术人员应当理解,除非在上下文另有明确指出,否则应该理解为“一个或多个”。
本公开实施方式中的多个装置之间所交互的消息或者信息的名称仅用于说明性的目的,而并不是用于对这些消息或信息的范围进行限制。
对于社交网络或线上办公应用而言,需要按照一定层级来组织用户(使用人)的关系,例如将用户组织为群组,在群组内的用户,即群组成员可以彼此进行信息交互。同时,还可以将不同群组组织为团队、或团队的一部分,群组内的用户相应地也是团队内的用户,也即群组成员也是这个团队的团队成员。群组和团队之间的关联关系是可以变更的,对于一个团队而言可以增加或删除所属的群组。在利用数据结构来实现团队、群组以及管理它们之间的关系时,可以将对应于团队的数据对象与对应于群组的数据对象直接关联,这种方法简单、直接,但是扩展性较差,不利于引入新的数据对象以及扩展新的功能,并且数据处理速度较慢及数据处理效率不高。
本公开至少一个实施例提供一种数据处理方法,该数据处理方法包括:为第一实体对象创建第一管理项且将第一实体对象绑定至第一管理项,第一管理项包括第一实体对象的第一变更信息;为至少一个第二实体对象分别创建至少一个第二管理项且将至少一个第二实体对象分别绑定至至少一个第二管理项,至少一个第二管理项分别包括对应的至少一个第二实体对象的第二变更信息;基于第一实体对象与至少一个第二实体对象之间的逻辑关系,建立第一管理项与至少一个第二管理项之间的第一层级关系;以及根据第一实体对象与至少一个第二实体对象之间的逻辑关系,维护第一层级关系。
本公开上述实施例提供的数据处理方法中,通过将第一实体对象绑定至独立于第一实体对象的第一管理项,且将第二实体对象绑定至独立于第二实体对象的第二管理项,并建立第一管理项与第二管理项之间的第一层级关系,由此可以使第一实体对象与第二实体对象之间的关联关系的变更通过对该第一层级关系进行修改而实现,从而降低不同实体对象之间的逻辑关系发生变更时所需的运算量,提高数据处理速度及数据处理效率,同时也有助于实现对数据结构的优化,提高上层应用的灵活性。
并且,在本公开上述实施例提供的数据处理方法中,第一管理项和第二管理项分别存储有第一实体对象的第一变更信息和第二实体对象的第二变更信息,由此基于第一管 理项和第二管理项中分别记录的第一变更信息和第二变更信息,可以准确且高效地获取对应的第一实体对象和第二实体对象的当前版本信息,从而有助于实现对存储在不同终端的第一实体对象的数据和第二实体对象的数据的组织、存储、调用、更新等处理操作。
下面,将参考附图详细地说明本公开的实施例。应当注意的是,不同的附图中相同的附图标记将用于指代已描述的相同的元件。
图1为一种可用于实施本公开实施例提供的数据处理方法的系统。如图1所示,该系统100可以包括用户终端110、网络120、服务器130以及数据库140。例如,该系统100可以用于实施本公开任一实施例所述的数据处理方法。
用户终端110例如为电脑110-1或手机110-2。可以理解的是,用户终端110可以是能够执行数据处理的任何其他类型的电子设备,其可以包括但不限于台式电脑、笔记本电脑、平板电脑、智能手机、智能家居设备、可穿戴设备、车载电子设备、监控设备等。用户终端110也可以是设置有电子设备的任何装备,例如车辆、机器人等。
用户可以对安装在用户终端110上的应用程序进行操作,应用程序通过网络120将用户行为数据传输给服务器130,用户终端110还可以通过网络120接收服务器130传输的数据。
用户终端110可以通过运行程序或线程的方式实施本公开实施例提供的数据处理方法,例如运行客户端部分。在一些示例中,用户终端110可以利用其内置的应用程序执行数据处理方法。在另一些示例中,用户终端110可以通过调用用户终端110外部存储的应用程序执行数据处理方法。
网络120可以是单个网络,或至少两个不同网络的组合。例如,网络120可以包括但不限于局域网、广域网、公用网络、专用网络等中的一种或几种的组合。
服务器130可以通过运行程序或线程的方式实施本公开实施例提供的数据处理方法,其可以是一个单独的服务器,或一个服务器群组(例如云服务),服务器群组内的各个服务器通过有线的或无线的网络进行连接。一个服务器群组可以是集中式的,例如数据中心,也可以是分布式的。服务器130可以是本地的或远程的。服务器130可以通过有线的或无线的网络与用户终端110进行通信。例如,服务器130上可以运行社交软件或线上办公软件中的服务端,集中管理用户数据以及负责信息传输等,并且对于用户通过不同的用户终端110使用上述社交软件或线上办公软件的客户端的情形,服务器130上的服务端还可以负责对这些不同的用户终端110上的客户端各自记录的用户数据进行部分同步或全部同步,使得这些不同的用户终端110上的客户端各自记录的用户数据是完全相同的或对于至少部分时段是相同的,从而方便用户使用。
数据库140可以泛指具有存储功能的设备。数据库140主要用于存储用户终端110和服务器130在工作中所利用、产生和输出的各种数据。数据库140可以是本地的或远程的。数据库140可以包括相应的软件和硬件,例如包括各种存储器、例如随机存取存储器(Random Access Memory,RAM)、只读存储器(Read Only Memory,ROM)等。以上提及的存储设备只是列举了一些例子,该系统100可以使用的存储设备并不局限于 此。
数据库140可以经由网络120与服务器130或其一部分相互连接或通信,或直接与服务器130相互连接或通信,或是上述两种方式的结合。
在一些示例中,数据库140可以是独立的设备。在另一些示例中,数据库140也可以集成在用户终端110和服务器130中的至少一个中。例如,数据库140可以设置在用户终端110上,也可以设置在服务器130上。又例如,数据库140也可以是分布式的,其一部分设置在用户终端110上,另一部分设置在服务器130上,例如也可以为运行在云端的数据库。
图2A为本公开一些实施例提供的一种数据处理方法的示意性流程图。该数据处理方法例如可以应用于服务端或客户端,例如服务端运行于图1所示的系统100中的服务器130上,客户端运行于用户终端110上,从而例如使用人的用户可以通过用户终端110访问服务端并且通过用户终端110上的客户端提供的操作界面进行操作。例如该数据处理方法可以应用于社交应用、线上办公等应用中。由于服务端集中管理用户数据以及负责信息传输等,下面以数据处理方法应用于服务端为例进行说明,并且在涉及与客户端进行同步时,加入对客户端的相应说明。
如图2A所示,本公开实施例提供的数据处理方法包括步骤S11至步骤S14。
步骤S11:为第一实体对象创建第一管理项且将第一实体对象绑定至第一管理项,第一管理项包括第一实体对象的第一变更信息。
步骤S12:为至少一个第二实体对象分别创建至少一个第二管理项且将至少一个第二实体对象分别绑定至至少一个第二管理项,至少一个第二管理项分别包括对应的至少一个第二实体对象的第二变更信息。
步骤S13:基于第一实体对象与至少一个第二实体对象之间的逻辑关系,建立第一管理项与至少一个第二管理项之间的第一层级关系。
步骤S14:根据第一实体对象与至少一个第二实体对象之间的逻辑关系,维护第一层级关系。
由于是根据第一实体对象与至少一个第二实体对象之间的逻辑关系来维护第一层级关系,因此,在一些实施例中,可以基于第一层级关系,在客户端上实现对第一实体对象和第二实体对象及其逻辑关系的可视化呈现,后文将详细说明。
图3为本公开一些实施例提供的一种数据结构的示意图,例如该数据结构包括上述步骤S11至S14中的第一实体对象、第二实体对象、第一管理项、第二管理项等。下面结合图3中所示的数据结构,对图2A所示的数据处理方法中的各个步骤进行说明。
例如,参考图2A和图3所示,第一实体对象UT1可以为各种适当类型的实体对象,例如可以为社交软件或线上办公软件中的对象集合,也可以为其他实体对象,例如文档、日程等;第二实体对象UT2可以为各种适当类型的实体对象,例如可以为社交软件或线上办公软件中的对象集合,也可以为其他实体对象,例如文档、日程等。
例如,社交软件或线上办公软件中的对象集合为包括多个用户的集合,即包括多个 用户,这些用户被组织在一起,以便彼此进行信息交流以及数据共享。不同的对象集合之间可以建立一定的关联关系,例如第二对象集合可以从属于第一对象集合。第二对象集合“从属于”第一对象集合,可以是指第二对象集合所能够执行的操作权限受限于第一对象集合所能够执行的操作权限,或者,也可以是指第二对象集合的信息传输边界或传输范围受限于第一对象集合的信息传输边界或传输范围内。在本公开的实施例中,用户可以是指使用相关设备或网络服务的真实的人或实体,也即,真实存在的使用人;或者,用户也可以是指系统中设置的能够模拟人类对话的例如聊天机器人或服务助手等用于提供服务的计算机程序。
例如,下文中,以第一实体对象UT1为“第一对象集合”和第二实体对象UT2为“第二对象集合”为例进行说明,其中,在逻辑关系上,第二实体对象UT2基于(或从属于)第一实体对象UT1。
例如,在一些示例中,该“第一对象集合”可以表示或理解为包括多个用户的一个“团队”等;“第二对象集合”可以表示或理解为包括多个用户的一个“群组”,例如一个用于该多个用户在群组中进行例如文本、图片、语音、视频、网络链接等信息交互的即时通讯的聊天群组。
例如,在线上办公软件的一个示例性应用场景中,创建“第一用户集合”即“团队”,其包括了一个公司全体员工,创建一个或多个“第二用户集合”即“群组”对应于公司中不同类型的分组,例如由总经理办公室创建的包括了全体公司员工的“公司畅聊组”(例如对应于公司的默认沟通群),又例如由人力资源部门创建的包括了全体公司员工的“人力资源分组”,或者例如由市场部建立的仅包括了市场部成员的“市场部分组”,由技术部建立的仅包括了市场部成员的“技术部分组”等等。这些群组从属于公司这个团队,在这些群组中,各自的成员可以进行聊天、分享信息等。因此,当一个员工从公司离职之后,其将被从从属于公司的各个群组中删除,或者当市场部有新员工入职之后,该新员工将被加入到包括全体公司员工的“公司畅聊组”以及“人力资源分组”,并且也会被加入到“市场部分组”,但是不会被加入到“技术部分组”等。但是,非公司员工不能被加入到公司这个“团队”中,更不能被加入到从属于公司的各个分组中。因此,公司这个团队限定了从属于公司的各个群组的信息交互边界,例如还可以进一步限定从属于公司的各个群组的权限边界。
在线上办公软件的另一个示例性应用场景中,在技术部内创建多个“第一用户集合”即“团队”,包括开发产品1的全部员工的“产品1团队”,包括开发产品2的全部员工的“产品2团队”等。对于每个团队,还可以创建从属于自己的一个或多个“第二用户集合”即“群组”,对应于产品开发不同任务,例如,对于“产品1团队”,可以创建包括开发产品1的全部员工的“日常沟通群”(例如对应于该团队的默认沟通群),包括开发模块1的员工的“模块1交流群”,包括开发模块2的员工的“模块2交流群”等等。某一技术部内员工在对应的线上办公软件中可以属于一个或多个团队,并且在某一团队内且可以属于一个或多个群组。在该员工使用该线上办公软件的使用界面中,可 以同时列出这一个或多个团队以及在每个团队下的一个或多个群组,并且可以在这些群组中进行相应的信息交流、分享等。不同员工由于可能属于不同的团队或在某一团队中属于不同的群组,不同员工在使用该线上办公软件时所得到的使用界面不同。
图2B示出了本公开至少一个实施例的客户端操作界面的一个示例,且以上述“产品1团队”、“产品2团队”为例。该操作页面具有“团队”操作标签(tab)用于对团队这一方式进行操作,在页面左侧示出了该用户所属的团队以及每个团队中具有的群组。如图2B所示,该用户至少属于“产品1团队”和“产品2团队”,“产品1团队”具有“日常沟通群”、“模块1交流群”、“模块2交流群”。目前,选中了“日常沟通群”(以灰色显示),在页面右侧示出了对应于该“日常沟通群”的聊天窗口CHT,该聊天窗口CHT上侧显示了过往信息,例如该群组中其他用户USR1和USR2已经发出的信息,该聊天窗口下侧显示了输入框INPT,供用户进行输入。
例如,每个团队具有一个或多个团队管理员,团队管理员为团队成员之一,具有各种管理团队的权限,包括增加、减少团队成员,解散团队,在团队中创建一个或多个群组,例如还可以解散团队中的群组,又例如可以具有设置某个团队成员权限等。团队管理员这一身份可以转让,即转让给团队中其他团队成员。团队成员对于所属的团队可以进行各种个性化设置,例如将所属的某个团队置顶、设置免打扰功能等。
例如,每个群组可以具有一个或多个群组管理员,群组管理员为群组成员之一,具有各种管理群组的权限,但是该管理群组的权限在不同应用场景或要求可以不同。例如,在群组成员需要与所从属的团队中的团队成员保持相同(例如群组成员与团队成员绑定)的情形,群组管理员则不具有添加或删除群组成员的权限。群组管理员这一身份可以转让,即转让给群组中其他群组成员。群组成员对于所属的群组可以被设置为具有不同权限,例如收听信息的权限、发送信息、发送网络链接、发起在线会议、共享日程的权项等;另外,每个群组成员还可以进行各种个性化设置,例如将所属的某个群置顶(例如,在某个团队内将某个群置顶)、设置免打扰功能等。
例如,对于上述步骤S11,在为第一实体对象UT1创建第一管理项ITM1后,将第一实体对象UT1绑定至创建的第一管理项ITM1,例如第一管理项ITM1指向第一实体对象UT1,第一管理项ITM1与第一实体对象UT1之间可以进行数据访问、调用等多种类型的数据交互操作。第一管理项ITM1包括第一实体对象UT1的第一变更信息,例如该第一变更信息可以包括第一实体对象UT1的当前版本信息(version)、历史版本信息、版本变更信息等,由此可以基于第一管理项ITM1中记录的第一变更信息,用于辅助对第一实体对象UT1的数据进行更新。
例如,对于上述步骤S12,在为第二实体对象UT2创建第二管理项ITM2后,将第二实体对象UT2绑定至创建的第二管理项ITM2,例如第二管理项ITM2指向第二实体对象UT2,第二管理项ITM2与第二实体对象UT2之间可以进行数据访问、调用等多种类型的数据交互操作。第二管理项ITM2包括第二实体对象UT2的第二变更信息,例如该第二变更信息可以包括第二实体对象UT2的当前版本信息、历史版本信息、版本变更信 息等,由此可以基于第二管理项ITM2中记录的第二变更信息,用于辅助对第二实体对象UT2的数据进行更新。
例如,对于上述步骤S13,通过建立第一管理项ITM1与第二管理项ITM2之间的第一层级关系,可以构成由第一管理项ITM1和第二管理项ITM2分别作为数据元素的数据结构。并且,由于该第一层级关系是基于第一实体对象UT1和第二实体对象UT2之间的逻辑关系建立,因此,第一实体对象UT1与第二实体对象UT2之间的层级关系或关联关系也可以通过建立的该第一层级关系体现。
例如,第一管理项ITM1与第二管理项ITM2之间的第一层级关系可以为图3中所示的从属关系,即第二管理项ITM2从属于第一管理项ITM1,由此构成图3中所示的以第一管理项ITM1和第二管理项ITM2分别作为父结点和子结点的树形结构。或者,基于第一实体对象UT1和第二实体对象UT2之间的不同逻辑关系,第一管理项ITM1与第二管理项ITM2之间的第一层级关系也可以相应地为并列关系、链接关系等,由此以使第一管理项ITM1与第二管理项ITM2形成其他类型的数据结构。
需要说明的是,图3中示出了2个第二实体对象UT2以及为这2个第二实体对象UT2创建的2个第二管理项ITM2,且这2个第二管理项ITM2均从属于第一管理项ITM1。在本公开的其他一些实施例中,第二实体对象UT2以及对应的第二管理项ITM2的个数也可以为1个、3个、4个或更多个,且多个第二管理项ITM2各自与第一管理项ITM1之间的层级关系可以彼此相同,也可以彼此不同,本公开的实施例对此均不作具体限制。
例如,对于上述步骤S14,在建立由第一管理项ITM1和第二管理项ITM2分别作为数据元素的数据结构之后,可以根据第一实体对象UT1与第二实体对象UT2之间的逻辑关系的变更,对第一层级关系进行修改,由此以使第一管理项ITM1和第二管理项ITM2之间的第一层级关系与第一实体对象UT1和第二实体对象UT2之间的逻辑关系保持一致。
本公开至少一实施例提供的数据处理方法中,不需要直接建立第一实体对象UT1与第二实体对象UT2之间的层级关系或关联关系,而是在绑定至第一实体对象UT1的第一管理项ITM1与绑定至第二实体对象UT2的第二管理项ITM2之间建立第一层级关系,进而通过该第一层级关系建立以及管理第一实体对象UT1与第二实体对象UT2之间的关联。
例如,以第二实体对象UT2从属于第一实体对象UT1为例,在第一实体对象UT1与第二实体对象UT2之间的逻辑关系发生变更时,例如第二实体对象UT2不再从属于第一实体对象UT1时,对于直接建立第一实体对象UT1与第二实体对象UT2之间的层级关系的情形,由于用于实现上述层级关系的数据需要被存储在第一实体对象UT1和/或第二实体对象UT2中,因此需要访问并修改第一实体对象UT1和/或第二实体对象UT2的数据,以变更第一实体对象UT1与第二实体对象UT2之间的层级关系。当第一实体对象UT1和第二实体对象UT2的整体数据量较大时,上述访问更新操作可能会产生大量的数据运算量,导致数据的处理速度以及处理效率严重降低。但是,对于本公开实施例提供 的数据处理方法,在第一实体对象UT1与第二实体对象UT2之间的逻辑关系发生变更时,可以通过修改第一管理项ITM1与第二管理项ITM2之间的第一层级关系,实现对第一实体对象UT1与第二实体对象UT2之间的层级关系或关联关系的变更,无需访问或修改第一实体对象UT1和/或第二实体对象UT2的数据,从而降低了所需的运算量,提高了数据处理速度及数据处理效率。
并且,在本公开上述实施例提供的数据处理方法中,第一管理项ITM1和第二管理项ITM2分别存储有第一实体对象UT1的第一变更信息和第二实体对象UT2的第二变更信息,由此基于第一管理项ITM1和第二管理项ITM2中分别记录的第一变更信息和第二变更信息,可以准确且高效地获取对应的第一实体对象UT1和第二实体对象UT2的例如版本变更信息,从而减小对第一实体对象UT1和第二实体对象UT2进行更新时所需的运算量。
例如,第一实体对象UT1与第一管理项ITM1之间彼此分离存储,也即,第一管理项ITM1独立于第一实体对象UT1存储,具有不同的存储地址;第二实体对象UT2与第二管理项ITM2之间彼此分离存储,也即,第二管理项ITM2独立于第二实体对象UT2存储,具有不同的存储地址。
例如,当第一实体对象对应于“团队”时,可以与其他对应于“团队”的实体对象由同一团队服务模块(提供团队管理服务,例如也可以被称为团队服务器)进行存储并处理;当第二实体对象对应于“群组”时,可以与其他对应于“群组”的实体对象由同一群组服务模块(提供群组管理服务,例如也可以被称为群组服务器)进行存储并处理;第一管理项和第二管理项可以与其他管理项一起由管理项服务模块(提供管理项服务,例如也可以被称为管理项服务器)进行存储并处理。在该实施例中,在系统的服务端,团队服务模块、群组服务模块和管理项服务模块可以分别运行在不同的设备硬件中,或者运行在同一硬件设备中。服务端还可以包括消息网关(im-gateway),该消息网关用来接收来自客户端的消息,或者分发从服务端到客户端的服务器消息,实现服务端与客户端之间数据交换以及同步,例如服务器消息包括更新信息、用户操作指令反馈等。同样地,客户端也可以包括消息网关,该消息网关用来接收来自服务端的消息,或者发送从客户端到服务端的客户端消息,该客户端消息包括用户通过客户端上的操作界面输入的操作指令,这些操作指令包括输入的信息、发送的图片信息、创建群组、设置用户属性等。
例如,可以在服务端和/或客户端提供SDK(Software Development Kit,软件开发工具包)以实现相应的数据处理方法。
例如,在建立或修改第一管理项ITM1与第二管理项ITM2之间的第一层级关系时,需要对第一管理项ITM1的数据和第二管理项ITM2的数据进行修改。通过上述将第一实体对象UT1与第一管理项ITM1之间彼此分离存储以及将第二实体对象UT2与第二管理项ITM2之间彼此分离存储的方式,在第一实体对象UT1与第二实体对象UT2之间的逻辑关系发生变更时,仅需访问、调用或修改第一管理项ITM1和第二管理项ITM2的相应 数据,从而减少了所需的运算量,提高了数据处理速度及数据处理效率。
例如,本公开的实施例对第一实体对象UT1、第二实体对象UT2、第一管理项ITM1和第二管理项ITM2的数据类型、存储结构、存储的数据内容等均不作具体限制。例如,第一管理项ITM1和第二管理项ITM2每个可以具有这些属性:自身识别号(id)、被绑定实体对象ID(entity_id)、被绑定实体对象类型(entity_type)、父结点识别号(parent_id)、状态(status或is_deleted)等。当一个管理项被删除时,或该管理项对应的实体对象被删除或被解散时,则这个管理项的状态值被改变,例如以0表示有效而1表示被删除。例如,第一实体对象UT1对应于团队,其可以具有这些属性:团队自身识别号(team_id),以及其他与团队相关的属性;第二实体对象UT2对应于群组,其可以具有这些属性:群组自身识别号(chat_id),以及其他与群组相关的属性。
又例如,以将本公开实施例提供的数据处理方法应用于社交应用程序中为例,第一实体对象UT1和第二实体对象UT2各自可以对应于该社交应用程序中的一个包含多个用户成员的群组。例如,第一实体对象UT1可以为包括多个用户成员的第一用户群组,第二实体对象UT2可以为包括多个用户成员的第二用户群组。例如,以第二实体对象UT2从属于第一实体对象UT1为例,第二用户群组为第一用户群组的子集,也即,第二用户群组的全部用户成员均被包含在第一用户群组的用户成员内。
例如,第一实体对象UT1的类型可以不同于第二实体对象UT2的类型。由此,通过建立并维护第一管理项ITM1与第二管理项ITM2之间的第一层级关系,可以优化对不同类型的实体对象之间的关联关系或层级关系的建立和维护,降低对不同类型的实体对象的数据进行访问、调用或修改时所需的运算量,提高数据处理速度及数据处理效率。
例如,在本公开的一些实施例中,如图3所示,第二实体对象UT2从属于第一实体对象UT1。相应地,在第一层级关系中,第一管理项ITM1作为父结点,第二管理项ITM2为该父结点的子结点。该示例中,在将第一实体对象UT1绑定至第一管理项ITM1之后,第一管理项ITM1的entity_id被修该为第一实体对象UT1的team_id,且第一管理项ITM1的entity_type被修该为第一实体对象UT1的类型,即团队。在将第二实体对象UT2绑定至第二管理项ITM2之后,第二管理项ITM2的entity_id被修该为第二实体对象UT2的chat_id,且第二管理项ITM2的entity_type被修该为第二实体对象UT2的类型,即群组。并且,当设定第二管理项ITM2从属于第一管理项ITM1时,则将第二管理项ITM2的parent_id修该为第一管理项ITM1的id。
下面,本公开的一些实施例以图3中所示的由第一管理项ITM1和第二管理项ITM2构成的树形结构为例,对本公开实施例提供的数据处理方法中的各个步骤进行具体说明。
例如,响应于第一实体对象的变更,本公开实施例提供的数据处理方法还包括以下步骤S21。
步骤S21:更新第一管理项的第一变更信息。
由此,在第一实体对象发生变更时,通过更新第一变更信息可以在第一管理项中对第一实体对象的当前版本信息、历史版本信息、或版本变更信息等进行记录,以有助于 后续基于第一变更信息对第一实体对象进行更新。
例如,响应于第二实体对象的变更,本公开实施例提供的数据处理方法还包括以下步骤S22。
步骤S22:更新第二管理项的第二变更信息。
由此,在第二实体对象发生变更时,通过更新第二变更信息可以在第二管理项中对第二实体对象的当前版本信息、历史版本信息、或版本变更信息等进行记录,以有助于后续基于第二变更信息对第二实体对象进行更新。
例如,第一变更信息包括用于记录第一实体对象的版本变更信息的第一序列号,第二变更信息包括用于记录第二实体对象的版本变更信息的第二序列号。例如,上述第一序列号和第二序列号可以为版本编号、变更操作编号或变更次数等用于体现对应的实体对象的变更信息的一个数字或一组编号等。例如,第一序列号和第二序列号中可以包括数字、字母、标识符等。
例如,上述步骤S21可以包括:对第一序列号进行增量操作,以更新第一序列号。例如,当第一实体对象发生变更时,对第一序列号进行增量操作,例如将第一序列号加1,由此可以提高第一变更信息的更新效率,提高数据处理速度及数据处理效率。
例如,上述步骤S22可以包括以下步骤S221和S222。
步骤S221:确定当前更新的目标第二管理项。
步骤S222:对目标第二管理项的第二序列号进行增量操作,以更新目标第二管理项的第二序列号。
例如,对于上述步骤S221和S222,以图3所示的情况为例,当第一管理项与多个第二管理项之间均具有第一层级关系时,需要在该多个第二管理项中确定当前更新的第二管理项为目标第二管理项。例如,当第一管理项仅与一个第二管理项之间具有第一层级关系时,则响应于该一个第二管理项的更新,确定该一个第二管理项为目标第二管理项。由此,当第二实体对象发生变更时,通过对相应的目标第二管理项的第二序列号进行增量操作,例如将第二序列号加1,可以提高目标第二管理项的第二变更信息的更新效率,从而提高数据处理速度及数据处理效率。
例如,当第一管理项与多个第二管理项之间均具有第一层级关系时(当与多个第二管理项之间具有第一层级关系时,该第一层级关系可以是一个层级关系,也可以是多个层级关系,例如具有递进层次的多个层级关系),多个第二管理项的第二序列号彼此不同且不重复使用。例如,在目标第二管理项的第二序列号更新之前或更新之后,该目标第二管理项的第二序列号不同于其他任一第二管理项的第二序列号。例如,在对目标第二管理项的第二序列号按照预设增量值进行增量操作时,如果增量操作后的目标第二管理项的第二序列号与其他任一第二管理项的第二序列号相同,则继续对该目标第二管理项的第二序列号进行增量操作,直到不同于其他任一第二管理项的第二序列号。
图4为本公开一些实施例提供的另一种数据处理方法的示意性流程图。需要说明的是,除步骤S34以外,步骤S31至S33和步骤S35分别与图2A中所示的数据处理方法 中的步骤S11至S14基本相同或相似,关于步骤S31至S33和步骤S35的具体说明可以分别参考上述数据处理方法的实施例中对应于图2A所示的步骤S11至S14的相关描述,重复之处不再赘述。图5为本公开一些实施例提供的另一种数据结构的示意图。需要说明的是,除变更信息管理条目ITMLST以外,图5所示的数据结构与图3所示的数据结构基本相同或相似,重复之处不再赘述。
如图4所示,该数据处理方法包括以下步骤S31至S35。
步骤S31:为第一实体对象创建第一管理项且将第一实体对象绑定至第一管理项,第一管理项包括第一实体对象的第一变更信息。
步骤S32:为多个第二实体对象分别创建多个第二管理项且将多个第二实体对象分别绑定至多个第二管理项,多个第二管理项分别包括对应的多个第二实体对象的第二变更信息。
步骤S33:基于第一实体对象与多个第二实体对象之间的逻辑关系,建立第一管理项与多个第二管理项之间的第一层级关系。
步骤S34:为第一管理项创建变更信息管理条目,变更信息管理条目包括变更序列号,变更序列号表示多个第二管理项的第二序列号中的最大第二序列号。
步骤S35:根据第一实体对象与多个第二实体对象之间的逻辑关系,维护第一层级关系。
例如,对于步骤S34,结合图5所示,在建立第一管理项ITM1与多个第二管理项ITM2之间的第一层级关系后,可以为第一管理项ITM1创建变更信息管理条目ITMLST,以用于记录多个第二管理项ITM2的第二序列号中的最大第二序列号,由此在对目标第二管理项的第二序列号进行更新时,可以基于变更信息管理条目ITMLST中的变更序列号,优化对目标第二管理项的第二序列号进行增量操作的具体操作流程。
例如,对应于各个管理项的变更信息管理条目也可以单独存储和管理,此时为了与相应的实体对象对应,变更信息管理条目可以包括这些属性:对应管理项ID(item_id)、管理项自身版本(version)、管理项子结点最大版本(Max_version)等;这里当变更信息管理条目对应的管理项没有子结点时,则管理项子结点最大版本(Max_version)可以没有或设置为缺省值(例如0)。例如,上述第一管理项的第一序列号以及第二管理项的第二序列号对应于上述管理项自身版本(version)属性,例如为自然数(例如为int64类型)。
图6为本公开一些实施例提供的一种对目标第二管理项的第二序列号进行更新的示意图。
例如,如图6所示,第一管理项ITM1包括第一序列号N1,两个第二管理项ITM21和ITM22分别包括彼此不同的第二序列号N21和N22,变更信息管理条目ITMLST包括变更序列号NCG。例如,上述变更信息管理条目ITMLST的变更序列号NCG对应于上述管理项子结点最大版本(Max_version),例如为自然数(例如为int64类型)。
例如,结合图6所示,以第二管理项ITM21为目标第二管理项为例,上述步骤S222 中的对目标第二管理项的第二序列号进行增量操作可以包括以下步骤S2221。
步骤S2221:获取变更序列号NCG,将目标第二管理项ITM21的第二序列号N21更新为变更序列号NCG与预定增量之和。
例如,如图6所示,在执行步骤S2221之前,第二管理项ITM21和ITM22的第二序列号N21和N22分别为1和2,变更信息管理条目ITMLST的变更序列号NCG为1和2中的最大第二序列号,也即为2。例如,以预定增量为1为例,在对目标第二管理项ITM21的第二序列号N21进行更新时,将第二序列号N21更新为变更序列号NCG与预定增量之和,也即,将第二序列号N21更新为2+1=3。
例如,结合图6所示,在执行上述步骤S2221之后,上述步骤S222中的对目标第二管理项的第二序列号进行增量操作还包括以下步骤S2222。
步骤S2222:在更新目标第二管理项ITM21的第二序列号N21之后,将变更序列号NCG更新为目标第二管理项ITM21的第二序列号N21。
例如,如图6所示,在将目标第二管理项ITM21的第二序列号N21更新为3之后,将变更序列号NCG也更新为3,由此使变更序列号NCG可以始终与第二管理项ITM21和ITM22的第二序列号N21和N22中的最大第二序列号保持一致。
例如,在图6所示的示例中,第一管理项ITM1的第一序列号N1为1。例如,在上述对目标第二管理项ITM21的第二序列号N21更新的过程中,第一管理项ITM1的第一序列号N1不需要相应发生变化。例如,第一管理项ITM1的第一序列号N1与第二管理项ITM21的第二序列号N21或第二管理项ITM22的第二序列号N22之间并没有直接关系,因此第一管理项ITM1的第一序列号N1不需要响应于第二序列号N21或N22的更新,且在对第一管理项ITM1的第一序列号N1进行编号的过程中,可以采用与第二序列号N21或N22相同的编号。
例如,在本公开的一些实施例中,上述数据处理方法可以被分别应用于服务端与客户端上。对于某一用户而言,服务端记录并维护了该用户针对第一实体对象、第二实体对象、第一管理项、第二管理项等的全量数据,该用户的某一客户端则记录并维护了该用户端针对第一实体对象、第二实体对象、第一管理项、第二管理项等的拷贝。服务端与客户端之间通过网络实现数据传输,实现对于服务端与客户端上存储的关于第一实体对象、第二实体对象、第一管理项、第二管理项等等的数据的同步更新。因此,即便用户通过不同的客户端以使用相应的软件时,可以获得全部过往历史信息或选择部分的历史信息。
图7为本公开一些实施例提供的再一种数据处理方法的示意性流程图。需要说明的是,除步骤S44至S47以外,步骤S41至S43和步骤S48分别与图2A中所示的数据处理方法中的步骤S11至S14基本相同或相似,关于步骤S41至S43和步骤S48的具体说明可以分别参考上述数据处理方法的实施例中对应于图2A所示的步骤S11至S14的相关描述,重复之处不再赘述。
如图7所示,该数据处理方法包括以下步骤S41至S48。
步骤S41:为第一实体对象创建第一管理项且将第一实体对象绑定至第一管理项,第一管理项包括第一实体对象的第一变更信息。
步骤S42:为多个第二实体对象分别创建多个第二管理项且将多个第二实体对象分别绑定至多个第二管理项,多个第二管理项分别包括对应的多个第二实体对象的第二变更信息。
步骤S43:基于第一实体对象与多个第二实体对象之间的逻辑关系,建立第一管理项与多个第二管理项之间的第一层级关系。
步骤S44:通过服务端处理第一实体对象、第一管理项、第二实体对象、第二管理项以及第一层级关系。
步骤S45:通过客户端处理第一实体对象的拷贝、第一管理项的拷贝、第二实体对象的拷贝、第二管理项的拷贝以及第一层级关系的拷贝。
步骤S46:允许客户端向服务端提供所接收的指令,用于通过服务端更新第一实体对象、第一管理项、第二实体对象、第二管理项或第一层级关系。
步骤S47:允许客户端向服务端请求同步,以更新客户端各自处理的第一实体对象的拷贝、第一管理项的拷贝、第二实体对象的拷贝、第二管理项的拷贝以及第一层级关系的拷贝。
步骤S48:根据第一实体对象与多个第二实体对象之间的逻辑关系,维护第一层级关系。
例如,对于上述步骤S44至S47,服务端上存储有第一实体对象、第一管理项、第二实体对象、第二管理项以及第一层级关系,也即,存储有关于第一实体对象、第一管理项、第二实体对象、第二管理项以及第一层级关系的第一数据;客户端上存储有第一实体对象的拷贝、第一管理项的拷贝、第二实体对象的拷贝、第二管理项的拷贝以及第一层级关系的拷贝,也即,存储有关于第一实体对象、第一管理项、第二实体对象、第二管理项以及第一层级关系的第二数据。例如,当客户端接收到更新指令时,客户端对存储的第二数据进行更新,并向服务端提供所接收的更新指令,以使得服务端对存储的第一数据进行同步更新,从而使得服务端上的第一数据与客户端上的第二数据保持一致。
例如,当服务端与多个客户端之间均通过网络进行数据同步时,在服务端根据其中一个客户端提供的所接收的更新指令对第一数据进行同步更新后,当其他客户端向服务端请求同步时,其他客户端基于服务端更新后的第一数据对所存储的第二数据进行同步更新,由此使得服务端上的第一数据与不同客户端上的第二数据均保持一致。
例如,客户端可以通过运行程序或线程的方式执行上述操作,或者也可以利用其内置的应用程序或调用客户端外部存储的应用程序执行上述操作,本公开的实施例对此不作具体限制。
例如,上述步骤S44至S47还可以在步骤S48之后执行,以使得服务端上的第一数据与客户端上的第二数据之间可以保持同步。
图8为本公开一些实施例提供的一种数据处理方法的具体示例的示意性流程图。
例如,如图8所示,服务端SERV包括第一实体对象服务模块SERV1、第二实体对象服务模块SERV2以及管理项服务模块SERV3。第一实体对象服务模块SERV1向管理项服务模块SERV3发送第一创建请求RQ1,管理项服务模块SERV3响应于第一创建请求RQ1为第一实体对象创建第一管理项并将第一实体对象绑定至第一管理项,也即,执行例如上述图2A中所示的步骤S11。第二实体对象服务模块SERV2向管理项服务模块SERV3发送第二创建请求RQ2,管理项服务模块SERV3响应于第二创建请求RQ2为第二实体对象创建第二管理项并将第二实体对象绑定至第二管理项,也即,执行例如上述图2A中所示的步骤S12。管理项服务模块SERV3基于第一实体对象与第二实体对象之间的逻辑关系,建立并维护第一层级关系,也即,执行例如上述图2A中所示的步骤S13和S14。
此外,在至少一个实施例中,在客户端可以通过与服务端对应的第一实体对象服务模块SERV1、第二实体对象服务模块SERV2以及管理项服务模块SERV3,实现客户端本地的数据管理与维护。
例如,在本公开的一些实施例中,在客户端与服务端同步时,响应于第一管理项在第一层级关系中为第二管理项的父结点,先同步第一管理项与第一管理项的拷贝,然后同步第二管理项与第二管理项的拷贝。也即,在第一管理项与第二管理项之间的第一层级关系为例如图3中所示的第二管理项从属于第一管理项时,先对服务端上存储的第一管理项与客户端上存储的第一管理项的拷贝进行数据同步,然后在对服务端上存储的第二管理项与客户端上存储的第二管理项的拷贝进行数据同步。例如,当父结点的数据更新时,该父结点的所有子结点的数据均需要相应更新,因此,通过先对父结点进行同步之后在同步子结点,可以优化数据处理的操作流程,提升数据处理效率。
例如,对于一个父结点的多个子结点,该多个子结点的同步顺序可以根据该多个子结点对应的多个第二实体对象的数据确定。例如,以绑定至第一管理项的第一实体对象为上文中所述的团队为例,该团队的默认沟通群为一个第二实体对象,则可以优先对与该第二实体对象(也即默认沟通群)对应的子结点进行同步。
例如,在本公开的一些实施例中,该数据处理方法还包括以下步骤S51。
步骤S51:基于变更信息管理条目,对客户端进行同步。
例如,以图6所示的示例为例,当客户端与服务端同步时,在基于客户端上存储的第一管理项ITM1的拷贝的第一序列号N1与服务端上存储的第一管理项ITM1的第一序列号N1,对第一管理项ITM1的拷贝与第一管理项ITM1进行同步后,如果客户端上存储的变更信息管理条目ITMLST的拷贝中的变更序列号NCG与服务端上存储的变更信息管理条目ITMLST中的变更序列号NCG相同,则不需要对客户端上存储的第二管理项ITM2的拷贝与服务端上存储的第二管理项ITM2进行更新;如果客户端上存储的变更信息管理条目ITMLST的拷贝中的变更序列号NCG与服务端上存储的变更信息管理条目ITMLST中的变更序列号NCG不同,则需要根据服务端上存储的变更信息管理条目ITMLST中的变更序列号NCG以及客户端上存储的各第二管理项ITM2的拷贝的第二变 更序列号,确定客户端上需要进行更新的第二管理项ITM2的拷贝,以使客户端上存储的第二数据与服务端上存储的第一数据保持一致。
例如,如果服务端上存储的变更信息管理条目ITMLST中的变更序列号NCG为4,客户端上存储的变更信息管理条目ITMLST的拷贝中的变更序列号NCG为3,则仅需要找到服务端上第二变更序列号为4的第二管理项ITM2,并对客户端上对应的第二管理项ITM2的拷贝进行同步更新,无需对客户端上的其他第二管理项ITM2的拷贝进行同步更新,进而优化了数据处理的操作流程,提升了数据处理效率。进而,在对该对应的第二管理项ITM2的拷贝进行更新后,该对应的第二管理项ITM2的拷贝的第二变更序列号变为4,相应地,客户端上存储的变更信息管理条目ITMLST的拷贝中的变更序列号NCG也变为4,即与服务端上存储的变更信息管理条目ITMLST中的变更序列号NCG相同。
图9为本公开一些实施例提供的一种数据处理方法中的步骤S51的示意性流程图。
例如,如图9所示,上述步骤S51包括以下步骤S511至S513。
步骤S511:确定当前进行同步的目标客户端。
步骤S512:接受目标客户端进行第一同步的请求。
步骤S513:在从服务端对目标客户端进行第一同步之后,在服务端将第一同步中服务端发送给目标客户端的变更序列号记录为客户端最近变更序列号,在目标客户端将第一同步中服务端发送给目标客户端的变更序列号记录为客户端最大变更序列号。
例如,当服务端与多个客户端之间均通过网络进行数据同步时,需要在该多个客户端中确定当前进行同步的客户端为目标客户端。例如,当服务端仅需要与一个客户端之间保持数据同步时,则响应于该一个客户端的第一同步的请求,确定该一个客户端为目标客户端。
例如,在服务端接受目标客户端进行第一同步的请求后,目标客户端基于服务端上当前存储的变更信息管理条目进行第一同步。同时,在第一同步后,服务端将第一同步中发送给目标客户端的变更序列号记录为客户端最近变更序列号MAXCLT,目标客户端将第一同步中服务端发送的变更序列号记录为客户端最大变更序列号MAX。
例如,如图9所示,在本公开的一些实施例中,上述步骤S51还包括以下步骤S514至S518。
步骤S514:接受目标客户端进行第二同步的请求,第二同步在时间上与第一同步相邻。
步骤S515:从服务端向目标客户端发送客户端最近变更序列号以及接受第二同步的请求时服务端的变更序列号。
步骤S516:由目标客户端比较客户端最近变更序列号与客户端最大变更序列号。
响应于客户端最近变更序列号与客户端最大变更序列号相等:
步骤S517:将目标客户端根据客户端最大变更序列号以及服务端发送的变更序列号进行第二同步。
响应于客户端最近变更序列号与客户端最大变更序列号不等:
步骤S518:将目标客户端不限于客户端最大变更序列号进行第二同步。
例如,第二同步与第一同步在时间上紧邻,也即,在第一同步与第二同步之间,目标客户端与服务端之间没有进行过任何其他数据同步。在服务端接受目标客户端进行第二同步的请求后,服务端将存储的目标客户端的客户端最近变更序列号MAXCLT发送给目标客户端,目标客户端将存储的客户端最大变更序列号MAX与服务端发送的客户端最近变更序列号MAXCLT进行比较。如果客户端最近变更序列号MAXCLT与客户端最大变更序列号MAX相等,则执行步骤S517,根据服务端和目标客户端上当前的变更序列号进行第二同步;如果客户端最近变更序列号MAXCLT与客户端最大变更序列号MAX不等,则执行步骤S518,例如根据服务端上当前的变更序列号对客户端上的每个第二管理项的拷贝进行全局同步,也即,对客户端上的每个第二管理项的拷贝均进行同步,以避免客户端上的数据丢失或出现错误。
图10为本公开一些实施例提供的再一种数据处理方法的示意性流程图。需要说明的是,除步骤S64和S65以外,步骤S61至S63和步骤S66分别与图2A中所示的数据处理方法中的步骤S11至S14基本相同或相似,关于步骤S61至S63和步骤S66的具体说明可以分别参考上述数据处理方法的实施例中对应于图2A所示的步骤S11至S14的相关描述,重复之处不再赘述。
图11为本公开一些实施例提供的再一种数据结构的示意图。需要说明的是,除第一顺序条目ITMORD和变更信息管理条目ITMLST以外,图11所示的数据结构与图3所示的数据结构基本相同或相似,或者,除第一顺序条目ITMORD以外,图11所示的数据结构与图5所示的数据结构基本相同或相似,重复之处不再赘述。
如图10所示,在本公开的一些实施例中,该数据处理方法包括以下步骤S61至S64和步骤S66。
步骤S61:为第一实体对象创建第一管理项且将第一实体对象绑定至第一管理项,第一管理项包括第一实体对象的第一变更信息。
步骤S62:为多个第二实体对象分别创建多个第二管理项且将多个第二实体对象分别绑定至多个第二管理项,多个第二管理项分别包括对应的多个第二实体对象的第二变更信息。
步骤S63:基于第一实体对象与多个第二实体对象之间的逻辑关系,建立第一管理项与多个第二管理项之间的第一层级关系。
步骤S64:为多个第二管理项分别创建多个第一顺序条目,以用于记录多个第二管理项之间的第一排序信息。
步骤S66:根据第一实体对象与多个第二实体对象之间的逻辑关系,维护第一层级关系。
如图10所示,在本公开的一些实施例中,在执行步骤S64之后,该数据处理方法还包括以下步骤S65。
步骤S65:根据多个第一顺序条目,在多个第二管理项之间进行第一排序。
例如,参考图10和图11所示,第一顺序条目ITMORD可以包括对应的第二管理项ITM2的第一排序类型信息和/或第一排序权重信息,由此可以根据不同实际需求,根据第二管理项ITM2的第一顺序条目ITMORD中的信息,对第二管理项ITM2采用不同的排序方式。例如,可以根据第二管理项ITM2的第一顺序条目ITMORD中的信息,按照第二管理项ITM2的创建时间进行第一排序,或者按照第二管理项ITM2对应的第二实体对象UT2的权重进行第一排序等等,本公开的实施例对此不作具体限制。
图12为本公开一些实施例提供的一种数据处理方法中的步骤S65的示意性流程图。
例如,如图12所示,在本公开的一些实施例中,上述步骤S65可以包括以下步骤S651。
步骤S651:基于多个第二管理项对应的第一排序类型信息和/或第一排序权重信息,在多个第二管理项之间进行第一排序。
例如,步骤S651中的第一排序类型信息可以包括第二管理项的创建时间、命名字符或更新时间等。
例如,如图12所示,在本公开的一些实施例中,上述步骤S65还可以包括以下步骤S652。
步骤S652:对于第一排序后的多个第二管理项每个分别赋予顺序标识号,第一排序后的多个第二管理项对应的多个顺序标识号中至少两个不依序递增。
例如,多个第二管理项对应的多个顺序标识号按照预定间隔递增,预定间隔大于1。
例如,如图12所示,在本公开的一些实施例中,在上述步骤S652之后,上述步骤S65还可以包括以下步骤S653。
响应于插入一个新的第二管理项:
步骤S653:重新进行第一排序之后,确定新的第二管理项与在第一排序中前后紧相邻的两个第二管理项的顺序标识号之间的算术差。
例如,如果算术差小于或等于预定间隔且大于预定偏移,则将新的第二管理项的顺序标识号确定为在第一排序中前紧相邻的第二管理项的顺序标识号与预定偏移之和。例如,预定偏移大于等于1且小于预定间隔。
例如,为第二管理项设置的顺序标识号可以按照一定的预定间隔来处理,例如多个第二管理项的顺序标识号可以设置为0、1024、2048、3072,等等,以此类推。这样,在两个相邻的第二管理项之间插入新的第二管理项时,只需要把新插入的第二管理项的顺序标识号记为例如512即可,从而减少所需的运算量,提高数据处理效率。
例如,若两个相邻的第二管理项之间的顺序标识号均已被占用时,例如以顺序标识号0、1、2、8、256、512为例,其中0~2之间是无法添加新的顺序标识号的。如果需要在顺序标识号0和1对应的两个第二管理项之间插入新的第二管理项时,则需要对顺序标识号0对应的第二管理项之后的所有第二管理项按照预定偏移进行偏移操作,且预定偏移大于等于1且小于预定间隔。例如,以预定间隔设置为512,预定偏移设置为8为例,在进行偏移操作时,依次对需要偏移的第二管理项的顺序标识号按照预定偏移进行递加, 直至下一个顺序标识号与当前顺序标识号之间的差值小于预定偏移,可以重复执行上述偏移操作。例如,按照上述操作方法,生成的新的顺序标识号为:0、8、16、24、32、256、512。
例如,在本公开的一些实施例中,该数据处理方法还包括以下步骤S71。
步骤S71:为多个第二管理项分别创建多个第二顺序条目,以用于记录多个第二管理项之间的第二排序信息,第二排序信息不同于第一排序信息。
例如,在本公开的一些实施例中,该数据处理方法还包括以下步骤S72。
步骤S72:根据多个第二顺序条目,在多个第二管理项之间进行第二排序。
例如,多个第二顺序条目分别包括对应的第二管理项的第二排序类型信息和/或第二排序权重信息。由此,可以基于不同于第一排序信息的第二排序信息,对多个第二顺序条目之间进行第二排序,以得到与进行第一排行后不同的顺序,进而提升多个第二顺序条目之间的排序方式的灵活性和多样性,以满足不同实际需求并适用于不同应用场景中。
例如,上述步骤S72可以包括:基于多个第二管理项对应的第二排序类型信息和/或第二排序权重信息,在多个第二管理项之间进行第二排序。由此,以得到进行第二排序后的多个第二管理项。
例如,在本公开的一些实施例中,第二管理项包括结点标识信息,例如,该结点标识信息可以用于表示第二管理项与第一管理项之间的第一层级关系,例如用于表示第二管理项从属于第一管理项。例如,在第二管理项从属于第一管理项的情况下,该结点标识信息中可以包括第二管理项指向第一管理项的结构性信息。
例如,在本公开的一些实施例中,该数据处理方法还包括:响应于建立第一管理项与第二管理项之间的第一层级关系,更新第二管理项的结点标识信息以指向第一管理项。由此,以通过第二管理项的结点标识信息,记录该第一层级关系。例如,在后续步骤中该第一层级关系发生变更的情况下,同样可以通过更新该结点标识信息,以实现第一层级关系的变更。
例如,在本公开的一些实施例中,图2A中所示的上述步骤S11可以包括以下步骤S110。
步骤S110:根据预定管理项模板,基于第一实体对象的数据,创建第一管理项。
例如,在本公开的一些实施例中,图2A中所示的上述步骤S12可以包括以下步骤S120。
步骤S120:根据预定管理项模板,基于第二实体对象的数据,创建第二管理项。
例如,管理项模板包括标识信息项目和类型信息项目等,例如可以分别对应于上述自身识别号(id)、被绑定实体对象类型(entity_type),标识信息项目用于记录绑定至管理项的实体对象的标识信息,类型信息项目用于记录绑定至管理项的实体对象的类型信息。根据需要,管理项模板还可以包括对应于被绑定实体对象ID(entity_id)、父结点识别号(parent_id)、状态(status或is_deleted)等数据项。
例如,管理项服务模块在接收了针对某一实体对象创建管理项的请求之后,使用管 理项模板生成新的管理项,并对该新生成的管理项赋值,已将该管理项与该实体对象关联。
例如,在本公开的一些实施例中,响应于第一实体对象与第二实体对象之间的逻辑关系变更,图2A中所示的上述步骤S14可以包括以下步骤S141。
步骤S141:修改第一层级关系。
进而,在第一实体对象与第二实体对象之间的逻辑关系发生变更时,可以通过修改第一管理项与第二管理项之间的第一层级关系,实现对第一实体对象与第二实体对象之间的层级关系或关联关系的变更,无需访问或修改第一实体对象和/或第二实体对象的数据,从而降低了所需的运算量,提高了数据处理速度及数据处理效率。
例如,逻辑关系变更可以包括第一实体对象被删除,使得第一实体对象与第二实体对象之间不具有关联关系,例如,逻辑关系变更还可以包括每个第二实体对象均被删除,使得第一实体对象与任一第二实体对象之间均不具有关联关系。
在上述第一实体对象与第二实体对象之间不具有关联关系的情况下,上述步骤S141中的修改第一层级关系可以包括:解除第一层级关系。由此可以使第一实体对象与第二实体对象之间的关联关系或层级关系的解除不需要通过对第一实体对象与第二实体对象的数据进行修改而实现,进而降低了不同实体对象之间的逻辑关系发生变更时所需的运算量,提高数据处理速度及数据处理效率,同时也有助于实现对数据结构的优化。
例如,在本公开的一些实施例中,响应于第二实体对象的数量的增减,图2A中所示的上述步骤S14可以包括以下步骤S142。
步骤S142:更新第一层级关系。
例如,在第二实体对象的数量的增加时,通过为新增的第二实体对象创建相应的第二管理项,并建立该第二管理项之间的第一层级关系,由此可以实现对第一管理项和第二管理项构成的数据结构的更新。例如,在第二实体对象的数量的减少时,例如某一个第二实体对象被删除时,解除该第二实体对象对应的第二管理项(例如为待操作第二管理项)与第一管理项之间的第一层级关系,并删除对应的第二管理项,由此实现对第一管理项和第二管理项构成的数据结构的更新。
例如,以第一实体对象对应于第一对象集合,第二实体对象对应于第二对象集合为例,响应于第二实体对象从属于第一实体对象,该数据处理方法还包括:修改第一实体对象的数据,使得第二对象集合为第一对象集合的子集。
例如,以将本公开实施例提供的数据处理方法应用于社交应用程序中为例,第一实体对象和第二实体对象各自可以对应于该社交应用程序中的一个包含多个用户成员的集合。例如,第一实体对象可以为包括多个用户成员的第一用户集合,也即,第一对象集合;第二实体对象可以为包括多个用户成员的第二用户集合,也即,第二对象集合。例如,当第二实体对象从属于第一实体对象时,第二用户集合为第一用户集合的子集,也即,第二用户集合的全部用户成员均被包含在第一用户集合的用户成员内。
例如,第一对象集合的成员可以与第二对象集合的成员保持相同。
需要说明的是,在本公开的实施例中,本公开上述各个实施例提供的数据处理方法的流程可以包括更多或更少的操作,这些操作可以顺序执行或并行执行。虽然上文描述的数据处理方法的流程包括特定顺序出现的多个操作,但是应该清楚地了解,多个操作的顺序并不受限制。上文描述的数据处理方法可以执行一次,也可以按照预定条件执行多次。
本公开至少一个实施例还提供一种数据处理装置,该数据处理装置包括第一管理项处理单元、第二管理项处理单元、层级关系建立单元和层级关系维护单元;第一管理项处理单元配置为:为第一实体对象创建第一管理项且将第一实体对象绑定至第一管理项,第一管理项包括第一实体对象的第一变更信息;第二管理项处理单元配置为:为至少一个第二实体对象分别创建至少一个第二管理项且将至少一个第二实体对象分别绑定至至少一个第二管理项,至少一个第二管理项分别包括对应的至少一个第二实体对象的第二变更信息;层级关系建立单元配置为:基于第一实体对象与至少一个第二实体对象之间的逻辑关系,建立第一管理项与至少一个第二管理项之间的第一层级关系;层级关系维护单元配置为:根据第一实体对象与至少一个第二实体对象之间的逻辑关系,维护第一层级关系。
本公开上述实施例提供的数据处理装置通过将第一实体对象绑定至独立于第一实体对象的第一管理项,且将第二实体对象绑定至独立于第二实体对象的第二管理项,并建立第一管理项与第二管理项之间的第一层级关系,由此可以使第一实体对象与第二实体对象之间的关联关系的变更通过对该第一层级关系进行修改而实现,从而降低不同实体对象之间的逻辑关系发生变更时所需的运算量,提高数据处理速度及数据处理效率,同时也有助于实现对数据结构的优化,提高上层应用的灵活性。
图13为本公开一些实施例提供的一种数据处理装置的示意框图。
例如,如图13所示,该数据处理装置600包括第一管理项处理单元601、第二管理项处理单元602、层级关系建立单元603和层级关系维护单元604。
第一管理项处理单元601配置为:为第一实体对象创建第一管理项且将第一实体对象绑定至第一管理项,第一管理项包括第一实体对象的第一变更信息。例如,第一管理项处理单元601可以执行图2A中所示的数据处理方法中的步骤S11。
第二管理项处理单元602配置为:为至少一个第二实体对象分别创建至少一个第二管理项且将至少一个第二实体对象分别绑定至至少一个第二管理项,至少一个第二管理项分别包括对应的至少一个第二实体对象的第二变更信息。例如,第二管理项处理单元602可以执行图2A中所示的数据处理方法中的步骤S12。
层级关系建立单元603配置为:基于第一实体对象与至少一个第二实体对象之间的逻辑关系,建立第一管理项与至少一个第二管理项之间的第一层级关系。例如,层级关系建立单元603可以执行图2A中所示的数据处理方法中的步骤S13。
层级关系维护单元604配置为:根据第一实体对象与至少一个第二实体对象之间的逻辑关系,维护第一层级关系。例如,层级关系维护单元604可以执行图2A中所示的数 据处理方法中的步骤S14。
例如,第一管理项处理单元601、第二管理项处理单元602、层级关系建立单元603和层级关系维护单元604包括存储在存储器中的代码和程序;处理器可以执行该代码和程序以实现如上所述的第一管理项处理单元601、第二管理项处理单元602、层级关系建立单元603和层级关系维护单元604的一些功能或全部功能。例如,第一管理项处理单元601、第二管理项处理单元602、层级关系建立单元603和层级关系维护单元604可以是专用硬件器件,用来实现如上所述的第一管理项处理单元601、第二管理项处理单元602、层级关系建立单元603和层级关系维护单元604的一些或全部功能。例如,第一管理项处理单元601、第二管理项处理单元602、层级关系建立单元603和层级关系维护单元604可以是一个电路板或多个电路板的组合,用于实现如上所述的功能。在本申请实施例中,该一个电路板或多个电路板的组合可以包括:(1)一个或多个处理器;(2)与处理器相连接的一个或多个非暂时的存储器;以及(3)处理器可执行的存储在存储器中的固件。
需要说明的是,关于第一管理项处理单元601、第二管理项处理单元602、层级关系建立单元603和层级关系维护单元604的具体说明可以分别参考上述数据处理方法的实施例中对应于图2A所示的步骤S11至步骤S14的相关描述。此外,数据处理装置可以实现与前述数据处理方法相似的技术效果,在此不再赘述。
本公开至少一个实施例还提供一种电子设备,该电子设备包括处理器和存储器。该存储器包括一个或多个计算机可执行指令。一个或多个计算机可执行指令被存储在存储器中并被配置为由处理器执行,一个或多个计算机可执行指令用于实现本公开任一实施例提供的数据处理方法。
图14为本公开一些实施例提供的一种电子设备的示意框图。如图14所示,该电子设备300包括处理器310和存储器320,可以用于实现客户端或服务端,以分别实现对应的方法。存储器320用于非瞬时性地存储有计算机可执行指令(例如一个或多个计算机程序模块)。处理器310用于运行该计算机可执行指令,该计算机可执行指令被处理器310运行时可以执行上文所述的数据处理方法中的一个或多个步骤,进而实现上文所述的数据处理方法。存储器320和处理器310可以通过总线系统和/或其它形式的连接机构(未示出)互连。
例如,处理器310可以是中央处理单元(CPU)、图形处理单元(GPU)或者具有数据处理能力和/或程序执行能力的其它形式的处理单元。例如,中央处理单元(CPU)可以为X86或ARM架构等。处理器310可以为通用处理器或专用处理器,可以控制电子设备300中的其它组件以执行期望的功能。
例如,存储器320可以包括一个或多个计算机程序产品的任意组合,计算机程序产品可以包括各种形式的计算机可读存储介质,例如易失性存储器和/或非易失性存储器。易失性存储器例如可以包括随机存取存储器(RAM)和/或高速缓冲存储器(cache)等。非易失性存储器例如可以包括只读存储器(ROM)、硬盘、可擦除可编程只读存储器 (EPROM)、便携式紧致盘只读存储器(CD-ROM)、USB存储器、闪存等。在计算机可读存储介质上可以存储一个或多个计算机程序模块,处理器310可以运行一个或多个计算机程序模块,以实现电子设备300的各种功能。在计算机可读存储介质中还可以存储各种应用程序和各种数据以及应用程序使用和/或产生的各种数据等。
需要说明的是,本公开的实施例中,电子设备300的具体功能和技术效果可以参考上文中关于数据处理方法的描述,此处不再赘述。
图15为本公开一些实施例提供的另一种电子设备的示意框图。该电子设备400例如适于用来实施本公开实施例提供的数据处理方法。电子设备400可以是终端设备等,可以用于实现客户端或服务端。电子设备400可以包括但不限于诸如移动电话、笔记本电脑、数字广播接收器、PDA(个人数字助理)、PAD(平板电脑)、PMP(便携式多媒体播放器)、车载终端(例如车载导航终端)、可穿戴电子设备等等的移动终端以及诸如数字TV、台式计算机、智能家居设备等等的固定终端。需要注意的是,图15示出的电子设备400仅仅是一个示例,其不会对本公开实施例的功能和使用范围带来任何限制。
如图15所示,电子设备400可以包括处理装置(例如中央处理器、图形处理器等)410,其可以根据存储在只读存储器(ROM)420中的程序或者从存储装置480加载到随机访问存储器(RAM)430中的程序而执行各种适当的动作和处理。在RAM 430中,还存储有电子设备400操作所需的各种程序和数据。处理装置410、ROM 420以及RAM 430通过总线440彼此相连。输入/输出(I/O)接口450也连接至总线440。
通常,以下装置可以连接至I/O接口450:包括例如触摸屏、触摸板、键盘、鼠标、摄像头、麦克风、加速度计、陀螺仪等的输入装置460;包括例如液晶显示器(LCD)、扬声器、振动器等的输出装置470;包括例如磁带、硬盘等的存储装置480;以及通信装置490。通信装置490可以允许电子设备400与其他电子设备进行无线或有线通信以交换数据。虽然图15示出了具有各种装置的电子设备400,但应理解的是,并不要求实施或具备所有示出的装置,电子设备400可以替代地实施或具备更多或更少的装置。
例如,根据本公开的实施例,上述数据处理方法可以被实现为计算机软件程序。例如,本公开的实施例包括一种计算机程序产品,其包括承载在非暂态计算机可读介质上的计算机程序,该计算机程序包括用于执行上述数据处理方法的程序代码。在这样的实施例中,该计算机程序可以通过通信装置490从网络上被下载和安装,或者从存储装置480安装,或者从ROM 420安装。在该计算机程序被处理装置410执行时,可以实现本公开实施例提供的数据处理方法中限定的功能。
图16为本公开一些实施例提供的一种存储介质的示意图。例如,如图16所示,存储介质500可以为非暂时性计算机可读存储介质,用于存储非暂时性计算机可执行指令501。当非暂时性计算机可执行指令501由处理器执行时可以实现本公开实施例所述的数据处理方法,例如,当非暂时性计算机可执行指令501由处理器执行时,可以执行根据上文所述的数据处理方法中的一个或多个步骤。
例如,该存储介质500可以应用于上述电子设备中,例如,该存储介质500可以包 括电子设备中的存储器。
例如,存储介质可以包括智能电话的存储卡、平板电脑的存储部件、个人计算机的硬盘、随机存取存储器(RAM)、只读存储器(ROM)、可擦除可编程只读存储器(EPROM)、便携式紧致盘只读存储器(CD-ROM)、闪存、或者上述存储介质的任意组合,也可以为其他适用的存储介质。
例如,关于存储介质500的说明可以参考电子设备的实施例中对于存储器的描述,重复之处不再赘述。存储介质500的具体功能和技术效果可以参考上文中关于数据处理方法的描述,此处不再赘述。
需要说明的是,在本公开的上下文中,计算机可读介质可以是有形的介质,其可以包含或存储以供指令执行系统、装置或设备使用或与指令执行系统、装置或设备结合地使用的程序。计算机可读介质可以是计算机可读信号介质或者计算机可读存储介质或者是上述两者的任意组合。计算机可读存储介质例如可以是,但不限于:电、磁、光、电磁、红外线、或半导体的系统、装置或器件,或者任意以上的组合。计算机可读存储介质的更具体的例子可以包括但不限于:具有一个或多个导线的电连接、便携式计算机磁盘、硬盘、随机访问存储器(RAM)、只读存储器(ROM)、可擦式可编程只读存储器(EPROM或闪存)、光纤、便携式紧凑磁盘只读存储器(CD-ROM)、光存储器件、磁存储器件、或者上述的任意合适的组合。在本公开中,计算机可读存储介质可以是任何包含或存储程序的有形介质,该程序可以被指令执行系统、装置或者器件使用或者与其结合使用。而在本公开中,计算机可读信号介质可以包括在基带中或者作为载波一部分传播的数据信号,其中承载了计算机可读的程序代码。这种传播的数据信号可以采用多种形式,包括但不限于电磁信号、光信号或上述的任意合适的组合。计算机可读信号介质还可以是计算机可读存储介质以外的任何计算机可读介质,该计算机可读信号介质可以发送、传播或者传输用于由指令执行系统、装置或者器件使用或者与其结合使用的程序。计算机可读介质上包含的程序代码可以用任何适当的介质传输,包括但不限于:电线、光缆、RF(射频)等等,或者上述的任意合适的组合。
在一些实施方式中,客户端、服务端可以利用诸如HTTP(HyperText Transfer Protocol,超文本传输协议)之类的任何当前已知或未来研发的网络协议进行通信,并且可以与任意形式或介质的数字数据通信(例如,通信网络)互连。通信网络的示例包括局域网(“LAN”),广域网(“WAN”),网际网(例如,互联网)以及端对端网络(例如,ad hoc端对端网络),以及任何当前已知或未来研发的网络。
上述计算机可读介质可以是上述电子设备中所包含的;也可以是单独存在,而未装配入该电子设备中。
可以以一种或多种程序设计语言或其组合来编写用于执行本公开的操作的计算机程序代码,上述程序设计语言包括但不限于面向对象的程序设计语言,诸如Java、Smalltalk、C++,还包括常规的过程式程序设计语言,诸如“C”语言或类似的程序设计语言。程序代码可以完全地在用户计算机上执行、部分地在用户计算机上执行、作为一个独立的软 件包执行、部分在用户计算机上部分在远程计算机上执行、或者完全在远程计算机或服务器上执行。在涉及远程计算机的情形中,远程计算机可以通过任意种类的网络(,包括局域网(LAN)或广域网(WAN))连接到用户计算机,或者,可以连接到外部计算机(例如利用因特网服务提供商来通过因特网连接)。
附图中的流程图和框图,图示了按照本公开各种实施例的系统、方法和计算机程序产品的可能实现的体系架构、功能和操作。在这点上,流程图或框图中的每个方框可以代表一个模块、程序段、或代码的一部分,该模块、程序段、或代码的一部分包含一个或多个用于实现规定的逻辑功能的可执行指令。也应当注意,在有些作为替换的实现中,方框中所标注的功能也可以以不同于附图中所标注的顺序发生。例如,两个接连地表示的方框实际上可以基本并行地执行,它们有时也可以按相反的顺序执行,这依所涉及的功能而定。也要注意的是,框图和/或流程图中的每个方框、以及框图和/或流程图中的方框的组合,可以用执行规定的功能或操作的专用的基于硬件的系统来实现,或者可以用专用硬件与计算机指令的组合来实现。
描述于本公开实施例中所涉及到的单元可以通过软件的方式实现,也可以通过硬件的方式来实现。其中,单元的名称在某种情况下并不构成对该单元本身的限定。
本文中以上描述的功能可以至少部分地由一个或多个硬件逻辑部件来执行。例如,非限制性地,可以使用的示范类型的硬件逻辑部件包括:现场可编程门阵列(FPGA)、专用集成电路(ASIC)、专用标准产品(ASSP)、片上系统(SOC)、复杂可编程逻辑设备(CPLD)等等。
根据本公开的一个或多个实施例,一种数据处理方法,包括:为第一实体对象创建第一管理项且将所述第一实体对象绑定至所述第一管理项,其中,所述第一管理项包括所述第一实体对象的第一变更信息;为至少一个第二实体对象分别创建至少一个第二管理项且将所述至少一个第二实体对象分别绑定至所述至少一个第二管理项,其中,所述至少一个第二管理项分别包括对应的所述至少一个第二实体对象的第二变更信息;基于所述第一实体对象与所述至少一个第二实体对象之间的逻辑关系,建立所述第一管理项与所述至少一个第二管理项之间的第一层级关系;以及根据所述第一实体对象与所述至少一个第二实体对象之间的所述逻辑关系,维护所述第一层级关系。
根据本公开的一个或多个实施例,所述至少一个第二实体对象从属于所述第一实体对象,在所述第一层级关系中,所述第一管理项作为父结点,所述至少一个第二管理项分别为所述父结点的至少一个子结点。
根据本公开的一个或多个实施例,所述第一实体对象与所述第一管理项之间彼此分离存储,所述至少一个第二实体对象与对应的所述至少一个第二管理项之间彼此分离存储。
根据本公开的一个或多个实施例,数据处理方法还包括:响应于所述第一实体对象的变更,更新所述第一管理项的第一变更信息;和/或响应于所述至少一个第二实体对象各自的变更,更新所述至少一个第二管理项各自的第二变更信息。
根据本公开的一个或多个实施例,所述第一变更信息包括用于记录所述第一实体对象的版本变更信息的第一序列号,更新所述第一管理项的第一变更信息,包括:对所述第一序列号进行增量操作,以更新所述第一序列号。
根据本公开的一个或多个实施例,所述第二变更信息包括用于记录对应的所述第二实体对象的版本变更信息的第二序列号,更新所述至少一个第二管理项各自的第二变更信息,包括:在所述至少一个第二管理项中确定当前更新的目标第二管理项,以及对所述目标第二管理项的第二序列号进行增量操作,以更新所述目标第二管理项的第二序列号。
根据本公开的一个或多个实施例,所述至少一个第二实体对象包括多个第二实体对象,对应的所述至少一个第二管理项包括多个第二管理项,所述多个第二管理项的第二序列号彼此不同且不重复使用。
根据本公开的一个或多个实施例,数据处理方法还包括:为所述第一管理项创建变更信息管理条目,其中,所述变更信息管理条目包括变更序列号,所述变更序列号表示所述至少一个第二管理项的第二序列号中的最大第二序列号。
根据本公开的一个或多个实施例,对所述目标第二管理项的第二序列号进行增量操作,以更新所述目标第二管理项的第二序列号,包括:获取所述变更序列号,将所述目标第二管理项的第二序列号更新为所述变更序列号与预定增量之和。
根据本公开的一个或多个实施例,对所述目标第二管理项的第二序列号进行增量操作,以更新所述目标第二管理项的第二序列号,还包括:在更新所述目标第二管理项的第二序列号之后,将所述变更序列号更新为所述目标第二管理项的第二序列号。
根据本公开的一个或多个实施例,数据处理方法还包括:通过服务端处理所述第一实体对象、所述第一管理项、所述至少一个第二实体对象、所述至少一个第二管理项以及所述第一层级关系;以及通过至少一个客户端处理所述第一实体对象的拷贝、所述第一管理项的拷贝、所述至少一个第二实体对象的拷贝、所述至少一个第二管理项的拷贝以及所述第一层级关系的拷贝;其中,所述至少一个客户端向所述服务端提供所接收的指令,以用于通过所述服务端更新所述第一实体对象、所述第一管理项、所述至少一个第二实体对象、所述至少一个第二管理项或所述第一层级关系;所述至少一个客户端向所述服务端请求同步,以更新所述至少一个客户端各自处理的所述第一实体对象的拷贝、所述第一管理项的拷贝、所述至少一个第二实体对象的拷贝、所述至少一个第二管理项的拷贝以及所述第一层级关系的拷贝。
根据本公开的一个或多个实施例,所述服务端包括第一实体对象服务端、第二实体对象服务端以及管理项服务端;所述第一实体对象服务端向所述管理项服务端发送第一创建请求,所述管理项服务端响应于所述第一创建请求为所述第一实体对象创建所述第一管理项并将所述第一实体对象绑定至所述第一管理项;所述第二实体对象服务端向所述管理项服务端发送第二创建请求,所述管理项服务端响应于所述第二创建请求为所述至少一个第二实体对象分别创建所述至少一个第二管理项并将所述至少一个第二实体对 象分别绑定至所述至少一个第二管理项;所述管理项服务端基于所述第一实体对象与所述至少一个第二实体对象之间的所述逻辑关系,建立并维护所述第一层级关系。
根据本公开的一个或多个实施例,在所述至少一个客户端与所述服务端同步时,响应于所述第一管理项在所述第一层级关系中为所述至少一个第二管理项的父结点,先同步所述第一管理项与所述第一管理项的拷贝,然后同步所述至少一个第二管理项与所述至少一个第二管理项的拷贝。
根据本公开的一个或多个实施例,数据处理方法还包括:基于为所述第一管理项创建的变更信息管理条目,对所述至少一个客户端进行同步。
根据本公开的一个或多个实施例,基于所述变更信息管理条目,对所述至少一个客户端进行同步,包括:在所述至少一个客户端中确定当前进行同步的目标客户端;接受所述目标客户端进行第一同步的请求;以及在从所述服务端对所述目标客户端进行所述第一同步之后,在所述服务端将所述第一同步中所述服务端发送给所述目标客户端的变更序列号记录为客户端最近变更序列号,在所述目标客户端将所述第一同步中所述服务端发送给所述目标客户端的所述变更序列号记录为客户端最大变更序列号。
根据本公开的一个或多个实施例,基于所述变更信息管理条目,对所述至少一个客户端进行同步,还包括:接受所述目标客户端进行第二同步的请求,其中,所述第二同步在时间上与所述第一同步相邻,从所述服务端向所述目标客户端发送所述客户端最近变更序列号以及接受所述第二同步的请求时所述服务端的变更序列号,由所述目标客户端比较所述客户端最近变更序列号与所述客户端最大变更序列号,响应于所述客户端最近变更序列号与所述客户端最大变更序列号相等,将所述目标客户端根据所述客户端最大变更序列号以及所述服务端发送的变更序列号进行所述第二同步,响应于所述客户端最近变更序列号与所述客户端最大变更序列号不等,将所述目标客户端不限于所述客户端最大变更序列号进行所述第二同步。
根据本公开的一个或多个实施例,数据处理方法还包括:为所述至少一个第二管理项分别创建至少一个第一顺序条目,以用于记录所述至少一个第二管理项之间的第一排序信息。
根据本公开的一个或多个实施例,数据处理方法还包括:根据所述至少一个第一顺序条目,在所述至少一个第二管理项之间进行第一排序。
根据本公开的一个或多个实施例,所述至少一个第一顺序条目分别包括对应的所述第二管理项的第一排序类型信息和/或第一排序权重信息,根据所述至少一个第一顺序条目,在所述至少一个第二管理项之间进行所述第一排序,包括:基于所述至少一个第二管理项对应的所述第一排序类型信息和/或所述第一排序权重信息,在所述至少一个第二管理项之间进行所述第一排序。
根据本公开的一个或多个实施例,所述第一排序类型信息包括:所述第二管理项的创建时间、命名字符或更新时间。
根据本公开的一个或多个实施例,所述至少一个第二管理项包括多个第二管理项, 根据所述至少一个第一顺序条目,在所述至少一个第二管理项之间进行所述第一排序,还包括:对于所述第一排序后的所述多个第二管理项每个分别赋予顺序标识号,其中,所述第一排序后的所述多个第二管理项对应的多个顺序标识号中至少两个不依序递增。
根据本公开的一个或多个实施例,所述多个第二管理项对应的多个顺序标识号按照预定间隔递增,所述预定间隔大于1。
根据本公开的一个或多个实施例,在对于排序后的所述多个第二管理项每个分别赋予顺序标识号后,根据所述至少一个第一顺序条目,在所述至少一个第二管理项之间进行所述第一排序,还包括:响应于插入一个新的第二管理项,重新进行所述第一排序之后,确定所述新的第二管理项与在所述第一排序中前后紧相邻的两个第二管理项的顺序标识号之间的算术差,如果所述算术差小于或等于所述预定间隔且大于预定偏移,则将所述新的第二管理项的顺序标识号确定为在所述第一排序中前紧相邻的第二管理项的顺序标识号与所述预定偏移之和,其中,所述预定偏移大于等于1且小于所述预定间隔。
根据本公开的一个或多个实施例,数据处理方法还包括:为所述至少一个第二管理项分别创建至少一个第二顺序条目,以用于记录所述至少一个第二管理项之间的第二排序信息,其中,所述第二排序信息不同于所述第一排序信息。
根据本公开的一个或多个实施例,数据处理方法还包括:根据所述至少一个第二顺序条目,在所述至少一个第二管理项之间进行第二排序。
根据本公开的一个或多个实施例,所述至少一个第二顺序条目分别包括对应的所述第二管理项的第二排序类型信息和/或第二排序权重信息,根据所述至少一个第二顺序条目,对所述至少一个第二管理项之间进行所述第二排序,包括:基于所述至少一个第二管理项对应的所述第二排序类型信息和/或所述第二排序权重信息,在所述至少一个第二管理项之间进行所述第二排序。
根据本公开的一个或多个实施例,所述至少一个第二管理项包括结点标识信息,所述数据处理方法还包括:响应于建立所述第一管理项与所述至少一个第二管理项之间的所述第一层级关系,更新所述至少一个第二管理项的结点标识信息以指向所述第一管理项。
根据本公开的一个或多个实施例,根据所述第一实体对象与所述至少一个第二实体对象之间的所述逻辑关系,维护所述第一层级关系,包括:响应于所述第一实体对象与所述至少一个第二实体对象之间的所述逻辑关系变更,修改所述第一层级关系。
根据本公开的一个或多个实施例,所述逻辑关系变更包括所述第一实体对象被删除,使得所述第一实体对象与所述至少一个第二实体对象之间不具有关联关系,修改所述第一层级关系,包括:解除所述第一层级关系。
根据本公开的一个或多个实施例,所述逻辑关系变更包括所述至少一个第二实体对象每个均被删除,使得所述第一实体对象与所述至少一个第二实体对象之间不具有关联关系,修改所述第一层级关系,包括:解除所述第一层级关系。
根据本公开的一个或多个实施例,根据所述第一实体对象与所述至少一个第二实体 对象之间的所述逻辑关系,维护所述第一层级关系,包括:响应于所述至少一个第二实体对象的数量的增减,更新所述第一层级关系。
根据本公开的一个或多个实施例,所述第一实体对象对应于第一对象集合,所述至少一个第二实体对象分别对应于至少一个第二对象集合,所述数据处理方法还包括:响应于所述至少一个第二实体对象从属于所述第一实体对象,修改所述第一实体对象的数据,使得所述至少一个第二对象集合为所述第一对象集合的子集。
根据本公开的一个或多个实施例,响应于所述至少一个第二实体对象从属于所述第一实体对象,所述第一对象集合的成员与所述第二对象集合的成员保持相同。
根据本公开的一个或多个实施例,所述第一实体对象的类型不同于所述至少一个第二实体对象的类型。
根据本公开的一个或多个实施例,为所述第一实体对象创建所述第一管理项,包括:根据预定管理项模板,基于所述第一实体对象的数据,创建所述第一管理项;为所述至少一个第二实体对象分别创建所述至少一个第二管理项,包括:根据所述预定管理项模板,基于所述至少一个第二实体对象的数据,创建所述至少一个第二管理项。
根据本公开的一个或多个实施例,所述管理项模板包括标识信息项目和类型信息项目,所述标识信息项目用于记录绑定至管理项的实体对象的标识信息,所述类型信息项目用于记录绑定至所述管理项的所述实体对象的类型信息。
根据本公开的一个或多个实施例,一种电子设备,包括处理器和存储器;所述存储器包括一个或多个计算机可执行指令;其中,所述一个或多个计算机可执行指令被存储在所述存储器中并被配置为由所述处理器执行,所述一个或多个计算机可执行指令用于实现本公开任一实施例所述的数据处理方法。
根据本公开的一个或多个实施例,一种存储介质,用于存储非暂时性计算机可执行指令,当所述非暂时性计算机可执行指令由处理器执行时可以实现本公开任一实施例所述的数据处理方法。
根据本公开的一个或多个实施例,所述至少一个第二实体对象包括多个第二实体对象,所述逻辑关系变更包括所述多个第二实体对象中的一部分第二实体对象被删除,使得所述第一管理项与对应于所述一部分第二实体对象的第二管理项之间的层级关系被解除,且与对应于所述多个第二实体对象中的另一部分第二实体对象的第二管理项之间的层级关系仍保持,修改所述第一层级关系,包括:解除所述第一管理项与对应于所述一部分第二实体对象的第二管理项之间的层级关系,保留所述第一管理项与对应于所述另一部分第二实体对象的第二管理项之间的层级关系。
根据本公开的一个或多个实施例,该方法包括以下至少之一:响应于所述至少一个第二实体对象的数量的增加,更新所述第一层级关系,包括:为增加的第二实体对象创建新的第二管理项且将所述增加的第二实体对象绑定至所述新的第二管理项;以及建立所述第一管理项与所述新的第二管理项之间的层级关系;响应于所述至少一个第二实体对象的数量的减少,更新所述第一层级关系,包括:确定对应于减少的第二实体对象的 待操作第二管理项;以及解除所述第一管理项与所述待操作第二管理项之间的层级关系。
根据本公开的一个或多个实施例,响应于所述至少一个第二实体对象的数量的增加,更新所述第一层级关系,还包括:基于所述第一管理项的变更信息管理条目,更新所述新的第二管理项的第二变更信息;响应于所述至少一个第二实体对象的数量的减少,更新所述第一层级关系,还包括:在解除所述第一管理项与所述待操作第二管理项之间的层级关系之前,更新所述待操作第二管理项的第二变更信息,以更新所述第一管理项的变更信息管理条目。
根据本公开的一个或多个实施例,响应于所述至少一个第二实体对象的数量的减少,更新所述第一层级关系,还包括:删除所述待操作第二管理项。
根据本公开的一个或多个实施例,所述第一实体对象对应于第一对象集合,所述第一对象集合的成员为用户,所述至少一个第二实体对象分别对应于至少一个第二对象集合,所述第二对象集合的成员为用户。
根据本公开的一个或多个实施例,通过对所述第一对象集合的用户的增加操作,相应地对所述第二对象集合的成员进行增加操作,和/或通过对所述第一对象集合的用户的减少操作,相应地对所述第二对象集合的成员进行减少操作。
根据本公开的一个或多个实施例,一种数据处理装置,包括:第一管理项处理单元,配置为:为第一实体对象创建第一管理项且将所述第一实体对象绑定至所述第一管理项,其中,所述第一管理项包括所述第一实体对象的第一变更信息;第二管理项处理单元,配置为:为至少一个第二实体对象分别创建至少一个第二管理项且将所述至少一个第二实体对象分别绑定至所述至少一个第二管理项,其中,所述至少一个第二管理项分别包括对应的所述至少一个第二实体对象的第二变更信息;层级关系建立单元,配置为:基于所述第一实体对象与所述至少一个第二实体对象之间的逻辑关系,建立所述第一管理项与所述至少一个第二管理项之间的第一层级关系;以及层级关系维护单元,配置为:根据所述第一实体对象与所述至少一个第二实体对象之间的所述逻辑关系,维护所述第一层级关系。
以上描述仅为本公开的较佳实施例以及对所运用技术原理的说明。本领域技术人员应当理解,本公开中所涉及的公开范围,并不限于上述技术特征的特定组合而成的技术方案,同时也应涵盖在不脱离上述公开构思的情况下,由上述技术特征或其等同特征进行任意组合而形成的其它技术方案。例如上述特征与本公开中公开的(但不限于)具有类似功能的技术特征进行互相替换而形成的技术方案。
此外,虽然采用特定次序描绘了各操作,但是这不应当理解为要求这些操作以所示出的特定次序或以顺序次序执行来执行。在一定环境下,多任务和并行处理可能是有利的。同样地,虽然在上面论述中包含了若干具体实现细节,但是这些不应当被解释为对本公开的范围的限制。在单独的实施例的上下文中描述的某些特征还可以组合地实现在单个实施例中。相反地,在单个实施例的上下文中描述的各种特征也可以单独地或以任何合适的子组合的方式实现在多个实施例中。
尽管已经采用特定于结构特征和/或方法逻辑动作的语言描述了本主题,但是应当理解所附权利要求书中所限定的主题未必局限于上面描述的特定特征或动作。相反,上面所描述的特定特征和动作仅仅是实现权利要求书的示例形式。
对于本公开,还有以下几点需要说明:
(1)本公开实施例附图只涉及到本公开实施例涉及到的结构,其他结构可参考通常设计。
(2)在不冲突的情况下,本公开的实施例及实施例中的特征可以相互组合以得到新的实施例。
以上所述,仅为本公开的具体实施方式,但本公开的保护范围并不局限于此,本公开的保护范围应以所述权利要求的保护范围为准。

Claims (45)

  1. 一种数据处理方法,包括:
    为第一实体对象创建第一管理项且将所述第一实体对象绑定至所述第一管理项,其中,所述第一管理项包括所述第一实体对象的第一变更信息;
    为至少一个第二实体对象分别创建至少一个第二管理项且将所述至少一个第二实体对象分别绑定至所述至少一个第二管理项,其中,所述至少一个第二管理项分别包括对应的所述至少一个第二实体对象的第二变更信息;
    基于所述第一实体对象与所述至少一个第二实体对象之间的逻辑关系,建立所述第一管理项与所述至少一个第二管理项之间的第一层级关系;以及
    根据所述第一实体对象与所述至少一个第二实体对象之间的所述逻辑关系,维护所述第一层级关系。
  2. 根据权利要求1所述的数据处理方法,其中,所述至少一个第二实体对象从属于所述第一实体对象,
    在所述第一层级关系中,所述第一管理项作为父结点,所述至少一个第二管理项分别为所述父结点的至少一个子结点。
  3. 根据权利要求1或2所述的数据处理方法,其中,所述第一实体对象与所述第一管理项之间彼此分离存储,所述至少一个第二实体对象与对应的所述至少一个第二管理项之间彼此分离存储。
  4. 根据权利要求1-3任一项所述的数据处理方法,还包括:
    响应于所述第一实体对象的变更,更新所述第一管理项的第一变更信息;和/或
    响应于所述至少一个第二实体对象各自的变更,更新所述至少一个第二管理项各自的第二变更信息。
  5. 根据权利要求4所述的数据处理方法,其中,所述第一变更信息包括用于记录所述第一实体对象的版本变更信息的第一序列号,
    更新所述第一管理项的第一变更信息,包括:
    对所述第一序列号进行增量操作,以更新所述第一序列号。
  6. 根据权利要求4或5所述的数据处理方法,其中,所述第二变更信息包括用于记录对应的所述第二实体对象的版本变更信息的第二序列号,
    更新所述至少一个第二管理项各自的第二变更信息,包括:
    在所述至少一个第二管理项中确定当前更新的目标第二管理项,以及
    对所述目标第二管理项的第二序列号进行增量操作,以更新所述目标第二管理项的第二序列号。
  7. 根据权利要求6所述的数据处理方法,其中,所述至少一个第二实体对象包括多个第二实体对象,对应的所述至少一个第二管理项包括多个第二管理项,所述多个第二管理项的第二序列号彼此不同且不重复使用。
  8. 根据权利要求6或7所述的数据处理方法,还包括:
    为所述第一管理项创建变更信息管理条目,其中,所述变更信息管理条目包括变更序列号,所述变更序列号表示所述至少一个第二管理项的第二序列号中的最大第二序列号。
  9. 根据权利要求8所述的数据处理方法,其中,对所述目标第二管理项的第二序列号进行增量操作,以更新所述目标第二管理项的第二序列号,包括:
    获取所述变更序列号,将所述目标第二管理项的第二序列号更新为所述变更序列号与预定增量之和。
  10. 根据权利要求8或9所述的数据处理方法,其中,对所述目标第二管理项的第二序列号进行增量操作,以更新所述目标第二管理项的第二序列号,还包括:
    在更新所述目标第二管理项的第二序列号之后,将所述变更序列号更新为所述目标第二管理项的第二序列号。
  11. 根据权利要求1-10任一项所述的数据处理方法,还包括:
    通过服务端处理所述第一实体对象、所述第一管理项、所述至少一个第二实体对象、所述至少一个第二管理项以及所述第一层级关系;以及
    通过至少一个客户端处理所述第一实体对象的拷贝、所述第一管理项的拷贝、所述至少一个第二实体对象的拷贝、所述至少一个第二管理项的拷贝以及所述第一层级关系的拷贝;
    其中,所述至少一个客户端向所述服务端提供所接收的指令,以用于通过所述服务端更新所述第一实体对象、所述第一管理项、所述至少一个第二实体对象、所述至少一个第二管理项或所述第一层级关系;
    所述至少一个客户端向所述服务端请求同步,以更新所述至少一个客户端各自处理的所述第一实体对象的拷贝、所述第一管理项的拷贝、所述至少一个第二实体对象的拷贝、所述至少一个第二管理项的拷贝以及所述第一层级关系的拷贝。
  12. 根据权利要求11所述的数据处理方法,其中,所述服务端包括第一实体对象服务端、第二实体对象服务端以及管理项服务端;
    所述第一实体对象服务端向所述管理项服务端发送第一创建请求,所述管理项服务端响应于所述第一创建请求为所述第一实体对象创建所述第一管理项并将所述第一实体对象绑定至所述第一管理项;
    所述第二实体对象服务端向所述管理项服务端发送第二创建请求,所述管理项服务端响应于所述第二创建请求为所述至少一个第二实体对象分别创建所述至少一个第二管理项并将所述至少一个第二实体对象分别绑定至所述至少一个第二管理项;
    所述管理项服务端基于所述第一实体对象与所述至少一个第二实体对象之间的所述逻辑关系,建立并维护所述第一层级关系。
  13. 根据权利要求11或12所述的数据处理方法,其中,在所述至少一个客户端与所述服务端同步时,响应于所述第一管理项在所述第一层级关系中为所述至少一个第二 管理项的父结点,先同步所述第一管理项与所述第一管理项的拷贝,然后同步所述至少一个第二管理项与所述至少一个第二管理项的拷贝。
  14. 根据权利要求11-13任一项所述的数据处理方法,还包括:
    基于为所述第一管理项创建的变更信息管理条目,对所述至少一个客户端进行同步。
  15. 根据权利要求14所述的数据处理方法,其中,基于所述变更信息管理条目,对所述至少一个客户端进行同步,包括:
    在所述至少一个客户端中确定当前进行同步的目标客户端;
    接受所述目标客户端进行第一同步的请求;以及
    在从所述服务端对所述目标客户端进行所述第一同步之后,在所述服务端将所述第一同步中所述服务端发送给所述目标客户端的变更序列号记录为客户端最近变更序列号,在所述目标客户端将所述第一同步中所述服务端发送给所述目标客户端的所述变更序列号记录为客户端最大变更序列号。
  16. 根据权利要求15所述的数据处理方法,其中,基于所述变更信息管理条目,对所述至少一个客户端进行同步,还包括:
    接受所述目标客户端进行第二同步的请求,其中,所述第二同步在时间上与所述第一同步相邻,
    从所述服务端向所述目标客户端发送所述客户端最近变更序列号以及接受所述第二同步的请求时所述服务端的变更序列号,
    由所述目标客户端比较所述客户端最近变更序列号与所述客户端最大变更序列号,
    响应于所述客户端最近变更序列号与所述客户端最大变更序列号相等,将所述目标客户端根据所述客户端最大变更序列号以及所述服务端发送的变更序列号进行所述第二同步,
    响应于所述客户端最近变更序列号与所述客户端最大变更序列号不等,将所述目标客户端不限于所述客户端最大变更序列号进行所述第二同步。
  17. 根据权利要求1-16任一项所述的数据处理方法,还包括:
    为所述至少一个第二管理项分别创建至少一个第一顺序条目,以用于记录所述至少一个第二管理项之间的第一排序信息。
  18. 根据权利要求17所述的数据处理方法,还包括:
    根据所述至少一个第一顺序条目,在所述至少一个第二管理项之间进行第一排序。
  19. 根据权利要求18所述的数据处理方法,其中,所述至少一个第一顺序条目分别包括对应的所述第二管理项的第一排序类型信息和/或第一排序权重信息,
    根据所述至少一个第一顺序条目,在所述至少一个第二管理项之间进行所述第一排序,包括:
    基于所述至少一个第二管理项对应的所述第一排序类型信息和/或所述第一排序权重信息,在所述至少一个第二管理项之间进行所述第一排序。
  20. 根据权利要求19所述的数据处理方法,其中,所述第一排序类型信息包括:所 述第二管理项的创建时间、命名字符或更新时间。
  21. 根据权利要求18-20任一项所述的数据处理方法,其中,所述至少一个第二管理项包括多个第二管理项,
    根据所述至少一个第一顺序条目,在所述至少一个第二管理项之间进行所述第一排序,还包括:
    对于所述第一排序后的所述多个第二管理项每个分别赋予顺序标识号,其中,所述第一排序后的所述多个第二管理项对应的多个顺序标识号中至少两个不依序递增。
  22. 根据权利要求21所述的数据处理方法,其中,所述多个第二管理项对应的多个顺序标识号按照预定间隔递增,所述预定间隔大于1。
  23. 根据权利要求22所述的数据处理方法,其中,在对于排序后的所述多个第二管理项每个分别赋予顺序标识号后,根据所述至少一个第一顺序条目,在所述至少一个第二管理项之间进行所述第一排序,还包括:
    响应于插入一个新的第二管理项,重新进行所述第一排序之后,确定所述新的第二管理项与在所述第一排序中前后紧相邻的两个第二管理项的顺序标识号之间的算术差,
    如果所述算术差小于或等于所述预定间隔且大于预定偏移,则将所述新的第二管理项的顺序标识号确定为在所述第一排序中前紧相邻的第二管理项的顺序标识号与所述预定偏移之和,其中,所述预定偏移大于等于1且小于所述预定间隔。
  24. 根据权利要求17-23任一项所述的数据处理方法,还包括:
    为所述至少一个第二管理项分别创建至少一个第二顺序条目,以用于记录所述至少一个第二管理项之间的第二排序信息,
    其中,所述第二排序信息不同于所述第一排序信息。
  25. 根据权利要求24所述的数据处理方法,还包括:
    根据所述至少一个第二顺序条目,在所述至少一个第二管理项之间进行第二排序。
  26. 根据权利要求25所述的数据处理方法,其中,所述至少一个第二顺序条目分别包括对应的所述第二管理项的第二排序类型信息和/或第二排序权重信息,
    根据所述至少一个第二顺序条目,对所述至少一个第二管理项之间进行所述第二排序,包括:
    基于所述至少一个第二管理项对应的所述第二排序类型信息和/或所述第二排序权重信息,在所述至少一个第二管理项之间进行所述第二排序。
  27. 根据权利要求1-26任一项所述的数据处理方法,其中,所述至少一个第二管理项包括结点标识信息,
    所述数据处理方法还包括:
    响应于建立所述第一管理项与所述至少一个第二管理项之间的所述第一层级关系,更新所述至少一个第二管理项的结点标识信息以指向所述第一管理项。
  28. 根据权利要求1-27任一项所述的数据处理方法,其中,根据所述第一实体对象 与所述至少一个第二实体对象之间的所述逻辑关系,维护所述第一层级关系,包括:
    响应于所述第一实体对象与所述至少一个第二实体对象之间的所述逻辑关系变更,修改所述第一层级关系。
  29. 根据权利要求28所述的数据处理方法,其中,所述逻辑关系变更包括所述第一实体对象被删除,使得所述第一实体对象与所述至少一个第二实体对象之间不具有关联关系,
    修改所述第一层级关系,包括:
    解除所述第一层级关系。
  30. 根据权利要求28所述的数据处理方法,其中,所述逻辑关系变更包括所述至少一个第二实体对象每个均被删除,使得所述第一实体对象与所述至少一个第二实体对象之间不具有关联关系,
    修改所述第一层级关系,包括:
    解除所述第一层级关系。
  31. 根据权利要求28-30任一项所述的数据处理方法,其中,所述至少一个第二实体对象包括多个第二实体对象,所述逻辑关系变更包括所述多个第二实体对象中的一部分第二实体对象被删除,使得所述第一管理项与对应于所述一部分第二实体对象的第二管理项之间的层级关系被解除,且与对应于所述多个第二实体对象中的另一部分第二实体对象的第二管理项之间的层级关系仍保持,
    修改所述第一层级关系,包括:
    解除所述第一管理项与对应于所述一部分第二实体对象的第二管理项之间的层级关系,保留所述第一管理项与对应于所述另一部分第二实体对象的第二管理项之间的层级关系。
  32. 根据权利要求1-31任一项所述的数据处理方法,其中,根据所述第一实体对象与所述至少一个第二实体对象之间的所述逻辑关系,维护所述第一层级关系,包括:
    响应于所述至少一个第二实体对象的数量的增减,更新所述第一层级关系。
  33. 根据权利要求32所述的数据处理方法,其中,该方法包括以下至少之一:
    响应于所述至少一个第二实体对象的数量的增加,更新所述第一层级关系,包括:
    为增加的第二实体对象创建新的第二管理项且将所述增加的第二实体对象绑定至所述新的第二管理项;以及
    建立所述第一管理项与所述新的第二管理项之间的层级关系;
    响应于所述至少一个第二实体对象的数量的减少,更新所述第一层级关系,包括:
    确定对应于减少的第二实体对象的待操作第二管理项;以及
    解除所述第一管理项与所述待操作第二管理项之间的层级关系。
  34. 根据权利要求33所述的数据处理方法,其中,
    响应于所述至少一个第二实体对象的数量的增加,更新所述第一层级关系,还包括:
    基于所述第一管理项的变更信息管理条目,更新所述新的第二管理项的第二变 更信息;
    响应于所述至少一个第二实体对象的数量的减少,更新所述第一层级关系,还包括:
    在解除所述第一管理项与所述待操作第二管理项之间的层级关系之前,更新所述待操作第二管理项的第二变更信息,以更新所述第一管理项的变更信息管理条目。
  35. 根据权利要求33或34所述的数据处理方法,其中,
    响应于所述至少一个第二实体对象的数量的减少,更新所述第一层级关系,还包括:
    删除所述待操作第二管理项。
  36. 根据权利要求1-35任一项所述的数据处理方法,其中,所述第一实体对象对应于第一对象集合,所述至少一个第二实体对象分别对应于至少一个第二对象集合,
    所述数据处理方法还包括:
    响应于所述至少一个第二实体对象从属于所述第一实体对象,修改所述第一实体对象的数据,使得所述至少一个第二对象集合为所述第一对象集合的子集。
  37. 根据权利要求36所述的数据处理方法,其中,响应于所述至少一个第二实体对象从属于所述第一实体对象,所述第一对象集合的成员与所述第二对象集合的成员保持相同。
  38. 根据权利要求1-37任一项所述的数据处理方法,其中,所述第一实体对象对应于第一对象集合,所述第一对象集合的成员为用户,
    所述至少一个第二实体对象分别对应于至少一个第二对象集合,所述第二对象集合的成员为用户。
  39. 根据权利要求38所述的数据处理方法,其中,通过对所述第一对象集合的用户的增加操作,相应地对所述第二对象集合的成员进行增加操作,和/或
    通过对所述第一对象集合的用户的减少操作,相应地对所述第二对象集合的成员进行减少操作。
  40. 根据权利要求1-39任一项所述的数据处理方法,其中,所述第一实体对象的类型不同于所述至少一个第二实体对象的类型。
  41. 根据权利要求1-40任一项所述的数据处理方法,其中,为所述第一实体对象创建所述第一管理项,包括:
    根据预定管理项模板,基于所述第一实体对象的数据,创建所述第一管理项;
    为所述至少一个第二实体对象分别创建所述至少一个第二管理项,包括:
    根据所述预定管理项模板,基于所述至少一个第二实体对象的数据,创建所述至少一个第二管理项。
  42. 根据权利要求41所述的数据处理方法,其中,所述管理项模板包括标识信息项目和类型信息项目,
    所述标识信息项目用于记录绑定至管理项的实体对象的标识信息,所述类型信息项目用于记录绑定至所述管理项的所述实体对象的类型信息。
  43. 一种数据处理装置,包括:
    第一管理项处理单元,配置为:为第一实体对象创建第一管理项且将所述第一实体对象绑定至所述第一管理项,其中,所述第一管理项包括所述第一实体对象的第一变更信息;
    第二管理项处理单元,配置为:为至少一个第二实体对象分别创建至少一个第二管理项且将所述至少一个第二实体对象分别绑定至所述至少一个第二管理项,其中,所述至少一个第二管理项分别包括对应的所述至少一个第二实体对象的第二变更信息;
    层级关系建立单元,配置为:基于所述第一实体对象与所述至少一个第二实体对象之间的逻辑关系,建立所述第一管理项与所述至少一个第二管理项之间的第一层级关系;以及
    层级关系维护单元,配置为:根据所述第一实体对象与所述至少一个第二实体对象之间的所述逻辑关系,维护所述第一层级关系。
  44. 一种电子设备,包括:
    处理器;
    存储器,包括一个或多个计算机可执行指令;
    其中,所述一个或多个计算机可执行指令被存储在所述存储器中并被配置为由所述处理器执行,所述一个或多个计算机可执行指令用于实现权利要求1-42任一所述的数据处理方法。
  45. 一种存储介质,用于存储非暂时性计算机可执行指令,当所述非暂时性计算机可执行指令由处理器执行时可以实现权利要求1-42任一所述的数据处理方法。
PCT/CN2022/110633 2021-08-06 2022-08-05 数据处理方法及装置、电子设备及存储介质 WO2023011645A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202110903063.8A CN115705554A (zh) 2021-08-06 2021-08-06 数据处理方法、电子设备及存储介质
CN202110903063.8 2021-08-06

Publications (1)

Publication Number Publication Date
WO2023011645A1 true WO2023011645A1 (zh) 2023-02-09

Family

ID=85154855

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/110633 WO2023011645A1 (zh) 2021-08-06 2022-08-05 数据处理方法及装置、电子设备及存储介质

Country Status (2)

Country Link
CN (1) CN115705554A (zh)
WO (1) WO2023011645A1 (zh)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120197809A1 (en) * 2011-01-29 2012-08-02 Charles Calvin Earl Method and System for Automated Construction of Project Teams
US20160036872A1 (en) * 2014-08-04 2016-02-04 Candex Technologies Ltd. Systems and methods for organizational collaboration
CN106603391A (zh) * 2016-12-30 2017-04-26 和创(北京)科技股份有限公司 自动构建即时通信群组的方法、服务器和终端设备
CN111385186A (zh) * 2018-12-29 2020-07-07 钉钉控股(开曼)有限公司 项目群组的创建方法、项目管理方法及装置
CN112785248A (zh) * 2020-12-30 2021-05-11 金蝶软件(中国)有限公司 人力资源数据跨组织交互方法、装置、设备和存储介质

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120197809A1 (en) * 2011-01-29 2012-08-02 Charles Calvin Earl Method and System for Automated Construction of Project Teams
US20160036872A1 (en) * 2014-08-04 2016-02-04 Candex Technologies Ltd. Systems and methods for organizational collaboration
CN106603391A (zh) * 2016-12-30 2017-04-26 和创(北京)科技股份有限公司 自动构建即时通信群组的方法、服务器和终端设备
CN111385186A (zh) * 2018-12-29 2020-07-07 钉钉控股(开曼)有限公司 项目群组的创建方法、项目管理方法及装置
CN112785248A (zh) * 2020-12-30 2021-05-11 金蝶软件(中国)有限公司 人力资源数据跨组织交互方法、装置、设备和存储介质

Also Published As

Publication number Publication date
CN115705554A (zh) 2023-02-17

Similar Documents

Publication Publication Date Title
JP7398514B2 (ja) リモートデータオブジェクトのためのリモートリソースとインタラクトするグループベースコミュニケーションシステムのための方法、装置、及びシステム
AU2014225329B2 (en) Sharing a content item
US20160255092A1 (en) Unregistered user account generation for content item sharing
CN118104218A (zh) 通信平台上的集成工作空间
US20220164743A1 (en) Managing projects in a content management system
WO2021218850A1 (zh) 一种信息交互方法、装置、服务器、系统及存储介质
EP2951710A1 (en) Providing access to information across multiple computing devices
CN110909521A (zh) 在线文档信息的同步处理方法、装置及电子设备
WO2018136340A1 (en) Application programming interface
US20200192661A1 (en) Developer tools for a communication platform
US20200192643A1 (en) Developer tools for a communication platform
WO2023011645A1 (zh) 数据处理方法及装置、电子设备及存储介质
CN113204790B (zh) 一种视图权限处理方法、装置、设备及介质
CN114760360B (zh) 请求响应方法、装置、电子设备及计算机可读存储介质
CN110661857B (zh) 一种数据同步方法和装置
CN111984686A (zh) 一种数据处理的方法和装置
CN112131181A (zh) 存储路径的展示方法、装置以及电子设备
WO2023011649A1 (zh) 交互方法及装置、电子设备及存储介质
WO2024083158A1 (zh) 交互方法及装置、电子设备及存储介质
CN117955759A (zh) 交互方法及装置、电子设备及存储介质
CN110633324B (zh) 用于同步数据的方法、装置、电子设备和计算机可读介质
CN117955942A (zh) 交互方法及装置、电子设备及存储介质
WO2023001278A1 (zh) 一种信息处理方法、装置、终端和存储介质
US20220253467A1 (en) Method, device and program product for generating configuration information of storage system
CN117955947A (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: 22852356

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE