CN109788031B - Service data acquisition method and device, computer equipment and storage medium - Google Patents

Service data acquisition method and device, computer equipment and storage medium Download PDF

Info

Publication number
CN109788031B
CN109788031B CN201811543631.2A CN201811543631A CN109788031B CN 109788031 B CN109788031 B CN 109788031B CN 201811543631 A CN201811543631 A CN 201811543631A CN 109788031 B CN109788031 B CN 109788031B
Authority
CN
China
Prior art keywords
request
data
data acquisition
service
scene
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
CN201811543631.2A
Other languages
Chinese (zh)
Other versions
CN109788031A (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.)
Ping An Puhui Enterprise Management Co Ltd
Original Assignee
Ping An Puhui Enterprise Management 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 Ping An Puhui Enterprise Management Co Ltd filed Critical Ping An Puhui Enterprise Management Co Ltd
Priority to CN201811543631.2A priority Critical patent/CN109788031B/en
Publication of CN109788031A publication Critical patent/CN109788031A/en
Application granted granted Critical
Publication of CN109788031B publication Critical patent/CN109788031B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Computer And Data Communications (AREA)

Abstract

The application relates to a service data acquisition method, a device, computer equipment and a storage medium based on the technical field of communication, which are used for receiving a data acquisition request sent by a terminal, wherein the data acquisition request carries a request parameter and a service identifier; searching a configuration table corresponding to the service identifier according to the request parameter; calling a service interface according to the data acquisition request; searching whether the request parameters correspond to a plurality of dimensions in the configuration table by utilizing the service interface; when the request parameters correspond to a plurality of dimensions, collecting scene information corresponding to the request parameters; looking up scene dimensions in the scene information corresponding to the request parameters in the configuration table; and acquiring the service data of the request parameters under the scene dimension by using the configuration table, and feeding back the service data to the terminal. By adopting the method, the number of the service interfaces can be reduced, so that the maintenance cost of the service system is reduced.

Description

