CN112597187B - GraphQL query method and device based on FHIR standard - Google Patents

GraphQL query method and device based on FHIR standard Download PDF

Info

Publication number
CN112597187B
CN112597187B CN202110232292.1A CN202110232292A CN112597187B CN 112597187 B CN112597187 B CN 112597187B CN 202110232292 A CN202110232292 A CN 202110232292A CN 112597187 B CN112597187 B CN 112597187B
Authority
CN
China
Prior art keywords
fhir
graphql
query
format
restful
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202110232292.1A
Other languages
Chinese (zh)
Other versions
CN112597187A (en
Inventor
吴侃
包培文
杨开轶
侯文利
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Guanxin Medical And Health Software Technology Co ltd
Original Assignee
Beijing Guanxin Medical And Health Software Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Guanxin Medical And Health Software Technology Co ltd filed Critical Beijing Guanxin Medical And Health Software Technology Co ltd
Priority to CN202110232292.1A priority Critical patent/CN112597187B/en
Publication of CN112597187A publication Critical patent/CN112597187A/en
Application granted granted Critical
Publication of CN112597187B publication Critical patent/CN112597187B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/242Query formulation
    • G06F16/2433Query languages
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/245Query processing
    • G06F16/2455Query execution
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/248Presentation of query results
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/25Integrating or interfacing systems involving database management systems
    • G06F16/258Data format conversion from or to a database

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computational Linguistics (AREA)
  • Mathematical Physics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention relates to a GraphQL query method and a device based on an FHIR standard, wherein the query method comprises the following steps: receiving a GraphQL query request; acquiring parameters in the GraphQL query request, and verifying the parameters; converting the GraphQL query statement into uri in a FHIR RESTful format; invoking FHIR RESTful api with the uri; and converting the format of the query result returned by the FHIR application server, and returning the converted data serving as a GraphQL query result. The invention utilizes the existing FHIR application server, and realizes the GraphQL query mechanism of the FHIR protocol in a way of standard conversion from the GraphQL object to the FHIR resource; the invention can make the FHIR RESTful api more flexible and efficient to call and query, and enriches the front-end development means.

Description

GraphQL query method and device based on FHIR standard
Technical Field
The invention relates to the technical field of software development, in particular to a GraphQL query method and device based on an FHIR standard.
Background
FHIR (Fast Health interactive Resources) is a new generation of medical information exchange standard framework proposed by HL7, which defines a set of medical and Health Resources that express individual modular medical concepts, and by exchanging them, problems can be solved quickly and efficiently in healthcare and related processes. These resources cover essential elements of medical health, such as: patient, admission, diagnostic reports, medication and problem lists, and information for some of the participants, while also supporting a more rich and complex clinical model.
GraphQL is a syntax that describes the method of requesting data, typically used by a client to load data from a server. GraphQL has the following three main features:
it allows the client to specify the specifically required data;
it makes gathering data from multiple data sources simpler;
it uses a type system to describe the data.
The GraphQL provides a brand-new data query mode, and can only acquire required data, so that the api call is more flexible, efficient and low in cost.
The existing FHIR RESTful api calling query process has poor flexibility and low efficiency.
Disclosure of Invention
In view of this, the present invention provides a graph ql query method and apparatus based on FHIR standard to make the FHIR RESTful api call query process more flexible, efficient and low-cost, and make the completeness of the front-end call better.
In order to achieve the purpose, the invention adopts the following technical scheme: a GraphQL query method based on FHIR standard comprises the following steps:
receiving a GraphQL query request; wherein the GraphQL query request comprises a GraphQL query statement;
acquiring parameters in the GraphQL query request, and verifying the parameters;
converting the GraphQL query statement into a resource identifier in a FHIR RESTful format;
utilizing the resource identifier in the FHIR RESTful format to call RESTful api on the FHIR application server;
acquiring query result data returned by the FHIR application server;
carrying out format conversion on the query result data, and returning the data after format conversion as a GraphQL query result;
wherein, the obtaining the parameters in the GraphQL query request and checking the parameters includes:
defining a GraphQLInputObject object of the query parameter according to the FHIR protocol to complete the definition of the GraphQL query parameter, enabling the parameter to accord with the resource standard of the FHIR protocol, wherein the format of the GraphQL standard is the GraphQL standard, and meanwhile, completing the verification constraint of the parameter;
the converting the GraphQL query statement into the resource identifier in FHIR RESTful format includes:
and constructing a regular expression component, and converting the GraphQL query statement into a resource identifier in a FHIR RESTful format.
Optionally, the defining the GraphQLInputObject object of the query parameter according to the FHIR protocol includes:
the name of the query parameters, the data type and the corresponding check rules are defined according to the FHIR protocol.
Optionally, when the resource identifier in the FHIR RESTful format is used to call a RESTful api on the FHIR application server, verifying whether the query parameter meets the check constraint;
and when the query parameters meet the check constraint, executing a calling operation.
Optionally, the verifying whether the query parameter satisfies the verification constraint includes:
the GraphQL verifies whether the query parameter is a standard resource identifier.
Optionally, the query result data returned by the FHIR application server is in an XML format;
the format conversion of the query result data includes:
and converting the XML-format query result data returned by the FHIR application server into JSON-format data.
The invention also provides a GraphQL inquiry device based on the FHIR standard, which comprises:
the receiving module is used for receiving a GraphQL inquiry request; wherein the GraphQL query request comprises a GraphQL query statement;
the verification module is used for acquiring parameters in the GraphQL query request and verifying the parameters;
the first conversion module is used for converting the GraphQL query statement into a resource identifier in a FHIR RESTful format;
the calling module is used for calling RESTful api on the FHIR application server by utilizing the resource identifier in the FHIR RESTful format;
the acquisition module is used for acquiring the query result data returned by the FHIR application server;
the second conversion module is used for carrying out format conversion on the query result data and returning the data after format conversion as a GraphQL query result;
wherein, the obtaining the parameters in the GraphQL query request and checking the parameters includes:
defining a GraphQLInputObject object of the query parameter according to the FHIR protocol to complete the definition of the GraphQL query parameter, enabling the parameter to accord with the resource standard of the FHIR protocol, wherein the format of the GraphQL standard is the GraphQL standard, and meanwhile, completing the verification constraint of the parameter;
the converting the GraphQL query statement into the resource identifier in FHIR RESTful format includes:
and constructing a regular expression component, and converting the GraphQL query statement into a resource identifier in a FHIR RESTful format.
The invention also provides a controller for executing the GraphQL query method based on the FHIR standard.
The present invention also provides a computer-readable storage medium having a computer program stored thereon, where the computer program, when executed by a processor, performs a GraphQL query method based on FHIR standard, including:
receiving a GraphQL query request; wherein the GraphQL query request comprises a GraphQL query statement;
acquiring parameters in the GraphQL query request, and verifying the parameters;
converting the GraphQL query statement into a resource identifier in a FHIR RESTful format;
utilizing the resource identifier in the FHIR RESTful format to call RESTful api on the FHIR application server;
acquiring query result data returned by the FHIR application server;
carrying out format conversion on the query result data, and returning the data after format conversion as a GraphQL query result;
wherein, the obtaining the parameters in the GraphQL query request and checking the parameters includes:
defining a GraphQLInputObject object of the query parameter according to the FHIR protocol to complete the definition of the GraphQL query parameter, enabling the parameter to accord with the resource standard of the FHIR protocol, wherein the format of the GraphQL standard is the GraphQL standard, and meanwhile, completing the verification constraint of the parameter;
the converting the GraphQL query statement into the resource identifier in FHIR RESTful format includes:
and constructing a regular expression component, and converting the GraphQL query statement into a resource identifier in a FHIR RESTful format.
The invention adopts the technical scheme that the GraphQL query method based on the FHIR standard comprises the following steps: receiving a GraphQL query request; wherein the GraphQL query request comprises a GraphQL query statement; acquiring parameters in the GraphQL query request, and verifying the parameters; converting the GraphQL query statement into a resource identifier in a FHIR RESTful format; utilizing the resource identifier in the FHIR RESTful format to call RESTful api on the FHIR application server; acquiring query result data returned by the FHIR application server; and converting the format of the query result data, and returning the data after format conversion as a GraphQL query result. The method of the invention utilizes the existing FHIR application server, and realizes the realizing mechanism of the FHIR protocol GraphQL inquiry in a way of standard conversion from GraphQL object to FHIR resource; the query method of the invention can make the FHIR RESTful api more flexible and efficient in calling and querying, and enriches the front-end development means.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
FIG. 1 is a schematic flow chart provided by the GraphQL query method based on FHIR standard according to the present invention;
fig. 2 is a schematic structural diagram provided by a GraphQL query device based on FHIR standard according to the present invention.
In the figure: 1. a receiving module; 2. a checking module; 3. a first conversion module; 4. calling a module; 5. an acquisition module; 6. and a second conversion module.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the technical solutions of the present invention will be described in detail below. It is to be understood that the described embodiments are merely exemplary of the invention, and not restrictive of the full scope of the invention. All other embodiments, which can be derived by a person skilled in the art from the examples given herein without any inventive step, are within the scope of the present invention.
FIG. 1 is a flow chart diagram provided by the GraphQL query method based on the FHIR standard.
As shown in fig. 1, the GraphQL query method based on FHIR standard according to the present invention includes:
s11: receiving a GraphQL query request; wherein the GraphQL query request comprises a GraphQL query statement;
s12: acquiring parameters in the GraphQL query request, and verifying the parameters;
wherein, the obtaining the parameters in the GraphQL query request and checking the parameters includes:
defining a GraphQLInputObject object of a query parameter according to an FHIR protocol to complete the definition of a GraphQL query parameter, enabling the parameter to conform to the resource standard of the FHIR protocol, wherein the format of the GraphQL query parameter is the GraphQL standard, and meanwhile, completing the check constraint of the parameter (for example, type: UriScalar indicates that the parameter is uri);
defining GraphQLObject objects of all resources according to FHIR protocol, and realizing GraphQL rotation objects of FHIR resources, wherein the objects conform to FHIR standard.
Further, the GraphQLInputObject defining query parameters according to the FHIR protocol includes:
the name of the query parameters, the data type and the corresponding check rules are defined according to the FHIR protocol.
S13: converting the GraphQL query statement into uri in a FHIR RESTful format;
the uri is a resource identifier;
the converting the GraphQL query statement into the resource identifier in FHIR RESTful format includes:
and constructing a regular expression component according to the query parameters, and converting the GraphQL query statement into a resource identifier in a FHIR RESTful format.
S14: utilizing the uri in the FHIR RESTful format to call RESTful api on the FHIR application server;
further, when the resource identifier in the FHIR RESTful format is used for calling the RESTful api on the FHIR application server, whether the query parameter meets the check constraint is verified;
when the query parameter meets the check constraint, executing a calling operation; otherwise, the call can be directly returned and the call fails; further, when the call fails, corresponding information feedback can be given to inform a caller that the call fails because the query parameters do not meet the check constraint.
Further, the verifying whether the query parameter satisfies the check constraint includes:
the GraphQL verifies that the query parameter is a standard resource identifier (i.e., a standard uri).
S15: acquiring query result data returned by the FHIR application server;
s16: carrying out format conversion on the query result data, and returning the data after format conversion as a GraphQL query result;
further, the query result data returned by the FHIR application server is in an XML format;
the format conversion of the query result data includes:
and converting the XML-format query result data returned by the FHIR application server into JSON-format data.
In practical application, the query method firstly receives a GraphQL query request; the GraphQL query request comprises a GraphQL query statement; acquiring parameters in the GraphQL query request, and verifying the parameters; specifically, the method defines the GraphQLInputObject of all query parameters according to the FHIR protocol, completes the definition of the GraphQL query input parameters, the parameters conform to the resource standard of the FHIR protocol, the format is the GraphQL standard, and the verification constraint of the parameters is defined, such as type: UriSlar indicates that the parameter is uri, and GraphQL automatically verifies whether the parameter is the standard uri when the parameter is called. Then, a regular expression is constructed according to the query parameters, and the GraphQL query statement is converted into uri in the format of FHIR RESTful according to the regular expression; utilizing the uri in the FHIR RESTful format to call RESTful api on the FHIR application server; during calling, the GraphQL automatically verifies whether the parameter is the standard uri, if so, the calling operation is executed, and query result data returned by the FHIR application server is obtained; acquiring query result data (in XML format) returned by the FHIR application server; converting the format of the query result data into JSON format, and returning the JSON format data after format conversion as GraphQL query results; the query process is now complete.
The method of the invention utilizes the existing FHIR application server, and realizes the realizing mechanism of the FHIR protocol GraphQL inquiry in a way of standard conversion from GraphQL object to FHIR resource; the query method of the invention can make the FHIR RESTful api more flexible and efficient in calling and querying, and enriches the front-end development means.
Fig. 2 is a schematic structural diagram provided by a GraphQL query device based on FHIR standard according to the present invention.
As shown in fig. 2, the GraphQL query device based on FHIR standard according to the present invention includes:
the receiving module 1 is used for receiving a GraphQL query request; wherein the GraphQL query request comprises a GraphQL query statement;
the checking module 2 is used for acquiring parameters in the GraphQL query request and checking the parameters;
a first conversion module 3, configured to convert the GraphQL query statement into a resource identifier in FHIR RESTful format;
the calling module 4 is used for calling RESTful api on the FHIR application server by using the resource identifier in the FHIR RESTful format;
an obtaining module 5, configured to obtain query result data returned by the FHIR application server;
the second conversion module 6 is used for performing format conversion on the query result data and returning the data after format conversion as a GraphQL query result;
wherein, the obtaining the parameters in the GraphQL query request and checking the parameters includes:
defining a GraphQLInputObject object of the query parameter according to the FHIR protocol to complete the definition of the GraphQL query parameter, enabling the parameter to accord with the resource standard of the FHIR protocol, wherein the format of the GraphQL standard is the GraphQL standard, and meanwhile, completing the verification constraint of the parameter;
the converting the GraphQL query statement into the resource identifier in FHIR RESTful format includes:
and constructing a regular expression component, and converting the GraphQL query statement into a resource identifier in a FHIR RESTful format.
The working principle of the GraphQL query device based on the FHIR standard of the present invention is the same as the working principle of the GraphQL query method based on the FHIR standard, and is not described herein again.
The query device of the invention utilizes the existing FHIR application server, and realizes the realization mechanism of the FHIR protocol GraphQL query in a way of standard conversion from GraphQL object to FHIR resource; the query device of the invention can make the FHIR RESTful api more flexible and efficient in calling and querying, and enriches the front-end development means.
The invention also provides a controller for executing the GraphQL query method based on the FHIR standard shown in fig. 1.
Furthermore, the present invention provides a computer-readable storage medium having a computer program stored thereon, where the computer program is executed by a processor to perform a GraphQL query method based on FHIR standard, including:
receiving a GraphQL query request; wherein the GraphQL query request comprises a GraphQL query statement;
acquiring parameters in the GraphQL query request, and verifying the parameters;
converting the GraphQL query statement into a resource identifier in a FHIR RESTful format;
utilizing the resource identifier in the FHIR RESTful format to call RESTful api on the FHIR application server;
acquiring query result data returned by the FHIR application server;
carrying out format conversion on the query result data, and returning the data after format conversion as a GraphQL query result;
wherein, the obtaining the parameters in the GraphQL query request and checking the parameters includes:
defining a GraphQLInputObject object of the query parameter according to the FHIR protocol to complete the definition of the GraphQL query parameter, enabling the parameter to accord with the resource standard of the FHIR protocol, wherein the format of the GraphQL standard is the GraphQL standard, and meanwhile, completing the verification constraint of the parameter;
the converting the GraphQL query statement into the resource identifier in FHIR RESTful format includes:
and constructing a regular expression component, and converting the GraphQL query statement into a resource identifier in a FHIR RESTful format.
It is understood that the same or similar parts in the above embodiments may be mutually referred to, and the same or similar parts in other embodiments may be referred to for the content which is not described in detail in some embodiments.
It should be noted that the terms "first," "second," and the like in the description of the present invention are used for descriptive purposes only and are not to be construed as indicating or implying relative importance. Further, in the description of the present invention, the meaning of "a plurality" means at least two unless otherwise specified.
Any process or method descriptions in flow charts or otherwise described herein may be understood as representing modules, segments, or portions of code which include one or more executable instructions for implementing specific logical functions or steps of the process, and alternate implementations are included within the scope of the preferred embodiment of the present invention in which functions may be executed out of order from that shown or discussed, including substantially concurrently or in reverse order, depending on the functionality involved, as would be understood by those reasonably skilled in the art of the present invention.
It should be understood that portions of the present invention may be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, the various steps or methods may be implemented in software or firmware stored in memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, any one or combination of the following techniques, which are known in the art, may be used: a discrete logic circuit having a logic gate circuit for implementing a logic function on a data signal, an application specific integrated circuit having an appropriate combinational logic gate circuit, a Programmable Gate Array (PGA), a Field Programmable Gate Array (FPGA), or the like.
It will be understood by those skilled in the art that all or part of the steps carried by the method for implementing the above embodiments may be implemented by hardware related to instructions of a program, which may be stored in a computer readable storage medium, and when the program is executed, the program includes one or a combination of the steps of the method embodiments.
In addition, functional units in the embodiments of the present invention may be integrated into one processing module, or each unit may exist alone physically, or two or more units are integrated into one module. The integrated module can be realized in a hardware mode, and can also be realized in a software functional module mode. The integrated module, if implemented in the form of a software functional module and sold or used as a stand-alone product, may also be stored in a computer readable storage medium.
The storage medium mentioned above may be a read-only memory, a magnetic or optical disk, etc.
In the description herein, references to the description of the term "one embodiment," "some embodiments," "an example," "a specific example," or "some examples," etc., mean that a particular feature, structure, material, or characteristic described in connection with the embodiment or example is included in at least one embodiment or example of the invention. In this specification, the schematic representations of the terms used above do not necessarily refer to the same embodiment or example. Furthermore, the particular features, structures, materials, or characteristics described may be combined in any suitable manner in any one or more embodiments or examples.
Although embodiments of the present invention have been shown and described above, it is understood that the above embodiments are exemplary and should not be construed as limiting the present invention, and that variations, modifications, substitutions and alterations can be made to the above embodiments by those of ordinary skill in the art within the scope of the present invention.

Claims (6)

1. A GraphQL query method based on FHIR standard is characterized by comprising the following steps:
receiving a GraphQL query request; wherein the GraphQL query request comprises a GraphQL query statement;
acquiring parameters in the GraphQL query request, and verifying the parameters;
converting the GraphQL query statement into a resource identifier in a FHIR RESTful format;
utilizing the resource identifier in the FHIR RESTful format to call RESTful api on the FHIR application server;
acquiring query result data returned by the FHIR application server;
carrying out format conversion on the query result data, and returning the data after format conversion as a GraphQL query result;
wherein, the obtaining the parameters in the GraphQL query request and checking the parameters includes:
defining a GraphQLInputObject object of the query parameter according to the FHIR protocol to complete the definition of the GraphQL query parameter, enabling the parameter to accord with the resource standard of the FHIR protocol, wherein the format of the GraphQL standard is the GraphQL standard, and meanwhile, completing the verification constraint of the parameter;
the converting the GraphQL query statement into the resource identifier in FHIR RESTful format includes:
constructing a regular expression component, and converting the GraphQL query statement into a resource identifier in a FHIR RESTful format;
further comprising:
when the resource identifier in the FHIR RESTful format is used for calling the RESTful api on the FHIR application server, verifying whether the query parameter meets the check constraint;
when the query parameter meets the check constraint, executing a calling operation;
whether the verification query parameter satisfies a verification constraint includes:
the GraphQL verifies whether the query parameter is a standard resource identifier.
2. The GraphQL query method of claim 1, wherein the GraphQLInputObject object defining the query parameters according to FHIR protocol comprises:
the name of the query parameters, the data type and the corresponding check rules are defined according to the FHIR protocol.
3. The GraphQL query method of claim 1 or 2,
the query result data returned by the FHIR application server is in an XML format;
the format conversion of the query result data includes:
and converting the XML-format query result data returned by the FHIR application server into JSON-format data.
4. A GraphQL inquiry device based on FHIR standard is characterized by comprising:
the receiving module is used for receiving a GraphQL inquiry request; wherein the GraphQL query request comprises a GraphQL query statement;
the verification module is used for acquiring parameters in the GraphQL query request and verifying the parameters;
the first conversion module is used for converting the GraphQL query statement into a resource identifier in a FHIR RESTful format;
the calling module is used for calling RESTful api on the FHIR application server by utilizing the resource identifier in the FHIR RESTful format;
the acquisition module is used for acquiring the query result data returned by the FHIR application server;
the second conversion module is used for carrying out format conversion on the query result data and returning the data after format conversion as a GraphQL query result;
wherein, the obtaining the parameters in the GraphQL query request and checking the parameters includes:
defining a GraphQLInputObject object of the query parameter according to the FHIR protocol to complete the definition of the GraphQL query parameter, enabling the parameter to accord with the resource standard of the FHIR protocol, wherein the format of the GraphQL standard is the GraphQL standard, and meanwhile, completing the verification constraint of the parameter;
the converting the GraphQL query statement into the resource identifier in FHIR RESTful format includes:
constructing a regular expression component, and converting the GraphQL query statement into a resource identifier in a FHIR RESTful format;
when the calling module calls RESTful api on the FHIR application server by using the resource identifier in the FHIR RESTful format, verifying whether the query parameter meets the check constraint; when the query parameter meets the check constraint, executing a calling operation;
whether the verification query parameter satisfies a verification constraint includes:
the GraphQL verifies whether the query parameter is a standard resource identifier.
5. A controller for performing the method of any of claims 1 to 3 for the GraphQL lookup based on FHIR standard.
6. A computer-readable storage medium having stored thereon a computer program which, when executed by a processor, performs a method for GraphQL lookup based on FHIR standards, comprising:
receiving a GraphQL query request; wherein the GraphQL query request comprises a GraphQL query statement;
acquiring parameters in the GraphQL query request, and verifying the parameters;
converting the GraphQL query statement into a resource identifier in a FHIR RESTful format;
utilizing the resource identifier in the FHIR RESTful format to call RESTful api on the FHIR application server;
acquiring query result data returned by the FHIR application server;
carrying out format conversion on the query result data, and returning the data after format conversion as a GraphQL query result;
wherein, the obtaining the parameters in the GraphQL query request and checking the parameters includes:
defining a GraphQLInputObject object of the query parameter according to the FHIR protocol to complete the definition of the GraphQL query parameter, enabling the parameter to accord with the resource standard of the FHIR protocol, wherein the format of the GraphQL standard is the GraphQL standard, and meanwhile, completing the verification constraint of the parameter;
the converting the GraphQL query statement into the resource identifier in FHIR RESTful format includes:
constructing a regular expression component, and converting the GraphQL query statement into a resource identifier in a FHIR RESTful format;
further comprising:
when the resource identifier in the FHIR RESTful format is used for calling the RESTful api on the FHIR application server, verifying whether the query parameter meets the check constraint;
when the query parameter meets the check constraint, executing a calling operation;
whether the verification query parameter satisfies a verification constraint includes:
the GraphQL verifies whether the query parameter is a standard resource identifier.
CN202110232292.1A 2021-03-03 2021-03-03 GraphQL query method and device based on FHIR standard Active CN112597187B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110232292.1A CN112597187B (en) 2021-03-03 2021-03-03 GraphQL query method and device based on FHIR standard

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110232292.1A CN112597187B (en) 2021-03-03 2021-03-03 GraphQL query method and device based on FHIR standard

Publications (2)

Publication Number Publication Date
CN112597187A CN112597187A (en) 2021-04-02
CN112597187B true CN112597187B (en) 2021-06-29

Family

ID=75210106

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110232292.1A Active CN112597187B (en) 2021-03-03 2021-03-03 GraphQL query method and device based on FHIR standard

Country Status (1)

Country Link
CN (1) CN112597187B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113094574A (en) * 2021-04-09 2021-07-09 北京奇艺世纪科技有限公司 Information query method and device, electronic equipment and readable storage medium
CN114816403A (en) * 2022-04-19 2022-07-29 北京字节跳动网络技术有限公司 Request processing method, device, equipment and storage medium
CN114860834B (en) * 2022-06-01 2024-03-26 北京字节跳动网络技术有限公司 Processing method, device, equipment and storage medium of association query request
CN114896272A (en) * 2022-06-15 2022-08-12 北京奇艺世纪科技有限公司 Information acquisition method and device, electronic equipment and computer readable storage medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111026931A (en) * 2019-12-09 2020-04-17 中国建设银行股份有限公司 Data query method, device, equipment and medium
CN111782923A (en) * 2020-06-24 2020-10-16 平安科技(深圳)有限公司 Data query method and device, electronic equipment and storage medium
CN111984675A (en) * 2020-09-02 2020-11-24 深圳壹账通智能科技有限公司 Data query method and device and service equipment

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107948135B (en) * 2017-10-31 2020-02-21 贵州白山云科技股份有限公司 Data processing method and device supporting multiple API protocols
US10776189B2 (en) * 2017-12-22 2020-09-15 MuleSoft, Inc. API query
US10558671B2 (en) * 2018-05-01 2020-02-11 Servicenow, Inc. Modified representational state transfer (REST) application programming interface (API) including a customized GraphQL framework

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111026931A (en) * 2019-12-09 2020-04-17 中国建设银行股份有限公司 Data query method, device, equipment and medium
CN111782923A (en) * 2020-06-24 2020-10-16 平安科技(深圳)有限公司 Data query method and device, electronic equipment and storage medium
CN111984675A (en) * 2020-09-02 2020-11-24 深圳壹账通智能科技有限公司 Data query method and device and service equipment

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
A GraphQL approach to Healthcare Information Exchange with HL7 FHIR;Suresh Kumar Mukhiya;《Procedia Computer Science》;20191107;第160卷;338-345 *

Also Published As

Publication number Publication date
CN112597187A (en) 2021-04-02

Similar Documents

Publication Publication Date Title
CN112597187B (en) GraphQL query method and device based on FHIR standard
CN108696381B (en) Protocol configuration method and device
US20170103163A1 (en) System and Method for a Cloud Enabled Health Record Exchange Engine
US20050149536A1 (en) Data migration and format transformation system
US9734476B2 (en) Dynamically allocating data processing components
US20150081798A1 (en) Process-based inter-thing collaboration apparatus and method in web of things environment
CN108595316A (en) Life cycle management method, manager, equipment and the medium of Distributed Application
US11031138B2 (en) System and method for generating data resources in a processing system
US20130096951A1 (en) Business transaction capture and replay with long term request persistence
US20130018694A1 (en) Dynamically Allocating Business Workflows
CN104881438A (en) Network hospital platform, specialist platform, method for requesting emergency specialist consultation based on specialist platform
EP3994698A1 (en) Image processing and routing using ai orchestration
CN112328551A (en) Medical data analysis method, device, medium, and electronic device
EP3217286A1 (en) Architecture customization at user application layer
CN105160749A (en) Queuing and calling system for medical and technical department
KR20150032151A (en) Apparatus and method for process based collaboration in web of things
Moreira et al. SAREF4health: Towards IoT standard-based ontology-driven cardiac e-health systems
CN114116842B (en) Multidimensional medical data real-time acquisition method and device, electronic equipment and storage medium
EP3740954A1 (en) Detecting recurrence of a medical condition
CN111243695A (en) Non-invasive medical data acquisition method and system
CN112506917A (en) Dictionary mapping method, device, system, equipment and medium for main data
CN111400219A (en) Interface adapter and electronic equipment thereof
CN113127226B (en) Method for generating data conversion model, data conversion method and device
Chaudhry et al. Dynamic health level 7 packetizer for on-the-fly integrated healthcare enterprises (IHE) in disaster zones
Khan et al. Saas based interoperability service for semantic mappings among health-care standards

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant