WO2017049959A1 - 一种业务处理方法及设备 - Google Patents

一种业务处理方法及设备 Download PDF

Info

Publication number
WO2017049959A1
WO2017049959A1 PCT/CN2016/084750 CN2016084750W WO2017049959A1 WO 2017049959 A1 WO2017049959 A1 WO 2017049959A1 CN 2016084750 W CN2016084750 W CN 2016084750W WO 2017049959 A1 WO2017049959 A1 WO 2017049959A1
Authority
WO
WIPO (PCT)
Prior art keywords
operation request
identification code
controller
distributed node
distributed
Prior art date
Application number
PCT/CN2016/084750
Other languages
English (en)
French (fr)
Inventor
陈志峰
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Priority to EP16847841.0A priority Critical patent/EP3346671B1/en
Publication of WO2017049959A1 publication Critical patent/WO2017049959A1/zh
Priority to US15/935,788 priority patent/US10951732B2/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/60Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L65/00Network arrangements, protocols or services for supporting real-time applications in data packet communication
    • H04L65/40Support for services or applications
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/60Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources
    • H04L67/62Establishing a time schedule for servicing the requests

Definitions

  • the embodiments of the present invention relate to the field of communications technologies, and in particular, to a service processing method and device.
  • SDN Software Defined Network
  • the SDN controller accesses the distributed cloud platform in the north, enabling more intelligent services.
  • the system architecture can be as shown in Figure 1.
  • the administrator manages the devices and resources of the distributed cloud platform through the cloud platform interface provided by the distributed platform.
  • the distributed cloud platform is composed of multiple distributed nodes. There are two types of distributed nodes, one that provides northbound interface capabilities, such as distributed node 1, and the other that provides service processing capabilities and southbound interface capabilities, such as distributed nodes 2, 3, and 4.
  • the distributed cloud platform connects to the SDN controller in the south, and uses the SDN controller to control a large amount of network data. Therefore, for the distributed cloud platform, the network device is no longer seen, but a giant super Internet equipment.
  • each cloud platform interface instance is accessed through a distributed node, and of course, different cloud platform interface instances are connected through different distributed nodes. Entry is completely feasible.
  • the cloud platform interface shown in Figure 1 is connected to the cloud platform through the distributed node 1, so all the operation requests sent through the cloud platform interface will first pass through the distributed node 1, and then through other distributed nodes (such as the distributed node 2). , 3, 4) forwarded to the SDN controller for processing.
  • the distributed node 1 when two operation requests are updated for each other for the same service object, the distributed node 1 sends the same to the controller through different distributed nodes (for example, distributed nodes 2, 3). For two operation requests, to ensure that the processing result is correct, you must ensure that the first operation request is first to the controller, so that the final operation request is the one that is finally effective.
  • distributed cloud platform due to the distributed nature of the nodes in the platform, the processing capabilities of different nodes are different, and it is usually impossible to guarantee the first operation request to the controller first, if the post-operation request arrives at the controller. The time before the first operation request arrives at the controller, and finally the first operation request is processed, and the final operation request is the first, which results in an error in the processing result.
  • the embodiment of the present invention provides a service processing method and device, which can ensure the correctness of service processing in a distributed cloud platform.
  • a service processing method for use in a system including a first distributed node and at least two second distributed nodes, wherein the first distributed node passes the at least two second distributed The node communicates with the controller, the method comprising:
  • the first distributed node acquires a first operation request, where the first operation request includes a first service object;
  • the first distributed node allocates a first identifier to the first operation request according to a preset rule, where the first identifier is used to identify a processing sequence of the first service request to the first service object;
  • the determining, by the controller, whether the first operation request needs to be processed according to the preset rule and the first identification code includes:
  • the second operation Request sending, by the first distributed node, to the controller by another second distributed node of the at least two second distributed nodes, wherein the second operation request includes the first service object .
  • the first identifier code is a time stamp, or the first identifier code is a natural number that is incremented or decremented;
  • the preset rule is: for different operation requests including the same service object, the corresponding identification code is allocated according to the order of operation requests.
  • the method further includes:
  • the first distributed node acquires a third operation request, where the third operation request includes a second service object;
  • the first distributed node allocates a third identification code to the third operation request according to the preset rule, where the third identification code is used to identify the processing of the second service object by the third operation request. order;
  • the first distributed node determines that the third operation request is dependent on the first operation request, using the first identification code as a dependency code of the third operation request;
  • the third operation request is dependent on the code to cause the controller to process the third operation request after processing the first operation request according to the dependency code of the third operation request.
  • a service processing method for use in a system including a first distributed node and at least two second distributed nodes, wherein the first distributed node passes the at least two second distributed The node communicates with the controller, the method comprising:
  • the controller receives a first operation request and a first identification code sent by the first distributed node by using one of the at least two second distributed nodes, where the first operation request is a first service object, where the first identification code is used to identify a processing sequence of the first operation request by the first operation request;
  • the method further includes:
  • the controller receives a third operation request sent by the first distributed node by another second distributed node of the at least two second distributed nodes, a third identification code, and the third operation request Dependent code, the third operation request includes a second service object, the third identification code And a process for identifying a processing order of the second service object by the third operation request, where the first identifier code is a dependency code of the third operation request;
  • the controller processes the third operation request after processing the first operation request according to the dependency code of the third operation request.
  • a first distributed node communicating with a controller by using at least two second distributed nodes, the first distributed node comprising:
  • An obtaining unit configured to acquire a first operation request, where the first operation request includes a first service object
  • An allocating unit configured to allocate a first identification code to the first operation request according to a preset rule, where the first identification code is used to identify a processing sequence of the first operation request by the first operation request;
  • a sending unit configured to send, by using one of the at least two second distributed nodes, the first operation request and the first identification code to the controller, so that the controller Determining whether the first operation request needs to be processed according to the preset rule and the first identification code.
  • the determining, by the controller, whether the first operation request needs to be processed according to the preset rule and the first identification code includes:
  • the controller processes the first operation request If the first operation request is determined to be sent after the second operation request that the controller has processed according to the preset rule and the first identification code, the controller processes the first operation request If the first operation request is determined to be sent before the second operation request that the controller has processed according to the preset rule and the first identification code, the controller does not process the first An operation request; the second operation request is sent by the first distributed node to the controller by another second distributed node of the at least two second distributed nodes, the second operation request The first business object is included in the middle.
  • the acquiring unit is further configured to: acquire a third operation request, where the third operation request includes Second business object;
  • the allocating unit is further configured to: allocate, according to the second service object, a third identification code to the third operation request, where the third identification code is used to identify the third operation request to the second service object Processing order;
  • the first distributed node further includes:
  • a determining unit configured to determine that the third operation request is dependent on the first operation request, and use the first identification code as a dependency code of the third operation request;
  • the sending unit is further configured to send, by using another second distributed node of the at least two second distributed nodes, the third operation request, the third identification code, and the The third operation requests the dependency code to cause the controller to process the third operation request after processing the first operation request according to the dependency code of the third operation request.
  • a controller comprising:
  • a receiving unit configured to receive a first operation request and a first identification code sent by the first distributed node by using one of the at least two second distributed nodes, where the first operation request includes the first a service object, where the first identification code is used to identify a processing sequence of the first operation request by the first operation request;
  • a determining unit configured to determine, according to the preset rule and the first identification code, whether the first operation request needs to be processed; and determining, according to the preset rule and the first identification code, the first operation request Determining, after the second operation request that the controller has processed, processing the first operation request; determining, according to the preset rule and the first identification code, that the first operation request is in the Not transmitting the first operation request before the second operation request processed by the controller; the second operation request is passed by the first distributed node through the at least two second distributed nodes Another second distributed node is sent to the controller, and the second operation request includes the first service object.
  • the receiving unit is further configured to receive, by the first distributed node, another second one of the at least two second distributed nodes a third operation request, a third identification code, and a dependency code of the third operation request, where the third operation request includes a second service object, where the third identification code is used to identify the The third operation requests a processing sequence of the second service object, where the first identification code is a dependency code of the third operation request;
  • the controller further includes a processing unit, configured to process the third operation request after processing the first operation request according to the dependency code of the third operation request.
  • the first distributed node allocates an identification code to the operation request to identify the processing order of the service object by using different operation requests of the same service object, and sends the operation request and its identification code correspondingly. Giving the controller, so that the controller determines, according to the preset rule and the identification code of the operation request, whether the operation request needs to be processed, so as to ensure that the operation request containing the business object finally issued by the first distributed node is finally effective, thereby The business processing errors caused by the distributed characteristics of the nodes are avoided, and the correctness of the business processing is ensured.
  • FIG. 1 is a schematic diagram of a system architecture of a prior art distributed cloud platform
  • FIG. 2 is a flowchart of a service processing method according to an embodiment of the present invention.
  • FIG. 3 is a schematic diagram of interaction of a service processing method according to an embodiment of the present invention.
  • FIG. 4 is a schematic diagram of interaction of another service processing method according to an embodiment of the present disclosure.
  • FIG. 5 is a schematic diagram of interaction of another service processing method according to an embodiment of the present invention.
  • FIG. 6 is a schematic structural diagram of a first distributed node according to an embodiment of the present disclosure.
  • FIG. 7 is a schematic structural diagram of another first distributed node according to an embodiment of the present disclosure.
  • FIG. 8 is a schematic structural diagram of a controller according to an embodiment of the present disclosure.
  • FIG. 9 is a schematic structural diagram of another controller according to an embodiment of the present invention.
  • the embodiments of the present invention provide a service processing method and related equipment, which can ensure the correctness of service processing in a distributed cloud platform.
  • the system is composed of two types of distributed nodes, and the northbound interface can be provided.
  • a distributed node of capabilities is referred to as a first distributed node, such as distributed node 1 in FIG. 1; a distributed node that provides service processing capabilities and southbound interface capabilities is referred to as a second distributed node, such as in FIG.
  • the distributed nodes 2, 3, 4 have at least two second distributed nodes, and the first distributed nodes communicate with the controller through the at least two second distributed nodes.
  • FIG. 2 is a flowchart of a service processing method according to an embodiment of the present invention, where the method includes:
  • Step 201 The first distributed node obtains the first operation request, where the first operation request includes the first service object.
  • the cloud platform interface can deliver the first operation request to the first distributed node according to the operation of the user.
  • Step 202 The first distributed node allocates a first identification code to the first operation request according to a preset rule.
  • the first identification code is used to identify a processing sequence of the first operation request by the first operation request. For different operation requests containing the same business object, the processing order of the first operation request to the business object should be prior to the processing order of the subsequent operation request for the business object.
  • Step 203 The first distributed node sends the first operation request and the first identification code to the controller by using one of the at least two second distributed nodes.
  • the controller determines whether the first operation request needs to be processed according to the preset rule and the first identification code.
  • the determining, by the controller, whether the first operation request needs to be processed according to the preset rule and the first identification code includes: determining, according to the preset rule and the first identification code, the first An operation request is sent after the second operation request that the controller has processed (ie, the first operation request that is sent first, the first operation request that is sent later, and the processing order of the second operation request for the first business object should be And determining, in the first operation request, the processing sequence of the first service object, the actual processing sequence is consistent with the first operation request; and determining the first operation request according to the preset rule and the first identification code An operation request is sent before the second operation request that the controller has processed (ie, the first operation request sent first, and the second operation request sent later, the processing order of the first operation request to the first business object should be In the second operation requesting the processing order of the first business object, and the actual processing sequence is opposite to the first processing request), the first operation request is not processed; the second operation is requested Requesting, by the first distributed node,
  • the operation request including the same service object has a different identification code.
  • the identification code may be a timestamp
  • the first distributed node may use the timestamp when the operation request is sent as the identification code of the operation request.
  • the preset rules can be: chronological order. For example, the first distributed node first sends a first operation request including the first service object to the controller, and then sends a second operation request including the first service object to the controller, where the first operation request is The corresponding first identification code is a timestamp that is earlier than the second identification code corresponding to the second operation request.
  • the controller determines, according to the preset rule and the first identification code, that the first distributed node initiates The first operation request, the second operation request sent later, does not process the first operation request.
  • the identification code may also be a natural number that is incremented or decremented, and the first distributed node may assign an operation request with an increasing or decreasing natural number as an identifier according to a sequence of sending operation requests.
  • the preset rule may be: from small to large or from large to small.
  • the first distributed node first sends a first operation request including the first service object to the controller, and then sends a second operation including the first service object to the controller.
  • the request, the first identification code allocated for the first operation request is a natural number smaller than the second identification code corresponding to the second operation request.
  • the controller receives the second operation request, after receiving the second operation request, and receiving the first operation request, determining, according to the preset rule and the first identification code, the first distributed node first An operation request, a second operation request issued later, does not process the first operation request.
  • FIG. 3 is a schematic diagram of interaction of a service processing method according to an embodiment of the present invention, where the method includes:
  • Step 301 The cloud platform interface sends a first operation request to the distributed node 1, where the first operation request includes the first service object.
  • Step 302 the distributed node 1 assigns a first identification code to the first operation request, and sends the first identification code and the first operation request to the distributed node 2;
  • the distributed node 1 may allocate a first identification code for the first operation request according to a preset rule.
  • the identification code is an incremental natural number
  • the preset rule is a chronological order as an example.
  • the first identification code g_id allocated here for the first operation request is 1.
  • a second distributed node may be selected by using a distributed algorithm, or a second distributed node may be selected according to the current load condition of each second distributed node, or may be randomly selected.
  • a second distributed node sends the first operation request and its identification code 1 to the selected second distributed node. For example, the second distributed node selected this time is the distributed node 2. Due to the network or the distributed node 2 itself, the first operation request and its identification code are not forwarded by the distributed node 2 in time.
  • Step 303 The cloud platform interface sends a second operation request to the distributed node 1, where the second operation request includes the first service object.
  • the cloud platform interface sends two operation requests including the same business object (the first business object) to the distributed node 1.
  • Step 304 the distributed node 1 allocates a second identification code for the second operation request and sends the second identification code and the second operation request to the distributed node 3;
  • the distributed node 1 forwards different operation requests including the same service object to the controller through different second distributed nodes.
  • the second identification code g_id assigned here for the second operation request is 2.
  • Step 305 The distributed node 3 forwards the second operation request and the second identification code to the controller.
  • the distributed node 3 after receiving the second operation request and the second identification code, the distributed node 3 performs processing in time, and forwards the second operation request and the second identification code to the controller in time.
  • Step 306 the controller processes the second operation request and after processing, saves the identification code 2 of the second operation request;
  • the controller may maintain the following Table 1 in the local cache for recording related information of the processed operation request.
  • the processed in this embodiment refers to information that has been successfully processed, and the related information of the unprocessed or unsuccessfully processed operation request will not be recorded in the above table.
  • the controller when the controller receives the second operation request (including the first service object) and the identification code 2, the controller does not save the other operation request that is the same as the service object included in the second operation request.
  • the identification code that is, before this, the controller does not process or successfully process the other operation requests that are the same as the business objects included in the second operation request, and therefore, the second operation request can be directly processed.
  • Step 307 The controller sends a processing result to the corresponding network device.
  • Step 308 The distributed node 2 forwards the first operation request and the first identification code to the controller.
  • Step 309 The controller determines, according to the preset rule and the first identification code, that the first operation request is not processed.
  • the identifier of the first operation request is 1, and the identifier of another processed operation request containing the same service object (the first service object) stored in the controller is 2, that is, Indicates the first operation request sent by the distributed node 1 and the second operation request sent later.
  • the processing order of the first operation request should be before the second operation request, but the actual situation is that the second operation request is already in the first operation request. It was processed before, so the first operation request does not need to be processed.
  • the controller may directly determine whether the identifier of the current operation request is greater than the identifier of the other operation request stored in the controller that is the same as the service object included in the current operation request, and if it is greater, determine that the current operation needs to be processed. Request, otherwise, it is determined that the current operation request does not need to be processed.
  • the update IP address is used as an example.
  • the cloud platform interface sends two IP address update requests to the same network entity according to the user's operation.
  • the service processing method provided by the present invention regardless of the first operation. Whether the request is first to the controller or the subsequent operation request is first to the controller, and the final effect will be the post-operation request; that is, if the operation request is first sent first, the processor can process the request according to the operation code of the operation request.
  • the operation request, the operation request sent after the finalization is effective, if the operation request is sent first, the processor may decide not to process the operation request that does not meet the preset processing order according to the identification code of the operation request, and ensure that the final effect is still issued. Operation request.
  • the first distributed node when the first distributed node sends different operation requests for the same service object to the controller through different second distributed nodes, different operation requests are allocated differently.
  • An identification code where the identifier is used to identify a processing order of the operation request to the service object, and send the operation request and the identifier thereof to the controller, so that the controller determines, according to the identifier corresponding to the operation request, whether the current operation request needs to be processed, thereby It is guaranteed that the last distributed node is the last operation request containing the service object, which avoids the business processing error caused by the distributed characteristics of the node and ensures the correctness of the business processing.
  • FIG. 4 is a schematic diagram of interaction of another service processing method according to an embodiment of the present invention, where the method includes:
  • Step 401 The cloud platform interface sends a first operation request to the distributed node 1, where the first operation request includes the first service object.
  • Step 403 The cloud platform interface sends a third operation request to the distributed node 1, where the third operation request includes the second service object.
  • Step 404 The distributed node 1 determines that the third operation request is dependent on the first operation request, and uses the first identification code as the dependency code of the third operation request.
  • the distributed node 1 may determine the dependency of the operation request according to the service logic, for example, the first operation request is an operation request for creating the router R1, and the third operation request is an operation request for creating the interface A on the router R1, according to The business logic can determine that the third operational request is dependent on the first operational request.
  • Step 407 The controller determines that the first operation request whose ID code is 1 has not been processed, and does not process the second operation request.
  • the controller may maintain Table 2 below in the local cache for recording the processing status of each operation request.
  • the controller may determine the status of the identification code 1 of the first operation request that is dependent (because the controller has not received the forwarding of the distributed node 2 at this time)
  • the controller may mark the identification code 1 as not Processing status.
  • the processing result is that the processing fails, the identifier code 1 and its state are not saved in the controller.
  • 1 is marked as an unprocessed state, so the unprocessed state of this embodiment may indicate unprocessed, or may indicate processing failure.) Since the identification code 1 is in an unprocessed state, the controller temporarily does not process the third operation request, and saves the third. Operation request, 3 and its identification code dependent code, and code 3 which is a pending state.
  • Step 409 The controller processes the first operation request.
  • the controller sets the identification code of the first operation request to the processed state.
  • Step 410 The controller sends the processing result to the network device.
  • Step 411 The controller searches for and processes the third operation request that is dependent on the first operation request.
  • the controller After successfully processing the first operation request, the controller searches for the third operation request, and the status of the identification code is a third operation request to be processed, processes the third operation request, and after the processing succeeds, the third operation request is Identification code 3 is marked as processed.
  • Step 412 The controller sends the processing result to the network device.
  • the fourth operation request includes the third service object, and determines that the fourth operation request also depends on the first operation request, the identification code of the first operation request is used as the fourth operation.
  • the requested dependency code may directly process the fourth operation request according to the state of the dependency code of the fourth operation request after the controller receives the fourth operation request (since the identification code of the first operation request is the processed state).
  • the administrator sends an operation request for creating a router R1 to the distributed node 1 through the cloud platform interface, and the distributed node 1 assigns an identification code to the operation request and forwards the operation request and its identification code to the controller through the distributed node 2. Then, the administrator sends an operation request for creating interface A in the router R1 to the distributed node 1 through the cloud platform interface, and the distributed node 1 learns, according to the service logic, that the operation request depends on the previous operation request for creating the router R1.
  • the distributed node 1 After assigning the identification code to the operation request, the distributed node 1 forwards the current operation request and the identification code, and the identification code of the operation request of the created router R1, to the controller through the distributed node 3, if created
  • the operation request of the interface A reaches the controller before the operation request of the router R1 is created, the controller marks the identification code of the operation request of the interface A created in the router R1 as the pending state, and saves the operation request (if the operation is directly processed)
  • the operation request will fail because the router R1 is not found) until the controller receives the creation of the router R1.
  • the controller After the operation request and its identification code are successfully processed and the operation request for creating the router R1 is successfully processed, the controller starts to process the operation request for creating the interface A in the router R1, and thereafter if the controller receives the creation of the router R1 through the distributed node 3 The operation request of interface B, the controller can directly process the operation request (because the operation request for creating router A has been successfully processed).
  • an operation request may also depend on multiple first-time operation requests.
  • an operation request simultaneously depends on multiple first-time operation requests, only the operation request is required.
  • the request and its identification code, and a plurality of dependent codes are simultaneously sent to the controller.
  • the controller processes the operation request only when the identification codes of the plurality of operation requests that are dependent are processed. .
  • the present invention provides the following solution. Referring to FIG. 5, an interaction diagram of another service processing method according to an embodiment of the present invention is provided. The method includes:
  • Step 501 The terminal sends a first operation request to the first distributed node, where the first operation request includes the first service object.
  • Step 503 The terminal sends a third operation request to the distributed node 1, where the third operation request includes the second service object.
  • Step 504 The distributed node 1 determines that the third operation request is dependent on the first operation request, and uses the first identifier code as the dependency code of the third operation request.
  • Step 507 The controller determines that the first operation request that is dependent on is not processed, and does not process the third operation request temporarily;
  • Step 508 The controller learns that the first operation request is not processed after the preset time is exceeded.
  • the unprocessed state of the identification code 1 indicates that the operation request 1 is not processed, if the operation request 1 is successfully processed within the preset time period, the state of the identification code 1 is updated to the processed state. Identification code 1
  • the unprocessed state indicates that the operation request 1 fails to process, and the state of the identification code 1 will remain unprocessed for a preset period of time.
  • Step 509 The controller sends a third operation request processing failure notification message to the distributed node 1 through the distributed node 3;
  • Step 510 The distributed node 1 sends a third operation request processing failure notification message to the cloud platform interface for the user to perform troubleshooting.
  • the first distributed node allocates an identification code for each operation request, and when the post-operation request depends on the previous operation request, the first distributed node sends the message to the controller after passing the second distributed node.
  • the dependency code is simultaneously sent, so that the controller determines whether the next operation request can be processed according to the state of the dependent code, that is, when the previous operation request has been successfully processed, the latter operation request is processed. Otherwise, the latter operation request is not processed temporarily, so that the forward and backward operation requests can be processed sequentially, and the previous operation request is not processed yet, and the processing caused by the subsequent operation request is directly processed.
  • the timeout judgment mechanism can report the processing status of the operation request in time, which helps to eliminate the fault in time.
  • FIG. 6 is a schematic structural diagram of a first distributed node according to an embodiment of the present invention.
  • the first distributed node of the present invention communicates with a controller by using at least two second distributed nodes.
  • the first distributed node includes:
  • the obtaining unit 601 is configured to obtain a first operation request, where the first operation request includes a first service object;
  • the allocating unit 602 is configured to allocate a first identification code to the first operation request according to a preset rule, where the first identification code is used to identify a processing sequence of the first operation request by the first operation request;
  • the sending unit 603 is configured to send, by using one of the at least two second distributed nodes, the first operation request and the first identification code to the controller, so that the control Determining whether the first operation request needs to be processed according to the preset rule and the first identification code.
  • the controller determines, according to the preset rule and the first identification code, whether The first operation request to be processed includes:
  • the controller processes the first operation request If the first operation request is determined to be sent after the second operation request that the controller has processed according to the preset rule and the first identification code, the controller processes the first operation request If the first operation request is determined to be sent before the second operation request that the controller has processed according to the preset rule and the first identification code, the controller does not process the first An operation request; the second operation request is sent by the first distributed node to the controller by another second distributed node of the at least two second distributed nodes, the second operation request The first business object is included in the middle.
  • the obtaining unit 601 is further configured to: acquire a third operation request, where the third operation request includes a second service object;
  • the allocating unit 602 is further configured to: allocate, according to the second service object, a third identification code to the third operation request, where the third identification code is used to identify the third operation request to the second service The processing order of the object;
  • the first distributed node further includes:
  • the determining unit 604 is configured to determine that the third operation request is dependent on the first operation request, and use the first identification code as a dependency code of the third operation request;
  • the sending unit 603 is further configured to send, by using another second distributed node of the at least two second distributed nodes, the third operation request, the third identification code, and the Determining a dependency code of the third operation request, so that the controller processes the third operation request after processing the first operation request according to the dependency code of the third operation request.
  • the first distributed node allocates an identifier to the operation request to identify a processing order of the service object that is different operation requests of the same service object, and sends the operation request and the identifier thereof to the controller. So that the controller determines whether the operation request needs to be processed according to the preset rule and the operation code of the operation request, so as to ensure that the operation request containing the service object finally issued by the first distributed node is finally effective, thereby avoiding the node Business processing errors caused by distributed features ensure the correctness of business processing.
  • FIG. 7 is a schematic structural diagram of another first distributed node according to an embodiment of the present invention.
  • the first distributed node includes at least a communication interface 701, a processor 702, and a memory 703.
  • the memory 703 stores a set of program instructions, which may be a high speed RAM memory or a non-volatile memory such as at least one disk memory or the like.
  • the processor 702 may be a general-purpose processor, such as a central processing unit (CPU), a network processor (NP), or an application specific integrated circuit (ASIC), or One or more integrated circuits configured to implement embodiments of the present invention.
  • CPU central processing unit
  • NP network processor
  • ASIC application specific integrated circuit
  • the processor 702 is configured to invoke a program instruction stored in the memory 703, and perform the following operations:
  • the first distributed node communicates with the at least two second distributed nodes through the communication interface 701.
  • determining, by the controller, whether the first operation request needs to be processed according to the preset rule and the first identification code includes:
  • the controller processes the first operation request If the first operation request is determined to be sent after the second operation request that the controller has processed according to the preset rule and the first identification code, the controller processes the first operation request If the first operation request is determined to be sent before the second operation request that the controller has processed according to the preset rule and the first identification code, the controller does not process the first An operation request; the second operation request is sent by the first distributed node to the controller by another second distributed node of the at least two second distributed nodes, the second operation request The first business object is included in the middle.
  • processor 702 is further configured to:
  • the third identification code Assigning, by the second service object, the third identification code to the third operation request, where the third identification code is used to identify a processing sequence of the second operation request by the third operation request;
  • FIG. 8 is a schematic structural diagram of a controller according to an embodiment of the present disclosure, where the controller includes:
  • the receiving unit 801 is configured to receive a first operation request and a first identification code that are sent by the first distributed node by using one of the at least two second distributed nodes, where the first operation request includes the first a business object, the first identification code is used to identify a processing sequence of the first operation request by the first operation request;
  • a determining unit 802 configured to determine, according to the preset rule and the first identification code, whether the first operation request needs to be processed; if the first operation is determined according to the preset rule and the first identification code, The request is sent after the second operation request that the controller has processed, and the first operation request is processed; if the first operation request is determined according to the preset rule and the first identification code, The first operation request is not processed before the second operation request processed by the controller is sent; the second operation request is passed by the first distributed node through the at least two second distributed nodes Another second distributed node is sent to the controller, and the second operation request includes the first service object.
  • the receiving unit 801 is further configured to receive, by the first distributed node, a third operation request sent by another second distributed node of the at least two second distributed nodes, the third identifier a code and a dependency code of the third operation request, where the third operation request includes a second service object, where the third identification code is used to identify a processing order of the second operation request by the third operation request
  • the first identification code is a dependency code of the third operation request
  • the controller further includes a processing unit 803, configured to process the third operation request after processing the first operation request according to the dependency code of the third operation request.
  • the information received by the controller includes an operation request and an identifier thereof, and the identifier code is used to identify a processing order of the service object that is included in the operation request of the same service object, and the controller may perform the request according to the preset rule and the operation request.
  • the identification code determines whether the operation request needs to be processed, so as to ensure that the operation request containing the business object finally issued by the first distributed node is finally effective. The business processing errors caused by the distributed characteristics of the nodes are avoided, and the correctness of the business processing is ensured.
  • FIG. 9 is a schematic structural diagram of another controller according to an embodiment of the present invention.
  • the controller includes at least a communication interface 901, a processor 902, and a memory 903.
  • the memory 903 stores a set of program instructions, which may be a high speed RAM memory or a non-volatile memory such as at least one disk memory or the like.
  • the processor 902 can be a general purpose processor, such as a CPU, NP, etc., or can be an Application Specific Integrated Circuit (ASIC), or one or more integrated circuits configured to implement embodiments of the present invention.
  • ASIC Application Specific Integrated Circuit
  • the processor 902 is configured to invoke a program instruction stored in the memory 903, and perform the following operations:
  • the communication interface 901 Receiving, by the communication interface 901, a first operation request and a first identification code sent by the first distributed node by using one of the at least two second distributed nodes, where the first operation request includes the first a business object, the first identification code is used to identify a processing sequence of the first operation request by the first operation request;
  • processor 902 is further configured to:
  • the code is a dependency code of the third operation request
  • the device embodiments described above are merely illustrative, and the units described as separate components may or may not be physically separated. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the embodiment.
  • the connection relationship between the modules indicates that there is a communication connection between them, and specifically, one or more communication buses or signal lines can be realized.
  • the present invention can be implemented by means of software plus necessary general hardware, and of course, dedicated hardware, dedicated CPU, dedicated memory, dedicated memory, Special components and so on.
  • functions performed by computer programs can be easily implemented with the corresponding hardware, and the specific hardware structure used to implement the same function can be various, such as analog circuits, digital circuits, or dedicated circuits. Circuits, etc.
  • software program implementation is a better implementation in more cases.
  • the technical solution of the present invention which is essential or contributes to the prior art, can be embodied in the form of a software product stored in a readable storage medium, such as a floppy disk of a computer.
  • U disk mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk, etc., including a number of instructions to make a computer device (may be A personal computer, server, or network device, etc.) performs the methods described in various embodiments of the present invention.
  • a computer device may be A personal computer, server, or network device, etc.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Multimedia (AREA)
  • Mobile Radio Communication Systems (AREA)
  • Computer And Data Communications (AREA)

