Information migration method, apparatus, and system

By selecting appropriate node computing strategies and computing nodes in the target device, lossless session and communication information migration during the physical machine iteration process is achieved, solving the problem of traffic interruption caused by poor session object synchronization in the prior art, and improving user experience and device performance.

CN116708382BActive Publication Date: 2025-10-17ALIBABA CLOUD COMPUTING CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310571321.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-05-18
Publication Date
2025-10-17
Estimated Expiration
2043-05-18

AI Technical Summary

Technical Problem

The existing technology cannot guarantee the synchronization of session objects during the physical machine iteration process, resulting in the interruption of migration traffic and affecting the user experience.

Method used

After receiving session information, the target device selects a node computing strategy based on the session type, performs node computing, finds the target computing node, and migrates the session and communication information to that node, ensuring lossless migration.

Benefits of technology

It enables seamless migration during device iteration, avoids traffic interruptions, and improves user experience and device performance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116708382B_ABST
    Figure CN116708382B_ABST
Patent Text Reader

Abstract

Embodiments of the present specification provide information migration methods, devices and systems. The information migration method is applied to a target device and includes: receiving session information sent by a source device for an information migration task when the device change condition is met; selecting a node calculation strategy according to a session type corresponding to the session information, and performing node calculation on the session information by using the node calculation strategy; selecting a target calculation node in a node cluster of the target device according to a node calculation result, and migrating the session information to the target calculation node; matching communication information associated with the session information for the target calculation node, and migrating the communication information to the target calculation node as a task execution result of the information migration task. The method realizes lossless migration between the source device and the target device, and does not cause information interruption, thereby ensuring system stability.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] Embodiments of the present specification relate to the technical field of computer technology, and particularly relate to an information migration method, device and system. BACKGROUND

[0002] With the development of Internet technology, more and more services begin to be online, and in order to provide more stable network services for users using services, service providers usually use or rent cloud computing resources, and cloud computing resources need to be supported by a large number of physical machines to realize tasks such as data analysis, calculation or data transmission. With the increase of task complexity and quantity, online physical machines usually perform model iteration at a set time interval to replace old version physical machines with physical machines with better computing power. The iteration of physical machines will involve daily instance migration processing. In the prior art, when performing instance migration processing, only instances on the old version physical machine are migrated to the new physical machine; however, this migration processing will have the problem of physical machine cross-model, and cannot guarantee session object synchronization, thereby causing migration traffic interruption problem, so an effective solution is needed to solve the above problem. SUMMARY

[0003] Therefore, the embodiments of the present specification provide an information migration method. One or more embodiments of the present specification also relate to an information migration device, an information migration system, a target device, a computer readable storage medium and a computer program to solve the technical defects in the prior art.

[0004] According to a first aspect of the embodiments of the present specification, an information migration method is provided, applied to a target device, comprising:

[0005] receiving session information sent by a source device satisfying a device change condition for an information migration task;

[0006] selecting a node calculation strategy according to a session type corresponding to the session information, and performing node calculation on the session information by using the node calculation strategy;

[0007] selecting a target calculation node in a node cluster of the target device according to a node calculation result, and migrating the session information to the target calculation node;

[0008] matching communication information associated with the session information for the target calculation node, and migrating the communication information to the target calculation node as a task execution result of the information migration task.

[0009] According to a second aspect of the embodiments of the present specification, an information migration device is provided, applied to a target device, comprising:

[0010] receiving module configured to receive session information sent by a source device satisfying a device change condition for an information migration task;

[0011] selecting module configured to select a node calculation strategy according to a session type corresponding to the session information, and perform node calculation on the session information by using the node calculation strategy;

[0012] migrating module configured to select a target calculation node in a node cluster of the target device according to a node calculation result, and migrate the session information to the target calculation node;

[0013] matching module configured to match communication information associated with the session information for the target calculation node, and migrate the communication information to the target calculation node as a task execution result of the information migration task.

[0014] According to a third aspect of the embodiments of the present specification, an information migration system is provided, comprising a source device and a target device, wherein the source device satisfies a device change condition;

[0015] The source device is configured to send session information corresponding to an information migration task to the target device when detecting that an information migration interface state of the target device is an open state.

[0016] The target device is configured to select a node calculation strategy according to a session type corresponding to the session information, and perform node calculation on the session information by using the node calculation strategy; select a target calculation node in a node cluster of the target device according to a node calculation result, and migrate the session information to the target calculation node; match communication information associated with the session information for the target calculation node, and migrate the communication information to the target calculation node as a task execution result of the information migration task.

[0017] According to a fourth aspect of the embodiments of the present specification, a target device is provided, comprising:

[0018] a memory and a processor;

[0019] The memory is configured to store computer executable instructions, and the processor is configured to implement steps of the above information migration method when executing the computer executable instructions.

[0020] According to a fifth aspect of the embodiments of the present specification, a computer readable storage medium is provided, which stores computer executable instructions, and the instructions are executed by a processor to implement steps of the above information migration method.

[0021] According to a sixth aspect of the embodiments of this specification, a computer program is provided, wherein when the computer program is executed in a computer, the computer is caused to execute the steps of the above-mentioned information migration method.

[0022] The information migration method provided in this embodiment is to achieve lossless migration between the source device and the target device without interrupting the migration traffic due to different device models. After the target device receives the session information sent by the source device that meets the device change conditions for the information migration task, it can first select a node computing strategy based on the session type corresponding to the session information, and use the node computing strategy to perform node computing on the session information, so that it can accurately find the target computing node that can serve as the carrier object in the node cluster corresponding to the target device, and then migrate the session information sent by the source device to the target computing node to achieve session information migration between the source device and the target device. On this basis, in order to avoid the interruption of migration traffic after the session information is migrated, the communication information associated with the session information can be matched with the target computing node to achieve the migration of the communication information to the target computing node, so that the session information and communication information corresponding to the source device are both migrated to the new computing node, ensuring that the subsequent processing process can use the target device to directly replace the source device, thereby achieving the purpose of lossless migration and avoiding the problem of traffic interruption after instance migration. BRIEF DESCRIPTION OF THE DRAWINGS

[0023] Figure 1 This is a schematic diagram of an information migration method provided by an embodiment of this specification;

[0024] Figure 2 This is a flow chart of an information migration method provided by one embodiment of this specification;

[0025] Figure 3 is a schematic diagram of an information migration process in an information migration method provided in one embodiment of this specification;

[0026] Figure 4 This is a flowchart of a processing process of an information migration method provided by an embodiment of this specification;

[0027] Figure 5 This is a schematic diagram of the structure of an information migration device provided by one embodiment of this specification;

[0028] Figure 6 This is a schematic diagram of the structure of an information migration system provided by an embodiment of this specification;

[0029] Figure 7 This is a structural block diagram of a target device provided by an embodiment of this specification. DETAILED DESCRIPTION

[0030] In the following description, numerous specific details are set forth in order to provide a thorough understanding of the present description. However, the present description can be practiced without the specific details. In other instances, well-known methods, procedures, components, and circuits have not been described in detail so as not to obscure the present description. The present description can be practiced with the specific details presented.

[0031] The terminology used in this description is for the purpose of describing particular embodiments only and is not intended to be limiting of one or more embodiments of the present description. As used in this description and the appended claims, the singular forms "a," "an" and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It will also be understood that the term "and / or" as used herein refers to and encompasses any and all possible combinations of one or more of the associated listed items.