Service data acquisition method and device, computer equipment and storage medium
Technical Field
The present application relates to the field of communications technologies, and in particular, to a method and an apparatus for acquiring service data, a computer device, and a storage medium.
Background
With the development of communication technology, internet applications are increasing to meet the growing and diversified business demands. When an internet application server provides services for a large number of users, in order to meet different requirements of different groups of people, multiple service modes are often required to be provided, and business data related to the different service modes are different. In a traditional mode, in order to meet different requirements of different users, a service interface capable of providing multiple service modes is developed through an internet application server, each service interface only serves one service mode, so that a service system is very large, and more manpower and material resources are required for system maintenance. Therefore, how to reduce the number of service interfaces, thereby reducing the maintenance cost of the service system, is a technical problem to be solved at present.
Disclosure of Invention
In view of the foregoing, it is necessary to provide a business data acquisition method, an apparatus, a computer device, and a storage medium, which can reduce the number of service interfaces, thereby reducing the maintenance cost of a service system.
A method for acquiring service data, the method comprising:
receiving a data acquisition request sent by a terminal, wherein the data acquisition request carries a request parameter and a service identifier;
searching a configuration table corresponding to the service identifier according to the request parameter;
calling a service interface according to the data acquisition request;
searching whether the request parameters correspond to a plurality of dimensions in the configuration table by utilizing the service interface;
when the request parameters correspond to a plurality of dimensions, collecting scene information corresponding to the request parameters;
searching the scene dimension in the scene information corresponding to the request parameter in the configuration table;
and acquiring the service data of the request parameters under the scene dimension by using the configuration table, and feeding back the service data to the plurality of terminals.
In one embodiment, the obtaining, by using the configuration table, service data of the request parameter in the scene dimension includes:
searching data source information corresponding to the request parameters under the scene dimension in the configuration table;
and acquiring the service data of the request parameter according to the data source information.
In one embodiment, the obtaining the service data of the request parameter according to the data source information includes:
determining a data acquisition type corresponding to the request parameter according to data source information;
determining the data acquisition mode mapped by the data acquisition type according to the preset mapping relation between the data acquisition type and the data acquisition mode;
and acquiring the service data of the request parameter according to the data acquisition mode.
In one embodiment, the method further comprises:
dividing data sources in all data source information corresponding to the request parameters into multiple data types;
and defining according to the data acquisition type to obtain a plurality of data acquisition modes.
In one embodiment, the method further comprises:
marking the request parameters corresponding to the multiple dimensions as multi-dimensional parameters;
and when the received data acquisition request sent by the terminal carries the multi-dimensional parameters, acquiring scene information corresponding to the multi-dimensional parameters.
A traffic information testing apparatus, the apparatus comprising:
the communication module is used for receiving a data acquisition request sent by a terminal, wherein the data acquisition request carries a request parameter and a service identifier;
the configuration table searching module is used for searching a configuration table corresponding to the service identifier according to the request parameter;
the interface calling module is used for calling a service interface according to the data acquisition request;
the dimension searching module is used for searching whether the request parameters correspond to a plurality of dimensions in the configuration table by using the service interface;
the information collection module is used for collecting scene information corresponding to the request parameters when the request corresponds to a plurality of dimensions;
the dimension searching module is further configured to search, in the configuration table, a scene dimension in the scene information corresponding to the request parameter;
the data acquisition module is used for acquiring the service data of the request parameters under the scene dimension by using the configuration table;
the communication module is further configured to feed back the service data to the terminal.
In one embodiment, the data obtaining module is further configured to search the configuration table for data source information corresponding to the request parameter in the scene dimension; and acquiring the service data of the request parameter according to the data source information.
In one embodiment, the data obtaining module is further configured to determine a data obtaining type corresponding to the request parameter according to data source information; determining the data acquisition mode mapped by the data acquisition type according to the preset mapping relation between the data acquisition type and the data acquisition mode; and acquiring the service data of the request parameter according to the data acquisition mode.
A computer device comprising a memory and a processor, the memory storing a computer program operable on the processor, the processor implementing the steps in the various method embodiments described above when executing the computer program.
A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the steps of the respective method embodiment described above.
According to the service data acquisition method, the service data acquisition device, the computer equipment and the storage medium, when the service interface is used for searching the multiple dimensions corresponding to the request parameters in the configuration table, the scene information corresponding to the request parameters is collected. And searching the scene dimension in the scene information corresponding to the request parameter in the configuration table to acquire the service data of the request parameter under the scene dimension. One service interface is realized to provide data acquisition service under different scenes, and the number of the service interfaces is reduced, so that the maintenance cost of the service system is reduced.
Drawings
Fig. 1 is a diagram of an application environment of a service data acquisition method in an embodiment;
fig. 2 is a schematic flow chart of a service data acquisition method in an embodiment;
fig. 3 is a schematic flow chart illustrating a process of acquiring service data of a request parameter corresponding to a scene dimension through a configuration table in an embodiment;
fig. 4 is a block diagram showing a structure of a service data acquisition apparatus according to an embodiment;
FIG. 5 is a diagram illustrating an internal structure of a computer device according to an embodiment.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of and not restrictive on the broad application.
The service data acquisition method provided by the application can be applied to the application environment shown in fig. 1. Wherein the terminal 102 communicates with the server 104 via a network. The server 104 receives a data acquisition request sent by the terminal 102, where the data acquisition request carries a request parameter and a service identifier. The server 104 searches the configuration table corresponding to the service identifier according to the request parameter. The server 104 invokes the service interface according to the data acquisition request. The server 104 uses the service interface to look up in the configuration table whether the request parameters correspond to multiple dimensions. When the request parameter corresponds to multiple dimensions, the server 104 collects scene information corresponding to the request parameter. The server 104 searches the scene dimension in the scene information corresponding to the request parameter in the configuration table. The server 104 acquires the service data of the request parameters corresponding to the scene dimensions through the configuration table, and feeds the service data back to the terminal 102. There may be a plurality of terminals 102, the terminals 102 may be, but are not limited to, various personal computers, notebook computers, smart phones, tablet computers, and portable wearable devices, and the server 104 may be implemented by an independent server or a server cluster formed by a plurality of servers.
In an embodiment, as shown in fig. 2, a service data obtaining method is provided, which is described by taking the application of the method to the server in fig. 1 as an example, and includes the following steps:
step 202, receiving a data acquisition request sent by a terminal, where the data acquisition request carries a request parameter and a service identifier.
The server receives a data acquisition request sent by the terminal, wherein the data acquisition request is automatically generated by the terminal according to business operation. The data acquisition request can be a service transaction request, a data viewing request, a video playing request and the like.
For example, the terminal automatically generates a ticket buying request according to a ticket buying operation, and the server receives the ticket buying request sent by the terminal, wherein the ticket buying request carries the remaining ticket quantity parameter and the service handling identification.
For another example, the terminal automatically generates a policy inquiry request according to the policy inquiry operation, and the server receives the policy inquiry request sent by the terminal, wherein the policy inquiry request carries a policy number parameter and a data viewing identifier.
The data acquisition request can also carry a service identifier for distinguishing a plurality of service products. The server can acquire the service data in the data acquisition requests of a plurality of service products, and the service data in the data acquisition requests of each service product are different. For example, the server may acquire service data in data acquisition requests of a plurality of payment products such as agreement payment, platform payment, telephone fee payment, account payment, credit payment and surcharge, and the service data in the data acquisition requests of the plurality of payment products such as agreement payment, platform payment, telephone fee payment, account payment, credit payment and surcharge are different.
And step 204, searching a configuration table corresponding to the service identifier according to the request parameter.
After receiving a data acquisition request sent by a terminal, the server can search a configuration table corresponding to a service identifier according to the request parameter after the data acquisition request carries the request parameter and the service identifier. The service identifier is used for distinguishing a plurality of service products, and the server can correspondingly generate a configuration table according to each service product. And the server searches a configuration table corresponding to the service identifier in the plurality of configuration tables according to the request parameter.
The server receives a data acquisition request sent by the terminal, analyzes the data acquisition request to obtain request parameters and service identification, and searches a configuration table corresponding to the service identification carried in the data acquisition request according to the request parameters carried in the data acquisition request.
Step 206, calling a service interface according to the data acquisition request.
After searching the configuration table corresponding to the service identifier according to the request parameter, the server can call the service interface according to the data acquisition request. The server receives different data acquisition requests uploaded by the terminal, and correspondingly, the called service interfaces are different. A service interface can acquire service data of a data acquisition request of one service product in different scenes, and also can acquire service data of data acquisition requests of a plurality of service products in different scenes. For example, the service interface may obtain service data of the payment request of the agreement payment product in the signing stage and the contracting stage, or obtain service data of the agreement payment product in the signing stage and the contracting stage, and service data of the platform payment product in the signing stage and the contracting stage.
Step 208, using the service interface to look up in the configuration table whether the request parameter corresponds to multiple dimensions.
Step 210, when the request parameter corresponds to multiple dimensions, collecting scene information corresponding to the request parameter.
After the server calls the service interface according to the data acquisition request, whether the request parameters correspond to multiple dimensions or not can be searched in the configuration table by using the service interface. The configuration table comprises a request parameter field name, dimension information corresponding to the request parameter field, and data source information of the request parameter corresponding to each dimension. The request parameter field names include name, quantity, date, etc. The field names of the request parameters corresponding to different data acquisition requests may be the same or different. The dimension information includes a dimension corresponding to the request parameter. The data source information comprises data sources corresponding to each request parameter under different dimensions.
Specifically, the server locates the position of the request parameter in the configuration table, and searches whether the request parameter corresponds to multiple dimensions according to the located position. And when the request parameters correspond to a plurality of dimensions, the server collects scene information corresponding to the request parameters. The scene information comprises a channel scene of the triggering request, a phase scene of the request and the like.
Step 212, the scene dimension in the scene information corresponding to the request parameter is looked up in the configuration table.
After the server collects the scene information corresponding to the request parameter, the server can search the scene dimension in the scene information corresponding to the request parameter in the configuration table. The scene information includes a channel scene triggering the request, a phase scene where the request is located, and the like. The channel scenario that triggers the request includes an online dimension and an offline dimension. The number of dimensions of the phase scenario in which the request is placed is not limited. The phase scene may include three phase dimensions, namely a first phase dimension, a second phase dimension and a third phase dimension, wherein the first phase dimension may be a reservation phase, the second phase dimension may be an application phase, and the third phase dimension may be a solution phase. The scene dimensions are one or more of the dimensions to which the request parameters correspond.
Specifically, when the scene information collected by the server includes two scenes, namely a channel scene triggering the request and a stage scene where the request is located, a scene dimension under the channel scene corresponding to the request parameter is searched in the configuration table according to the channel scene triggering the request, where the scene dimension may be an online dimension or an offline dimension. The server searches the scene dimension under the phase scene corresponding to the request parameter in the configuration table according to the phase scene where the request is located, and the dimension number of the phase scene is not limited, wherein the scene dimension can be a first phase dimension, a second phase dimension or a third phase dimension. At this time, the request parameter corresponds to a plurality of scene dimensions.
When the scene information collected by the server only comprises the channel scene of the trigger request, the server searches the scene dimension under the channel scene corresponding to the request parameter in the configuration table according to the channel scene of the trigger request, wherein the scene dimension can be an online dimension or an offline dimension. At this time, the request parameter corresponds to only one scene dimension.
When the scene information collected by the server only includes the phase scene where the request is located, the server searches the scene dimension under the phase scene corresponding to the request parameter in the configuration table according to the phase scene where the request is located, the number of the dimensions of the phase scene is not limited, and the scene dimension may be a first phase dimension, a second phase dimension, or a third phase dimension. At this time, the request parameter corresponds to only one scene dimension.
Step 214, obtaining the service data of the request parameter in the scene dimension through the configuration table, and feeding back the service data to the terminal.
After the server searches the scene dimension in the scene information corresponding to the request parameter in the configuration table, the server can acquire the service data of the request parameter in the scene dimension through the configuration table and feed the service data back to the terminal. Among other things, the request parameters may correspond to multiple scene dimensions of the dimensions, e.g., the scene dimensions include a first dimension and a second dimension. The first dimension may be an inline dimension and the second dimension may be a first stage dimension. Specifically, the server searches the configuration table for data source information of the request parameters in the scene dimension. And acquiring the service data of the request parameters according to the data source information. And the server feeds back the service data to the terminal.
For example, the terminal automatically generates a ticket buying request according to a ticket buying operation, and the server receives the ticket buying request sent by the terminal, wherein the ticket buying request carries the remaining ticket quantity parameter and the service handling identifier. And the server searches a business handling configuration table corresponding to the business handling identification according to the ticket buying request. And the server calls a service interface according to the ticket buying request, and searches whether the remaining ticket quantity parameter corresponds to a plurality of dimensions in the business handling configuration table by using the service interface. When the remaining ticket quantity parameter corresponds to the online dimension, the offline dimension, the first stage dimension, the second stage dimension and the third stage dimension, collecting the channel scene and the stage scene corresponding to the remaining ticket quantity parameter, and finding the offline dimension in the channel scene and the first stage dimension in the stage scene corresponding to the remaining ticket quantity parameter in the configuration table. And the server acquires the remaining ticket data of the dimensional remaining ticket quantity parameter of the first stage under the line by using the configuration table, and feeds the remaining ticket data back to the terminal.
It can be understood that, when the request parameter corresponds to one dimension, the server obtains the service data of the request parameter corresponding to the dimension through the configuration table, and feeds the service data back to the terminal. Specifically, the server searches the data source information of the request parameter in the dimension in the configuration table, acquires the service data of the request parameter according to the data source information, and feeds back the service data to the terminal.
Further, the server can generate a page file from the service data and the page template file through the terminal, and display the service data in the page according to the page file. The server can also generate a voice broadcast file from the service data through the terminal and broadcast the voice broadcast file.
In this embodiment, when the server finds multiple dimensions corresponding to the request parameter in the configuration table by using the service interface, the server collects scene information corresponding to the request parameter. The server searches the scene dimension in the scene information corresponding to the request parameter in the configuration table to acquire the service data of the request parameter under the scene dimension. The server can flexibly acquire the service data matched with the data acquisition request scene, one service interface provides data acquisition services under different scenes, the number of the service interfaces is reduced, and therefore the maintenance cost of a service system is reduced.
In one embodiment, the method further comprises: and acquiring the service data of the request parameters corresponding to the scene dimensions through the configuration table. As shown in fig. 3, the steps specifically include:
step 302, data source information corresponding to the request parameter under the scene dimension is searched in the configuration table.
Specifically, when the request parameter corresponds to a first dimension and a second dimension of the dimensions, the server searches the configuration table for data source information corresponding to the request parameter in the first dimension, and searches the configuration table for data source information corresponding to the request parameter in the second dimension. When the request parameter only corresponds to one scene dimension in the multiple dimensions, the server searches the data source information of the request parameter in the dimension in the configuration table. The configuration table stores data source information of other dimensions.
And step 304, acquiring the service data of the request parameter according to the data source information.
After the server searches the data source information corresponding to the request parameter in the scene dimension in the configuration table, the server can obtain the service data of the request parameter according to the data source information. The server can obtain the service data of the request parameters from the database according to the data source information. For example, the server stores the remaining ticket information for the online dimension in a first location of the database. The remaining ticket monitoring system can store the online remaining ticket information updated in real time into the first position of the database in real time. And the server acquires the remaining ticket data from the database according to the first position, namely the data source information corresponding to the online dimension remaining ticket quantity parameter. The server can also call the interface from the interface calling address according to the data source information to receive the service data fed back by the service interface.
In this embodiment, the server obtains the service data of the request parameter according to the data source information by looking up the data source information corresponding to the request parameter in the scene dimension in the configuration table. When the dimension of the parameter needs to be expanded, only expanded dimension information needs to be added in the configuration table, the data source of the parameter under the dimension is recorded, the existing service data does not need to be changed, and the expansion capability of the service data is improved.
In one embodiment, obtaining the service data of the request parameter according to the data source information includes: determining a data acquisition type corresponding to the request parameter according to the data source information; determining a data acquisition mode mapped by the data acquisition type according to a preset mapping relation between the data acquisition type and the data acquisition mode; and acquiring the service data of the request parameter according to the data acquisition mode.
The data source information comprises a storage position of the data and an acquisition channel of the data. And when the data source information is the storage position of the data, the server determines the data acquisition type corresponding to the request parameter according to the storage position of the data. The type of data acquisition is not limited. The method can be a local data acquisition type or a cloud data acquisition type. The storage locations of the data are different, and correspondingly, the data acquisition modes are also different.
And when the data source information is the acquisition channel of the service data, the server determines the data acquisition type corresponding to the request parameter according to the acquisition channel of the service data. The type of data acquisition is not limited. May be an interface class, e.g. an interface address for traffic data. Or may be a model class, e.g., model information for business data.
In one embodiment, the method further comprises: dividing data sources in the data source information corresponding to all the request parameters into multiple data types; and defining according to the data acquisition type to obtain a plurality of data acquisition modes. The server can divide the data types of the data sources corresponding to all the request parameters, and each data acquisition type defines a data acquisition mode. For example, the server defines the local data type as a first data acquisition mode, the cloud data acquisition type as a second data acquisition mode, the interface class as a third data acquisition mode, and the model class as a fourth data acquisition mode. The data acquisition mode comprises data acquisition implementation logic.
In this embodiment, the server obtains the service data of the request parameter according to a preset data obtaining manner, so that the data source information in the configuration table may be information of different forms, and the data storage manner is more flexible. When new data source information is added, only a data acquisition mode corresponding to the data source information needs to be defined, and the data acquisition mode is associated with a data acquisition type corresponding to the data source information. The data storage and the data acquisition are more flexibly realized.
In one embodiment, the method further comprises: marking the request parameters corresponding to the multiple dimensions as multi-dimensional parameters; and when the data acquisition request sent by the receiving terminal carries the multi-dimensional parameters, acquiring scene information corresponding to the multi-dimensional parameters.
In this embodiment, the server searches whether the request parameter corresponds to multiple dimensions in the configuration table by using the service interface, when the request parameter corresponds to multiple dimensions, the request parameter is marked as a multi-dimensional parameter, and when a data acquisition request carrying the multi-dimensional parameter is received, scene information corresponding to the multi-dimensional parameter can be directly acquired.
In this embodiment, the server marks the request parameters corresponding to the multiple dimensions as the multiple-dimensional parameters, and can accurately search the scene dimension corresponding to each multiple-dimensional parameter from the configuration table in the data acquisition request carrying the multiple multi-dimensional request parameters, thereby realizing acquisition of the service data of the multiple multi-dimensional parameters.
It should be understood that although the various steps in the flow charts of fig. 2-3 are shown in order as indicated by the arrows, the steps are not necessarily performed in order as indicated by the arrows. The steps are not performed in the exact order shown and described, and may be performed in other orders, unless explicitly stated otherwise. Moreover, at least some of the steps in fig. 2-3 may include multiple sub-steps or multiple stages that are not necessarily performed at the same time, but may be performed at different times, and the order of performance of the sub-steps or stages is not necessarily sequential, but may be performed in turn or alternating with other steps or at least some of the sub-steps or stages of other steps.
In one embodiment, as shown in fig. 4, there is provided a service data acquiring apparatus, including: a communication module 402, a configuration table lookup module 404, an interface calling module 406, a dimension lookup module 408, an information collection module 410, and a data acquisition module 412, wherein:
the communication module 402 is configured to receive a data acquisition request sent by a terminal, where the data acquisition request carries a request parameter and a service identifier.
And a configuration table lookup module 404, configured to lookup a configuration table corresponding to the service identifier according to the request parameter.
And an interface calling module 406, configured to call a service interface according to the data obtaining request.
The dimension searching module 408 is configured to search, by using the service interface, whether the request parameter corresponds to multiple dimensions in the configuration table.
The information collecting module 410 is configured to collect scene information corresponding to the request parameter when the request parameter corresponds to multiple dimensions.
The dimension lookup module 408 is further configured to lookup a scene dimension in the scene information corresponding to the request parameter in the configuration table.
And a data obtaining module 412, configured to obtain service data of the request parameter in the scene dimension by using the configuration table.
The communication module 402 is also used for feeding back the service data to the terminal.
In one embodiment, the data obtaining module 412 is further configured to search the configuration table for data source information corresponding to the request parameter in the scene dimension; and acquiring the service data of the request parameters according to the data source information.
In one embodiment, the data obtaining module 412 is further configured to determine a data obtaining type corresponding to the request parameter according to the data source information; determining a data acquisition mode mapped by the data acquisition type according to a preset mapping relation between the data acquisition type and the data acquisition mode; and acquiring the service data of the request parameter according to the data acquisition mode.
In one embodiment, the apparatus further includes a source partitioning module, where the source partitioning module is configured to partition data sources in the data source information corresponding to all the request parameters into multiple data types; and defining according to the data acquisition type to obtain a plurality of data acquisition modes.
In one embodiment, the information collection module is further configured to label the request parameters corresponding to the plurality of dimensions as multi-dimensional parameters; and when the data acquisition request sent by the receiving terminal carries the multi-dimensional parameters, acquiring scene information corresponding to the multi-dimensional parameters.
For specific definition of the service data acquiring apparatus, reference may be made to the definition of the service data acquiring method above, and details are not described herein again. All or part of each module in the service data acquisition device can be realized by software, hardware and a combination thereof. The modules can be embedded in a hardware form or independent from a processor in the computer device, and can also be stored in a memory in the computer device in a software form, so that the processor can call and execute operations corresponding to the modules.
In one embodiment, a computer device is provided, which may be a server, the internal structure of which may be as shown in fig. 5. The computer device includes a processor, a memory, a network interface, and a database connected by a system bus. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device comprises a nonvolatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the operation of an operating system and computer programs in the non-volatile storage medium. The database of the computer device is used for storing business data information. The network interface of the computer device is used for communicating with an external terminal through a network connection. The computer program is executed by a processor to implement a business data acquisition method.
Those skilled in the art will appreciate that the architecture shown in fig. 5 is merely a block diagram of some of the structures associated with the disclosed aspects and is not intended to limit the computing devices to which the disclosed aspects apply, as particular computing devices may include more or less components than those shown, or may combine certain components, or have a different arrangement of components.
In one embodiment, there is provided a computer device comprising a memory storing a computer program and a processor implementing the following steps when the processor executes the computer program: receiving a data acquisition request sent by a terminal, wherein the data acquisition request carries a request parameter and a service identifier; searching a configuration table corresponding to the service identifier according to the request parameter; calling a service interface according to the data acquisition request; searching whether the request parameters correspond to a plurality of dimensions in the configuration table by utilizing a service interface; when the request parameters correspond to a plurality of dimensions, collecting scene information corresponding to the request parameters; searching a scene dimension in the scene information corresponding to the request parameter in the configuration table; and acquiring service data of the request parameters under the scene dimension by using the configuration table, and feeding back the service data to the terminal.
In one embodiment, the processor, when executing the computer program, further performs the steps of: searching data source information corresponding to the request parameters under the scene dimension in a configuration table; and acquiring the service data of the request parameters according to the data source information.
In one embodiment, the processor, when executing the computer program, further performs the steps of: determining a data acquisition type corresponding to the request parameter according to the data source information; determining a data acquisition mode mapped by the data acquisition type according to a preset mapping relation between the data acquisition type and the data acquisition mode; and acquiring the service data of the request parameter according to the data acquisition mode.
In one embodiment, the processor, when executing the computer program, further performs the steps of: dividing data sources in the data source information corresponding to all the request parameters into multiple data types; and defining according to the data acquisition type to obtain a plurality of data acquisition modes.
In one embodiment, the processor, when executing the computer program, further performs the steps of: marking the request parameters corresponding to the multiple dimensions as multi-dimensional parameters; and when the data acquisition request sent by the receiving terminal carries the multi-dimensional parameters, acquiring scene information corresponding to the multi-dimensional parameters.
In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored, which when executed by a processor implements the steps in the method of the above embodiments: receiving a data acquisition request sent by a terminal, wherein the data acquisition request carries a request parameter and a service identifier; searching a configuration table corresponding to the service identifier according to the request parameter; calling a service interface according to the data acquisition request; searching whether the request parameters correspond to a plurality of dimensions in the configuration table by utilizing a service interface; when the request parameters correspond to a plurality of dimensions, collecting scene information corresponding to the request parameters; searching a scene dimension in the scene information corresponding to the request parameter in the configuration table; and acquiring service data of the request parameters under the scene dimension by using the configuration table, and feeding back the service data to the terminal.
In one embodiment, the processor, when executing the computer program, further performs the steps of: searching data source information corresponding to the request parameters under the scene dimension in a configuration table; and acquiring the service data of the request parameters according to the data source information.
In one embodiment, the processor, when executing the computer program, further performs the steps of: determining a data acquisition type corresponding to the request parameter according to the data source information; determining a data acquisition mode mapped by the data acquisition type according to a preset mapping relation between the data acquisition type and the data acquisition mode; and acquiring the service data of the request parameter according to the data acquisition mode.
In one embodiment, the processor when executing the computer program further performs the steps of: dividing data sources in the data source information corresponding to all the request parameters into multiple data types; and defining according to the data acquisition type to obtain a plurality of data acquisition modes.
In one embodiment, the processor, when executing the computer program, further performs the steps of: marking the request parameters corresponding to the multiple dimensions as multi-dimensional parameters; and when the data acquisition request sent by the receiving terminal carries the multi-dimensional parameters, acquiring scene information corresponding to the multi-dimensional parameters.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by hardware instructions of a computer program, which can be stored in a non-volatile computer-readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. Any reference to memory, storage, database, or other medium used in the embodiments provided herein may include non-volatile and/or volatile memory, among others. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically Programmable ROM (EPROM), electrically Erasable Programmable ROM (EEPROM), or flash memory. Volatile memory can include Random Access Memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms such as Static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double Data Rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous Link DRAM (SLDRAM), rambus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
The technical features of the above embodiments can be arbitrarily combined, and for the sake of brevity, all possible combinations of the technical features in the above embodiments are not described, but should be considered as the scope of the present specification as long as there is no contradiction between the combinations of the technical features.
The above-mentioned embodiments only express several embodiments of the present application, and the description thereof is specific and detailed, but not to be understood as limiting the scope of the invention. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the concept of the present application, which falls within the scope of protection of the present application. Therefore, the protection scope of the present patent application shall be subject to the appended claims.