Abstract

本发明公开了一种业务处理方法及设备,业务处理方法应用于包括第一分布式节点和至少两个第二分布式节点的系统中,第一分布式节点通过至少两个第二分布式节点与控制器通信,业务处理方法包括:第一分布式节点获取第一操作请求,第一操作请求中包括第一业务对象;第一分布式节点按照预设规则为第一操作请求分配第一标识码,第一标识码用于标识第一操作请求对第一业务对象的处理顺序;第一分布式节点通过至少两个第二分布式节点中的一个第二分布式节点向控制器发送第一操作请求及第一标识码,以使得控制器根据预设规则和第一标识码确定是否需要处理第一操作请求,本发明能够保证业务处理的正确性。

Description

一种业务处理方法及设备 技术领域
本发明实施例涉及通信技术领域,尤其涉及一种业务处理方法及设备。
背景技术
软件定义网络(Software Defined Network,SDN)是一种优化和简化网络操作的体系结构,将SDN技术引入云计算领域后,SDN控制器北向接入分布式云平台,能够实现更为智能化的业务功能。将SDN引入云计算领域后,系统架构可如图1所示,管理员通过分布式平台提供的云平台界面管理分布式云平台的设备与资源,分布式云平台由多台分布式节点组成,分布式节点分为两类,一类提供北向接口能力,如分布式节点1,而另一类提供业务处理能力以及南向接口能力,例如分布式节点2、3、4。分布式云平台南向与SDN控制器对接,利用SDN控制器来控制大量的网络数据,由此对分布式云平台而言,看到的不再是大量的网络设备,而只是一个巨型的超级网络设备。
目前系统架构中,由于云平台界面不感知云平台的分布式的存在,所以每个云平台界面实例都是通过一个分布式节点接入,当然不同的云平台界面实例通过不同的分布式节点接入是完全可行的。图1所示的云平台界面通过分布式节点1接入云平台,所以所有通过该云平台界面下发的操作请求都会先通过分布式节点1,再通过其它分布式节点(如分布式节点2、3、4)转发给SDN控制器进行处理。
上述网络架构下,当针对同一业务对象先后发送了两个互为更新关系的操作请求时,由于分布式节点1通过不同的分布式节点(例如分布式节点2、3)先后向控制器发送这两个操作请求,要保证处理结果正确,则必须保证先发的操作请求先至控制器,这样最终生效的才是后发的操作请求。但在分布式云平台中,由于平台中各节点之间的分布式特性,不同节点的处理能力不同,通常无法保障先发操作请求先至控制器,如果后发的操作请求到达控制器的时间早于先发的操作请求到达控制器的时间,最后处理的是先发的操作请求,则最终生效的反而是先发的操作请求,从而导致了处理结果错误。
发明内容
有鉴于此,本发明实施例提供了一种业务处理方法及设备,能够在分布式云平台中保证业务处理的正确性。
第一方面,提供了一种业务处理方法,应用于包括第一分布式节点和至少两个第二分布式节点的系统中,所述第一分布式节点通过所述至少两个第二分布式节点与控制器通信,所述方法包括:
所述第一分布式节点获取第一操作请求,所述第一操作请求中包括第一业务对象;
所述第一分布式节点按照预设规则为所述第一操作请求分配第一标识码,所述第一标识码用于标识所述第一操作请求对所述第一业务对象的处理顺序;
所述第一分布式节点通过所述至少两个第二分布式节点中的一个第二分布式节点向所述控制器发送所述第一操作请求及所述第一标识码,以使得所述控制器根据所述预设规则和所述第一标识码确定是否需要处理所述第一操作请求。
结合第一方面,在第一方面的第一种实施方式中,所述控制器根据所述预设规则和所述第一标识码确定是否需要处理所述第一操作请求包括:
若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之后发送,则处理所述第一操作请求;若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之前发送,则不处理所述第一操作请求;所述第二操作请求由所述第一分布式节点通过所述至少两个第二分布式节点中的另一个第二分布式节点发送给所述控制器,所述第二操作请求中包括所述第一业务对象。
结合第一方面的第一种实施方式,在第一方面的第二种实施方式中,所述第一标识码为时间戳,或者所述第一标识码是递增或递减的自然数;
所述预设规则是:针对包含同一业务对象的不同操作请求,按照操作请求的先后顺序分配对应的标识码。
结合第一方面,或第一方面的第一种、或第二种实施方式,在第一方面的第三种实施方式中,所述方法还包括:
所述第一分布式节点获取第三操作请求,所述第三操作请求中包括第二业务对象;
所述第一分布式节点按照所述预设规则为所述第三操作请求分配第三标识码,所述第三标识码用于标识所述第三操作请求对所述第二业务对象的处理顺序;
若所述第一分布式节点确定所述第三操作请求依赖于所述第一操作请求,则将所述第一标识码作为所述第三操作请求的依赖码;
所述第一分布式节点通过所述至少两个第二分布式节点中的另一个第二分布式节点向所述控制器发送所述第三操作请求,所述第三标识码以及所述第三操作请求的依赖码,以使得所述控制器根据所述第三操作请求的依赖码,在处理所述第一操作请求之后处理所述第三操作请求。
第二方面,提供了一种业务处理方法,应用于包括第一分布式节点和至少两个第二分布式节点的系统中,所述第一分布式节点通过所述至少两个第二分布式节点与控制器通信,所述方法包括:
所述控制器接收所述第一分布式节点通过所述至少两个第二分布式节点中的一个第二分布式节点发送的第一操作请求和第一标识码,所述第一操作请求中包括第一业务对象,所述第一标识码用于标识所述第一操作请求对所述第一业务对象的处理顺序;
所述控制器根据预设规则和所述第一标识码,确定是否需要处理所述第一操作请求;若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之后发送,则处理所述第一操作请求;若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之前发送,则不处理所述第一操作请求;所述第二操作请求由所述第一分布式节点通过所述至少两个第二分布式节点中的另一个第二分布式节点发送给所述控制器,所述第二操作请求中包括所述第一业务对象。
结合第二方面,在第二方面的第一种实施方式中,所述方法还包括:
所述控制器接收所述第一分布式节点通过所述至少两个第二分布式节点中的另一个第二分布式节点发送的第三操作请求,第三标识码及所述第三操作请求的依赖码,所述第三操作请求中包括第二业务对象,所述第三标识码 用于标识所述第三操作请求对所述第二业务对象的处理顺序,所述第一标识码为所述第三操作请求的依赖码;
所述控制器根据所述第三操作请求的依赖码,在处理所述第一操作请求之后处理所述第三操作请求。
第三方面,提供了一种第一分布式节点,所述第一分布式节点通过至少两个第二分布式节点与控制器通信,所述第一分布式节点包括:
获取单元,用于获取第一操作请求,所述第一操作请求中包括第一业务对象;
分配单元,用于按照预设规则为所述第一操作请求分配第一标识码,所述第一标识码用于标识所述第一操作请求对所述第一业务对象的处理顺序;
发送单元,用于通过所述至少两个第二分布式节点中的一个第二分布式节点向所述控制器发送所述第一操作请求及所述第一标识码,以使得所述控制器根据所述预设规则和所述第一标识码确定是否需要处理所述第一操作请求。
结合第三方面,在第三方面的第一种实施方式中,所述控制器根据所述预设规则和所述第一标识码确定是否需要处理所述第一操作请求包括:
若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之后发送,则所述控制器处理所述第一操作请求;若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之前发送,则所述控制器不处理所述第一操作请求;所述第二操作请求由所述第一分布式节点通过所述至少两个第二分布式节点中的另一个第二分布式节点发送给所述控制器,所述第二操作请求中包括所述第一业务对象。
结合第三方面,或第三方面的第一种实施方式,在第三方面的第二种实施方式中,所述获取单元还用于,获取第三操作请求,所述第三操作请求中包括第二业务对象;
所述分配单元还用于,根据所述第二业务对象为所述第三操作请求分配第三标识码,所述第三标识码用于标识所述第三操作请求对所述第二业务对象的处理顺序;
所述第一分布式节点还包括:
确定单元,用于确定所述第三操作请求依赖于所述第一操作请求,将所述第一标识码作为所述第三操作请求的依赖码;
所述发送单元还用于,通过所述至少两个第二分布式节点中的另一个第二分布式节点向所述控制器发送所述第三操作请求,所述第三标识码以及所述第三操作请求的依赖码,以使得所述控制器根据所述第三操作请求的依赖码,在处理所述第一操作请求之后处理所述第三操作请求。
第四方面,提供了一种控制器,包括:
接收单元,用于接收第一分布式节点通过至少两个第二分布式节点中的一个第二分布式节点发送的第一操作请求和第一标识码,所述第一操作请求中包括第一业务对象,所述第一标识码用于标识所述第一操作请求对所述第一业务对象的处理顺序;
确定单元,用于根据预设规则和所述第一标识码,确定是否需要处理所述第一操作请求;若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之后发送,则处理所述第一操作请求;若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之前发送,则不处理所述第一操作请求;所述第二操作请求由所述第一分布式节点通过所述至少两个第二分布式节点中的另一个第二分布式节点发送给所述控制器,所述第二操作请求中包括所述第一业务对象。
结合第四方面,在第四方面的第一种实施方式中,所述接收单元还用于,接收所述第一分布式节点通过所述至少两个第二分布式节点中的另一个第二分布式节点发送的第三操作请求,第三标识码及所述第三操作请求的依赖码,所述第三操作请求中包括第二业务对象,所述第三标识码用于标识所述第三操作请求对所述第二业务对象的处理顺序,所述第一标识码为所述第三操作请求的依赖码;
所述控制器还包括处理单元,所述处理单元用于根据所述第三操作请求的依赖码,在处理所述第一操作请求之后处理所述第三操作请求。
本申请的技术方案具有以下优点:
第一分布式节点会为操作请求分配标识码,以标识包含同一业务对象的不同操作请求对该业务对象的处理顺序,并将操作请求及其标识码对应发送 给控制器,以使得控制器根据预设规则及操作请求的标识码确定是否需要处理该操作请求,以保证最终生效的是第一分布式节点最后发出的包含该业务对象的操作请求,以此避免了节点的分布式特性导致的业务处理错误,保证了业务处理的正确性。
附图说明
为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1为现有技术分布式云平台系统架构示意图;
图2为本发明实施例提供的一种业务处理方法流程图;
图3为本发明实施例提供的一种业务处理方法的交互示意图;
图4为本发明实施例提供的另一种业务处理方法的交互示意图;
图5为本发明实施例提供的又一种业务处理方法的交互示意图;
图6为本发明实施例提供的一种第一分布式节点的结构示意图;
图7为本发明实施例提供的另一种第一分布式节点的结构示意图;
图8为本发明实施例提供的一种控制器的结构示意图;
图9为本发明实施例提供的另一种控制器的结构示意图。
具体实施方式
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行描述,显然,所描述的实施例仅仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。
由于分布式云平台中各节点之间的分布式特性,不同节点的处理能力不同,无法保障先发业务先至,因此也就无法保证业务处理的正确性。本发明实施例提供了一种业务处理方法及相关设备,能够在分布式云平台中保证业务处理的正确性。
本发明实施例中,系统中由两类分布式节点组成,可以将提供北向接口 能力的分布式节点称为第一分布式节点,例如图1中的分布式节点1;将提供业务处理能力以及南向接口能力的分布式节点称为第二分布式节点,例如图1中的分布式节点2、3、4,第二分布式节点至少有两个,第一分布式节点通过所述至少两个第二分布式节点与控制器通信。
请参阅图2,为本发明实施例提供的一种业务处理方法的流程图,所述方法包括:
步骤201、第一分布式节点获取第一操作请求,第一操作请求中包括第一业务对象;
云平台界面可以根据用户的操作向第一分布式节点下发第一操作请求。
步骤202、第一分布式节点按照预设规则,为所述第一操作请求分配第一标识码;
第一标识码用于标识所述第一操作请求对所述第一业务对象的处理顺序。针对包含同一业务对象的不同操作请求,先发的操作请求对该业务对象的处理顺序应该先于后发的操作请求对该业务对象的处理顺序。
步骤203、第一分布式节点通过所述至少两个第二分布式节点中的一个第二分布式节点向所述控制器发送所述第一操作请求及所述第一标识码,以使得所述控制器根据所述预设规则和所述第一标识码确定是否需要处理所述第一操作请求。
具体实现中,控制器根据所述预设规则和所述第一标识码确定是否需要处理所述第一操作请求包括:若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之后发送(即先发的第二操作请求,后发的第一操作请求,第二操作请求对第一业务对象的处理顺序应该先于第一操作请求对第一业务对象的处理顺序,实际处理顺序与之相符),则处理所述第一操作请求;若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之前发送(即先发的第一操作请求,后发的第二操作请求,第一操作请求对第一业务对象的处理顺序应该先于第二操作请求对第一业务对象的处理顺序,而实际处理顺序与之相反,先处理了第二操作请求),则不处理所述第一操作请求;所述第二操作请求由所述第一分布式节点通过所述至少两个第二分布式节点中的另一个第二分布式节点发送给所述控制器,所述第二操作请求中包括所述第 一业务对象。
包含同一业务对象的操作请求具有不同的标识码,可选地,标识码可以是时间戳,所述第一分布式节点可以将发送操作请求时的时间戳作为该操作请求的标识码。预设规则可以是:时间先后顺序。例如,第一分布式节点先向控制器发送了包含第一业务对象的第一操作请求,后向控制器发送了包含所述第一业务对象的第二操作请求,则所述第一操作请求对应的第一标识码为早于所述第二操作请求对应的第二标识码的时间戳。若控制器先接收到第二操作请求,在处理第二操作请求之后,接收到了第一操作请求,则根据上述预设规则及第一标识码,所述控制器确定第一分布式节点先发的第一操作请求,后发的第二操作请求,则不处理第一操作请求。
可选地,标识码也可以是递增或递减的自然数,所述第一分布式节点可按照发送操作请求的先后,以递增或递减的自然数作为标识符分配给操作请求。所述预设规则可以是:从小到大或从大到小。以标识码是递增自然数为例,例如,第一分布式节点先向控制器发送了包含第一业务对象的第一操作请求,后向控制器发送了包含所述第一业务对象的第二操作请求,则为所述第一操作请求分配的第一标识码为小于所述第二操作请求对应的第二标识码的自然数。若控制器先接收到第二操作请求,在处理第二操作请求之后,接收到了第一操作请求,则根据上述预设规则及所述第一标识码可以确定第一分布式节点先发的第一操作请求,后发的第二操作请求,则不处理第一操作请求。
为便于理解,下面以一个具体实施例说明本发明提供的业务处理方法,请参阅图3,为本发明实施例提供的一种业务处理方法的交互示意图,所述方法包括:
步骤301、云平台界面向分布式节点1发送第一操作请求,第一操作请求中包括第一业务对象;
步骤302、分布式节点1为第一操作请求分配第一标识码,并将第一标识码及第一操作请求发送给分布式节点2;
具体地,分布式节点1可以按照预设规则为第一操作请求分配第一标识码。本实施例以标识码为递增的自然数,预设规则为时间先后顺序为例进行说明。例如,此处为第一操作请求分配的第一标识码g_id为1。
在分布式节点1接收到第一操作请求之后,可以通过分布式算法选择一个第二分布式节点,或者根据当前各个第二分布式节点的负载情况选择一个第二分布式节点,或者可以随机选择一个第二分布式节点,将第一操作请求及其标识码1发送给所选的第二分布式节点,例如本次所选的第二分布式节点为分布式节点2。由于网络或分布式节点2自身的原因,此处第一操作请求及其标识码没有得到分布式节点2的及时转发。
步骤303、云平台界面向分布式节点1发送第二操作请求,第二操作请求中包括所述第一业务对象;
即云平台界面先后向分布式节点1发送了两个包含同一业务对象(第一业务对象)的操作请求。
步骤304、分布式节点1为第二操作请求分配第二标识码并将第二标识码及第二操作请求发送给分布式节点3;
即分布式节点1通过不同的第二分布式节点将包含同一业务对象的不同操作请求转发给控制器。例如,此处为第二操作请求分配的第二标识码g_id为2。
步骤305、分布式节点3将第二操作请求及第二标识码转发给控制器;
即分布式节点3在接收到第二操作请求及第二标识码之后,及时做了处理,将第二操作请求及第二标识码及时转发给了控制器。
步骤306、控制器处理第二操作请求并在处理之后,保存第二操作请求的标识码2;
具体地,控制器可以在本地缓存中维持如下表1,用于记录已处理的操作请求的相关信息。
表1
Figure PCTCN2016084750-appb-000001
本实施例中的已处理指的是已成功处理,未处理或未成功处理的操作请求的相关信息将不记录在上述表格中。
具体在本实施例中,在控制器接收到第二操作请求(包含第一业务对象)及标识码2时,由于控制器中没有保存与第二操作请求包含的业务对象相同的其他操作请求的标识码,即在此之前,控制器未处理或未成功处理与第二操作请求包含的业务对象相同的其他操作请求,因此,可以直接处理第二操作请求。
步骤307、控制器向对应的网络设备下发处理结果;
此时,第二操作请求生效。
步骤308、分布式节点2将第一操作请求及第一标识码转发给控制器;
步骤309、控制器根据预设规则及第一标识码确定不处理第一操作请求。
由于预设规则为时间先后顺序,第一操作请求的标识码为1,而控制器中存储的已处理的包含同一业务对象(第一业务对象)的另一操作请求的标识码为2,即表明分布式节点1先发的第一操作请求,后发的第二操作请求,第一操作请求的处理顺序应该在第二操作请求之前,但实际情况是第二操作请求已在第一操作请求之前处理了,所以第一操作请求无需处理。
本实施例中,控制器可以直接判断当前操作请求的标识码是否大于控制器中已存储的与当前操作请求包含的业务对象相同的其他操作请求的标识码,如果大于,则确定需要处理当前操作请求,否则,确定不需要处理当前操作请求。
下面举例进行说明,同样以更新IP地址为例,例如云平台界面根据用户的操作,针对同一网络实体先后发送了两次IP地址更新请求,按照本发明提供的业务处理方法,无论先发的操作请求先至控制器,还是后发的操作请求先至控制器,最终生效的都将是后发的操作请求;即如果操作请求先发先至,则处理器可以根据操作请求的标识码依次处理操作请求,最终生效后发的操作请求,如果操作请求先发后至,则处理器可以根据操作请求的标识码决定不处理不符合预设处理顺序的操作请求,保证最终生效的仍是后发的操作请求。
本实施例中,第一分布式节点在将针对同一业务对象的不同操作请求通过不同的第二分布式节点发送给控制器时,会为不同的操作请求分配不同的 标识码,标识码用于标识操作请求对业务对象的处理顺序,并将操作请求及其标识码发送给控制器,以使得控制器根据操作请求对应的标识码确定是否需要处理当前操作请求,从而保证最终生效的是第一分布式节点最后发出的包含该业务对象的操作请求,避免了节点的分布式特性导致的业务处理错误,保证了业务处理的正确性。
上面的实施例解决了针对同一业务对象前后发送了互为操作更新关系的两个操作请求,当前后处理乱序时导致的处理错误问题。实际应用中,还可能出现针对不同的业务对象,前后发了两个操作请求,后一操作请求是否能够处理依赖前一操作请求的处理状态的应用场景,只有当前一操作请求已成功处理,后一操作请求才能处理,如果前一操作请求未成功处理(未处理或处理失败),则直接导致后一操作请求处理失败。而现有技术中,针对后一操作请求依赖前一操作请求的处理状态的应用场景,还没有有效的机制保证前后操作请求能够依次处理,因而容易出现前一操作请求还未处理,而直接处理后一操作请求导致的处理失败。针对这种应用场景,本发明提供了进一步的解决方案,请参阅图4,为本发明实施例提供的另一种业务处理方法的交互示意图,所述方法包括:
步骤401、云平台界面向分布式节点1发送第一操作请求,第一操作请求中包括第一业务对象;
步骤402、分布式节点1为第一操作请求分配第一标识码g_id=1并将g_id=1及第一操作请求发送给分布式节点2;
由于网络或分布式节点2自身的原因,此处第一操作请求及g_id=1没有得到分布式节点2的及时转发。
步骤403、云平台界面向分布式节点1发送第三操作请求,第三操作请求中包括第二业务对象;
步骤404、分布式节点1确定第三操作请求依赖于第一操作请求,将所述第一标识码作为所述第三操作请求的依赖码;
具体实现中,分布式节点1可以根据业务逻辑确定操作请求的依赖关系,例如第一操作请求为创建路由器R1的操作请求,第三操作请求为在路由器R1上创建接口A的操作请求,则根据业务逻辑即可确定第三操作请求依赖第一操作请求。
步骤405、分布式节点1为第三操作请求分配第三标识码g_id=3并将第三操作请求及g_id=3及依赖码pg_id=1发送给分布式节点3;
步骤406、分布式节点3将第三操作请求,g_id=3,pg_id=1转发给控制器;
即分布式节点3在接收到第三操作请求及g_id=3,pg_id=1之后,及时做了处理,将第三操作请求及g_id=3,pg_id=1及时转发给了控制器。
步骤407、控制器判断所依赖的标识码为1的第一操作请求还未处理,暂不处理第二操作请求;
具体地,控制器可以在本地缓存中维持如下表2,用于记录每个操作请求的处理状态。
表2
包括的业务对象 操作请求及其标识码g_id
  g_id=1(未处理)
