# US 2024/0256551 A1 · Execution tracing for node cluster

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2024/0256551 A1
- Document ID: US20240256551A1
- Status: Published application
- Kind: A1
- Application number: 18/162,371
- Filed: 2023-01-31
- Published: 2024-08-01
- Earliest claimed: 2023-01-31
- Assignees: Salesforce, Inc.
- Applicants: Salesforce, Inc.
- Inventors: Shao-Yuan Ho; Atul Jha; Mark Mears; Thomas Fanghaenel
- Web page: https://patentgrep.com/patent/US20240256551A1

## CPC

- G06F 16/24561: {Intermediate data storage techniques for performance improvement}
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

Techniques are disclosed that pertain to tracing performance information. A computer system receives a request from a second computer system to perform operations pertaining to a database statement of a database transaction that is being executed by the second computer system. The computer system determines that the request is an initial request received by the computer system to perform work of that database statement. Based on the determining, the computer system stores, in association with the database statement, baseline information that is indicative of a baseline state of one or more performance metrics. Subsequent to performing the operations, the computer system receives a request from the second computer system for performance information. The computer system derives the performance information from a difference between the current state of the one or more performance metrics and the baseline state. The computer system sends the performance information to the second computer system.

## Claims

### Claim 1

A method for tracing performance information at a first computer system that participates in an execution of a first database statement included in a database transaction that is being executed by a second computer system, the method comprising:
receiving, by the first computer system, a first request from the second computer system to perform one or more operations pertaining to the first database statement;
determining, by the first computer system, that the first request is an initial request received by the first computer system to perform work of the first database statement;
based on the determining, the first computer system storing, in association with the first database statement, first baseline information that is indicative of a first baseline state of one or more performance metrics;
after performing the one or more operations, the first computer system receiving a second request from the second computer system for the performance information;
deriving, by the first computer system, the performance information from a difference between a current state of the one or more performance metrics and the first baseline state that is indicated by the first baseline information; and
providing, by the first computer system, a response to the second computer system that includes the performance information.

### Claim 2 (depends on 1)

The method of claim 1, wherein the first database statement is nested within a second database statement included in the database transaction, and the method further comprising:
storing, by the first computer system, second baseline information, in association with the second database statement, that is indicative of a second baseline state for the one or more performance metrics.

### Claim 3 (depends on 2)

The method of claim 2, wherein the first baseline information and the second baseline information are stored in a stack structure having a set of levels, each of which corresponds to a respective level of a nested database statement hierarchy having the first and second database statements.

### Claim 4 (depends on 3)

The method of claim 3, further comprising:
receiving, by the first computer system, an initial request to perform work of a database statement associated with a particular level of the nested database statement hierarchy; and
purging, by the first computer system, baseline information stored in the stack structure that is associated with at least one lower level of the nested database statement hierarchy than the particular level.

### Claim 5 (depends on 2)

The method of claim 2, wherein the first request identifies a nested level of the first database statement within a nested database statement hierarchy having the first and second database statements, and wherein the first baseline information is stored in association with the nested level of the first database statement.

### Claim 6 (depends on 2)

The method of claim 2, further comprising:
in response to receiving a request that is an initial request to perform work for a third database statement that is nested within the second database statement at a same level as the first database statement, the first computer system replacing the first baseline information with third baseline information that is associated with the third database statement.

### Claim 7 (depends on 2)

The method of claim 2, wherein the first request is an initial request that is received by the first computer system to perform work of the second database statement, wherein the first and second baseline states are a same state for the one or more performance metrics.

### Claim 8 (depends on 2)

The method of claim 2, wherein the second baseline information is stored in response to the first computer system receiving an initial request to perform work of the second database statement, wherein the first and second baseline states are different states for the one or more performance metrics.

### Claim 9 (depends on 1)

The method of claim 1, wherein the one or more performance metrics include a memory usage metric that specifies a memory usage associated with the first computer system.

### Claim 10 (depends on 1)

The method of claim 1, wherein the first and second computer systems correspond to respective nodes of a database node cluster that are operable to write data to a database.

### Claim 11

A non-transitory computer readable medium having program instructions stored thereon that are capable of causing a first computer system to perform operations comprising:
receiving, from a second computer system, a first request to perform a first portion of work of a first database statement included in a database transaction that is being executed by the second computer system;
determining that the first request is an initial request received by the first computer system to perform work of the first database statement;
based on the determining, storing, in association with the first database statement, first baseline information that is indicative of a first baseline state of one or more performance metrics of the first computer system;
subsequent to performing the first portion of work, receiving a second request from the second computer system for performance information associated with performance of the first database statement;
deriving the performance information from a difference between a current state of the one or more performance metrics and the first baseline state; and
providing, to the second computer system, the performance information.

### Claim 12 (depends on 11)

The non-transitory computer readable medium of claim 11, wherein the first database statement is nested within a second database statement included in the database transaction, and wherein the operations further comprise:
storing second baseline information, in association with the second database statement, that is indicative of a second baseline state for the one or more performance metrics.

### Claim 13 (depends on 12)

The non-transitory computer readable medium of claim 12, wherein the second request includes a request for additional performance information that is associated with performance of the second database statement, and wherein the operations further comprise:
deriving the additional performance information from a difference between the current state and the second baseline state.

### Claim 14 (depends on 11)

The non-transitory computer readable medium of claim 11, wherein the first request identifies a nested level of the first database statement in a nested database statement hierarchy, and wherein the operations further comprise overriding baseline information that was previously stored for the nested level with the first baseline information.

### Claim 15 (depends on 11)

The non-transitory computer readable medium of claim 11, wherein the operations further comprise:
receiving, from the second computer system, a third request to perform a second portion of work of the first database statement; and
in response to the third request not being an initial request to perform work of the first database statement, performing the second portion of work without storing a baseline state of the one or more performance metrics.

### Claim 16

A non-transitory computer readable medium having program instructions stored thereon that are capable of causing a first computer system to perform operations comprising:
receiving a first request to execute a database transaction that includes a first database statement having a set of operations;
sending, to a second computer system, a second request to perform one or more of the set of operations of the first database statement, wherein the second request is an initial request sent to the second computer system to perform work of the first database statement;
after completion of the set of operations, determining that an execution time of the first database statement exceeded a threshold amount of time; and
sending, to the second computer system, a third request for performance information indicative of a set of performance metrics associated with the second computer system and the one or more operations performed by the second computer system; and
receiving the performance information from the second computer system.

### Claim 17 (depends on 16)

The non-transitory computer readable medium of claim 16, wherein the first database statement is nested in a set of database statements included in the database transaction, wherein the operations further comprise:
before sending the second request to the second computer system, determining a nested level of the first database statement, wherein the second request specifies the nested level.

### Claim 18 (depends on 16)

The non-transitory computer readable medium of claim 16, wherein at least one other computer system performed work of the first database statement, and wherein sending the third request includes broadcasting the third request to the second computer system and the at least one other computer system.

### Claim 19 (depends on 16)

The non-transitory computer readable medium of claim 16, wherein the first database statement is nested in a second database statement, wherein the third request is a request for performance information indicative of the set of performance metrics for the second database statement.

### Claim 20 (depends on 16)

The non-transitory computer readable medium of claim 16, wherein the first database statement is nested in a second database statement, wherein the operations further comprise:
sending, to the second computer system, a fourth request for performance information indicative of the set of performance metrics for the second database statement.
