# US 12,222,851 B2 · Selectively capturing traffic in service mesh

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

- Number: US 12,222,851 B2
- Document ID: US12222851B2
- Status: Granted
- Kind: B2
- Application number: 18/314,977
- Filed: 2023-05-10
- Published: 2024-11-14
- Granted: 2025-02-11
- Earliest claimed: 2023-05-10
- Assignees: International Business Machines Corporation
- Applicants: International Business Machines Corporation
- Inventors: Yue Wang; Xinpeng Liu; Wei Wu; Peng Hui Jiang; Xiao Ling Chen
- Web page: https://patentgrep.com/patent/US12222851B2

## CPC

- G06F 11/3688: {for test execution, e.g. scheduling of test suites}
- G06F 11/3692: {for test results analysis}
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

A computer-implemented method for a service mesh to simulate and address a situation in which there are several transactions among services with an asynchronous relationship between the services is provided. The computer-implemented method includes identifying that the situation occurs with a response provided to a user upon a user invocation of one of the services, analyzing the situation to determine that the asynchronous relationship between the services caused an error in at least one of the several transactions, recording data of a next user invocation of the one of the services, modifying the data of the next user invocation of the one of the services to correct the error and to thereby generate modified data, simulating an execution of the next user invocation of the service using the modified data and confirming that the modified data corrects the error based on results of the simulating.

## Claims

### Claim 1

A computer-implemented method for a service mesh to simulate and address a situation in which there are several transactions among services with an asynchronous relationship between the services, the computer-implemented method comprising:
identifying that the situation occurs with a response provided to a user upon a user invocation of one of the services;
analyzing the situation to determine that the asynchronous relationship between the services caused an error in at least one of the several transactions;
recording data of a next user invocation of the one of the services;
modifying the data of the next user invocation of the one of the services to correct the error and to thereby generate modified data;
simulating an execution of the next user invocation of the service using the modified data; and
confirming that the modified data corrects the error based on results of the simulating of the execution of the next user invocation of the service.

### Claim 2 (depends on 1)

The computer-implemented method according to claim 1, wherein the one of the services comprises an electronic product order form.

### Claim 3 (depends on 2)

The computer-implemented method according to claim 2, wherein the situation comprises the electronic product order form using a product catalog querier to obtain a product catalog from a catalog database prior to the product catalog being stored in the catalog database.

### Claim 4 (depends on 1)

The computer-implemented method according to claim 1, wherein the recording of the data comprises:
updating a sampling rate of the data; and
adding a new header to a request of the next user invocation of the service.

### Claim 5 (depends on 4)

The computer-implemented method according to claim 4, wherein the updating of the sampling rate of the data comprises setting the sampling rate at 100% and the new header comprises a tracing instruction.

### Claim 6 (depends on 1)

The computer-implemented method according to claim 1, wherein the modifying of the data comprises changing a data timestamp.

### Claim 7

A computer-implemented method for operating a service mesh to simulate and address a situation in which there are several transactions among services with an asynchronous relationship between the services,
wherein one of the services comprises an electronic product order form and the situation comprises an error caused by the electronic product order form using a product catalog querier to obtain a product catalog from a catalog database prior to the product catalog being stored in the catalog database,
the computer-implemented method comprising:
identifying a solution for the situation in a production environment; and
simulating the solution in a simulator environment to confirm that the solution is corrective,
wherein the solution comprises modifying data of a next user invocation of the one of the services to correct the error and to thereby generate modified data for use in the simulating of the solution and using the modified data in the simulating of the solution.

### Claim 8

A computer program product for a service mesh to simulate and address a situation in which there are several transactions among services with an asynchronous relationship between the services, the computer program product comprising one or more computer readable storage media having computer readable program code collectively stored on the one or more computer readable storage media, the computer readable program code being executed by a processor of a computer system to cause the computer system to perform a method comprising:
identifying that the situation occurs with a response provided to a user upon a user invocation of one of the services;
analyzing the situation to determine that the asynchronous relationship between the services caused an error in at least one of the several transactions;
recording data of a next user invocation of the one of the services;
modifying the data of the next user invocation of the one of the services to correct the error and to thereby generate modified data;
simulating an execution of the next user invocation of the service using the modified data; and
confirming that the modified data corrects the error based on results of the simulating of the execution of the next user invocation of the service.

### Claim 9 (depends on 8)

The computer program product according to claim 8, wherein the one of the services comprises an electronic product order form.

### Claim 10 (depends on 9)

The computer program product according to claim 9, wherein the situation comprises the electronic product order form using a product catalog querier to obtain a product catalog from a catalog database prior to the product catalog being stored in the catalog database.

### Claim 11 (depends on 8)

The computer program product according to claim 8, wherein the recording of the data comprises:
updating a sampling rate of the data; and
adding a new header to a request of the next user invocation of the service.

### Claim 12 (depends on 11)

The computer program product according to claim 11, wherein the updating of the sampling rate of the data comprises setting the sampling rate at 100% and the new header comprises a tracing instruction.

### Claim 13 (depends on 8)

The computer program product according to claim 8, wherein the modifying of the data comprises changing a data timestamp.

### Claim 14

A computing system comprising:
a processor;
a memory coupled to the processor; and
one or more computer readable storage media coupled to the processor, the one or more computer readable storage media collectively containing instructions that are executed by the processor via the memory to implement a method for a service mesh to simulate and address a situation in which there are several transactions among services with an asynchronous relationship between the services comprising:
identifying that the situation occurs with a response provided to a user upon a user invocation of one of the services;
analyzing the situation to determine that the asynchronous relationship between the services caused an error in at least one of the several transactions;
recording data of a next user invocation of the one of the services;
modifying the data of the next user invocation of the one of the services to correct the error and to thereby generate modified data;
simulating an execution of the next user invocation of the service using the modified data; and
confirming that the modified data corrects the error based on results of the simulating of the execution of the next user invocation of the service.

### Claim 15 (depends on 14)

The computing system according to claim 14, wherein the one of the services comprises an electronic product order form.

### Claim 16 (depends on 15)

The computing system according to claim 15, wherein the situation comprises the electronic product order form using a product catalog querier to obtain a product catalog from a catalog database prior to the product catalog being stored in the catalog database.

### Claim 17 (depends on 14)

The computing system according to claim 14, wherein the recording of the data comprises:
updating a sampling rate of the data; and
adding a new header to a request of the next user invocation of the service.

### Claim 18 (depends on 17)

The computing system according to claim 17, wherein the updating of the sampling rate of the data comprises setting the sampling rate at 100% and the new header comprises a tracing instruction.

### Claim 19 (depends on 14)

The computer system according to claim 14, wherein the modifying of the data comprises changing a data timestamp.

### Claim 20

A computing system comprising:
a processor;
a memory coupled to the processor; and
one or more computer readable storage media coupled to the processor, the one or more computer readable storage media collectively containing instructions that are executed by the processor via the memory to implement a method for a service mesh to simulate and address a situation in which there are several transactions among services with an asynchronous relationship between the services,
wherein one of the services comprises an electronic product order form and the situation comprises an error caused by the electronic product order form using a product catalog querier to obtain a product catalog from a catalog database prior to the product catalog being stored in the catalog database,
the method comprising:
identifying a solution for the situation in a first environment; and
simulating the solution in a second environment to confirm that the solution is corrective,
wherein the solution comprises modifying data of a next user invocation of the one of the services to correct the error and to thereby generate modified data for use in the simulating of the solution and using the modified data in the simulating of the solution.