[0032] It will be understood that, although the terms first, second, etc. can be used herein to describe various information, these terms are not intended to denote a temporal sequence, but are used only to distinguish one piece of information from another. For example, a first item can be termed a second item, and, similarly, a second item can be termed a first item, without departing from the scope of one or more embodiments of the present description. As used herein, the term "if' can be interpreted to mean "when" or "upon" or "in response to determining" taking into account the context in which the term is used.

[0033] In the present description, a method for information migration is provided, and the present description relates to an apparatus for information migration, a system for information migration, a target device, a computer readable storage medium, and a computer program, which are described in detail one by one in the following embodiments.

[0034] In practical applications, the RSS (Receive Side Scaling) technology refers to using a key to perform hash calculation on fields such as IP addresses and port numbers, and then using the hash value to take the modulus of the number of queues to calculate the corresponding queue. After the packet is placed in the queue, the queue is bound to a CPU, so that packets with the same tuple (source and destination addresses) can be allocated to the same CPU for processing. This packet processing model is a run-to-completion model, and combining RSS and thread binding cores can significantly improve forwarding performance. Existing load balancing generally uses a group of cluster systems composed of multiple same models of machines to jointly provide services through dynamic routing to publish the ECMP (Equal Cost Multi Path, a data communication routing redundancy technology) VIP (Virtual IP, a virtual IP provided by load balancing). Single load balancing is generally stateful, i.e., session-based forwarding. When the network card is outer RSS, the session is created on the outer RSS CPU core, and the session is synchronized to the same core of other machines. When the network card is inner RSS, the session is created on the inner RSS CPU core, and the session is synchronized to the same core of other machines.

[0035] Current load balancing synchronizes sessions through multicast messages. Each machine is configured with a flow director of the same multicast address, and the same multicast address is bound to the same queue and CPU to ensure that sessions can be normally synchronized to the corresponding forwarding core. In the same model scenario, instance migration or forwarding node failure switching relies on session synchronization to ensure session copying, which can achieve lossless migration. However, in real online operation, as the machine model is overhauled and iteratively replaced, different models may exist in the same cluster. The number of CPUs of the new model is increasing, and the layout of the CPUs is different from that of the old machine. When performing instance migration or machine replacement, it is impossible to guarantee that the multicast synchronization core and the real machine forwarding core are the same, resulting in session miss in the machine failure switching / instance migration scenario, causing user traffic to be silent and packet loss or receiving a load balancing sent Reset packet disconnection, thereby causing a large number of customer services to be reconnected, and poor user experience.

[0036] Reference Figure 1As shown in the schematic diagram, the information migration method provided in this embodiment can realize lossless migration between the source device and the target device, and can avoid migration traffic interruption caused by different device models. After the target device receives session information sent by the source device for an information migration task and meeting device change conditions, the target device can select a node calculation strategy according to a session type corresponding to the session information, perform node calculation on the session information by using the node calculation strategy, accurately find a target calculation node that can be used as a bearing object in a node cluster corresponding to the target device, and then migrate the session information sent by the source device to the target calculation node, thereby realizing session information migration between the source device and the target device. On this basis, in order to avoid migration traffic interruption after the session information migration, the target calculation node can be matched with communication information associated with the session information, so as to realize migration of the communication information to the target calculation node, realize migration of the session information and the communication information corresponding to the source device to the new calculation node, ensure that the target device can directly replace the source device in a subsequent processing process, thereby achieving the purpose of lossless migration, and avoiding the problem of traffic interruption after instance migration.

[0037] In addition, it should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data for analysis, stored data, displayed data, etc.) involved in one or more embodiments of the present specification are all information and data authorized by the user or authorized by all parties, and the collection, use and processing of related data need to comply with relevant laws, regulations and standards of relevant countries and regions, and provide corresponding operation entrances for users to choose authorization or refusal.

[0038] Figure 2 A flowchart of an information migration method provided by one embodiment of the present specification is shown, and the method is applied to a target device and specifically includes the following steps:

[0039] In step S202, session information sent by a source device for an information migration task and meeting device change conditions is received.

[0040] The information migration method provided in this embodiment is applied to a target device, where the target device specifically refers to a new physical machine used to replace the source device, which can be a physical machine with the same model but different versions as the source device, such as a physical machine with better performance and more cpu cores. Correspondingly, the source device specifically refers to a physical machine to be replaced, which may need to be replaced due to failure, over maintenance, etc. At this time, the target device can be selected to replace the source device to continue working instead of the source device.

[0041] Specifically, the device change condition specifically refers to a condition for detecting whether the source device meets the condition of triggering the information migration task, so as to ensure that when the target device is used as the receiving end, the session information submitted by the source device for the information migration task can be received. Correspondingly, the information migration task specifically refers to a task triggered by the source device when the device change condition is met, which is used to determine whether the source device is a device that needs to be replaced, determine the target device that replaces the source device, and perform subsequent session migration. Correspondingly, the session information specifically refers to the session in the source device, that is, the session object, which is used to store the attributes and configuration information required for a specific user session, such as storing the first option of the user, in addition, the session information also includes quintuple information. When the source device needs to be replaced by the target device, if the session information is not migrated, a new session object needs to be established in the target device, which will greatly affect the user experience, therefore, through lossless migration, the migration can be completed without the user's awareness, and the device performance can be improved to provide more stable services for the user.

[0042] This embodiment takes the case where the source device has a hardware failure and needs to be replaced by the target device as an example to illustrate the information migration method, and the same or corresponding description of other scenarios can be referred to the same or corresponding description of this embodiment, which is not limited in this embodiment.

[0043] Based on this, in the case where the source device meets the device change condition, it is indicated that the source device may not be able to be used and needs to be replaced in order to ensure the stability and water level capacity of the cluster. However, due to different cpu numbers and different architectures of different models, when the session object is migrated between devices, there may be a problem of invalid session object. Therefore, in order to avoid the problem of invalid session object, the source device will use the multicast address bound to each forwarding cpu itself to send the session information synchronization message to the corresponding multicast address through the udp (User Datagram Protocol) message, and the multicast address contains the address of the target device, and the target device is a new physical machine that replaces the source device, so the session information in the source device cpu can be sent to the target device.

[0044] After the target device receives the session information sent by the source device for the information migration task meeting the device change condition, a node calculation strategy can be selected according to the session type corresponding to the session information, node calculation of the session information is implemented by using the node calculation strategy, so that the target calculation node that can be used as a bearing object can be accurately found in the node cluster corresponding to the target device, and then the session information sent by the source device is migrated to the target calculation node, and the session information migration between the source device and the target device is implemented. On this basis, in order to avoid the interruption of migration traffic after the session information migration, the communication information associated with the session information can be matched for the target calculation node, so as to implement migration of the communication information to the target calculation node, migration of the session information and the communication information corresponding to the source device to the new calculation node is implemented, and subsequent processing process can use the target device to directly replace the source device, so as to achieve the purpose of lossless migration, and the problem of traffic interruption after instance migration is avoided.

[0045] In step S204, a node calculation strategy is selected according to the session type corresponding to the session information, and node calculation of the session information is implemented by using the node calculation strategy.

[0046] Specifically, after receiving the session information sent by the source device for the target device, in order to ensure lossless migration between the source device and the target device and avoid traffic interruption, a node calculation strategy can be selected in the target device according to the session type corresponding to the session information, so as to implement node calculation of the session information by using the node calculation strategy, select the target calculation node that can be used as a receiving node in the node cluster corresponding to the target device, and migrate other information corresponding to the session information sent by the source device to the target calculation node in the subsequent process, so as to realize lossless migration of information between devices and achieve the effect of uninterrupted traffic.

