IP Library Granted Patent US 11,409,795
Granted Patent B2
US 11,409,795 · App. 16/123,228 · Granted Aug 9, 2022

Atomically executed application program interfaces

Inventors: Bei Chun Zhou (Beijing, CN); Adrian Kyte (Hursley, GB); Joe Winchester (Hursley, GB); Jenny J. He (Hursley, GB); Guan Jun Liu (Beijing, CN)
Assignee: International Business Machines Corporation
G06F16/901G06F16/11
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 11,409,795
App. No.
16/123,228
Granted
Aug 9, 2022
Kind
B2
Abstract

An example operation may include one or more of identifying a caller blockchain node and one or more callee blockchain nodes within a blockchain network and issuing, by the caller blockchain node, application programming interface calls to application programming interfaces corresponding to each of the one or more callee nodes, in response to a first application programming interface call being issued successfully, directing a smart contract associated with the caller blockchain node to initiate a distributed transaction involving the one or more callee nodes to perform the application program interface calls, the caller node issues application programming interface calls and the one or more callee nodes each performing application programming interface requests.

Claims (58)

1. A callee node in a blockchain network, the callee node comprising:

a memory storing one or more instructions; and

a processor that when executing the one or more instructions is configured to:

receive an application program interface (API) call from a caller node of the blockchain network, the API call associated with a distributed transaction generated by a second smart contract executed by a processor of the caller node;

attempt to perform the API call by a first smart contract of the callee node;

generate an API result indicating a success or a failure of the attempt to perform the API call;

send the API result to the caller node to review the API result and to cause the caller node to generate a notification indicating a success or a failure of the distributed transaction;

in response to a receipt of the notification indicating the success of the distributed transaction, commit the distributed transaction to a shared ledger of the blockchain network.

2. The callee node of claim 1 , wherein, when the API result indicates a successful performance of the API call, the processor is further configured to:

update an API call completion status in the shared ledger.

3. The callee node of claim 1 , wherein the processor is further configured to:

submit a transaction comprising the API result to the shared ledger.

4. The callee node of claim 1 , wherein, when the API result indicates a failed performance of the API call, the processor is further configured to:

execute a rollback of the failed API call; and

update the shared ledger with the failed API result.

5. The callee node of claim 1 , wherein, when the API result indicates a successful completion of the API call, the processor is further configured to:

perform a self-prepare operation; and

update the shared ledger with the successful API result.

6. The callee node of claim 1 , wherein, in response to the receipt of the notification indicating a failure of the distributed transaction, the processor is further configured to:

execute a rollback of the failed API result.

7. The callee node of claim 6 , wherein the rollback of the failed API call is not part of the API call.

8. The callee node of claim 6 , wherein the API call and the API result are completely resolved within the blockchain network.

9. A method, comprising:

receiving, by a callee node of a blockchain network, an application programming interface (API) call from a caller node of the blockchain network, the API call associated with a distributed transaction generated by a second smart contract executed by a processor of the caller node;

attempting, by the callee node, to perform the API call by a first smart contract of the callee node;

generating, by the callee node, an API result indicating the API call completing successfully or indicating a failure of the API call;

sending, by the callee node, the API result to the caller node to review the API result and to cause the caller node to generate a notification indicating a success or a failure of the distributed transaction;

in response to receiving the notification indicating the success of the distributed transaction, committing, by the callee node, the distributed transaction to a shared ledger of the blockchain network.

10. The method of claim 9 , wherein, when the API result indicates the API call completing successfully, the method further comprises:

updating, by the callee node, an API call completion status in the shared ledger.

11. The method of claim 9 , wherein the method further comprises:

submitting, by the callee node, a transaction comprising the API result to the shared ledger.

12. The method of claim 9 , wherein, when the API result indicates the failure of the API call, the method further comprises:

executing, by the callee node, a rollback of the failed API call; and

updating, by the callee node, the shared ledger with the failed API result.

13. The method of claim 9 , wherein, when the API result indicates the API call completing successfully, the method further comprises:

performing a self-prepare operation; and

updating the shared ledger with the successful API result.

14. The method of claim 9 , wherein, in response to the receipt of the notification indicating a failure of the distributed transaction, the method further comprises:

executing, by the callee node, a rollback of the failed API result.

15. A non-transitory computer readable medium comprising one or more instructions that when executed by a processor of a callee node in a blockchain network cause the processor to perform:

receiving an application programming interface (API) call from a caller node of the blockchain network, the API call associated with a distributed transaction generated by a second smart contract executed by a processor of the caller node;

attempting to perform the API call by a first smart contract of the callee node;

generating an API result indicating the API call completing successfully or indicating a failure of the API call;

sending the API result to the caller node to review the API result and to cause the caller node to generate a notification indicating a success or a failure of the distributed transaction;

in response to receiving the notification indicating the success of the distributed transaction, committing the distributed transaction to a shared ledger of the blockchain network.

16. The non-transitory computer readable medium of claim 15 , wherein, when the API result indicates the API call completing successfully, the one or more instructions further cause the processor to perform:

updating an API call completion status in the shared ledger.

17. The non-transitory computer readable medium of claim 15 , wherein the one or more instructions further cause the processor to perform:

submitting a transaction comprising the API result to the shared ledger.

18. The non-transitory computer readable medium of claim 15 , wherein, when the API result indicates the failure of the API call, the one or more instructions further cause the processor to perform:

executing a rollback of the failed API call; and

updating the shared ledger with the failed API result.

19. The non-transitory computer readable medium of claim 15 , wherein, when the API result indicates the API call completing successfully, the one or more instructions further cause the processor to perform:

performing a self-prepare operation; and

updating the shared ledger with the successful API result.

20. The non-transitory computer readable medium of claim 15 , wherein, in response to a receipt of the notification indicating a failure of the distributed transaction, the one or more instructions further cause the processor to perform:

executing a rollback of the failed API result.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Sep 6, 2018
From: ZHOU, BEI CHUN; KYTE, ADRIAN; WINCHESTER, JOE; HE, JENNY J.; LIU, GUAN JUN
To: INTERNATIONAL BUSINESS MACHINES CORPORATION
Reel/Frame 046801/0565 →
Continuity (1)
Related Publication 20200082025A1 · Mar 12, 2020