CN112732807A - Interface calling method and device - Google Patents

Interface calling method and device Download PDF

Info

Publication number
CN112732807A
CN112732807A CN202011600392.7A CN202011600392A CN112732807A CN 112732807 A CN112732807 A CN 112732807A CN 202011600392 A CN202011600392 A CN 202011600392A CN 112732807 A CN112732807 A CN 112732807A
Authority
CN
China
Prior art keywords
data
interface
control table
interface control
modifying
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.)
Pending
Application number
CN202011600392.7A
Other languages
Chinese (zh)
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.)
Fujian Zhuohong Information Technology Co ltd
Original Assignee
Fujian Zhuohong Information 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 Fujian Zhuohong Information Technology Co ltd filed Critical Fujian Zhuohong Information Technology Co ltd
Priority to CN202011600392.7A priority Critical patent/CN112732807A/en
Publication of CN112732807A publication Critical patent/CN112732807A/en
Pending legal-status Critical Current

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/25Integrating or interfacing systems involving database management systems
    • G06F16/252Integrating or interfacing systems involving database management systems between a Database Management System and a front-end application
    • 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

Landscapes

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

Abstract

The invention provides a method and a device for calling an interface, which receive a query request and acquire corresponding identification information; and judging whether the first data corresponding to the identification information exists in the interface control table within preset time, if so, modifying the first data in the interface control table to be returned, otherwise, calling the interface to inquire the data and receiving the returned result, if the returned result is successful, analyzing the data and warehousing the data, and modifying the state of the interface control table, so that not only can the acquisition of repeated data in the same period be prevented, but also the frequency of calling the interface is reduced.

Description

Interface calling method and device
Technical Field
The present invention relates to the field of integrated interface data transmission, and in particular, to a method and an apparatus for interface invocation.
Background
With the development of the business and the demand of risk control of the bank, the business data of the bank is too single, and a large amount of external data is required for reinforcement, such as credit investigation data, operator data and the like. The external data is purchased with a corresponding fee, and is generally charged according to the number of calls. At present, many schedules are called according to needs, but there are some disadvantages:
1) the general scheduling does not consider the change of data, and the data is called when needed, but the change maintenance of the data has a certain period, and the calling in the period needs to be recharged but the data is not changed.
2) The risk control of various bank products all needs the same data support, and the general scheduling does not consider whether effective data exists or not and then directly carries out interface calling, so that a great deal of waste is caused.
Disclosure of Invention
Technical problem to be solved
In order to solve the above problems in the prior art, the present invention provides a method and an apparatus for interface invocation, which can prevent the acquisition of duplicate data in the same period and reduce the number of interface invocation.
(II) technical scheme
In order to achieve the purpose, the invention adopts a technical scheme that:
a method of interface invocation comprising the steps of:
s1, receiving the query request and acquiring corresponding identification information;
s2, judging whether the first data corresponding to the identification information exists in the interface control table within the preset time, if so, modifying the first data in the interface control table and returning, otherwise, executing the step S3;
and S3, calling the interface to inquire data, receiving the returned result, analyzing the data and warehousing if the returned result is successful, and modifying the state of the interface control table.
In order to achieve the purpose, the invention adopts another technical scheme as follows:
an apparatus for interface invocation, comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, the processor implementing the following steps when executing the program:
s1, receiving the query request and acquiring corresponding identification information;
s2, judging whether the first data corresponding to the identification information exists in the interface control table within the preset time, if so, modifying the first data in the interface control table and returning, otherwise, executing the step S3;
and S3, calling the interface to inquire data, receiving the returned result, analyzing the data and warehousing if the returned result is successful, and modifying the state of the interface control table.
(III) advantageous effects
The invention has the beneficial effects that: receiving a query request and acquiring corresponding identification information; and judging whether the first data corresponding to the identification information exists in the interface control table within preset time, if so, modifying the first data in the interface control table to be returned, otherwise, calling the interface to inquire the data and receiving the returned result, if the returned result is successful, analyzing the data and warehousing the data, and modifying the state of the interface control table, so that not only can the acquisition of repeated data in the same period be prevented, but also the frequency of calling the interface is reduced.
Drawings
FIG. 1 is a flow chart of a method of interface invocation in an embodiment of the present invention;
fig. 2 is a schematic overall structure diagram of an interface calling device according to an embodiment of the present invention.
[ description of reference ]
1: means for interface invocation;
2: a memory;
3: a processor.
Detailed Description
For the purpose of better explaining the present invention and to facilitate understanding, the present invention will be described in detail by way of specific embodiments with reference to the accompanying drawings.
A method of interface invocation comprising the steps of:
s1, receiving the query request and acquiring corresponding identification information;
s2, judging whether the first data corresponding to the identification information exists in the interface control table within the preset time, if so, modifying the first data in the interface control table and returning, otherwise, executing the step S3;
and S3, calling the interface to inquire data, receiving the returned result, analyzing the data and warehousing if the returned result is successful, and modifying the state of the interface control table.
Step S3 specifically includes:
s31, judging whether the accumulated query times corresponding to the identification information in the interface control table exceed a preset value, if not, executing a step S32;
s32, calling an interface to inquire data, receiving a returned result, analyzing the data and warehousing if the returned result is successful, and modifying the state of an interface control table;
and if the returned result fails, increasing the accumulated query times corresponding to the identification information by one.
The state of the modified interface control table is specifically as follows:
and modifying the state of the interface control table to be successful, the effective time to be current and the ineffective time to be the current time plus the effective days.
Example two
The difference between this embodiment and the first embodiment is that this embodiment will further explain how the above-mentioned interface calling method of the present invention is implemented by combining a specific application scenario:
1. receiving a query request, and acquiring corresponding identification information, for example, recording the query condition of certain data by taking a client certificate number as the identification information;
2. judging whether first data corresponding to the identification information exists in an interface control table within 30 days (preset time), if so, modifying the first data in the interface control table and returning, otherwise, executing the step 3.1;
specifically, the preset time may be configured according to validity periods of different data types, and this embodiment takes 30 days as an example;
3.1, judging whether the accumulated query times corresponding to the identification information in the interface control table exceed 5 times (preset value), if not, executing the step 3.2;
3.2, calling an interface to inquire data, receiving a returned result, analyzing the data and warehousing if the returned result is successful, and modifying the state of an interface control table;
and if the returned result fails, increasing the accumulated query times corresponding to the identification information by one.
Specifically, the number of application errors of the client is controlled (the configuration can be performed), the problem that the interface is blocked due to some special reasons is avoided, and the problem that the data cannot be retrieved due to call failure of a network and the like is also avoided.
Specifically, data is only inquired once in a period according to the period of different data, and repeated data acquisition is not performed while service use is met.
The data scheduling is independent of a product system, and data can be provided across products, so that waste is avoided.
EXAMPLE III
Referring to fig. 2, an apparatus 1 for interface call includes a memory 2, a processor 3, and a computer program stored on the memory 2 and executable on the processor 3, wherein the processor 3 implements the steps of the first embodiment when executing the computer program.
The above description is only an embodiment of the present invention, and not intended to limit the scope of the present invention, and all equivalent changes made by using the contents of the present specification and the drawings, or applied directly or indirectly to the related technical fields, are included in the scope of the present invention.