[0047] Specifically, the session type refers to the instance traffic type corresponding to the session information, different node calculation strategies are selected for different session types, so as to select the target calculation node that can be used as a receiving node according to the node calculation strategy for different types of session information, so as to ensure that the nodes of the source device and the nodes of the target device can communicate. Correspondingly, the node refers to the cpu in the physical machine, which is used to provide specific calculation capability; because the physical machine models are different and the number of cpus contained is also different, when the device is iterated, the target cpu needs to be migrated to the session information, so as to complete the work of the source cpu in the source device by using the target cpu, so as to achieve the purpose of lossless migration. Correspondingly, the node calculation strategy refers to the strategy for node calculation of the session information, which is used to select the calculation node corresponding to the current session information from a large number of calculation nodes for migration processing operation. Different types of session information select different node calculation strategies to ensure the accuracy of the calculation result.

[0048] Further, in order to improve the node calculation accuracy, so as to ensure that the subsequent can achieve the purpose of lossless migration session object, different node calculation strategies can be selected according to the session type for node calculation. In the embodiment, the specific implementation is as follows:

[0049] (1) According to the field information contained in the session information, it is determined that the session type corresponding to the session information is a reference session type; the reference node calculation strategy corresponding to the reference session type is selected as the node calculation strategy, and the communication parameters in the session information are extracted according to the reference node calculation strategy; the communication hash value corresponding to the communication parameter is calculated, and the session information is calculated based on the communication hash value.

[0050] Specifically, the field information specifically refers to the field that can describe the session information type. Because different types of session information correspond to different instance flows, their component structures are also different, so the session type corresponding to the session information can be determined by identifying the field information. Correspondingly, the reference session type specifically refers to the instance flow corresponding to the session information, which is classic instance flow, that is, classic flow, normal ip+tcp single-layer flow, etc. Such as classic private network or classic public network type VIP; Correspondingly, the reference node calculation strategy specifically refers to the strategy for node calculation of the session information of the reference session type. Correspondingly, the communication parameter specifically refers to the quintuple recorded in the session information of the reference session type; Correspondingly, the communication hash value specifically refers to the hash value obtained by performing hash operation on the communication parameter.

[0051] Based on this, after receiving the session information sent by the source device, in order to be able to find the corresponding calculation node in the target device for migration, the field information contained in the session information can be used to determine the session type corresponding to the session information. In the case where it is determined that the session type corresponding to the session information is a reference session type, it is indicated that the instance flow corresponding to the session information is a classic instance flow. At this time, the reference node calculation strategy corresponding to the reference session type can be selected as the node calculation strategy, and then the communication parameters in the session information are extracted according to the reference node calculation strategy. Then the communication hash value corresponding to the communication parameter is calculated, and the session information is calculated based on the communication hash value, so as to realize the subsequent use of the node index information.

[0052] In actual application, after the target device receives the session synchronization message sent by the source device, the target device does not immediately create and update the session in the CPU, but extracts the quintuple information in the session through the receiving core and determines the instance flow type corresponding to the session. When the session corresponds to the classic instance flow type, the software RSS can directly calculate the forwarding core matched by the network card according to the quintuple information, and then synchronizes the session message ICC (Inter-processor Interrupt Control) to the real forwarding core. That is, the software RSS performs hash operation on the quintuple information, and calculates the queue number corresponding to the CPU of the target device according to the hash value, so as to determine the real forwarding core, so as to facilitate subsequent sending of the session message to the forwarding core, and to complete the migration of inter-core information.

[0053] The embodiment takes the failure of the W1 machine in the A cluster as an example to illustrate the above description. After the W2 machine in the B cluster receives the session synchronization message sent by the W1 machine, the W2 machine can first extract the quintuple information {source IP address a1, source port b1, target IP address a2, target port b2 and transmission layer protocol c} in the session through the receiving core in the W2 machine. At this time, if it is determined that the session corresponds to the classic instance flow, the forwarding core matched by the network card can be calculated through the software RSS according to the quintuple information, that is, the hash1 is obtained after the hash operation on the quintuple information, and then the number of cores on the W2 machine is taken modulo based on the hash1, and the target CPU is determined according to the modulo result. After that, the session message ICC can be synchronized to the real CPU for use.

[0054] In actual application, since the number of queues and the number of forwarding core CPUs are consistent and have a one-to-one correspondence with each other, after the hash operation, the number of CPUs is taken modulo through the hash operation result, a specific value can be obtained, and the value is the identifier of a specific forwarding core. After that, the forwarding core receiving the session message can be used.

[0055] In summary, the session information of the reference session type will select the reference node calculation strategy for node calculation, so that after the target device receives the session information, the target calculation node can be calculated through the receiving core, so as to facilitate subsequent completion of lossless migration between cores.

[0056] (2) According to field information contained in the session information, it is determined that the session type corresponding to the session information is a dedicated session type; according to the dedicated session type, the policy start state of the target device is detected; in the case of the internal start state of the policy start state, the internal node calculation policy is selected as the node calculation policy, and the step of performing node calculation on the session information by using the node calculation policy is executed; in the case of the external start state of the policy start state, the external node calculation policy is selected as the node calculation policy, and the step of performing node calculation on the session information by using the node calculation policy is executed.

[0057] Specifically, the dedicated session type specifically refers to the instance traffic corresponding to the session information being vpc (Virtual Private Cloud) instance traffic, that is, the traffic corresponding to the dedicated network isolated by the logical address space of the tenant on the public cloud through network virtualization technology, which has a dedicated nature. For example, the message encapsulated by the network virtualization technology is of the udp type. Correspondingly, the policy start state specifically refers to the description state of detecting whether the target device has started the internal RSS, which includes the internal start state and the external start state, and different states will select different node calculation policies. The internal start state will select the internal node calculation policy, wherein the internal node calculation policy specifically refers to the calculation side policy for the address five-tuple information inside the virtualization technology. The external start state will select the external node calculation policy, wherein the external node calculation policy specifically refers to the calculation side policy for the five-tuple information of the udp message outside the virtualization technology.

[0058] Based on this, after receiving the session information sent by the source device, in order to be able to find the corresponding calculation node in the target device for migration, the field information contained in the session information can be used to determine the session type corresponding to the session information. In the case of determining that the session type corresponding to the session information is a dedicated session type, it is explained that the instance traffic corresponding to the session information is vpc instance traffic. At this time, the policy start state of the target device can be detected according to the dedicated session type. In the case of the internal start state of the policy start state, it is explained that the vpc instance traffic corresponds to the address five-tuple inside the virtualization, and then the internal node calculation policy can be selected as the node calculation policy, and the step of performing node calculation on the session information by using the node calculation policy is executed.

[0059] In the case of the external start state of the policy start state, it is explained that the vpc instance traffic corresponds to the message five-tuple outside the virtualization, and then the external node calculation policy can be selected as the node calculation policy, and the step of performing node calculation on the session information by using the node calculation policy is executed.

[0060] In summary, for the session information of the special session type, different node calculation strategies are selected according to the policy start state, which can realize the subsequent node calculation processing of different types of session information, so as to accurately locate the target calculation node, and realize the lossless migration by using the target calculation node as the receiving end.

[0061] Further, in the case of the node calculation strategy being an internal node calculation strategy, the node calculation needs to be performed by extracting the set communication parameter, and in the embodiment, the specific implementation manner is as follows:

[0062] According to the internal node calculation strategy, the session information is parsed to obtain internal communication parameters, the internal communication hash value corresponding to the internal communication parameters is calculated, and the node number corresponding to the node cluster is taken modulo based on the internal communication hash value; and the node index information corresponding to the session information is determined according to the modulo result.

[0063] Specifically, the internal communication parameter specifically refers to the address quintuple information of the virtualization inside the session information of the special session type. Correspondingly, the internal communication hash value specifically refers to the hash value obtained by performing hash operation on the internal communication parameter. Correspondingly, the node index information specifically refers to the information used to find the target calculation node matching the session information in the node cluster of the target device.

[0064] Based on this, in the case of the node calculation strategy being an internal node calculation strategy, the session information can be parsed according to the internal node calculation strategy first to obtain the internal communication parameter according to the parsing result; at this time, the internal communication hash value corresponding to the internal communication parameter can be calculated, and then the node number corresponding to the node cluster can be taken modulo based on the internal communication hash value; that is, the node index information corresponding to the session information can be determined according to the modulo result, so as to facilitate the determination of the target calculation node using the node index information subsequently.

[0065] In summary, by selecting the internal calculation strategy for the special session type to realize node calculation, the matching of the selected node calculation strategy and the session type can be ensured, the calculation result is more accurate, and after the node index information is obtained, the target calculation node can be accurately found to complete the migration processing of the information.

[0066] In the case of the node calculation strategy being an internal node calculation strategy, the node calculation needs to be performed by extracting the set communication parameter, and in the embodiment, the specific implementation manner is as follows:

[0067] According to the external node calculation strategy, the session information is parsed to obtain external message parameters; a hash value of the external message corresponding to the external message parameters is calculated, and the number of nodes corresponding to the node cluster is taken modulo based on the hash value of the external message; and the node index information corresponding to the session information is determined according to the modulo result.

[0068] Specifically, the external message parameters specifically refer to the message quintuple information outside the virtualization in the session information of the special session type, and correspondingly, the external message hash value specifically refers to the hash value obtained by performing hash operation on the external message parameters.

[0069] Based on this, in the case of the node calculation strategy being the external node calculation strategy, the session information can be parsed according to the external node calculation strategy first to obtain the external message parameters according to the parsing result; at this time, the hash value of the external message corresponding to the external message parameters can be calculated, and the number of nodes corresponding to the node cluster is taken modulo based on the hash value of the external message; and the node index information corresponding to the session information can be determined according to the modulo result, to facilitate the determination of the target calculation node using the node index information subsequently.

[0070] That is, if the instance flow corresponding to the session information is a vpc instance flow type, it is necessary to detect whether the target device has started the inner-layer RSS at this time, so as to select different RSS software algorithms for downstream calculation, to realize the calculation of the forwarding core, and to give the session message ICC to the corresponding forwarding core. Specifically, the target device can determine whether the inner-layer RSS is started according to the configuration file when the process is started, and can be controlled by a switch.

[0071] Further, in the case that the target device has started the inner-layer RSS, the inner-layer RSS software algorithm can be selected, the corresponding forwarding core can be calculated according to the inner-layer quintuple information in the session, and the session message ICC can be given to the corresponding forwarding core. In the case that the target device has not started the inner-layer RSS, the outer-layer RSS software algorithm can be selected, the corresponding forwarding core can be calculated according to the outer-layer quintuple information in the session, and the session message ICC can be given to the corresponding forwarding core.

[0072] Specifically, in the inner-layer RSS software algorithm for forwarding core calculation, different vpc formats are selected, and the inner-layer RSS software algorithm is an algorithm for calculating the forwarding core using the address quintuple inside the virtualization technology, for example, real cip:cport-->vip:vport calculation. Correspondingly, the outer-layer RSS software algorithm is an algorithm for calculating the forwarding core using the message quintuple outside the virtualization technology, for example, nc_ip:nc_port--->gw_ip:250 calculation.

[0073] Continuing with the above example, after the receiving core in the W2 machine receives the session packet sent by the W1 machine, it can first determine whether the inner-layer RSS software algorithm is started in the W2 machine. If the inner-layer RSS software algorithm is started, the inner-layer RSS software algorithm can be selected to perform a hash operation on the inner-layer quintuple information in the session to obtain hash2, and then the number of cores on the W2 machine is taken modulo based on hash2, and the target cpu is determined according to the modulo result, and then the session packet ICC can be synchronized to the real cpu for use. If not, the outer-layer RSS software algorithm can be selected to perform a hash operation on the outer-layer quintuple information in the session to obtain hash3, and then the number of cores on the W2 machine is taken modulo based on hash3, and the target cpu is determined according to the modulo result, and then the session packet ICC can be synchronized to the real cpu for use. The inner-layer RSS and the outer-layer RSS calculation correspond to different formats of vpc instance traffic.

[0074] In summary, by selecting different calculation strategies for different types of session information, node calculation can be performed to achieve lossless migration between source devices and target devices when information migration is performed, and subsequent communication information migration can be combined with the migration result to achieve the purpose of uninterrupted traffic.

[0075] Step S206, according to the node calculation result, a target calculation node is selected in the node cluster of the target device, and the session information is migrated to the target calculation node.

[0076] Specifically, after the above node calculation strategy is used to calculate the session information, further, in order to accurately select the target calculation node and use the target calculation node to replace the source node in the source device for subsequent processing, the target calculation node can be accurately found in the node cluster of the target device according to the node calculation result, and then the session information can be migrated to the target calculation node to realize that the heterogeneous devices can complete the lossless migration of inter-cluster traffic.

[0077] Among them, the node cluster specifically refers to a cluster composed of calculation nodes in the target device for calculation and processing. That is, a cluster composed of multiple cpus in a physical machine. Correspondingly, the target calculation node specifically refers to a calculation node selected in the node cluster according to the node calculation result, which will be used as a receiving end forwarding core to replace the forwarding core in the source device for work. Correspondingly, migration specifically refers to the process of synchronizing the session information to the target calculation node.

[0078] Further, when selecting the target computing node, considering that the node cluster corresponding to the target device can include a large number of computing nodes, in order to be able to achieve lossless migration of the session object between devices and not cause interruption of the instance flow of the session object, the determination of the target computing node can be completed in combination with the node index information. In the embodiment, the specific implementation manner is as follows:

[0079] According to the node calculation result, target node index information is determined; a computing node corresponding to the target node index information in the node cluster of the target device is queried as the target computing node; and a node communication algorithm is called to migrate the session information to the target computing node.

[0080] Specifically, the target node index information specifically refers to information used for finding a target computing node matching the session information in the node cluster of the target device. The target node index information is obtained by performing node calculation on the session information through a node calculation strategy, and has a unique correspondence with the selected target computing node. Correspondingly, the node communication algorithm specifically refers to an algorithm for data transmission between computing nodes, which can realize direct transmission of data between computing nodes without changing the data structure.

[0081] Based on this, after the node calculation is completed by using the node calculation strategy, the target node index information can be determined according to the node calculation result; at this time, the computing node corresponding to the target node index information in the node cluster of the target device can be queried as the target computing node; finally, the node communication algorithm is called to migrate the session information to the target computing node.

[0082] Following the above example, after the receiving core on the W2 machine performs calculation on the quintuple information and takes the modulus, the value n is obtained. At this time, based on the unique correspondence between the queue and the cpu, the value n is used to select cpu1 as the forwarding core in the m cpus in the W2 machine, and the session message received by the receiving core is given to the forwarding core by the ICC, so as to facilitate subsequent calculation and processing by cpu1.

