Composable query language gateway routing protocol
AssigneeRed Hat, Inc.
InventorsWojciech Julian Trocki, Hiram Remigio Chirino
Life of this patent
Estimating the term…
Abstract
A query request for data associated with a plurality of services executed by a plurality of host systems is received. A type of query associated with the query request is identified. A subset of the plurality of services comprising data associated with the type of query is identified using a query routing data structure, wherein the query routing data structure is received from a gateway system that generates the query routing data structure in view of receiving corresponding service schemas from the plurality of services. The query request is transmitted to the subset of the plurality of services identified using the query routing data structure.
Claims19
A method comprising:
- receiving, at a client device, a GraphQL query request for data comprising a plurality of query types associated with a plurality of services executed by a plurality of host systems;
- identifying, by a processing device of the client device, the plurality of query types associated with the GraphQL query request;
- sending the GraphQL query request and the plurality of query types identified as associated with the GraphQL query request from the client device to a gateway system and receiving at the client device a corresponding query routing data structure that identifies each service associated with each query type and routing information for each service, wherein the gateway system generates the query routing data structure by receiving a GraphQL service schema from each service and merging the GraphQL service schemas into a composable GraphQL query language schema;
- transmitting the GraphQL query request from the client device to each of the plurality of services identified using the query routing data structure, wherein transmitting the GraphQL query request from the client device to each of the plurality of services comprises transmitting GraphQL queries to GraphQL application programming interfaces (APIs) associated with each of the plurality of services;
- receiving query results from each of the plurality of services responsive to the GraphQL query request;
- and
- aggregating the query results received from each of the plurality of services for presentation to a user.
An apparatus comprising:
- a memory;
- and
- a processing device, operatively coupled to the memory, to:
- receive a GraphQL query request and a plurality of query types associated with the GraphQL query request from a client device;
- receive corresponding GraphQL service schemas from a plurality of services executed by a plurality of host systems;
- identify corresponding types of queries for each of the plurality of services in view of the corresponding GraphQL service schemas of the plurality of services;
- generate a query routing data structure comprising the corresponding types of queries for each of the plurality of services by merging the corresponding GraphQL service schemas into a composable GraphQL query language schema;
- provide the query routing data structure to the client device, wherein the client device is to transmit additional GraphQL query requests to the plurality of services in view of the query routing data structure, wherein transmitting the additional GraphQL query requests from the client device to each of the plurality of services comprises transmitting GraphQL queries to GraphQL application programming interfaces (APIs) associated with each of the plurality of services;
- receive query results from each of the plurality of services responsive to the additional GraphQL query requests;
- and
- aggregate the query results received from each of the plurality of services for presentation to a user.
A non-transitory computer-readable storage medium including instructions that, when executed by a processing device of a first host system, cause the processing device to:
- generate a first query routing data structure comprising corresponding types of queries for each of a plurality of services executed by a plurality of host systems using corresponding GraphQL service schemas received from the plurality of services executed by the plurality of host systems and merged into a composable GraphQL query language schema;
- provide the first query routing data structure to a client device, wherein the client device is to transmit GraphQL query requests to the plurality of services in view of the first query routing data structure, wherein transmitting the GraphQL query requests from the client device to each of the plurality of services comprises transmitting GraphQL queries and associated query types to GraphQL application programming interfaces (APIs) associated with each of the plurality of services;
- identify a modification to the plurality of services in the first query routing data structure;
- generate a second query routing data structure comprising the modification to the plurality of services;
- provide the second query routing data structure to the client device;
- receive query results from each of the plurality of services responsive to the GraphQL query request;
- and aggregate the query results received from each of the plurality of services for presentation to a user.
Dependencies are inferred from the claim text.