Claims (6)

1. A method for interface invocation, characterized by comprising the steps of:
s1, receiving the query request and acquiring corresponding identification information;
s2, judging whether the first data corresponding to the identification information exists in the interface control table within the preset time, if so, modifying the first data in the interface control table and returning, otherwise, executing the step S3;
and S3, calling the interface to inquire data, receiving the returned result, analyzing the data and warehousing if the returned result is successful, and modifying the state of the interface control table.
2. The method for interface invocation according to claim 1, wherein the step S3 specifically includes:
s31, judging whether the accumulated query times corresponding to the identification information in the interface control table exceed a preset value, if not, executing a step S32;
s32, calling an interface to inquire data, receiving a returned result, analyzing the data and warehousing if the returned result is successful, and modifying the state of an interface control table;
and if the returned result fails, increasing the accumulated query times corresponding to the identification information by one.
3. The method of claim 2, wherein the modifying the state of the interface control table specifically comprises:
and modifying the state of the interface control table to be successful, the effective time to be current and the ineffective time to be the current time plus the effective days.
4. An apparatus for interface invocation, comprising a memory, a processor, and a computer program stored on the memory and operable on the processor, wherein the processor implements the following steps when executing the program:
s1, receiving the query request and acquiring corresponding identification information;
s2, judging whether the first data corresponding to the identification information exists in the interface control table within the preset time, if so, modifying the first data in the interface control table and returning, otherwise, executing the step S3;
and S3, calling the interface to inquire data, receiving the returned result, analyzing the data and warehousing if the returned result is successful, and modifying the state of the interface control table.
5. The interface invoking device according to claim 4, wherein the step S3 specifically comprises:
s31, judging whether the accumulated query times corresponding to the identification information in the interface control table exceed a preset value, if not, executing a step S32;
s32, calling an interface to inquire data, receiving a returned result, analyzing the data and warehousing if the returned result is successful, and modifying the state of an interface control table;
and if the returned result fails, increasing the accumulated query times corresponding to the identification information by one.
6. The apparatus of claim 5, wherein the means for modifying the status of the interface control table specifically comprises:
and modifying the state of the interface control table to be successful, the effective time to be current and the ineffective time to be the current time plus the effective days.
CN202011600392.7A 2020-12-30 2020-12-30 Interface calling method and device Pending CN112732807A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011600392.7A CN112732807A (en) 2020-12-30 2020-12-30 Interface calling method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011600392.7A CN112732807A (en) 2020-12-30 2020-12-30 Interface calling method and device

Publications (1)

Publication Number Publication Date
CN112732807A true CN112732807A (en) 2021-04-30

Family

ID=75610010

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011600392.7A Pending CN112732807A (en) 2020-12-30 2020-12-30 Interface calling method and device

Country Status (1)