Claims (10)

1. A method for acquiring service data, the method comprising:
receiving a data acquisition request sent by a terminal, wherein the data acquisition request carries request parameters and a service identifier;
searching a configuration table corresponding to the service identifier according to the request parameter;
calling a service interface according to the data acquisition request;
searching whether the request parameters correspond to a plurality of dimensions in the configuration table by utilizing the service interface;
when the request parameters correspond to a plurality of dimensions, collecting scene information corresponding to the request parameters;
looking up scene dimensions in the scene information corresponding to the request parameters in the configuration table;
searching data source information corresponding to the request parameters under the scene dimension in the configuration table;
and acquiring the service data of the request parameter according to the data source information, and feeding back the service data to the terminal.
2. The method according to claim 1, wherein the obtaining the service data of the request parameter according to the data source information comprises:
determining a data acquisition type corresponding to the request parameter according to data source information;
determining the data acquisition mode mapped by the data acquisition type according to the preset mapping relation between the data acquisition type and the data acquisition mode;
and acquiring the service data of the request parameter according to the data acquisition mode.
3. The method of claim 1, further comprising:
dividing data sources in the data source information corresponding to all the request parameters into multiple data types;
and defining according to the data type to obtain a plurality of data acquisition modes.
4. The method of claim 1, further comprising:
marking the request parameters corresponding to the multiple dimensions as multi-dimensional parameters;
and when receiving a data acquisition request sent by the terminal and carrying the multi-dimensional parameters, acquiring scene information corresponding to the multi-dimensional parameters.
5. A service data acquisition apparatus, characterized in that the apparatus comprises:
the communication module is used for receiving a data acquisition request sent by a terminal, wherein the data acquisition request carries a request parameter and a service identifier;
the configuration table searching module is used for searching a configuration table corresponding to the service identifier according to the request parameter;
the interface calling module is used for calling a service interface according to the data acquisition request;
the dimension searching module is used for searching whether the request parameters correspond to a plurality of dimensions in the configuration table by using the service interface;
the information collection module is used for collecting scene information corresponding to the request parameters when the request parameters correspond to a plurality of dimensions;
the dimension searching module is further configured to search, in the configuration table, a scene dimension in the scene information corresponding to the request parameter;
the data acquisition module is used for searching data source information corresponding to the request parameters under the scene dimension in the configuration table; acquiring the service data of the request parameter according to the data source information;
the communication module is further configured to feed back the service data to the terminal.
6. The apparatus according to claim 5, wherein the data obtaining module is further configured to determine a data obtaining type corresponding to the request parameter according to data source information; determining the data acquisition mode mapped by the data acquisition type according to the preset mapping relation between the data acquisition type and the data acquisition mode; and acquiring the service data of the request parameter according to the data acquisition mode.
7. The apparatus of claim 5, further comprising:
the source dividing module is used for dividing data sources in the data source information corresponding to all the request parameters into a plurality of data types; and defining according to the data type to obtain a plurality of data acquisition modes.
8. The apparatus of claim 5, wherein the information collection module is further configured to label request parameters corresponding to a plurality of dimensions as multi-dimensional parameters; and when receiving a data acquisition request sent by the terminal and carrying the multi-dimensional parameters, acquiring scene information corresponding to the multi-dimensional parameters.
9. A computer device comprising a memory and a processor, the memory storing a computer program operable on the processor, wherein the processor implements the steps of the method of any one of claims 1 to 4 when executing the computer program.
10. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the steps of the method of any one of claims 1 to 4.
CN201811543631.2A 2018-12-17 2018-12-17 Service data acquisition method and device, computer equipment and storage medium Active CN109788031B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811543631.2A CN109788031B (en) 2018-12-17 2018-12-17 Service data acquisition method and device, computer equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811543631.2A CN109788031B (en) 2018-12-17 2018-12-17 Service data acquisition method and device, computer equipment and storage medium