第二业务对象 第三操作请求,g_id=3(待处理),pg_id=1
第三业务对象 第四操作请求,g_id=4(待处理),pg_id=1
控制器在接收到第三操作请求及g_id=3,pg_id=1之后,可以判断所依赖的第一操作请求的标识码1的状态(由于此时控制器还未接收到分布式节点2转发的第一操作请求及其标识码1,控制器中未保存标识码1及其状态,故控制器在接收到第三操作请求及g_id=3,pg_id=1之后,可以将标识码1标记为未处理状态。当然,若控制器在接收到第三操作请求及g_id=3,pg_id=1之前,已接收到分布式节点2转发的第一操作请求及其标识码1,但对第一操作请求的处理结果为处理失败,则控制器中也不会保存标识码1及其状态,这种情况下,控制器在接收到第二操作请求及g_id=2,pg_id=1,仍可以将标识码1标记为未处理状态,故本实施例的未处理状态可以表示未处理,也可以表示处理失败),由于标识码1为未处理状态,则控制器暂不处理第三操作请求,保存第三操作请求、标识码3及其依赖码,并将其标识码3设置为待处理状态。
步骤408、分布式节点2将第一操作请求及其标识码g_id=1转发给控制器;
步骤409、控制器处理第一操作请求;
在第一操作请求处理成功之后,控制器将第一操作请求的标识码设置为已处理状态。
步骤410、控制器将处理结果下发给网络设备;
步骤411、控制器查找依赖第一操作请求的第三操作请求并处理;
控制器在成功处理第一操作请求之后,查找依赖第一操作请求,且标识码的状态为待处理的第三操作请求,处理第三操作请求,并在处理成功之后,将第三操作请求的标识码3标记为已处理状态。
步骤412、控制器将处理结果下发给网络设备;
此后,若分布式节点1接收到第四操作请求,第四操作请求包括第三业务对象,且确定第四操作请求也依赖第一操作请求,则将第一操作请求的标识码作为第四操作请求的依赖码,则在控制器接收到第四操作请求之后,根据第四操作请求的依赖码的状态可以直接处理第四操作请求(由于第一操作请求的标识码为已处理状态)。
例如管理员通过云平台界面向分布式节点1下发了创建路由器R1的操作请求,分布式节点1为该操作请求分配标识码并将操作请求及其标识码通过分布式节点2转发给控制器,接下来管理员又通过云平台界面向分布式节点1下发了在路由器R1中创建接口A的操作请求,分布式节点1根据业务逻辑获知本次操作请求依赖之前的创建路由器R1的操作请求,分布式节点1在为本次操作请求分配标识码之后,将本次操作请求及标识码,以及所依赖的创建路由器R1的操作请求的标识码通过分布式节点3转发给控制器,如果创建接口A的操作请求在创建路由器R1的操作请求之前到达控制器,则控制器将在路由器R1中创建接口A的操作请求的标识码标记为待处理状态,并保存该操作请求(如果直接处理该操作请求,将会因为找不到路由器R1而失败),直到控制器在接收到创建路由器R1的操作请求及其标识码,并成功处理创建路由器R1的操作请求之后,控制器才开始处理在路由器R1中创建接口A的操作请求,此后如果控制器通过分布式节点3收到了在路由器R1中创建接口B的操作请求,则控制器可以直接处理该操作请求(因为创建路由器A的操作请求已被成功处理)。
本实施例中,某个操作请求还可以同时依赖多个先发的操作请求,具体实现中,如果某个操作请求同时依赖多个先发的操作请求,只需将该操作请 求及其标识码,以及多个依赖码同时发送给控制器即可,这种情况下,只有当被依赖的多个操作请求的标识码均为已处理状态时,控制器才处理该操作请求。
另外,本实施例中,由于第三操作请求依赖第一操作请求,如果第一操作请求未处理,则第三操作请求将一直处于待处理状态。当被依赖的第一操作请求出现丢包时,将会导致第三操作请求长时间无法处理,影响处理效率。针对这一问题,本发明提供了如下解决方案,请参阅图5,为本发明实施例提供的又一种业务处理方法的交互示意图,所述方法包括:
步骤501、终端向第一分布式节点发送第一操作请求,第一操作请求中包括第一业务对象;
步骤502、第一分布式节点为第一操作请求分配第一标识码g_id=1并g_id=1及第一操作请求发送给分布式节点2;
步骤503、终端向分布式节点1发送第三操作请求,第三操作请求中包括第二业务对象;
步骤504、分布式节点1确定第三操作请求依赖于第一操作请求,则将所述第一标识码作为所述第三操作请求的依赖码;
步骤505、分布式节点1为第三操作请求分配第三标识码g_id=3并将第二操作请求及g_id=3及依赖码pg_id=1发送给分布式节点3;
步骤506、分布式节点3将第三操作请求,g_id=3,pg_id=1转发给控制器;
步骤507、控制器判断所依赖的第一操作请求未处理,暂不处理第三操作请求;
步骤501至步骤507的详细描述可参阅前述步骤401至407,此处不再赘述。
步骤508、控制器获知第一操作请求超过预设时间未处理,;
控制器可在接收到第三操作请求,g_id=3,pg_id=1之后,记录等待第一操作请求的标识码1的状态变化的时长,当等待时间超过预设时长,标识码1仍为未处理状态时,即可发送第三操作请求处理失败通知消息。本实施例中,若标识码1的未处理状态表示操作请求1未处理,则在预设时长内,若操作请求1被成功处理了,则标识码1的状态将更新为已处理状态,若标识码1 的未处理状态表示操作请求1处理失败,则在预设时长内标识码1的状态将仍为未处理状态。
步骤509、控制器通过分布式节点3向分布式节点1发送第三操作请求处理失败通知消息;
第三操作请求处理失败通知消息中可以包括第三操作请求的标识码g_id=3,依赖码pg_id=1及处理失败原因,处理失败原因即所依赖的第一操作请求超时未成功处理。
步骤510、分布式节点1将第三操作请求处理失败通知消息发送给云平台界面,以供用户排障。
本实施例中,第一分布式节点会为每个操作请求分配标识码,当后发的操作请求依赖前一操作请求时,第一分布式节点在通过第二分布式节点向控制器发送后一操作请求及标识码时,同时发送依赖码,以使得控制器根据所依赖码的状态确定能否是否处理后一操作请求,即前一操作请求已成功处理时,才处理后一操作请求,否则暂不处理后一操作请求,因而能够保证前后操作请求能够依次处理,避免前一操作请求还未处理,而直接处理后一操作请求导致的处理失败。另外,通过超时判断机制可以及时上报操作请求的处理状态,有助于及时排除故障。
下面请参阅图6,图6为本发明实施例提供的一种第一分布式节点的结构示意图,本发明的第一分布式节点通过至少两个第二分布式节点与控制器通信,所述第一分布式节点包括:
获取单元601,用于获取第一操作请求,所述第一操作请求中包括第一业务对象;
分配单元602,用于按照预设规则为所述第一操作请求分配第一标识码,所述第一标识码用于标识所述第一操作请求对所述第一业务对象的处理顺序;
发送单元603,用于通过所述至少两个第二分布式节点中的一个第二分布式节点向所述控制器发送所述第一操作请求及所述第一标识码,以使得所述控制器根据所述预设规则和所述第一标识码确定是否需要处理所述第一操作请求。
进一步地,所述控制器根据所述预设规则和所述第一标识码确定是否需 要处理所述第一操作请求包括:
若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之后发送,则所述控制器处理所述第一操作请求;若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之前发送,则所述控制器不处理所述第一操作请求;所述第二操作请求由所述第一分布式节点通过所述至少两个第二分布式节点中的另一个第二分布式节点发送给所述控制器,所述第二操作请求中包括所述第一业务对象。
进一步地,所述获取单元601还用于,获取第三操作请求,所述第三操作请求中包括第二业务对象;
所述分配单元602还用于,根据所述第二业务对象为所述第三操作请求分配第三标识码,所述第三标识码用于标识所述第三操作请求对所述第二业务对象的处理顺序;
所述第一分布式节点还包括:
确定单元604,用于确定所述第三操作请求依赖于所述第一操作请求,将所述第一标识码作为所述第三操作请求的依赖码;
所述发送单元603还用于,通过所述至少两个第二分布式节点中的另一个第二分布式节点向所述控制器发送所述第三操作请求,所述第三标识码以及所述第三操作请求的依赖码,以使得所述控制器根据所述第三操作请求的依赖码,在处理所述第一操作请求之后处理所述第三操作请求。
本实施例中,第一分布式节点会为操作请求分配标识码,以标识包含同一业务对象的不同操作请求对该业务对象的处理顺序,并将操作请求及其标识码对应发送给控制器,以使得控制器根据预设规则及操作请求的标识码确定是否需要处理该操作请求,以保证最终生效的是第一分布式节点最后发出的包含该业务对象的操作请求,以此避免了节点的分布式特性导致的业务处理错误,保证了业务处理的正确性。
通过图6所示实施例描述,本领域的技术人员可以清楚地了解到本申请可借助软件加通用硬件平台的方式来实现。参见图7,为本发明实施例提供的另一种第一分布式节点的结构示意图,该第一分布式节点至少包括通信接口701、处理器702及存储器703。
该存储器703存储一组程序指令,该存储器可以是是高速RAM存储器,也可能是非易失性存储器(non-volatile memory),例如至少一个磁盘存储器等。
该处理器702可以是通用处理器,例如中央处理器(central processing unit,简称CPU),网络处理器(network processor,简称NP),也可以是特定集成电路ASIC(Application Specific Integrated Circuit),或者是被配置成实施本发明实施例的一个或多个集成电路。
该处理器702,用于调用该存储器703存储的程序指令,执行如下操作:
获取第一操作请求,所述第一操作请求中包括第一业务对象;
按照预设规则为所述第一操作请求分配第一标识码,所述第一标识码用于标识所述第一操作请求对所述第一业务对象的处理顺序;
通过所述至少两个第二分布式节点中的一个第二分布式节点向所述控制器发送所述第一操作请求及所述第一标识码,以使得所述控制器根据所述预设规则和所述第一标识码确定是否需要处理所述第一操作请求。
所述第一分布式节点通过所述通信接口701与所述至少两个第二分布式节点通信。
进一步地,控制器根据所述预设规则和所述第一标识码确定是否需要处理所述第一操作请求包括:
若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之后发送,则所述控制器处理所述第一操作请求;若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之前发送,则所述控制器不处理所述第一操作请求;所述第二操作请求由所述第一分布式节点通过所述至少两个第二分布式节点中的另一个第二分布式节点发送给所述控制器,所述第二操作请求中包括所述第一业务对象。
进一步地,处理器702还用于,
获取第三操作请求,所述第三操作请求中包括第二业务对象;
根据所述第二业务对象为所述第三操作请求分配第三标识码,所述第三标识码用于标识所述第三操作请求对所述第二业务对象的处理顺序;
确定所述第三操作请求依赖于所述第一操作请求,将所述第一标识码作 为所述第三操作请求的依赖码;
通过所述至少两个第二分布式节点中的另一个第二分布式节点向所述控制器发送所述第三操作请求,所述第三标识码以及所述第三操作请求的依赖码,以使得所述控制器根据所述第三操作请求的依赖码,在处理所述第一操作请求之后处理所述第三操作请求。
请参阅图8,图8为本发明实施例提供的一种控制器的结构示意图,所述控制器包括:
接收单元801,用于接收第一分布式节点通过至少两个第二分布式节点中的一个第二分布式节点发送的第一操作请求和第一标识码,所述第一操作请求中包括第一业务对象,所述第一标识码用于标识所述第一操作请求对所述第一业务对象的处理顺序;
确定单元802,用于根据预设规则和所述第一标识码,确定是否需要处理所述第一操作请求;若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之后发送,则处理所述第一操作请求;若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之前发送,则不处理所述第一操作请求;所述第二操作请求由所述第一分布式节点通过所述至少两个第二分布式节点中的另一个第二分布式节点发送给所述控制器,所述第二操作请求中包括所述第一业务对象。
进一步地,所述接收单元801还用于,接收所述第一分布式节点通过所述至少两个第二分布式节点中的另一个第二分布式节点发送的第三操作请求,第三标识码及所述第三操作请求的依赖码,所述第三操作请求中包括第二业务对象,所述第三标识码用于标识所述第三操作请求对所述第二业务对象的处理顺序,所述第一标识码为所述第三操作请求的依赖码;
所述控制器还包括处理单元803,所述处理单元803用于根据所述第三操作请求的依赖码,在处理所述第一操作请求之后处理所述第三操作请求。
本实施例中,控制器接收的信息包括操作请求及其标识码,标识码用于标识包含同一业务对象的不同操作请求对该业务对象的处理顺序,控制器可以根据预设规则及操作请求的标识码确定是否需要处理该操作请求,以保证最终生效的是第一分布式节点最后发出的包含该业务对象的操作请求,以此 避免了节点的分布式特性导致的业务处理错误,保证了业务处理的正确性。
通过图8所示实施例描述可知,本领域的技术人员可以清楚地了解到本申请可借助软件加必需的通用硬件平台的方式来实现。参见图9,为本发明实施例提供的另一种控制器的结构示意图,该控制器至少包括通信接口901、处理器902及存储器903。
该存储器903存储一组程序指令,该存储器可以是是高速RAM存储器,也可能是非易失性存储器(non-volatile memory),例如至少一个磁盘存储器等。
该处理器902可以是通用处理器,例如CPU,NP等,也可以是特定集成电路ASIC(Application Specific Integrated Circuit),或者是被配置成实施本发明实施例的一个或多个集成电路。
该处理器902,用于调用该存储器903存储的程序指令,执行如下操作:
从所述通信接口901接收第一分布式节点通过至少两个第二分布式节点中的一个第二分布式节点发送的第一操作请求和第一标识码,所述第一操作请求中包括第一业务对象,所述第一标识码用于标识所述第一操作请求对所述第一业务对象的处理顺序;
根据预设规则和所述第一标识码,确定是否需要处理所述第一操作请求;若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之后发送,则处理所述第一操作请求;若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之前发送,则不处理所述第一操作请求;所述第二操作请求由所述第一分布式节点通过所述至少两个第二分布式节点中的另一个第二分布式节点发送给所述控制器,所述第二操作请求中包括所述第一业务对象。
进一步地,处理器902还用于,
从所述通信接口901接收所述第一分布式节点通过所述至少两个第二分布式节点中的另一个第二分布式节点发送的第三操作请求,第三标识码及所述第三操作请求的依赖码,所述第三操作请求中包括第二业务对象,所述第三标识码用于标识所述第三操作请求对所述第二业务对象的处理顺序,所述第一标识码为所述第三操作请求的依赖码;
根据所述第三操作请求的依赖码,在处理所述第一操作请求之后处理所 述第三操作请求。
以上装置实施例中未做详细描述的步骤或过程可参阅对应方法实施例的描述,此处不再赘述。
需说明的是,以上所描述的装置实施例仅仅是示意性的,其中所述作为分离部件说明的单元可以是或者也可以不是物理上分开的。可以根据实际的需要选择其中的部分或者全部模块来实现本实施例方案的目的。另外,本发明提供的装置实施例附图中,模块之间的连接关系表示它们之间具有通信连接,具体可以实现为一条或多条通信总线或信号线。本领域普通技术人员在不付出创造性劳动的情况下,即可以理解并实施。
通过以上的实施方式的描述,所属领域的技术人员可以清楚地了解到本发明可借助软件加必需的通用硬件的方式来实现,当然也可以通过专用硬件包括专用集成电路、专用CPU、专用存储器、专用元器件等来实现。一般情况下,凡由计算机程序完成的功能都可以很容易地用相应的硬件来实现,而且,用来实现同一功能的具体硬件结构也可以是多种多样的,例如模拟电路、数字电路或专用电路等。但是,对本发明而言更多情况下软件程序实现是更佳的实施方式。基于这样的理解,本发明的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在可读取的存储介质中,如计算机的软盘,U盘、移动硬盘、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、磁碟或者光盘等,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本发明各个实施例所述的方法。
以上对本发明实施例所提供的一种业务处理方法及设备进行了详细介绍,对于本领域的一般技术人员,依据本发明实施例,在具体实施方式及应用范围上均会有改变之处,因此,本说明书内容不应理解为对本发明的限制。