[0083] In summary, by selecting the target computing node in combination with the target node index information, and migrating the session information to the target computing node in combination with the node communication algorithm, lossless migration of information between devices is realized, and it is ensured that the front-end service will not be affected after the device is replaced, thereby improving the user experience.

[0084] In step S208, the communication information associated with the session information is matched for the target computing node, and the communication information is migrated to the target computing node as the task execution result of the information migration task.

[0085] Specifically, after the session information is migrated to the target computing node, further, considering that the session information is not migrated to any computing node on the target device at will, but is migrated through calculation, on this basis, in order to maintain uninterrupted traffic, the communication information associated with the session information also needs to be migrated to the target computing node, so that the forwarding core and the synchronization core are completed through the same computing node on the target device, that is, the operation of replacing the source node in the original source device without loss. Therefore, the communication information associated with the session information also needs to be matched for the target computing node, and then the communication information is migrated to the target computing node, which can be used as the task execution result of the information migration task.

[0086] Specifically, the communication information is the long connection information matched with the session information, because the instance configuration information has been migrated to the target computing node through the migration of the session information, and the remaining long connection information also needs to be migrated to avoid traffic interruption. That is, the information synchronized by session can be matched with session to perform corresponding snat / dnat or tcpseq calculation logic, so as to ensure that the remaining long connection will not be interrupted. Therefore, the communication information also needs to be migrated to the target computing node.

[0087] That is, when the instance is migrated to the target device, the session information corresponding to the session message can be matched to realize lossless migration between devices. Because the forwarding core needs to be calculated on the target device according to the five-tuple information of the session synchronization to the cip:cport-->vip:vport, in order to realize effective session synchronization. Therefore, it is necessary to ensure that the core of session synchronization and the actual forwarding core are the same, so it is necessary to migrate the session information to the node.

[0088] Further, in order to achieve the effect of uninterrupted instance traffic when matching the communication information of the node, the session information can be matched to determine, in the embodiment, the specific implementation manner is as follows:

[0089] In the case where the session information migration is completed, at least one to-be-allocated communication information sent by the source device is received; the to-be-allocated communication information associated with the session information is determined in the at least one to-be-allocated communication information; and the to-be-allocated communication information associated with the session information is taken as the communication information matched by the target computing node.

[0090] Specifically, the to-be-allocated communication information specifically refers to the to-be-allocated communication information sent by the source device and received by the target device, which corresponds to different computing nodes, so the to-be-allocated communication information associated with the session information needs to be selected from the at least one to-be-allocated communication information.

[0091] Based on this, in the case of session information migration completion, it is explained that the session information has been migrated to the target computing node, and thereafter in order to be able to ensure that the target computing node replaces the source computing node, at least one to-be-allocated communication information sent by the source device can be received first; thereafter the session information associated to-be-allocated communication information can be determined in the at least one to-be-allocated communication information; and thereafter the session information associated to-be-allocated communication information is taken as the communication information matched by the target computing node. And the operation of migrating the communication information to the target computing node can be performed.

[0092] In the above example, after sending the session packet to cpu1 in the W2 machine, in order to avoid the problem of session invalidation, the long connection information matched by the session packet can be determined again, and thereafter the long connection information matched by the session packet is also migrated to cpu1, so as to realize that the W2 machine takes over all the work of the W1 machine and realizes subsequent processing.

[0093] In addition, in order to avoid confusion in information migration, the trigger and closing of migration can be completed by setting a switch. In the embodiment, the specific implementation manner is as follows:

[0094] In the case of detecting that the information migration interface state of the target device is in the open state, the step of receiving the session information sent by the source device for the information migration task in the case of satisfying the device change condition is executed;

[0095] Correspondingly, after the step of matching the communication information associated with the session information by the target computing node and migrating the communication information to the target computing node as the task execution result of the information migration task is executed, it further comprises:

[0096] Updating the node attribute of the target device, and executing the information processing task corresponding to the source device based on the updated node attribute; in the case that the associated device in the device cluster to which the target device belongs completes the node attribute update, the information migration interface state is adjusted to the closed state.

[0097] Specifically, the information migration interface specifically refers to an interface of whether the target device opens the session information migration processing. The interface corresponds to the open state and the closed state, so that the session migration processing can be performed in the open state. Correspondingly, the node attribute update specifically refers to updating the target device to the same attribute as the source device attribute. So as to realize that the target device replaces the source device to execute the information processing task.

[0098] Based on this, if the information migration interface status of the target device is detected to be in the open state, it indicates that the information migration task is now enabled, and step S202 can be executed. After the information migration is completed, in order to avoid resource loss, the node attributes of the target device can be updated first, and the information processing task corresponding to the source device can be executed based on the updated node attributes. When the node attributes of the associated devices in the device cluster to which the target device belongs have completed the update, it indicates that the device cluster to which the source device belongs has completed the information migration, and the information migration interface status can be adjusted to the closed state.

[0099] For example, see Figure 3 As shown in the diagram, if machine X in cluster X fails, the session synchronization compatibility switch can be enabled first. This will cause all machine session synchronization receivers to perform ICC and session consumption operations, implementing inter-core ICC session information. Simultaneously, machine Y in cluster Y will be enabled, and the session synchronization compatibility switch will also be enabled. This ensures that sessions created by machines X and Y are synchronized. This ensures that even if a machine fails or is upgraded, traffic can still be properly matched to sessions on different models, without affecting traffic forwarding. As machine X goes offline and all machines in the group are replaced by machines Y, the compatibility switch can be disabled, and simple session synchronization can be implemented.

[0100] The information migration method provided in this embodiment is to achieve lossless migration between the source device and the target device without interrupting the migration traffic due to different device models. After the target device receives the session information sent by the source device that meets the device change conditions for the information migration task, it can first select a node computing strategy based on the session type corresponding to the session information, and use the node computing strategy to perform node computing on the session information, so that it can accurately find the target computing node that can serve as the carrier object in the node cluster corresponding to the target device, and then migrate the session information sent by the source device to the target computing node to achieve session information migration between the source device and the target device. On this basis, in order to avoid the interruption of migration traffic after the session information is migrated, the communication information associated with the session information can be matched with the target computing node to achieve the migration of the communication information to the target computing node, so that the session information and communication information corresponding to the source device are both migrated to the new computing node, ensuring that the subsequent processing process can use the target device to directly replace the source device, thereby achieving the purpose of lossless migration and avoiding the problem of traffic interruption after instance migration.

[0101] The following combined Figure 4With the application of the information migration method provided in the specification in the physical machine iteration scenario as an example, the information migration method is further described. In the physical machine iteration scenario, the old version of the physical machine will be replaced by the new version of the physical machine, and the models are different. Figure 4 A process flow diagram of an information migration method provided by an embodiment of the specification is shown, specifically including the following steps.

[0102] Step S402, receiving the session information sent by the source device for the information migration task that meets the device change condition.

[0103] Step S404, selecting a node calculation strategy according to the session type corresponding to the session information, and performing node calculation on the session information using the node calculation strategy.

[0104] Specifically, according to the field information contained in the session information, it is determined that the session type corresponding to the session information is a reference session type; At this time, the reference node calculation strategy corresponding to the reference session type can be selected as the node calculation strategy, and the communication parameters in the session information are extracted according to the reference node calculation strategy; Calculate the communication hash value corresponding to the communication parameter, and perform node calculation on the session information based on the communication hash value.