Publications (2)

Publication Number Publication Date
CN109788031A CN109788031A (en) 2019-05-21
CN109788031B true CN109788031B (en) 2022-10-11

Family

ID=66497396

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811543631.2A Active CN109788031B (en) 2018-12-17 2018-12-17 Service data acquisition method and device, computer equipment and storage medium

Country Status (1)

Country Link
CN (1) CN109788031B (en)

Families Citing this family (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110457563A (en) * 2019-07-12 2019-11-15 平安普惠企业管理有限公司 Acquiring product parameters method and Related product
CN110825796B (en) * 2019-10-09 2021-01-19 车轮互联科技(上海)股份有限公司 Data acquisition method, device and system
CN111090457A (en) * 2019-12-17 2020-05-01 广州品唯软件有限公司 Interface analysis method, terminal device and computer-readable storage medium
CN111352816A (en) * 2020-02-27 2020-06-30 中国工商银行股份有限公司 Tracking detection method and system based on distributed link
CN113467775A (en) * 2020-03-31 2021-10-01 北京沃东天骏信息技术有限公司 Method and device for generating page
CN111949910A (en) * 2020-07-20 2020-11-17 北京思特奇信息技术股份有限公司 Method and system for dynamically displaying acceptance information according to service
CN112182363B (en) * 2020-09-05 2024-02-02 南方电网数字电网研究院有限公司 Intelligent auditing method, device, equipment and storage medium based on micro-service framework
CN112465461A (en) * 2020-12-04 2021-03-09 金蝶云科技有限公司 Business object information changing method, system, computer device and storage medium
CN113271307B (en) * 2021-05-18 2023-05-16 中国工商银行股份有限公司 Data assembling method, device, computer system and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101197876A (en) * 2006-12-06 2008-06-11 中兴通讯股份有限公司 Method and system for multi-dimensional analysis of message service data
CN107016025A (en) * 2016-11-17 2017-08-04 阿里巴巴集团控股有限公司 A kind of method for building up and device of non-relational database index
WO2018086462A1 (en) * 2016-11-10 2018-05-17 阿里巴巴集团控股有限公司 Method and device for generating loading, push, and interaction information of service data
CN108446341A (en) * 2018-03-02 2018-08-24 平安普惠企业管理有限公司 Service condition querying method, device, computer equipment and storage medium
CN108876133A (en) * 2018-06-07 2018-11-23 中国平安人寿保险股份有限公司 Risk assessment processing method, device, server and medium based on business information

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101197876A (en) * 2006-12-06 2008-06-11 中兴通讯股份有限公司 Method and system for multi-dimensional analysis of message service data
WO2018086462A1 (en) * 2016-11-10 2018-05-17 阿里巴巴集团控股有限公司 Method and device for generating loading, push, and interaction information of service data
CN107016025A (en) * 2016-11-17 2017-08-04 阿里巴巴集团控股有限公司 A kind of method for building up and device of non-relational database index
CN108446341A (en) * 2018-03-02 2018-08-24 平安普惠企业管理有限公司 Service condition querying method, device, computer equipment and storage medium
CN108876133A (en) * 2018-06-07 2018-11-23 中国平安人寿保险股份有限公司 Risk assessment processing method, device, server and medium based on business information

Also Published As

Publication number Publication date
CN109788031A (en) 2019-05-21

Similar Documents

Publication Publication Date Title
CN109788031B (en) Service data acquisition method and device, computer equipment and storage medium
CN110727499B (en) Method, device, computer equipment and storage medium for acquiring resource data
CN109344183B (en) Data interaction method and device, computer equipment and storage medium
WO2020186786A1 (en) File processing method and apparatus, computer device and storage medium
CN109325729B (en) Method and server for generating electronic contract
CN111310427A (en) Service data configuration processing method and device, computer equipment and storage medium
CN109740137B (en) Name card generation method, device, computer equipment and storage medium
CN110659298B (en) Financial data processing method and device, computer equipment and storage medium
CN111324905A (en) Image data labeling method and device, computer equipment and storage medium
CN108052553B (en) Method and device for generating electronic manual, computer equipment and storage medium
CN111027295A (en) Data processing method, data processing device, computer equipment and storage medium
CN108334625B (en) User information processing method and device, computer equipment and storage medium
CN110716989A (en) Dimension data processing method and device, computer equipment and storage medium
CN110908778B (en) Task deployment method, system and storage medium
CN110659938A (en) Method and device for determining promotion channel, computer equipment and storage medium
CN110688598A (en) Service parameter acquisition method and device, computer equipment and storage medium
CN110213392B (en) Data distribution method and device, computer equipment and storage medium
CN112286997B (en) Salary data query method based on distributed deployment and related equipment
CN113329232B (en) Resource distribution method and device, electronic equipment and storage medium
CN109542962B (en) Data processing method, data processing device, computer equipment and storage medium
CN110636106A (en) Information pushing method and device, computer equipment and storage medium
CN114119300A (en) Electronic protocol matching method and device, computer equipment and storage medium
CN113240336A (en) Task management system based on label
CN111209061A (en) Method and device for filling in user information, computer equipment and storage medium
CN112433925A (en) Log generation method and device based on artificial intelligence, computer equipment and medium

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