API Version Compatibility Validation via Schema Querying
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Existing computer systems face challenges in ensuring API version compatibility, as checks at deploy time can become outdated, and runtime checks are computationally expensive and disruptive.
Innovation Solution
An API version compatibility and upgrade process that involves validating API functionality by querying the schema of functions that utilize APIs, updating metadata to allow functions to run with higher API versions, and executing remediation actions when compatibility is not validated.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Reliability
If API version compatibility checks are performed at deploy time, then compatibility validation is achieved, but the checks become outdated as APIs are updated
Solution Approach 1:
The system performs API compatibility validation in advance during deployment, storing the validation results. This preliminary action ensures compatibility is checked before the API is updated, and the results are cached for later use, avoiding the need for repeated runtime checks.
Solution Approach 2:
The system creates a copy of the API schema at deployment time and performs validation against this copied schema. This allows the validation to be performed on a static representation that doesn't change with API updates, while still ensuring compatibility with the actual API.
2Reliability
If API version compatibility checks are performed at runtime, then up-to-date compatibility validation is achieved, but computational expense and performance disruption increase
Solution Approach 1:
The system performs the computationally expensive compatibility validation in advance during deployment rather than at runtime. The validation results are cached and reused, eliminating the performance overhead during actual API operations while maintaining validation reliability.
Solution Approach 2:
The system uses the deployed function's own schema and metadata to perform self-validation against the API schema. This self-service approach allows automated compatibility checking without requiring external validation services or increasing runtime computational burden.
3Adaptability or versatility
If metadata is updated to allow functions to call higher API versions, then adaptability to new API versions is improved, but schema validation may be bypassed
Solution Approach 1:
The system performs schema validation in advance during the metadata update process. Before allowing a function to call a higher API version, the system validates that the function's schema is compatible with the target API version, ensuring reliability is maintained while enabling adaptability.
Solution Approach 2:
The system introduces an intermediate validation step that mediates between the function's current API version and the target higher version. This intermediary process checks schema compatibility and only updates metadata if validation succeeds, preventing bypass of schema validation while enabling version upgrades.
Data Source
AI summary
A system and method are provided for determining API version compatibility. The method includes executing a first query associated with at least one operation of a computer function that utilizes an application programming interface (API), to determine whether the first query validates to a schema for the at least one operation of the computer function, for a version of the API that is higher than a version of the API that the computer function currently calls. The method also includes, responsive to the first query validating to the schema, updating metadata for the computer function to subsequently have the computer function call the higher version of the API.