Claims (11)

  1. 一种业务处理方法,应用于包括第一分布式节点和至少两个第二分布式节点的系统中,其特征在于,所述第一分布式节点通过所述至少两个第二分布式节点与控制器通信,所述方法包括:
    所述第一分布式节点获取第一操作请求,所述第一操作请求中包括第一业务对象;
    所述第一分布式节点按照预设规则为所述第一操作请求分配第一标识码,所述第一标识码用于标识所述第一操作请求对所述第一业务对象的处理顺序;
    所述第一分布式节点通过所述至少两个第二分布式节点中的一个第二分布式节点向所述控制器发送所述第一操作请求及所述第一标识码,以使得所述控制器根据所述预设规则和所述第一标识码确定是否需要处理所述第一操作请求。
  2. 根据权利要求1所述的方法,其特征在于,所述控制器根据所述预设规则和所述第一标识码确定是否需要处理所述第一操作请求包括:
    若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之后发送,则处理所述第一操作请求;若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之前发送,则不处理所述第一操作请求;所述第二操作请求由所述第一分布式节点通过所述至少两个第二分布式节点中的另一个第二分布式节点发送给所述控制器,所述第二操作请求中包括所述第一业务对象。
  3. 根据权利要求2所述的方法,其特征在于,所述第一标识码为时间戳,或者所述第一标识码是递增或递减的自然数;
    所述预设规则是:针对包含同一业务对象的不同操作请求,按照操作请求的先后顺序分配对应的标识码。
  4. 根据权利要求1至3任意一项所述的方法,其特征在于,还包括:
    所述第一分布式节点获取第三操作请求,所述第三操作请求中包括第二业务对象;
    所述第一分布式节点按照所述预设规则为所述第三操作请求分配第三标识码,所述第三标识码用于标识所述第三操作请求对所述第二业务对象的处理顺序;
    若所述第一分布式节点确定所述第三操作请求依赖于所述第一操作请求,则将所述第一标识码作为所述第三操作请求的依赖码;
    所述第一分布式节点通过所述至少两个第二分布式节点中的另一个第二分布式节点向所述控制器发送所述第三操作请求,所述第三标识码以及所述第三操作请求的依赖码,以使得所述控制器根据所述第三操作请求的依赖码,在处理所述第一操作请求之后处理所述第三操作请求。
  5. 一种业务处理方法,应用于包括第一分布式节点和至少两个第二分布式节点的系统中,其特征在于,所述第一分布式节点通过所述至少两个第二分布式节点与控制器通信,所述方法包括:
    所述控制器接收所述第一分布式节点通过所述至少两个第二分布式节点中的一个第二分布式节点发送的第一操作请求和第一标识码,所述第一操作请求中包括第一业务对象,所述第一标识码用于标识所述第一操作请求对所述第一业务对象的处理顺序;
    所述控制器根据预设规则和所述第一标识码,确定是否需要处理所述第一操作请求;若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之后发送,则处理所述第一操作请求;若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之前发送,则不处理所述第一操作请求;所述第二操作请求由所述第一分布式节点通过所述至少两个第二分布式节点中的另一个第二分布式节点发送给所述控制器,所述第二操作请求中包括所述第一业务对象。
  6. 根据权利要求5所述的方法,其特征在于,还包括:
    所述控制器接收所述第一分布式节点通过所述至少两个第二分布式节点中的另一个第二分布式节点发送的第三操作请求,第三标识码及所述第三操作请求的依赖码,所述第三操作请求中包括第二业务对象,所述第三标识码用于标识所述第三操作请求对所述第二业务对象的处理顺序,所述第一标识码为所述第三操作请求的依赖码;
    所述控制器根据所述第三操作请求的依赖码,在处理所述第一操作请求之后处理所述第三操作请求。
  7. 一种第一分布式节点,其特征在于,所述第一分布式节点通过至少两个第二分布式节点与控制器通信,所述第一分布式节点包括:
    获取单元,用于获取第一操作请求,所述第一操作请求中包括第一业务对象;
    分配单元,用于按照预设规则为所述第一操作请求分配第一标识码,所述第一标识码用于标识所述第一操作请求对所述第一业务对象的处理顺序;
    发送单元,用于通过所述至少两个第二分布式节点中的一个第二分布式节点向所述控制器发送所述第一操作请求及所述第一标识码,以使得所述控制器根据所述预设规则和所述第一标识码确定是否需要处理所述第一操作请求。
  8. 根据权利要求7所述的第一分布式节点,其特征在于,所述控制器根据所述预设规则和所述第一标识码确定是否需要处理所述第一操作请求包括:
    若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之后发送,则所述控制器处理所述第一操作请求;若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之前发送,则所述控制器不处理所述第一操作请求;所述第二操作请求由所述第一分布式节点通过所述至少两个第二分布式节点中的另一个第二分布式节点发送给所述控制器,所述第二操作请求中包括所述第一业务对象。
  9. 根据权利要求7或8所述的第一分布式节点,其特征在于,
    所述获取单元还用于,获取第三操作请求,所述第三操作请求中包括第二业务对象;
    所述分配单元还用于,根据所述第二业务对象为所述第三操作请求分配第三标识码,所述第三标识码用于标识所述第三操作请求对所述第二业务对象的处理顺序;
    所述第一分布式节点还包括:
    确定单元,用于确定所述第三操作请求依赖于所述第一操作请求,将所 述第一标识码作为所述第三操作请求的依赖码;
    所述发送单元还用于,通过所述至少两个第二分布式节点中的另一个第二分布式节点向所述控制器发送所述第三操作请求,所述第三标识码以及所述第三操作请求的依赖码,以使得所述控制器根据所述第三操作请求的依赖码,在处理所述第一操作请求之后处理所述第三操作请求。
  10. 一种控制器,其特征在于,包括:
    接收单元,用于接收第一分布式节点通过至少两个第二分布式节点中的一个第二分布式节点发送的第一操作请求和第一标识码,所述第一操作请求中包括第一业务对象,所述第一标识码用于标识所述第一操作请求对所述第一业务对象的处理顺序;
    确定单元,用于根据预设规则和所述第一标识码,确定是否需要处理所述第一操作请求;若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之后发送,则处理所述第一操作请求;若根据所述预设规则和所述第一标识码,确定所述第一操作请求是在所述控制器已处理的第二操作请求之前发送,则不处理所述第一操作请求;所述第二操作请求由所述第一分布式节点通过所述至少两个第二分布式节点中的另一个第二分布式节点发送给所述控制器,所述第二操作请求中包括所述第一业务对象。
  11. 根据权利要求10所述的控制器,其特征在于,
    所述接收单元还用于,接收所述第一分布式节点通过所述至少两个第二分布式节点中的另一个第二分布式节点发送的第三操作请求,第三标识码及所述第三操作请求的依赖码,所述第三操作请求中包括第二业务对象,所述第三标识码用于标识所述第三操作请求对所述第二业务对象的处理顺序,所述第一标识码为所述第三操作请求的依赖码;
    所述控制器还包括处理单元,所述处理单元用于根据所述第三操作请求的依赖码,在处理所述第一操作请求之后处理所述第三操作请求。
PCT/CN2016/084750 2015-09-25 2016-06-03 一种业务处理方法及设备 WO2017049959A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
EP16847841.0A EP3346671B1 (en) 2015-09-25 2016-06-03 Service processing method and equipment
US15/935,788 US10951732B2 (en) 2015-09-25 2018-03-26 Service processing method and device

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201510621776.X 2015-09-25
CN201510621776.XA CN106559439B (zh) 2015-09-25 2015-09-25 一种业务处理方法及设备

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US15/935,788 Continuation US10951732B2 (en) 2015-09-25 2018-03-26 Service processing method and device

Publications (1)

Publication Number Publication Date
WO2017049959A1 true WO2017049959A1 (zh) 2017-03-30

Family

ID=58385807

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2016/084750 WO2017049959A1 (zh) 2015-09-25 2016-06-03 一种业务处理方法及设备

Country Status (4)

Country Link
US (1) US10951732B2 (zh)
EP (1) EP3346671B1 (zh)
CN (1) CN106559439B (zh)
WO (1) WO2017049959A1 (zh)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20200218994A1 (en) * 2019-01-08 2020-07-09 International Business Machines Corporation Generating a sequence rule
CN113127023B (zh) * 2019-12-31 2024-04-09 华为技术有限公司 业务升级的方法、装置和系统

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1859263A (zh) * 2005-11-16 2006-11-08 华为技术有限公司 信元重排序方法、使用该方法的信元处理方法及装置
CN101589594A (zh) * 2007-01-22 2009-11-25 高通股份有限公司 针对基于网络的移动性管理系统的多链路支持
CN101589602A (zh) * 2007-01-22 2009-11-25 高通股份有限公司 用于基于网络的移动性管理系统的消息排序
US20140177634A1 (en) * 2012-12-24 2014-06-26 Huawei Technologies Co., Ltd. Software defined network-based data processing method, node, and system
CN104883695A (zh) * 2015-04-24 2015-09-02 南京航空航天大学 一种多跳认知无线电网络架构及部署方法

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6971098B2 (en) * 2001-06-27 2005-11-29 Intel Corporation Method and apparatus for managing transaction requests in a multi-node architecture
US20060195606A1 (en) * 2003-08-22 2006-08-31 Wardwell David R Method and system for collating data in a distributed computer network
US8761085B2 (en) * 2007-09-05 2014-06-24 Nec Corporation Proxy mobile IP system, access gateway and method for determining the order of registration notification messages used therefor
WO2011083780A1 (ja) * 2010-01-05 2011-07-14 日本電気株式会社 通信システム、制御装置、処理規則の設定方法、パケットの送信方法およびプログラム
KR101503450B1 (ko) * 2010-03-17 2015-03-18 닛본 덴끼 가부시끼가이샤 통신 시스템, 노드, 제어 서버 및 통신 방법
US9246778B2 (en) * 2013-08-12 2016-01-26 International Business Machines Corporation System to enhance performance, throughput and reliability of an existing cloud offering
US9667416B1 (en) * 2014-12-18 2017-05-30 EMC IP Holding Company LLC Protecting master encryption keys in a distributed computing environment

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1859263A (zh) * 2005-11-16 2006-11-08 华为技术有限公司 信元重排序方法、使用该方法的信元处理方法及装置
CN101589594A (zh) * 2007-01-22 2009-11-25 高通股份有限公司 针对基于网络的移动性管理系统的多链路支持
CN101589602A (zh) * 2007-01-22 2009-11-25 高通股份有限公司 用于基于网络的移动性管理系统的消息排序
US20140177634A1 (en) * 2012-12-24 2014-06-26 Huawei Technologies Co., Ltd. Software defined network-based data processing method, node, and system
CN104883695A (zh) * 2015-04-24 2015-09-02 南京航空航天大学 一种多跳认知无线电网络架构及部署方法