[0105] In addition, in the case that the session type corresponding to the session information is determined to be a special session type according to the field information contained in the session information, the policy startup state of the target device can be detected according to the special session type; In the case that the policy startup state is an internal startup state, the internal node calculation strategy is selected as the node calculation strategy, and the step of performing node calculation on the session information using the node calculation strategy is executed; In the case that the policy startup state is an external startup state, the external node calculation strategy is selected as the node calculation strategy, and the step of performing node calculation on the session information using the node calculation strategy is executed.

[0106] In the case that the node calculation strategy is an internal node calculation strategy, the internal communication parameters can be obtained by parsing the session information according to the internal node calculation strategy; Calculate the internal communication hash value corresponding to the internal communication parameter, and perform modulo operation on the node number corresponding to the node cluster based on the internal communication hash value; The node index information corresponding to the session information is determined according to the modulo result.

[0107] In the case that the node calculation strategy is an external node calculation strategy, the external message parameters can be obtained by parsing the session information according to the external node calculation strategy; Calculate the external message hash value corresponding to the external message parameter, and perform modulo operation on the node number corresponding to the node cluster based on the external message hash value; The node index information corresponding to the session information is determined according to the modulo result.

[0108] Step S406, determining the target node index information according to the node calculation result.

[0109] In step S408, a computing node corresponding to the target node index information is queried in the node cluster of the target device as a target computing node.

[0110] In step S410, a node communication algorithm is invoked to migrate the session information to the target computing node.

[0111] In step S412, at least one to-be-assigned communication information sent by the source device is received in the case where the session information migration is completed.

[0112] In step S414, to-be-assigned communication information associated with the session information is determined in the at least one to-be-assigned communication information.

[0113] In step S416, the to-be-assigned communication information associated with the session information is matched as communication information of the target computing node.

[0114] In step S418, the communication information is migrated to the target computing node as a task execution result of the information migration task.

[0115] In step S420, the node attribute of the target device is updated, and an information processing task corresponding to the source device is executed based on the updated node attribute.

[0116] In step S422, in the case where the associated device in the device cluster to which the target device belongs completes the node attribute update, the information migration interface state is adjusted to a closed state.

[0117] The information migration method provided in this embodiment can realize lossless migration between the source device and the target device, and can avoid migration traffic interruption caused by different device models. After the target device receives session information sent by the source device for an information migration task and meeting device change conditions, a node computing strategy is selected according to a session type corresponding to the session information, node computing is performed on the session information by using the node computing strategy, a target computing node that can be used as a bearing object is accurately found in a node cluster corresponding to the target device, and then the session information sent by the source device is migrated to the target computing node, thereby realizing session information migration between the source device and the target device. On this basis, in order to avoid interruption of migration traffic after the session information is migrated, communication information associated with the session information is matched for the target computing node, thereby migrating the communication information to the target computing node, migrating the session information and the communication information corresponding to the source device to a new computing node, ensuring that the target device can be directly used to replace the source device in a subsequent processing process, thereby achieving the purpose of lossless migration, and avoiding the problem of traffic interruption after instance migration.

[0118] Corresponding to the method embodiments described above, the present specification also provides information migration device embodiments,Figure 5 A structural schematic diagram of an information migration device provided by one embodiment of the present specification is shown. As shown, the device is applied to a target device and includes: Figure 5

[0119] The receiving module 502 is configured to receive session information sent by a source device for an information migration task, which satisfies a device change condition;

[0120] The selection module 504 is configured to select a node calculation strategy according to a session type corresponding to the session information, and perform node calculation on the session information by using the node calculation strategy;

[0121] The migration module 506 is configured to select a target calculation node in a node cluster of the target device according to a node calculation result, and migrate the session information to the target calculation node;

[0122] The matching module 508 is configured to match communication information associated with the session information for the target calculation node, and migrate the communication information to the target calculation node as a task execution result of the information migration task.

[0123] In an optional embodiment, the selection module 504 is further configured to:

[0124] According to field information contained in the session information, it is determined that the session type corresponding to the session information is a reference session type; a reference node calculation strategy corresponding to the reference session type is selected as the node calculation strategy, and a communication parameter is extracted in the session information according to the reference node calculation strategy; a communication hash value corresponding to the communication parameter is calculated, and node calculation is performed on the session information based on the communication hash value.

[0125] In an optional embodiment, the selection module 504 is further configured to:

[0126] According to field information contained in the session information, it is determined that the session type corresponding to the session information is a special session type; the policy start state of the target device is detected according to the special session type; in the case that the policy start state is an internal start state, an internal node calculation strategy is selected as the node calculation strategy, and the step of performing node calculation on the session information by using the node calculation strategy is executed; in the case that the policy start state is an external start state, an external node calculation strategy is selected as the node calculation strategy, and the step of performing node calculation on the session information by using the node calculation strategy is executed.

[0127] ​In an optional embodiment, when the node calculation strategy is an internal node calculation strategy, the selection module 504 is further configured to:

[0128] According to the internal node calculation strategy, the session information is parsed to obtain internal communication parameters; an internal communication hash value corresponding to the internal communication parameters is calculated, and the node number corresponding to the node cluster is taken modulo based on the internal communication hash value; and the node index information corresponding to the session information is determined according to the modulo result.

[0129] In an optional embodiment, the migration module 506 is further configured to:

[0130] According to the node calculation result, target node index information is determined; a computing node corresponding to the target node index information in the node cluster of the target device is queried as the target computing node; and a node communication algorithm is called to migrate the session information to the target computing node.

[0131] In an optional embodiment, the matching module 508 is further configured to:

[0132] When the session information migration is completed, at least one to-be-assigned communication information sent by the source device is received; to-be-assigned communication information associated with the session information is determined in the at least one to-be-assigned communication information; and the to-be-assigned communication information associated with the session information is taken as the communication information matched by the target computing node.

[0133] In an optional embodiment, the apparatus further includes

[0134] The detection module is configured to, when it is detected that the information migration interface state of the target device is in an open state, perform the step of receiving session information sent by a source device that meets device change conditions for an information migration task;

[0135] The task execution result step of matching, by the target computing node, communication information associated with the session information, and migrating the communication information to the target computing node is performed after the step of receiving session information sent by a source device that meets device change conditions for an information migration task.

[0136] The update module is configured to update the node attribute of the target device, and perform an information processing task corresponding to the source device based on the updated node attribute; and when the associated devices in the device cluster to which the target device belongs complete node attribute updating, the information migration interface state is adjusted to a closed state.

[0137] In an optional embodiment, when the node calculation strategy is an external node calculation strategy, the selection module 504 is further configured to:

[0138] According to the external node computing strategy, the session information is parsed to obtain external message parameters; a hash value of the external message corresponding to the external message parameters is calculated, and the number of nodes corresponding to the node cluster is taken modulo based on the hash value of the external message; and the node index information corresponding to the session information is determined according to the modulo result.

[0139] The information migration device provided in the embodiment can realize lossless migration between the source device and the target device, and can avoid migration traffic interruption caused by different device models. After the target device receives session information sent by the source device for an information migration task and meeting a device change condition, a node computing strategy is selected according to a session type corresponding to the session information, node computing of the session information is implemented by using the node computing strategy, so that a target computing node that can be used as a bearing object can be accurately found in a node cluster corresponding to the target device, and then the session information sent by the source device is migrated to the target computing node, thereby realizing session information migration between the source device and the target device. On this basis, in order to avoid interruption of migration traffic after the session information is migrated, communication information associated with the session information can be matched for the target computing node, so as to implement migration of the communication information to the target computing node, migration of the session information and the communication information corresponding to the source device to the new computing node is implemented, and it is ensured that the target device can directly replace the source device in a subsequent processing process, so as to achieve the purpose of lossless migration, and the problem of traffic interruption after instance migration is avoided.