Country Link
CN (1) CN112732807A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114090135A (en) * 2021-11-24 2022-02-25 北京金堤科技有限公司 Method and device with error correction function and supporting cross-platform calling component
CN114090135B (en) * 2021-11-24 2024-05-24 北京金堤科技有限公司 Method and device with error correction function and supporting cross-platform calling component

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105868274A (en) * 2016-03-22 2016-08-17 努比亚技术有限公司 Resource data querying and processing method and device thereof
CN107844366A (en) * 2017-09-30 2018-03-27 广州供电局有限公司 Power grid application service calling method, device, storage medium and computer equipment
CN108153777A (en) * 2016-12-05 2018-06-12 北京国双科技有限公司 The acquisition methods and device of data access information
CN109976924A (en) * 2019-03-22 2019-07-05 北京奇艺世纪科技有限公司 Interface call method and device
CN110083457A (en) * 2018-01-26 2019-08-02 北京京东尚科信息技术有限公司 A kind of data capture method, device and data analysing method, device
CN110224974A (en) * 2019-04-26 2019-09-10 平安科技(深圳)有限公司 Interface method for authenticating and relevant device based on third party's access
CN110650186A (en) * 2019-09-06 2020-01-03 上海陆家嘴国际金融资产交易市场股份有限公司 Interface calling method and device, computer equipment and storage medium
CN111104191A (en) * 2019-12-17 2020-05-05 深圳前海环融联易信息科技服务有限公司 Interface docking method and device, computer equipment and storage medium
CN111626806A (en) * 2019-02-28 2020-09-04 阿里巴巴集团控股有限公司 Data processing method and device and electronic equipment
CN112015769A (en) * 2020-09-01 2020-12-01 平安付科技服务有限公司 Data processing method and device, computer equipment and storage medium

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105868274A (en) * 2016-03-22 2016-08-17 努比亚技术有限公司 Resource data querying and processing method and device thereof
CN108153777A (en) * 2016-12-05 2018-06-12 北京国双科技有限公司 The acquisition methods and device of data access information
CN107844366A (en) * 2017-09-30 2018-03-27 广州供电局有限公司 Power grid application service calling method, device, storage medium and computer equipment
CN110083457A (en) * 2018-01-26 2019-08-02 北京京东尚科信息技术有限公司 A kind of data capture method, device and data analysing method, device
CN111626806A (en) * 2019-02-28 2020-09-04 阿里巴巴集团控股有限公司 Data processing method and device and electronic equipment
CN109976924A (en) * 2019-03-22 2019-07-05 北京奇艺世纪科技有限公司 Interface call method and device
CN110224974A (en) * 2019-04-26 2019-09-10 平安科技(深圳)有限公司 Interface method for authenticating and relevant device based on third party's access
CN110650186A (en) * 2019-09-06 2020-01-03 上海陆家嘴国际金融资产交易市场股份有限公司 Interface calling method and device, computer equipment and storage medium
CN111104191A (en) * 2019-12-17 2020-05-05 深圳前海环融联易信息科技服务有限公司 Interface docking method and device, computer equipment and storage medium
CN112015769A (en) * 2020-09-01 2020-12-01 平安付科技服务有限公司 Data processing method and device, computer equipment and storage medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114090135A (en) * 2021-11-24 2022-02-25 北京金堤科技有限公司 Method and device with error correction function and supporting cross-platform calling component
CN114090135B (en) * 2021-11-24 2024-05-24 北京金堤科技有限公司 Method and device with error correction function and supporting cross-platform calling component

Similar Documents

Publication Publication Date Title
US6493680B2 (en) Method and apparatus for processing billing transactions
WO1997024688A9 (en) Method and aparatus for processing billing transactions
WO2013059797A1 (en) Service based information technology platform
EP2026552A1 (en) Multiple channel automated refill system
CN108255708B (en) Method, device, storage medium and equipment for accessing production file in test environment
CN104077362A (en) Online mass data processing system and method
CN106357791A (en) Method, device and system for processing services
CN109582329A (en) Data management and method for subscribing, device, system, electronic equipment and storage medium
CN103778066A (en) Data processing method and device
CN111209060A (en) Capability development platform processing method and device
CN111125106A (en) Batch running task execution method, device, server and storage medium
CN108563776A (en) Off-line data acquisition methods and system, server and storage medium
CN111651494B (en) Data processing method, device, equipment and computer readable storage medium
CN112040431B (en) Marketing short message management and control system and method thereof
CN112732807A (en) Interface calling method and device
CN110971664B (en) Interface service management system
CN114153583A (en) Task state management method, task management system and task calling system
CN114237634A (en) Application release risk identification method, device, equipment, medium and program product
CN111429125B (en) Account management method and device, storage medium and electronic equipment
US8904369B2 (en) Method and system for automated process distribution
US6782534B1 (en) Method and system for controlling program in information processing system
CN113347028B (en) Internet of things platform management system developed based on MQTT and RocktMQ
US20050209935A1 (en) Providing Real World Contexts To Computer Applications
CN109582330A (en) Data model upgrade method, device, equipment and readable storage medium storing program for executing
CN115291981A (en) Medical insurance card calling method, device and medium for self-service terminal

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