Also Published As

Publication number Publication date
EP3346671A4 (en) 2018-08-29
CN106559439A (zh) 2017-04-05
US10951732B2 (en) 2021-03-16
US20180219971A1 (en) 2018-08-02
CN106559439B (zh) 2019-10-01
EP3346671A1 (en) 2018-07-11
EP3346671B1 (en) 2020-08-26

Similar Documents

Publication Publication Date Title
CN109688235B (zh) 虚拟网络业务处理方法、装置和系统,控制器,存储介质
US20220124049A1 (en) Distributed fair allocation of shared resources to constituents of a cluster
US10897431B2 (en) Cloud resource processing method and physical node
US10657119B1 (en) Fleet node management system
US10666508B2 (en) Unified software defined networking configuration management over multiple hosting environments
US11398966B2 (en) Cluster wide packet tracing
CN114025021B (zh) 一种跨Kubernetes集群的通信方法、系统、介质和电子设备
CN105993161B (zh) 用于解析地址的元件、方法、系统和计算机可读存储设备
WO2019075773A1 (zh) 数据处理方法、装置、计算机设备和存储介质
CN111212134A (zh) 一种请求报文处理方法、装置、边缘计算系统和电子设备
US10657095B2 (en) Virtualizing connection management for virtual remote direct memory access (RDMA) devices
US10425475B2 (en) Distributed data management
CN111259072A (zh) 数据同步方法、装置、电子设备和计算机可读存储介质
CN111327651A (zh) 资源下载方法、装置、边缘节点及存储介质
EP3261302B1 (en) Storage network element discovery method and device
CN111064786B (zh) 账户标识管理方法及设备
US11070614B2 (en) Load balancing method and related apparatus
WO2017049959A1 (zh) 一种业务处理方法及设备
US9847927B2 (en) Information processing device, method, and medium
US9634987B2 (en) Obtaining a MAC address from an external source
US11140183B2 (en) Determining criticality of identified enterprise assets using network session information
US10536548B2 (en) Redundant network routing with proxy servers
CN116032994B (zh) 物联网设备连接方法、装置、电子设备和存储介质
US10417093B2 (en) Methods for providing global spare data storage device management and devices thereof
CN110958182B (zh) 一种通信方法及相关设备

Legal Events

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

Ref document number: 16847841

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

WWE Wipo information: entry into national phase

Ref document number: 2016847841

Country of ref document: EP