CN114741178A - Credit application processing method and device, electronic equipment and storage medium - Google Patents
Credit application processing method and device, electronic equipment and storage medium Download PDFInfo
- Publication number
- CN114741178A CN114741178A CN202210547704.5A CN202210547704A CN114741178A CN 114741178 A CN114741178 A CN 114741178A CN 202210547704 A CN202210547704 A CN 202210547704A CN 114741178 A CN114741178 A CN 114741178A
- Authority
- CN
- China
- Prior art keywords
- task
- application
- credit granting
- rule
- credit
- 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.)
- Granted
Links
- 238000003860 storage Methods 0.000 title claims abstract description 14
- 238000003672 processing method Methods 0.000 title claims description 13
- 238000012545 processing Methods 0.000 claims abstract description 102
- 238000000034 method Methods 0.000 claims abstract description 87
- 238000012795 verification Methods 0.000 claims description 65
- 208000011580 syndromic disease Diseases 0.000 claims description 60
- 238000004590 computer program Methods 0.000 claims description 11
- 238000012544 monitoring process Methods 0.000 claims description 6
- 230000008569 process Effects 0.000 description 43
- 238000010586 diagram Methods 0.000 description 12
- 238000011835 investigation Methods 0.000 description 8
- 230000006870 function Effects 0.000 description 7
- 238000004900 laundering Methods 0.000 description 7
- 238000004422 calculation algorithm Methods 0.000 description 6
- 238000004891 communication Methods 0.000 description 6
- 238000013475 authorization Methods 0.000 description 4
- 238000005516 engineering process Methods 0.000 description 4
- 230000008859 change Effects 0.000 description 3
- 230000007246 mechanism Effects 0.000 description 3
- 230000009286 beneficial effect Effects 0.000 description 2
- 238000013500 data storage Methods 0.000 description 2
- 230000001419 dependent effect Effects 0.000 description 2
- 238000013461 design Methods 0.000 description 2
- 238000011161 development Methods 0.000 description 2
- 238000012015 optical character recognition Methods 0.000 description 2
- 239000008186 active pharmaceutical agent Substances 0.000 description 1
- 230000004931 aggregating effect Effects 0.000 description 1
- 230000002776 aggregation Effects 0.000 description 1
- 238000004220 aggregation Methods 0.000 description 1
- 230000004888 barrier function Effects 0.000 description 1
- FFBHFFJDDLITSX-UHFFFAOYSA-N benzyl N-[2-hydroxy-4-(3-oxomorpholin-4-yl)phenyl]carbamate Chemical compound OC1=C(NC(=O)OCC2=CC=CC=C2)C=CC(=C1)N1CCOCC1=O FFBHFFJDDLITSX-UHFFFAOYSA-N 0.000 description 1
- 230000000903 blocking effect Effects 0.000 description 1
- 230000008878 coupling Effects 0.000 description 1
- 238000010168 coupling process Methods 0.000 description 1
- 238000005859 coupling reaction Methods 0.000 description 1
- 238000005286 illumination Methods 0.000 description 1
- 238000007689 inspection Methods 0.000 description 1
- 238000004519 manufacturing process Methods 0.000 description 1
- 239000003550 marker Substances 0.000 description 1
- 238000006386 neutralization reaction Methods 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 230000000737 periodic effect Effects 0.000 description 1
- 230000002093 peripheral effect Effects 0.000 description 1
- 238000002360 preparation method Methods 0.000 description 1
- 238000005070 sampling Methods 0.000 description 1
- 230000003068 static effect Effects 0.000 description 1
- 230000002123 temporal effect Effects 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/46—Multiprogramming arrangements
- G06F9/48—Program initiating; Program switching, e.g. by interrupt
- G06F9/4806—Task transfer initiation or dispatching
- G06F9/4843—Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system
- G06F9/4881—Scheduling strategies for dispatcher, e.g. round robin, multi-level priority queues
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/22—Indexing; Data structures therefor; Storage structures
- G06F16/2228—Indexing structures
- G06F16/2255—Hash tables
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/23—Updating
- G06F16/2365—Ensuring data consistency and integrity
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/23—Updating
- G06F16/2379—Updates performed during online database operations; commit processing
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/24—Querying
- G06F16/245—Query processing
- G06F16/2455—Query execution
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/25—Integrating or interfacing systems involving database management systems
- G06F16/252—Integrating or interfacing systems involving database management systems between a Database Management System and a front-end application
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/90—Details of database functions independent of the retrieved data types
- G06F16/901—Indexing; Data structures therefor; Storage structures
- G06F16/9024—Graphs; Linked lists
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/46—Multiprogramming arrangements
- G06F9/466—Transaction processing
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06Q—INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
- G06Q40/00—Finance; Insurance; Tax strategies; Processing of corporate or income taxes
- G06Q40/03—Credit; Loans; Processing thereof
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06Q—INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
- G06Q40/00—Finance; Insurance; Tax strategies; Processing of corporate or income taxes
- G06Q40/04—Trading; Exchange, e.g. stocks, commodities, derivatives or currency exchange
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F2209/00—Indexing scheme relating to G06F9/00
- G06F2209/48—Indexing scheme relating to G06F9/48
- G06F2209/482—Application
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Databases & Information Systems (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- Business, Economics & Management (AREA)
- Data Mining & Analysis (AREA)
- Software Systems (AREA)
- Accounting & Taxation (AREA)
- Finance (AREA)
- Economics (AREA)
- General Business, Economics & Management (AREA)
- Technology Law (AREA)
- Strategic Management (AREA)
- Marketing (AREA)
- Development Economics (AREA)
- Computational Linguistics (AREA)
- Computer Security & Cryptography (AREA)
- Financial Or Insurance-Related Operations Such As Payment And Settlement (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
The embodiment of the invention provides a method, a device, electronic equipment and a storage medium for processing a credit granting application, wherein the method comprises the following steps: receiving a credit application, and determining a task corresponding to the credit application in a target database based on the credit application and a global time wheel; controlling a local time wheel to obtain a task corresponding to the credit granting application and executing the task in a local application where the local time wheel is located; synchronizing the execution result of the task to a target database; and when the local time wheel monitors that the execution result of the task meets the processing condition of the credit granting application, acquiring the execution result of the task in the target database and feeding the execution result back to the sending end of the credit granting application. The distributed time wheel assembly is formed by setting the local time wheel and the global time wheel, and the credit granting application is processed in the distributed time wheel assembly, so that real-time processing can be realized when massive transaction tasks are faced, and the transaction processing efficiency and the service processing capacity are improved.
Description
Technical Field
The invention relates to the technical field of computers, in particular to a method and a device for processing a credit granting application, electronic equipment and a storage medium.
Background
When the existing credit granting application flow carries out service arrangement processing according to step splitting, all steps are mainly processed in series, or certain strategy parallel processing result collection is carried out through a thread pool in single application. Chinese patent publication No. CN112015572A entitled method, center and system for performing a delay task, which can be used as the related art of the present application.
The main problems at present are:
1. the whole transaction link is long, and the transaction time of one credit is usually dozens of seconds to minutes;
2. in the application, each credit transaction needs to occupy a thread to wait for a return result, the concurrence of each application is small, and the needed CPU resource is high. The existing parallel processing model is based on a JUC (tool in java.util.current packet, used for concurrent coding), and the concurrent rule statistics are generally coded through mechanisms such as a counter, a barrier, a semaphore and the like, so that the required CPU resource is high;
3. when the asynchronous processing is carried out by using the incoming and outgoing message queues, extra hardware resources are needed, and each message queue needs to be retransmitted or processed in an idempotent way when in use, so that the processing efficiency of transaction is low.
In view of solving the above technical problems, a method for processing a credit application capable of improving transaction efficiency is needed.
Disclosure of Invention
The invention provides a credit application processing method, a credit application processing device, electronic equipment and a storage medium, and aims to realize real-time processing and improve the processing efficiency and the service processing capacity of transactions when multiple transaction tasks are faced.
To achieve the above object, in a first aspect, the present invention provides a method for processing a credit application, including:
receiving a credit granting application, and determining a task corresponding to the credit granting application in a target database based on the credit granting application and a global time wheel;
controlling a local time wheel to obtain a task corresponding to the credit granting application and executing the task in a local application where the local time wheel is located;
synchronizing the execution result of the task to the target database;
and when the local time wheel monitors that the execution result of the task meets the processing condition of the credit granting application, acquiring the execution result of the task in the target database and feeding the execution result back to the sending end of the credit granting application.
In some possible embodiments, the target database comprises: redis database.
In some possible embodiments, the determining, in a target database, a task corresponding to the credit application based on the credit application and a global time wheel includes:
creating a task detail of the credit granting application based on the credit granting application;
creating a task corresponding to the credit granting application according to the task detail of the credit granting application;
establishing an incidence relation between the task detail of the credit granting application and the task corresponding to the credit granting application through the global time wheel;
and determining a task corresponding to the credit application in the target database according to the association relation.
In some possible embodiments, the creating a task detail of the trust application based on the trust application includes:
determining the content of the credit application request access;
creating a verification rule of the credit granting application according to the determined content of the access request of the credit granting application;
and generating a task detail of the credit granting application based on the verification rule.
In some possible embodiments, the creating, according to the determined content that the trust application requests to access, a verification rule of the trust application includes:
determining a check sub rule included in a check rule of the credit granting application according to the determined content of the access request of the credit granting application; wherein, the syndrome rules comprise the execution rules of each syndrome rule;
and creating the verification rule of the credit application based on the execution rule of each syndrome rule.
In some possible embodiments, the creating a verification rule of the trust application based on the execution rule of each syndrome rule includes:
judging whether an execution step dependency relationship exists between any syndrome rule and any other syndrome rule or not according to any syndrome rule;
when the execution step dependency relationship exists, determining that the execution rule of any syndrome rule is serial execution;
when the execution step dependency relationship does not exist, determining that the execution rule of any syndrome rule is executed in parallel;
and creating a verification rule of the credit granting application according to the determination result of the execution rule.
In some possible embodiments, after the creating the check rule of the trust application based on the execution rule of each check sub-rule, the method further includes:
storing the verification rule of the credit granting application in a task list of the global time wheel;
and acquiring the task details of the credit granting application based on the task list.
In some possible embodiments, task details of the trust application are obtained in the target database in a Lua script mode; the global time wheel stores a task List via a List data structure.
In some possible embodiments, the method further comprises:
recording the execution result of the task meeting the processing condition of the credit granting application;
and sending the execution result to a sending end of the credit granting application.
In some possible embodiments, when the local time wheel monitors that the execution result of the task does not meet the processing condition of the credit granting application, acquiring a task corresponding to the credit granting application;
judging whether the task is executed and completed;
when the task is not executed, synchronizing the task corresponding to the credit granting application to a local time wheel, and executing the task in the local time wheel;
and when the task is executed, recording the execution result of the task which does not meet the processing condition of the credit granting application and sending the execution result to the sending end of the credit granting application.
In a second aspect, the present invention provides a device for processing a credit granting application, including:
the searching module is used for receiving a credit granting application and determining a task corresponding to the credit granting application in a target database based on the credit granting application and a global time wheel;
the execution module is used for controlling a local time wheel to acquire a task corresponding to the credit granting application and executing the task in a local application where the local time wheel is located;
the synchronization module is used for synchronizing the execution result of the task to the target database;
and the monitoring module is used for acquiring the execution result of the task from the target database and feeding the execution result back to the sending end of the credit granting application when the local time wheel monitors that the execution result of the task meets the processing condition of the credit granting application.
In some possible embodiments, the search module specifically includes:
a task detail creating submodule for creating a task detail of the credit granting application based on the credit granting application;
the task creating submodule is used for creating a task corresponding to the credit granting application according to the task details of the credit granting application;
the incidence relation establishing submodule is used for establishing incidence relation between the task detail of the credit granting application and the task corresponding to the credit granting application through the global time wheel;
and the task determining sub-module is used for determining a task corresponding to the credit granting application in the target database according to the association relation.
In some possible embodiments, the task detail creation sub-module specifically includes:
a content determining unit, configured to determine content to which the trust application requests access;
a verification rule creating unit, configured to create a verification rule of the trust application according to the determined content requested to be accessed by the trust application;
and the task detail generating unit is used for generating the task details of the credit granting application based on the verification rule.
In some possible embodiments, the check rule creating unit is specifically configured to:
determining a check sub rule included in a check rule of the credit granting application according to the determined content of the access request of the credit granting application; wherein, the syndrome rule comprises an execution rule of each syndrome rule;
and creating the verification rule of the credit application based on the execution rule of each syndrome rule.
In some possible embodiments, the check rule creating unit is specifically configured to:
judging whether an execution step dependency relationship exists between any syndrome rule and any other syndrome rule or not aiming at any syndrome rule;
when the execution step dependency relationship exists, determining that the execution rule of any syndrome rule is serial execution;
when the execution step dependency relationship does not exist, determining that the execution rule of any syndrome rule is executed in parallel;
and creating a verification rule of the credit granting application according to the determination result of the execution rule.
In some possible embodiments, the apparatus further comprises: an acquisition module to:
storing sequence parameters in the verification rule of the credit granting application in a task list of the global time wheel;
and acquiring the task details of the credit granting application based on the task list.
In some possible embodiments, task details of the trust application are obtained in the target database in a Lua script mode; the global time wheel stores a task List via a List data structure.
In some possible embodiments, the apparatus further comprises a feedback module to:
recording the execution result of the task meeting the processing condition of the credit granting application;
and sending the execution result to a sending end of the credit granting application.
In some possible embodiments, the apparatus further comprises a determination processing module configured to:
when the local time wheel monitors that the execution result of the task does not meet the processing condition of the credit granting application, acquiring the task corresponding to the credit granting application;
judging whether the task is executed and completed;
when the task is not executed, synchronizing the task corresponding to the credit granting application to a local time wheel, and executing the task in the local time wheel;
and when the task is executed, recording the execution result of the task which does not meet the processing condition of the credit granting application and sending the execution result to the sending end of the credit granting application.
In a third aspect, the present invention also provides an electronic device, including:
a processor;
a memory storing a computer program which, when executed by the processor, implements any of the above described trust application processing methods.
In a fourth aspect, the present invention also provides a computer-readable storage medium storing instructions, which, when executed by at least one computing device, cause the at least one computing device to perform the method for processing a trusted application as described above.
The embodiment of the invention has the beneficial effects that:
the embodiment of the invention provides a method, a device, electronic equipment and a storage medium for processing a credit granting application, wherein the method comprises the following steps: receiving a credit application, and determining a task corresponding to the credit application in a target database based on the credit application and a global time wheel; controlling a local time wheel to obtain a task corresponding to the credit granting application and executing the task in a local application where the local time wheel is located; synchronizing the execution result of the task to a target database; and when the local time wheel monitors that the execution result of the task meets the processing condition of the credit granting application, acquiring the execution result of the task in the target database and feeding the execution result back to the sending end of the credit granting application. Different from the existing credit granting transaction processing method, the credit granting application processing method provided by the embodiment of the invention forms a distributed time wheel assembly by setting a local time wheel and a global time wheel, processes the credit granting application in the distributed time wheel assembly, and processes the task corresponding to the credit granting application in the distributed time wheel, so that when a large amount of transaction tasks are faced, real-time processing can be realized, and the transaction processing efficiency and the service processing capability are improved.
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 of a method for processing a credit granting application according to an embodiment of the present invention;
fig. 2 is a schematic flowchart of a trust application processing method according to an embodiment of the present invention;
fig. 3 is a schematic structural diagram of a trust application processing apparatus according to an embodiment of the present invention;
fig. 4 is a schematic structural diagram of an electronic device according to an embodiment of the present invention;
fig. 5 is a schematic structural diagram of a computer storage medium according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The technical terms used in the examples of the present invention are defined and explained below:
1. time complexity: the temporal complexity of the algorithm is a function that qualitatively describes the runtime of the algorithm. This is a function of the length of the string representing the algorithm input value. The time complexity is often represented by a large O symbol, describing the relationship between the time used by the algorithm and the size of the executed data.
2. Redis data Structure: string, Hash, List are all data storage structures provided by the Redis API.
3. Redis Lua: the embedded scripting language of Redis can combine certain business logic. The Lua script has exclusivity, namely, the Lua script does not accept and kill any Redis operation request outside the script during the execution period, and the atomicity of the Redis data change executed in the Lua script can be ensured.
4. Spring: spring is a lightweight open-source framework in the field of Java EE programming, and is an application-type framework for solving the complexity in enterprise-level programming development and realizing agile development. Currently, the mainstream Java applications are realized by using a Spring framework or by using Spring boot, Spring cloud and the like derived from the Spring framework.
The time wheel technology is an implementation mechanism for checking a low-precision timer (the minimum scale is 1Hz, the second level) in the Linux, and is also a timer with optimal time complexity. Most delay algorithms are based on a time wheel technology, the time wheel technology is a scheduling model for efficiently utilizing thread resources to perform batch scheduling, large batches of scheduling tasks are all bound to the same scheduler, the scheduler is used for managing, triggering and running all the tasks, various delay tasks, periodic tasks, notification tasks and the like can be efficiently managed, and the time complexity is O (1) under a specific condition.
In the asynchronous communication field of software architecture design, a time round technique is generally adopted when time precision requires a second level, massive tasks are added, requirements on a task execution sequence with similar time are not strict, and requirements that a task issuing party and a task executing party are not directly connected are met.
In the prior art, when a plurality of partners exist on an internet loan platform (short for an internet loan platform), rules of a plurality of third party interfaces are processed when being called during a single transaction. When the existing credit granting application flow carries out service arrangement processing according to step splitting, all steps are mainly processed in series or certain strategies are carried out for parallel processing result collection through a thread pool in a single application. The main problems that exist are: the whole transaction link is long in time, the transaction time of one credit authorization is usually from dozens of seconds to several minutes, each credit authorization transaction needs to occupy a thread to wait for a return result, the concurrence of each application is small, and the needed CPU resource is high; the asynchronous processing of the incoming and outgoing message queues requires additional hardware resources, and the retransmission/idempotent processing of each message queue is required during use, so that the processing efficiency of transaction is low.
In order to solve the technical problem, an embodiment of the present invention provides a method for processing a credit application, and a detailed description is provided below for a solution of the embodiment of the present invention.
Fig. 1 is a flowchart illustrating a method for processing a trust application according to an embodiment of the present invention. As shown in fig. 1, the method mainly comprises the following steps:
and S101, receiving a credit granting application, and determining a task corresponding to the credit granting application in a target database based on the credit granting application and the global time wheel.
The method provided by the embodiment of the invention can be applied to a server, the server can be a server of a network credit platform or a financial platform, and the local time wheel can be arranged in local application, such as Java application; the global time wheel can be time wheel related data stored based on a Redis database, Redis is used for storing the time wheel related data, equivalently global variables are carried, and the related Redis data structure design can meet the following requirements: (1) the task list for each time slice should be retrievable at O (1) time complexity, which is a function that qualitatively describes the run time of the algorithm; (2) the task list is a two-way linked list with the complexity of O (1) in operation time, and is convenient to insert and extract; (3) the operation of taking out the task can be balanced in load; (4) the tasks which are executed for multiple times can be provided with parameters so as to facilitate quick operation; (5) unpredictable large-scale operations are avoided from blocking the Redis main thread.
The server receives a credit application, which can be sent by an external system such as a partner or a business party, and a credit platform (which can be located in the server) receives the application and transmits information such as user information, identity cards, face recognition images, contacts, bank card information, equipment information and the like to the credit platform. And the credit granting platform performs storage falling on all information, performs verification such as blacklists, relation lists and anti-money laundering lists, performs anti-fraud verification, credit investigation and risk approval, and transmits approval results to the partner in real time.
In some embodiments, determining a task corresponding to the credit application in the target database based on the credit application and the global time wheel may include the following steps:
creating a task detail of the credit application based on the credit application; creating a task corresponding to the credit granting application according to the task details of the credit granting application; establishing an incidence relation between the task detail of the credit granting application and the task corresponding to the credit granting application through a global time wheel; and determining a task corresponding to the credit granting application in the target database according to the association relation.
Specifically, the credit application may include basic information of a service party or a partner, such as user information, an identity card, a face recognition image, a contact, bank card information, device information, and the like, and according to the information included in the credit application, a task detail that needs to be subjected to information approval is determined, such as verification of a blacklist, a related person list, an anti-money laundering list, and the like, anti-fraud verification, credit investigation, risk approval, and the like, the task detail is created according to the credit application, an association relationship is established through a global time wheel according to the created task detail and a task corresponding to the credit application, and according to the established association relationship, a task corresponding to the credit application may be determined in a task list in a target database.
In some embodiments, a method for creating a task specification of a trusted application based on the trusted application may include: determining the content of the credit application request access; establishing a verification rule of the credit granting application according to the determined content of the access request of the credit granting application; and generating a task detail of the trust application based on the verification rule.
Specifically, firstly, determining the content requested to be accessed by the credit application, such as a personal loan blacklist database, a related public service, a matching related person list, an anti-money laundering service and the like, and creating a check rule for accessing the content according to the content requested to be accessed in the credit application, wherein the check rule can comprise the access sequence of each content and can also be an access rule, for example, the content is not checked in the blacklist and is checked in the matching related person list, and the specific access rule can be set according to the actual requirement of a user. The task details of the trust application are generated according to the check rule, that is, the task details may include specific task contents, which is described above by way of example only, and the content requested to be accessed may be adjusted according to the actual business requirements of the business party or the partner.
In some embodiments, creating a verification rule of the trusted application according to the determined content requested to be accessed by the trusted application may include: determining a syndrome rule included in a verification rule of the credit application according to the determined content of the access request of the credit application; wherein, the syndrome rules comprise the execution rules of each syndrome rule; and creating a verification rule of the credit application based on the execution rule of each syndrome rule.
For example, the check rule for the credit application may include a syndrome rule for each requested access content, and the syndrome rule includes an execution rule of each syndrome rule, and the syndrome rule may be represented by a sequence parameter, such as a step number, a parallel or serial sequence, for example, a check sequence of each access content, and the check rule for the credit application is created based on the execution rule of each syndrome rule.
Further, creating the verification rule of the trust application based on the execution rule of each syndrome rule may include: judging whether an execution step dependency relationship exists between any syndrome rule and any other syndrome rule or not aiming at any syndrome rule; when the execution step dependency relationship exists, determining that the execution rule of any syndrome rule is serial execution; when the execution step dependency relationship does not exist, determining that the execution rule of any syndrome rule is executed in parallel; and creating a verification rule of the credit granting application according to the determination result of the execution rule.
Specifically, the check rule of the trust application may include a plurality of check sub-rules, and each check sub-rule may have a step dependency relationship, that is, the check sub-rules having the step dependency relationship need to be executed serially, which has a certain execution sequence requirement, and the check sub-rules having no step dependency relationship may be executed in parallel, and each check sub-rule does not affect each other, and may be executed simultaneously.
After creating the verification rule of the trust application based on the execution rule of each syndrome rule, the method may further include: storing the verification rule of the credit granting application in a task list of the global time wheel; and acquiring the task detail of the credit granting application based on the task list. In the embodiment of the invention, the verification rule of the credit granting application is stored in the task list of the global time wheel, and the task detail of the credit granting application is obtained according to the verification rule of the credit granting application stored in the task list and each sub-verification rule.
It should be noted that, the task details of the trust application are obtained in the target database in a Lua script mode; the global time wheel stores a task List via a List data structure. The Lua script is a script language embedded in Redis and can be combined with certain service logic. The Lua script has exclusivity, any Redis operation request except the Lua script is not accepted during the execution of the Lua script, and the atomicity of the Redis data change executed in the Lua script can be ensured. The Lua script mode can ensure that the taken tasks cannot be taken out again by other applications, thereby avoiding repeated access in the same time and realizing load balancing.
Taking the use of Redis to store time wheel data as an example, the Redis stores a current pointer and a task List of a time wheel, and the specific Redis can store the task List by using a List data structure, and when a task is added to the task List in the Redis, a single task can be added by an hmset command to ensure atomicity, and the hmset is ensured not to be blocked by limiting the number of fields of the task. When the number of steps and the step dependence sequence in the verification rule of the credit application are determined, a next field is added in the Hash of the task to point to the taskKey of the next task, namely, a linked list of another dimension is formed outside the task list. And the Lua script checks that when the execution time of the task returns to zero, if a next task exists, the task is put into a global time wheel according to a rule, and then the serial mechanism of the task can be realized.
Meanwhile, a tradeId field is added in the Hash of the task, the tradeId field can be used for aggregating parallel tasks of the same service Id, the execution result of the task is written into a set X according to a key value key spliced by the service Id (the execution result of the task is specifically designed according to the service and can be set data structures of Redis such as Hash, List, Zset and the like), and data preparation of the parallel result can be realized. Based on the monitoring of the set X, the aggregation of the parallel results is further realized.
And S102, controlling the local time wheel to acquire a task corresponding to the credit granting application and executing the task in the local application where the local time wheel is located.
The local time wheel is controlled to fetch the task and execute the task locally, because the local time wheel is typically provided in the local application, the task is executed by the local application.
Step S103, synchronizing the execution result of the task to the target database.
In step 102, after controlling the local time wheel to execute the task, generating a task execution result, and synchronizing the task execution result to the global time wheel, where the global time wheel is located in the target database, and besides storing the task list, generating a linked list storing the task execution result in the target database, where the linked list is static.
And step S104, when the local time wheel monitors that the execution result of the task meets the processing condition of the credit granting application, acquiring the execution result of the task in the target database and feeding the execution result back to the sending end of the credit granting application.
When the execution result of the task meets the processing conditions of the credit granting application, for example, when all the syndrome rules are passed through, namely the credit granting application is successful, the execution result of the task in the global time wheel is obtained in the target database and fed back to the sending end of the credit granting application so as to inform the sending end of successful credit granting application.
In a specific embodiment, the method provided in the embodiment of the present invention may further include: recording the execution result of the task meeting the processing condition of the credit granting application; and sending the execution result to a sending end of the credit granting application. Besides the execution result of the task, the execution result of the task meeting the processing condition of the credit granting application can be locally recorded, the execution result is sent to the sending end of the credit granting application, the execution result of the task is recorded in the local time wheel, the execution result of the task is not acquired by storing the execution result of the task in the global time wheel, the resource of the global time wheel is not occupied, and the execution result of the task is convenient to acquire.
In a specific embodiment, the method provided in the embodiment of the present invention may further include: when the local time wheel monitors that the execution result of the task does not meet the processing condition of the credit granting application, acquiring the task corresponding to the credit granting application; judging whether the execution of the task is completed; when the task is not executed, synchronizing the task corresponding to the credit granting application to a local time wheel, and executing the task in the local time wheel; and when the task execution is finished, recording the execution result of the task which does not meet the processing condition of the credit granting application and sending the execution result to the sending end of the credit granting application. When the local time wheel monitors that the execution result of the task does not meet the processing condition of the credit granting application, the task corresponding to the credit granting application is obtained again, and whether the task is executed or not is judged, for example, whether the task details included in the task are executed or not is judged specifically; when the task is not executed, synchronizing the task corresponding to the credit granting application to a local time wheel, executing the task in the local time wheel, and synchronizing the execution result to a global time wheel or recording the execution result in the local time wheel; when the task is executed, recording the execution result of the task which does not meet the processing condition of the credit granting application and sending the execution result to the sending end of the credit granting application, for example, all the checking rule steps are checked, but the final result is that the execution result is not passed, sending the execution result of the task to the sending end of the credit granting application and informing the client end sending the credit granting application.
In the embodiment of the present invention, regarding the data structures of the global time wheel and the local time wheel, taking Redis to store time wheel data as an example, current pointers and task lists of the time wheel are stored in Redis, and a specific Redis may store a task List using a List data structure, where key names of the task List are spliced by time slice markers tickId and round numbers round, and a corresponding time slice marker tickId and round numbers round may be determined according to a time wheel parameter of a next task to be executed, and a task is taken out from the task List according to the key name, where complexity of the retrieval time at this time is O (1). When accessing the task through the key name, the Hash data structure is used for storing, and fields such as the execution time and the execution times of the next task to be executed are contained in the Hash data structure and are used for executing the next task.
It should be noted that String, Hash, and List are all data storage structures provided by the Redis application program interface. Both the current number of time slices and the current number of rounds of the time round are stored using String, all operations of the time round parameters are of time complexity O (1). And acquiring a next task to be executed in the task list in a Lua script mode, wherein the Lua script is a script language embedded in Redis and can combine certain service logic. The Lua script has exclusivity, any Redis operation request except the Lua script is not accepted during the execution of the Lua script, and the atomicity of the Redis data change executed in the Lua script can be ensured. The Lua script mode can ensure that the taken tasks cannot be taken out again by other applications, thereby avoiding repeated access in the same time and realizing load balancing.
The following describes the trust application method provided by the embodiment of the present invention in detail by taking fig. 2 as an example and combining with an actual application scenario.
As shown in fig. 2, when a business party or a partner sends a credit application, the method mainly includes the following steps:
step S201, receiving a credit application;
step S202, a trust application is dropped into a library;
the credit granting application is stored in the local database, and when the same application of the same service party is received, the execution result of the task can be directly obtained and returned, or the same application is directly refused to be processed, so that the same credit granting application can be prevented from being repeatedly processed, the task processing time is saved, and the processing efficiency is improved.
Step S203, delivering a distributed time wheel queue according to the credit application;
and delivering a distributed time wheel queue according to the credit granting application, wherein the distributed time wheel comprises a global time wheel and a local time wheel, searching a task corresponding to the credit granting application in the global time wheel according to the credit granting application, synchronizing the task corresponding to the credit granting application to the local time wheel, and controlling the local time wheel to execute the task. Specifically, when a task is searched according to a credit application, a check rule for the credit application can be determined, wherein the check rule can include a wind control rule check, a blacklist check, a relation check, an anti-money laundering check, an anti-fraud risk check and the like, and the check rules can be executed in parallel, namely the check rules can be executed simultaneously, and are not influenced with each other and are checked independently.
Illustratively, the process of delivering the credit application to the distributed time wheel queue is divided into 16 main processes, and each process is numbered,
the main process 1, verifying the credit granting strategy by the network credit platform, and verifying whether the credit granting strategy is hit:
when the verification result is hit, updating the credit granting application state as refusal, and executing the main process 16;
when the verification result is not hit, executing the main process 2;
and 2, inquiring a personal loan blacklist database by the network loan platform, and verifying whether the personal loan blacklist database is hit:
when the verification result is hit, updating the credit granting application state as refusal, and executing the main process 16;
when the verification result is not hit, executing the main process 3;
and 3, the network loan platform transmits the client identity card number in the credit application to a public service of a relation person, matches the list of the relation person and verifies whether the client identity card number is hit:
when the verification result is hit, updating the credit granting application state as refusal, and executing the main process 16;
when the verification result is not hit, executing the main process 4;
and 4, the network credit platform transmits the client identity card number in the credit application to the anti-money laundering service to verify whether the anti-money laundering list is hit:
when the verification result is hit, updating the credit granting application state as refusal, and executing the main process 16;
when the verification result is not hit, executing the main process 5;
the main process 5, the network credit platform carries out face recognition large-head photo inspection, customer information is transmitted to the face recognition platform through a face recognition checkPerson interface, and the face recognition platform outputs a result:
when the verification result is hit, updating the credit granting application state as refusal, and executing the main process 16;
when the verification result is a miss, executing the main process 7;
the main process 6 is that the network loan platform performs face Recognition ocr (Optical Character Recognition), transmits the client identity information to the face Recognition platform through a face Recognition ocr interface, and the face Recognition platform outputs a result:
when the verification result does not meet the requirement, updating the credit granting application state as refusal, and executing a main process 16;
when the verification result meets the requirement, executing a main process 7;
and (3) judging whether the main process 7 and the network loan platform need to pass through an anti-fraud interface:
if the pass is required, executing a main process 8;
if no pass is required, the main process 9 is executed.
The main process 8 and the network loan platform call an ant shield anti-fraud interface for anti-fraud risk verification, and a returned result is verified:
if the anti-fraud check is hit, the query result is updated to be rejected, and the main process 16 is executed;
if the anti-fraud check is not hit, the main process 9 is executed.
And 9, a main process 9, according to a network loan platform configuration sampling rule, judging whether to call an ant shield scoring card interface:
if yes, executing the main process 10;
if no pass is required, main process 11 is performed.
The main process 10 and the network loan platform call an ant shield scoring card interface for risk verification of a scoring card, and a returned result is verified:
if the score of the hit score card is smaller than the limit value (public), the query result is updated to be rejected, and the main process 16 is executed;
if the scorecard check is not hit, main process 11 is executed.
The main process 11, the network credit platform will generate a credit investigation authorization and call a CFCA (China Financial authentication center) to sign a client name stamp, upload credit investigation image pieces (the front and back sides of an identity card and the authorization) to the image platform, and keep the corresponding batch number;
the main process 12 calls a second-generation credit investigation interface, inquires the second-generation credit investigation of the client, and informs the image batch number of the credit investigation prefix corresponding to the credit investigation serial number through a notification interface;
the main process 13, the network credit platform analyzes the credit report and puts the required content into a database;
the main process 14 transmits the information to the ant shield platform according to the interface, and the ant shield platform outputs information such as client amount, interest rate and rejection reason;
the main process 15, the network credit platform updates the credit granting result and informs the neutralization agriculture credit granting result;
the main process 16 ends.
Step S204, recording the processing result of the delivery distributed time wheel queue;
and the task processing result recorded in the S203 is stored in the global time wheel, so that the business party or the cooperation party initiates credit granting result query to the network credit platform.
In step S205, the processing result is returned.
And the network loan platform returns the result and executes the main process 2.
In this embodiment, the flow of the trust application may be split according to steps to perform service arrangement, a task number is allocated to each step, or 2 parameters may be added to each step, where a parameter a is used to configure whether the task supports parallel processing, a parameter B is used to configure a task number dependent on the step, and when parallel processing is supported, a parameter B is configured to be 0. As shown in fig. 2, when the serial is supported, the parameter B is the task number of the previous step that needs to be relied on, as shown in fig. 2, the task number of the wind control rule check is 1, the task number of the blacklist check is 2, the task number of the relation check is 3, the task number of the anti-money laundering check is 4, the task number of the big-head illumination check is 5, the task number of the OCR check is 6, the task number of the ant shield scoring card is 8, the task number of the CFCA signature is 9, the task number of the second generation credit inquiry is 10, the task number of the ant shield platform is 11, and the task number of the anti-fraud check is 7, wherein each check rule has a task number that represents whether the rule is parallel or serial processing, and if parallel, the parameter is "and-0"; if it is serial, the parameter is "string-needs dependent task number", e.g., task 6 needs to be done after task 5, the parameter is "string-5", and so on. When the external system initiates a trust application, the local application may save the request. The number of steps that the request can be in parallel is confirmed according to the value of the parameter A related to the steps, and the dependency relationship between the steps is confirmed according to the parameter B.
The method for processing the credit granting application provided by the embodiment of the invention comprises the following steps: receiving a credit granting application, and searching a task corresponding to the credit granting application in a global time wheel according to the received credit granting application; synchronizing the task corresponding to the credit granting application to a local time wheel, and controlling the local time wheel to execute the task; synchronizing the execution result of the task to a global time wheel; and when the local time wheel monitors that the execution result of the task meets the processing condition of the credit granting application, acquiring the execution result of the task and feeding the execution result back to the sending end of the credit granting application. Different from the existing credit granting transaction processing method, the credit granting application processing method provided by the embodiment of the invention forms a distributed time wheel assembly by setting a local time wheel and a global time wheel, processes the credit granting application in the distributed time wheel assembly, and processes the task corresponding to the credit granting application in the distributed time wheel, so that when a large amount of transaction tasks are faced, real-time processing can be realized, and the transaction processing efficiency and the service processing capability are improved.
Based on the same inventive concept as the method for processing the credit granting application shown in fig. 1, an embodiment of the present invention further provides a device for processing the credit granting application, as described in the following embodiments. Because the principle of the device for solving the problems is similar to that of the method for processing the credit application in fig. 1, the implementation of the device can refer to the implementation of the method for processing the credit application in fig. 1, and repeated details are not repeated. As shown in fig. 3, the trust application processing apparatus 30 includes: the system comprises a searching module 31, an executing module 32, a synchronizing module 33 and a monitoring module 34; wherein,
the searching module 31 is used for receiving a credit granting application and determining a task corresponding to the credit granting application in a target database based on the credit granting application and a global time wheel;
the execution module 32 is configured to control a local time wheel to obtain a task corresponding to the credit granting application and execute the task in a local application where the local time wheel is located;
a synchronization module 33, configured to synchronize an execution result of the task to the target database;
and the monitoring module 34 is configured to, when the local time wheel monitors that the execution result of the task meets the processing condition of the credit granting application, obtain the execution result of the task in the target database and feed the execution result back to the sending end of the credit granting application.
In an embodiment, the searching module 31 specifically includes:
the task detail creating submodule is used for creating the task details of the credit granting application based on the credit granting application;
the task creating sub-module is used for creating a task corresponding to the credit granting application according to the task details of the credit granting application;
the incidence relation establishing submodule is used for establishing incidence relation between the task detail of the credit granting application and the task corresponding to the credit granting application through the global time wheel;
and the task determining submodule is used for determining a task corresponding to the credit granting application in the target database according to the association relation.
In some embodiments, the task detail creation sub-module specifically includes:
the content determining unit is used for determining the content which is requested to be accessed by the credit application;
the verification rule creating unit is used for creating a verification rule of the credit granting application according to the determined content of the access requested by the credit granting application;
and the task detail generating unit is used for generating the task details of the credit granting application based on the verification rule.
In some embodiments, the check rule creating unit is specifically configured to:
determining a check sub rule included in a check rule of the credit granting application according to the determined content of the access request of the credit granting application; wherein, the syndrome rules comprise the execution rules of each syndrome rule;
and creating the verification rule of the credit application based on the execution rule of each syndrome rule.
In some embodiments, the check rule creating unit is specifically configured to:
judging whether an execution step dependency relationship exists between any syndrome rule and any other syndrome rule or not aiming at any syndrome rule;
when the execution step dependency relationship exists, determining that the execution rule of any syndrome rule is serial execution;
when the execution step dependency relationship does not exist, determining that the execution rule of any syndrome rule is executed in parallel;
and creating a verification rule of the credit granting application according to the determination result of the execution rule.
In some embodiments, the apparatus further comprises: an acquisition module to:
storing sequence parameters in the verification rule of the credit granting application in a task list of the global time wheel;
and acquiring the task details of the credit granting application based on the task list.
In some embodiments, the task details of the trust application are obtained in the target database in a Lua script mode; the global time wheel stores a task List via a List data structure.
In some embodiments, the apparatus further comprises a feedback module to:
recording the execution result of the task meeting the processing condition of the credit granting application;
and sending the execution result to a sending end of the credit granting application.
In some embodiments, the apparatus further comprises a determination processing module configured to:
when the local time wheel monitors that the execution result of the task does not meet the processing condition of the credit granting application, acquiring a task corresponding to the credit granting application;
judging whether the task is executed and completed;
when the task is not executed, synchronizing the task corresponding to the credit granting application to a local time wheel, and executing the task in the local time wheel;
and when the task is executed, recording the execution result of the task which does not meet the processing condition of the credit granting application and sending the execution result to the sending end of the credit granting application.
The embodiment of the invention has the beneficial effects that the invention provides a credit application processing device, which comprises:
the searching module is used for receiving the credit granting application and determining a task corresponding to the credit granting application in the target database based on the credit granting application and the global time wheel; the execution module is used for controlling the local time wheel to acquire a task corresponding to the credit granting application and executing the task in the local application where the local time wheel is located; the synchronization module is used for synchronizing the execution result of the task to the target database; and the monitoring module is used for acquiring the execution result of the task from the target database and feeding the execution result back to the sending end of the credit granting application when the local time wheel monitors that the execution result of the task meets the processing condition of the credit granting application. Different from the existing credit granting transaction processing method, the credit granting application processing device provided by the embodiment of the invention forms a distributed time wheel assembly by setting a local time wheel and a global time wheel, processes the credit granting application in the distributed time wheel assembly, and processes the task corresponding to the credit granting application in the distributed time wheel, so that when a large amount of transaction tasks are faced, real-time processing can be realized, and the transaction processing efficiency and the service processing capability are improved.
Fig. 4 is a schematic diagram of an electronic device for processing a credit application according to an embodiment of the present invention. As shown in fig. 4, the electronic device may be a computer device that may include a processor 401 and a memory 402 storing computer program instructions.
Specifically, the processor 401 may include a Central Processing Unit (CPU), or an Application Specific Integrated Circuit (ASIC), or may be configured as one or more Integrated circuits implementing embodiments of the present invention.
Memory 402 may include mass storage for data or instructions. By way of example, and not limitation, memory 402 may include a Hard Disk Drive (HDD), floppy Disk Drive, flash memory, optical Disk, magneto-optical Disk, tape, or Universal Serial Bus (USB) Drive or a combination of two or more of these. Memory 402 may include removable or non-removable (or fixed) media, where appropriate. In a particular embodiment, the memory 402 is a non-volatile solid-state memory. In a particular embodiment, the memory 402 includes Read Only Memory (ROM). Where appropriate, the ROM may be mask-programmed ROM, Programmable ROM (PROM), Erasable PROM (EPROM), Electrically Erasable PROM (EEPROM), Electrically Alterable ROM (EAROM), or flash memory or a combination of two or more of these.
The processor 401 reads and executes the computer program instructions stored in the memory 402 to implement the method for processing the credit application in the above embodiment.
In one example, the computer devices described above may also include a communication interface 403 and a bus 404. As shown in fig. 4, the processor 401, the memory 402, and the communication interface 403 are connected via a bus 404 to complete communication therebetween.
The communication interface 403 is mainly used for implementing communication between modules, devices, units and/or devices in the embodiment of the present invention.
The bus 404 may comprise hardware, software, or both for coupling the above-described components to one another. For example, a bus may include an Accelerated Graphics Port (AGP) or other graphics bus, an Enhanced Industry Standard Architecture (EISA) bus, a Front Side Bus (FSB), a Hyper Transport (HT) interconnect, an Industry Standard Architecture (ISA) bus, an infiniband interconnect, a Low Pin Count (LPC) bus, a memory bus, a Micro Channel Architecture (MCA) bus, a Peripheral Component Interconnect (PCI) bus, a PCI-Express (PCI-X) bus, a Serial Advanced Technology Attachment (SATA) bus, a video electronics standards association local (VLB) bus, or other suitable bus or a combination of two or more of these. Bus X10 may include one or more buses, where appropriate. Although specific buses have been described and illustrated with respect to embodiments of the invention, any suitable buses or interconnects are contemplated by the invention.
The computer device may execute the method for processing a credit granting application in the embodiment of the present invention, thereby implementing the method and apparatus for processing a credit granting application described with reference to fig. 1 and 3.
Further, the trust application processing method described with reference to fig. 1 may be implemented by a program (or instructions) recorded on a computer-readable storage medium. For example, as shown in FIG. 5, according to an exemplary embodiment of the invention, a computer-readable storage medium 501 may be provided that stores instructions which, when executed by at least one computing device, cause the at least one computing device to perform a method of trust application processing.
The computer program in the computer-readable storage medium 501 may be executed in an environment deployed in a computer device such as a client, a host, a proxy device, a server, and the like, and it should be noted that the computer program may also be used to perform additional steps other than the above steps or perform more specific processing when the above steps are performed, and the content of the additional steps and the further processing is already mentioned in the description of the related method with reference to fig. 1, and therefore will not be described again here to avoid repetition.
The present invention is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
The principle and the implementation mode of the invention are explained by applying specific embodiments in the invention, and the description of the embodiments is only used for helping to understand the method and the core idea of the invention; meanwhile, for a person skilled in the art, according to the idea of the present invention, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present invention.
Claims (20)
1. A credit application processing method is characterized by comprising the following steps:
receiving a credit granting application, and determining a task corresponding to the credit granting application in a target database based on the credit granting application and a global time wheel;
controlling a local time wheel to obtain a task corresponding to the credit granting application and executing the task in a local application where the local time wheel is located;
synchronizing the execution result of the task to the target database;
and when the local time wheel monitors that the execution result of the task meets the processing condition of the credit granting application, acquiring the execution result of the task in the target database and feeding the execution result back to the sending end of the credit granting application.
2. The method of claim 1, wherein the determining a task corresponding to the trust application in a target database based on the trust application and a global time wheel comprises:
creating a task detail of the credit granting application based on the credit granting application;
creating a task corresponding to the credit granting application according to the task details of the credit granting application;
establishing an association relation between the task details of the credit granting application and the task corresponding to the credit granting application through the global time wheel;
and determining a task corresponding to the credit application in the target database according to the association relation.
3. The method of claim 2, wherein creating the task specification of the trusted application based on the trusted application comprises:
determining the content of the credit application request access;
creating a verification rule of the credit granting application according to the determined content of the access request of the credit granting application;
and generating the task detail of the credit granting application based on the check rule.
4. The method according to claim 3, wherein the creating of the verification rule of the trusted application according to the determined content requested to be accessed by the trusted application comprises:
determining a check sub rule included in a check rule of the credit granting application according to the determined content of the access request of the credit granting application; wherein, the syndrome rules comprise the execution rules of each syndrome rule;
and creating the verification rule of the credit application based on the execution rule of each syndrome rule.
5. The method according to claim 4, wherein the creating of the verification rule of the trust application based on the execution rule of each syndrome rule comprises:
judging whether an execution step dependency relationship exists between any syndrome rule and any other syndrome rule or not aiming at any syndrome rule;
when the execution step dependency relationship exists, determining that the execution rule of any syndrome rule is serial execution;
when the execution step dependency relationship does not exist, determining that the execution rule of any syndrome rule is executed in parallel;
and creating a verification rule of the credit granting application according to the determination result of the execution rule.
6. The method as claimed in claim 4, wherein after the creating the verification rule of the trust application based on the execution rule of each syndrome rule, the method further comprises:
storing the verification rule of the credit granting application in a task list of the global time wheel;
and acquiring the task details of the credit granting application based on the task list.
7. The method according to claim 2, wherein the task details of the trust application are obtained in the target database by a Lua script mode; the global time wheel stores a task List via a List data structure.
8. The method of claim 1, further comprising:
recording the execution result of the task meeting the processing condition of the credit granting application;
and sending the execution result to a sending end of the credit granting application.
9. The method of claim 1, further comprising:
when the local time wheel monitors that the execution result of the task does not meet the processing condition of the credit granting application, acquiring the task corresponding to the credit granting application;
judging whether the task is executed and completed;
when the task is not executed and completed, synchronizing the task corresponding to the credit granting application to a local time wheel, and executing the task in the local time wheel;
and when the task is executed, recording the execution result of the task which does not meet the processing condition of the credit granting application and sending the execution result to the sending end of the credit granting application.
10. A trust application processing apparatus, the apparatus comprising:
the searching module is used for receiving a credit granting application and determining a task corresponding to the credit granting application in a target database based on the credit granting application and a global time wheel;
the execution module is used for controlling a local time wheel to acquire a task corresponding to the credit granting application and executing the task in a local application where the local time wheel is located;
the synchronization module is used for synchronizing the execution result of the task to the target database;
and the monitoring module is used for acquiring the execution result of the task from the target database and feeding the execution result back to the sending end of the credit granting application when the local time wheel monitors that the execution result of the task meets the processing condition of the credit granting application.
11. The apparatus according to claim 10, wherein the search module specifically includes:
a task detail creating submodule for creating a task detail of the credit granting application based on the credit granting application;
the task creating submodule is used for creating a task corresponding to the credit granting application according to the task details of the credit granting application;
the incidence relation establishing submodule is used for establishing incidence relation between the task detail of the credit granting application and the task corresponding to the credit granting application through the global time wheel;
and the task determining submodule is used for determining a task corresponding to the credit granting application in the target database according to the association relation.
12. The apparatus according to claim 11, wherein the task detail creation sub-module specifically includes:
a content determining unit, configured to determine content to which the trust application requests access;
a verification rule creating unit, configured to create a verification rule of the trust application according to the determined content requested to be accessed by the trust application;
and the task detail generating unit is used for generating the task details of the credit granting application based on the verification rule.
13. The apparatus according to claim 12, wherein the verification rule creating unit is specifically configured to:
determining a check sub rule included in a check rule of the credit granting application according to the determined content of the access request of the credit granting application; wherein, the syndrome rules comprise the execution rules of each syndrome rule;
and creating the verification rule of the credit application based on the execution rule of each syndrome rule.
14. The apparatus according to claim 13, wherein the verification rule creating unit is specifically configured to:
judging whether an execution step dependency relationship exists between any syndrome rule and any other syndrome rule or not aiming at any syndrome rule;
when the execution step dependency relationship exists, determining that the execution rule of any syndrome rule is serial execution;
when the dependency relationship of the execution steps does not exist, determining that the execution rule of any syndrome rule is executed in parallel;
and creating a verification rule of the credit granting application according to the determination result of the execution rule.
15. The apparatus of claim 13, further comprising an acquisition module configured to:
storing the verification rule of the credit granting application in a task list of the global time wheel;
and acquiring the task details of the credit granting application based on the task list.
16. The apparatus according to claim 11, wherein the task details of the trust application are obtained in the object database by a Lua script; the global time wheel stores a task List via a List data structure.
17. The apparatus of claim 10, further comprising a feedback module to:
recording the execution result of the task meeting the processing condition of the credit granting application;
and sending the execution result to a sending end of the credit granting application.
18. The apparatus of claim 10, further comprising a determination processing module configured to:
when the local time wheel monitors that the execution result of the task does not meet the processing condition of the credit granting application, acquiring the task corresponding to the credit granting application;
judging whether the task is executed and completed;
when the task is not executed, synchronizing the task corresponding to the credit granting application to a local time wheel, and executing the task in the local time wheel;
and when the task is executed, recording the execution result of the task which does not meet the processing condition of the credit granting application and sending the execution result to the sending end of the credit granting application.
19. An electronic device, characterized in that the device comprises:
a processor;
a memory storing a computer program which, when executed by the processor, implements the trusted application processing method as claimed in any one of claims 1 to 9.
20. A computer-readable storage medium storing instructions that, when executed by at least one computing device, cause the at least one computing device to perform the method of processing a trusted application as claimed in any one of claims 1 to 9.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210547704.5A CN114741178B (en) | 2022-05-20 | 2022-05-20 | Credit application processing method and device, electronic equipment and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210547704.5A CN114741178B (en) | 2022-05-20 | 2022-05-20 | Credit application processing method and device, electronic equipment and storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN114741178A true CN114741178A (en) | 2022-07-12 |
CN114741178B CN114741178B (en) | 2022-08-23 |
Family
ID=82287584
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202210547704.5A Active CN114741178B (en) | 2022-05-20 | 2022-05-20 | Credit application processing method and device, electronic equipment and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN114741178B (en) |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6389019B1 (en) * | 1998-03-18 | 2002-05-14 | Nec Usa, Inc. | Time-based scheduler architecture and method for ATM networks |
CN112463167A (en) * | 2020-11-11 | 2021-03-09 | 中国农业银行股份有限公司上海市分行 | Bank account dynamic account notification service system |
CN113986097A (en) * | 2021-10-20 | 2022-01-28 | 上海淇玥信息技术有限公司 | Task scheduling method and device and electronic equipment |
-
2022
- 2022-05-20 CN CN202210547704.5A patent/CN114741178B/en active Active
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6389019B1 (en) * | 1998-03-18 | 2002-05-14 | Nec Usa, Inc. | Time-based scheduler architecture and method for ATM networks |
CN112463167A (en) * | 2020-11-11 | 2021-03-09 | 中国农业银行股份有限公司上海市分行 | Bank account dynamic account notification service system |
CN113986097A (en) * | 2021-10-20 | 2022-01-28 | 上海淇玥信息技术有限公司 | Task scheduling method and device and electronic equipment |
Non-Patent Citations (1)
Title |
---|
喻诗祥等: "一种多核ARM平台下用户态定时器的实现", 《计算机工程》 * |
Also Published As
Publication number | Publication date |
---|---|
CN114741178B (en) | 2022-08-23 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN109146490B (en) | Block generation method, device and system | |
US20180365688A1 (en) | Transaction execution and validation in a blockchain | |
CN109639719B (en) | Identity verification method and device based on temporary identifier | |
US20180293580A1 (en) | Systems and methods for processing an access request | |
CN106878250B (en) | Cross-application single-state login method and device | |
CN107465693B (en) | Request message processing method and device | |
US20210166237A1 (en) | Enriching transaction request data for improving fraud prevention systems on a data communication network with user controls injected to back-end transaction approval requests in real-time with transactions | |
CN112073374B (en) | Information interception method, device and equipment | |
CN113760976B (en) | Service processing method, device, equipment and storage medium | |
CN107453872A (en) | A kind of unified safety authentication method and system based on Mesos container cloud platforms | |
CN113132400B (en) | Business processing method, device, computer system and storage medium | |
CN117934075A (en) | Electronic rights issuing method, electronic rights issuing device, electronic equipment and storage medium | |
CN114741178B (en) | Credit application processing method and device, electronic equipment and storage medium | |
CN111835773B (en) | User identity authentication system based on edge calculation | |
US20230208659A1 (en) | Blockchain apparatus and method for mobile edge computing | |
CN111614642A (en) | Method, device and system for registration authentication | |
CN106970915A (en) | A kind of processing method and processing device of operation system Data Migration | |
CN111737262B (en) | Data processing method and device | |
CN113592645A (en) | Data verification method and device | |
CN114398094A (en) | Applet starting method, device, equipment and computer readable storage medium | |
CN111866171A (en) | Message processing method and device, electronic equipment and medium | |
CN111415245A (en) | Account opening method and device | |
CN111681005A (en) | Data interaction method and device and electronic equipment | |
US20230033236A1 (en) | Data processing method and apparatus, computer device, and readable storage medium | |
CN110349025B (en) | Method and device for preventing loss of contract assets based on non-cost transaction output |
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 |