Patent ID: 11947517
Assignee: SAP SE
Field: Computer technology (Electrical engineering)
Classification: CPC G | IPC G

Claim 7:
8. One or more non-transitory computer-readable medium storing computer program code comprising sets of instructions to:
determine a plurality of types of transactions executable on a database, each type of transaction including a corresponding set of one or more queries accessing particular tables of the database;
determine a transaction topology for each type of transaction in the plurality of types, the transaction topology for a particular type of transaction including one or more nodes representing particular tables of the database accessed by that particular type of transaction and directed edges between the one or more nodes indicating data dependencies for that particular type of transaction;
combine the transaction topologies for each type of transaction into a combined topology;
generate a serialization graph representing the combined topology, the serialization graph including one or more nodes representing types of transactions and directed edges between the nodes indicating a before/after order of accessing a particular table of the database by the transactions;
identify one or more cycles in the serialization graph based on a determination that a set of directed edge starting from a particular node points back to that particular node to form a cycle;
determine a breaking transaction type for each of the one or more cycles, a corresponding breaking transaction type for a particular cycle breaking the particular cycle when the corresponding breaking transaction type is a last executed transaction in a current epoch;
receive requests to execute a stream of transactions on a database, each transaction in the stream of transaction having a corresponding type that is one of the plurality of types of transactions; and
execute the stream of transactions by scheduling execution of transactions that do not have the breaking transaction type in a current epoch, scheduling a transaction having the breaking transaction type as a last transaction in the current epoch, and scheduling later transaction not having the breaking transaction type in a next epoch, the transaction having the breaking transaction type being executed after every transaction scheduled in the current epoch and being executed before every transaction scheduled in the next epoch.