[0140] The above is a schematic scheme of the information migration device of the embodiment. It should be noted that the technical scheme of the information migration device belongs to the same concept as the technical scheme of the information migration method described above, and the details of the technical scheme of the information migration device that are not described in detail can be referred to the description of the technical scheme of the information migration method.

[0141] Corresponding to the method embodiments described above, the present specification also provides information migration system embodiments, Figure 6 A structural schematic diagram of an information migration system provided by an embodiment of the present specification is shown. As shown in the figure, Figure 6 The information migration system 600 includes a source device 610 and a target device 620, wherein the source device meets a device change condition;

[0142] The source device 610 is configured to send session information corresponding to an information migration task to the target device when it is detected that an information migration interface state of the target device is an open state.

[0143] The target device 620 is configured to select a node calculation strategy according to a session type corresponding to the session information, and perform node calculation on the session information by using the node calculation strategy; select a target calculation node in a node cluster of the target device according to a node calculation result, and migrate the session information to the target calculation node; and match communication information associated with the session information for the target calculation node, and migrate the communication information to the target calculation node as a task execution result of the information migration task.

[0144] In an optional embodiment, the target device 620 is further configured to determine, according to field information contained in the session information, that the session type corresponding to the session information is a reference session type; select a reference node calculation strategy corresponding to the reference session type as the node calculation strategy, and extract communication parameters in the session information according to the reference node calculation strategy; calculate a communication hash value corresponding to the communication parameters, and perform node calculation on the session information based on the communication hash value.

[0145] In an optional embodiment, the target device 620 is further configured to determine, according to field information contained in the session information, that the session type corresponding to the session information is a special session type; detect a policy start state of the target device according to the special session type; in a case where the policy start state is an internal start state, select an internal node calculation strategy as the node calculation strategy, and perform the step of performing node calculation on the session information by using the node calculation strategy; and in a case where the policy start state is an external start state, select an external node calculation strategy as the node calculation strategy, and perform the step of performing node calculation on the session information by using the node calculation strategy.

[0146] In an optional embodiment, the target device 620 is further configured to parse the session information according to the internal node calculation strategy to obtain internal communication parameters; calculate an internal communication hash value corresponding to the internal communication parameters, and perform modulo operation on a number of nodes corresponding to the node cluster based on the internal communication hash value; and determine node index information corresponding to the session information according to a modulo result.

[0147] In an optional embodiment, the target device 620 is further configured to determine target node index information according to the node calculation result; query a calculation node corresponding to the target node index information in the node cluster of the target device as the target calculation node; and call a node communication algorithm to migrate the session information to the target calculation node.

[0148] In an optional embodiment, the target device 620 is further configured to, in a case where the information migration of the target device is completed, receive at least one to-be-assigned communication information sent by the source device; determine to-be-assigned communication information associated with the session information from the at least one to-be-assigned communication information; and take the to-be-assigned communication information associated with the session information as the matched communication information of the target computing node.

[0149] In an optional embodiment, the target device 620 is further configured to, in a case where it is detected that the information migration interface state of the target device is in an open state, perform the step of receiving session information sent by the source device for an information migration task in a case where the device change condition is met; update the node attribute of the target device, and perform the information processing task corresponding to the source device based on the updated node attribute; and in a case where the associated device in the device cluster to which the target device belongs completes the node attribute update, adjust the information migration interface state to a closed state.

[0150] In an optional embodiment, the target device 620 is further configured to parse the session information according to the external node computing strategy to obtain external packet parameters; calculate an external packet hash value corresponding to the external packet parameters, and take the modulus of the number of nodes corresponding to the node cluster based on the external packet hash value; and determine the node index information corresponding to the session information according to the result of the modulus operation.

[0151] The information migration system provided in this embodiment can achieve lossless migration between the source device and the target device, and can avoid migration traffic interruption caused by different device models. After the target device receives session information sent by the source device for an information migration task in a case where the device change condition is met, the node computing strategy is selected according to the session type corresponding to the session information, node computing of the session information is performed by using the node computing strategy, the target computing node that can be used as a bearing object is accurately found in the node cluster corresponding to the target device, the session information sent by the source device is migrated to the target computing node, and the session information migration between the source device and the target device is achieved. On this basis, in order to avoid interruption of migration traffic after the session information is migrated, the communication information associated with the session information is matched for the target computing node, so that the communication information is also migrated to the target computing node, the session information and the communication information corresponding to the source device are both migrated to the new computing node, the subsequent processing process can be directly replaced by the target device, the purpose of lossless migration is achieved, and the problem of traffic interruption after instance migration is avoided.

[0152] The above is an intentional scheme of the information migration system according to the embodiment. It should be noted that the technical scheme of the information migration system and the technical scheme of the information migration method described above belong to the same concept, and the details of the technical scheme of the information migration system that are not described in detail can be referred to the description of the technical scheme of the information migration method.

[0153] Figure 7 A structural block diagram of a target device 700 according to one embodiment of the present specification is shown. The components of the target device 700 include, but are not limited to, a memory 710 and a processor 720. The processor 720 is connected to the memory 710 through a bus 730, and a database 750 is used to store data.

[0154] The target device 700 also includes an access device 740, which enables the target device 700 to communicate via one or more networks 760. Examples of these networks include a public switched telephone network (PSTN), a local area network (LAN), a wide area network (WAN), a personal area network (PAN), or a combination of communication networks such as the Internet. The access device 740 can include one or more of any type of network interface (e.g., a network interface card (NIC)), wired or wireless, such as an IEEE 802.11 wireless local area network (WLAN) wireless interface, a Worldwide Interoperability for Microwave Access (Wi-MAX) interface, an Ethernet interface, a Universal Serial Bus (USB) interface, a cellular network interface, a Bluetooth interface, a Near Field Communication (NFC) interface, and the like.

[0155] In one embodiment of the present application, the above-mentioned components of the target device 700 and other components not shown in the target device 700 can be connected to each other, for example, through a bus. It should be understood that Figure 7 the target device structure block diagram shown is only for the purpose of example, and is not a limitation on the scope of the present application. Those skilled in the art can add or replace other components as needed. Figure 7 the target device structure block diagram shown is only for the purpose of example, and is not a limitation on the scope of the present application. Those skilled in the art can add or replace other components as needed.

[0156] The target device 700 can be any type of stationary or mobile target device, including a mobile computer or mobile target device (e.g., a tablet computer, a personal digital assistant, a laptop computer, a notebook computer, a netbook, etc.), a mobile phone (e.g., a smartphone), a wearable target device (e.g., a smart watch, smart glasses, etc.), or other types of mobile devices, or a stationary target device such as a desktop computer or a personal computer (PC). The target device 700 can also be a mobile or stationary server.

[0157] The processor 720 is configured to execute computer-executable instructions to perform the steps of the information migration method described above.

[0158] The above is a schematic solution of the target device according to the embodiment. It should be noted that the technical solution of the target device and the technical solution of the information migration method described above belong to the same concept, and the details of the technical solution of the target device that are not described in detail can be referred to the description of the technical solution of the information migration method.

[0159] An embodiment of the present specification further provides a computer-readable storage medium storing computer-executable instructions, which, when executed by a processor, implement the steps of the information migration method described above.

[0160] The above is a schematic solution of the computer-readable storage medium according to the embodiment. It should be noted that the technical solution of the storage medium and the technical solution of the information migration method described above belong to the same concept, and the details of the technical solution of the storage medium that are not described in detail can be referred to the description of the technical solution of the information migration method.

