International Business Machines Corporation
Optimizing JSON document usage
Last updated:
Abstract:
An approach is provided for optimizing data fetching. A query employing a method to fetch data from a JSON document is received. An amount of time required to execute the query and a number of nested layers in a traversal of the JSON document required to fetch the data are determined. Based on the amount of time and the number of nested layers, a cost associated with an execution of the query is calculated. The cost is determined to exceed a threshold value. Responsive to the determination that the cost exceeds the threshold value and using historical query patterns and historical query execution times, a schema of the JSON document is re-designed. The data is fetched from the JSON document using the re-designed schema.
Utility
28 Feb 2020
24 May 2022