[0161] An embodiment of the present specification further provides a computer program, which, when executed in a computer, causes the computer to perform the steps of the information migration method described above.

[0162] The above is a schematic solution of the computer program according to the embodiment. It should be noted that the technical solution of the computer program and the technical solution of the information migration method described above belong to the same concept, and the details of the technical solution of the computer program that are not described in detail can be referred to the description of the technical solution of the information migration method.

[0163] The above-described embodiments of the application have several aspects, no single one of which is solely responsible for the application's desirable attributes. Without limiting the scope of the application as expressed by the claims which follow, some further embodiments make these aspects even more useful. Other embodiments can result in less desirable attributes.

[0164] The computer readable medium can include any entity or apparatus capable of carrying the computer program code, recording medium, U disk, mobile hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signal, telecommunication signal, software distribution medium, etc. It should be noted that the computer readable medium can include appropriate contents according to the requirements of patent practice, for example, according to the patent practice in some regions, the computer readable medium does not include electrical carrier signals and telecommunication signals.

[0165] It should be noted that for the foregoing method embodiments, the acts described can be performed in a different order from that described, and that various elements can be added, deleted, modified, or rearranged without departing from the scope of the present application. Further, it should be noted that the above-described embodiments do not limit the scope of the present application. The acts of the above-described embodiments can be performed by one or more of the above-described means or by other means. It should be noted that the above-described embodiments are merely intended to help explain the principles of the present application and that the application is not limited to the above-described embodiments.

[0166] In the above-described embodiments, the description of each embodiment focuses on different aspects, and the parts not described in detail in a certain embodiment can be referred to the relevant description of other embodiments.

[0167] The above-disclosed specification of the present application is only used to help explain the present application. The alternative embodiments do not describe all the details and do not limit the application to the specific embodiments described. Obviously, according to the content of the embodiments of the present application, many modifications and changes can be made. The present application selects and describes these embodiments in order to better explain the principles and practical application of the embodiments of the present application, so that those skilled in the art can well understand and use the present application. The present application is limited by the claims and their full scope and equivalents.

Claims

1. An information migration method, applied to a target device, comprising: receiving session information sent by a source device that meets the device change conditions for the information migration task; Selecting a node calculation strategy according to a session type corresponding to the session information, and performing node calculation on the session information using the node calculation strategy; Selecting a target computing node in the node cluster of the target device according to the node calculation result, and migrating the session information to the target computing node; The communication information associated with the session information is matched with respect to the target computing node, and the communication information is migrated to the target computing node as a task execution result of the information migration task.

2. The method according to claim 1, wherein selecting a node calculation strategy based on a session type corresponding to the session information and performing node calculation on the session information using the node calculation strategy comprises: Determining, based on field information included in the session information, that a session type corresponding to the session information is a benchmark session type; Selecting a reference node calculation strategy corresponding to the reference session type as the node calculation strategy, and extracting communication parameters from the session information according to the reference node calculation strategy; A communication hash value corresponding to the communication parameter is calculated, and node calculation is performed on the session information based on the communication hash value.

3. The method according to claim 1, wherein selecting a node calculation strategy based on a session type corresponding to the session information and performing node calculation on the session information using the node calculation strategy comprises: Determining, based on field information included in the session information, that a session type corresponding to the session information is a proprietary session type; detecting a policy activation state of the target device according to the proprietary session type; When the policy startup state is the internal startup state, selecting the internal node calculation policy as the node calculation policy, and performing the step of performing node calculation on the session information using the node calculation policy; In a case where the policy startup state is the external startup state, an external node calculation policy is selected as the node calculation policy, and a step of performing node calculation on the session information using the node calculation policy is executed.

4. The method according to claim 3, wherein when the node calculation strategy is an internal node calculation strategy, performing node calculation on the session information using the node calculation strategy comprises: Parsing the session information according to the internal node calculation strategy to obtain internal communication parameters; Calculating an internal communication hash value corresponding to the internal communication parameter, and performing a modulo operation on the number of nodes corresponding to the node cluster based on the internal communication hash value; The node index information corresponding to the session information is determined according to the modulo result.

5. The method according to claim 1, wherein selecting a target computing node in the node cluster of the target device according to the node computing result and migrating the session information to the target computing node comprises: Determine the target node index information according to the node calculation result; Querying a computing node corresponding to the target node index information in the node cluster of the target device as the target computing node; A node communication algorithm is invoked to migrate the session information to the target computing node.

6. The method according to claim 1, wherein matching the communication information associated with the session information to the target computing node comprises: When the session information migration is completed, receiving at least one communication information to be allocated sent by the source device; Determining the communication information to be allocated associated with the session information from the at least one communication information to be allocated; The communication information to be allocated associated with the session information is used as the communication information matched by the target computing node.

7. The method according to claim 1, before the step of receiving the session information sent by the source device that meets the device change conditions for the information migration task is performed, further comprising When it is detected that the information migration interface state of the target device is in an open state, performing the step of receiving session information sent by a source device that meets the device change condition for the information migration task; in, After the step of matching the communication information associated with the session information to the target computing node and migrating the communication information to the target computing node as the task execution result of the information migration task is performed, the method further includes: Updating the node attributes of the target device and executing the information processing task corresponding to the source device based on the updated node attributes; When the node attribute update of the associated devices in the device cluster to which the target device belongs is completed, the state of the information migration interface is adjusted to a closed state.

8. The method according to claim 3, wherein when the node calculation strategy is an external node calculation strategy, performing node calculation on the session information using the node calculation strategy comprises: Parsing the session information according to the external node calculation strategy to obtain external message parameters; Calculating an external message hash value corresponding to the external message parameter, and performing a modulo operation on the number of nodes corresponding to the node cluster based on the external message hash value; The node index information corresponding to the session information is determined according to the modulo result.

9. An information migration device, applied to a target device, comprising: a receiving module configured to receive session information sent by a source device that meets a device change condition for an information migration task; a selection module configured to select a node calculation strategy according to a session type corresponding to the session information, and perform node calculation on the session information using the node calculation strategy; A migration module configured to select a target computing node in the node cluster of the target device according to the node calculation result, and migrate the session information to the target computing node; The matching module is configured to match the communication information associated with the session information with respect to the target computing node, and migrate the communication information to the target computing node as a task execution result of the information migration task.

10. An information migration system, comprising a source device and a target device, wherein: The source device meets the device change condition; The source device is configured to send session information corresponding to the information migration task to the target device when detecting that the information migration interface of the target device is in an open state; The target device is configured to select a node calculation strategy according to a session type corresponding to the session information, and perform node calculation on the session information using the node calculation strategy; Selecting a target computing node in the node cluster of the target device according to the node calculation result, and migrating the session information to the target computing node; The communication information associated with the session information is matched with respect to the target computing node, and the communication information is migrated to the target computing node as a task execution result of the information migration task.

11. A target device, comprising: memory and processor; The memory is used to store computer-executable instructions, and the processor is used to execute the computer-executable instructions. When the computer-executable instructions are executed by the processor, the steps of the method according to any one of claims 1 to 8 are implemented.

12. A computer-readable storage medium storing computer-executable instructions, wherein the computer-executable instructions, when executed by a processor, implement the steps of the method according to any one of claims 1 to 8.

Citation Information

Patent Citations

  • Conversation moving method and conversation moving system

    CN101316204A

  • Method for realizing data migration in session and node

    CN102624759A