CN110532536B - Rule configuration method and device - Google Patents

Rule configuration method and device Download PDF

Info

Publication number
CN110532536B
CN110532536B CN201910817941.7A CN201910817941A CN110532536B CN 110532536 B CN110532536 B CN 110532536B CN 201910817941 A CN201910817941 A CN 201910817941A CN 110532536 B CN110532536 B CN 110532536B
Authority
CN
China
Prior art keywords
rule
character string
configuration information
attribute value
database
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
CN201910817941.7A
Other languages
Chinese (zh)
Other versions
CN110532536A (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.)
WeBank Co Ltd
Original Assignee
WeBank 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 WeBank Co Ltd filed Critical WeBank Co Ltd
Priority to CN201910817941.7A priority Critical patent/CN110532536B/en
Publication of CN110532536A publication Critical patent/CN110532536A/en
Application granted granted Critical
Publication of CN110532536B publication Critical patent/CN110532536B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/903Querying
    • G06F16/90335Query processing
    • G06F16/90344Query processing by using string matching techniques
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION 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/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes
    • G06Q40/03Credit; Loans; Processing thereof
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION 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/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes
    • G06Q40/04Trading; Exchange, e.g. stocks, commodities, derivatives or currency exchange

Landscapes

  • Engineering & Computer Science (AREA)
  • Business, Economics & Management (AREA)
  • Theoretical Computer Science (AREA)
  • Finance (AREA)
  • Accounting & Taxation (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Databases & Information Systems (AREA)
  • Development Economics (AREA)
  • Economics (AREA)
  • Marketing (AREA)
  • Strategic Management (AREA)
  • Technology Law (AREA)
  • General Business, Economics & Management (AREA)
  • General Engineering & Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Computational Linguistics (AREA)
  • Financial Or Insurance-Related Operations Such As Payment And Settlement (AREA)

Abstract

The invention discloses a rule configuration method and a rule configuration device, which are suitable for a banking system, wherein the method comprises the following steps: acquiring configuration information input by a user, determining a rule template corresponding to the configuration information, wherein the rule template is an execution logic which is preset in a banking system and has a rule result determined by rule conditions, calling the rule template corresponding to the configuration information, generating a rule character string corresponding to the configuration information, and storing the rule character string corresponding to the configuration information into a rule database. The technical scheme is used for reducing the requirement on the user specialty and reducing the workload of the user.

Description

Rule configuration method and device
Technical Field
The embodiment of the invention relates to the field of financial science (Fintech), in particular to a rule configuration method and device.
Background
With the development of computer technology, more and more technologies are applied in the financial field, the traditional financial industry is gradually changed to the financial technology, and rule configuration technology is not exceptional, but the rule configuration technology is also required to be higher due to the requirements of safety and instantaneity of the financial and payment industries.
In the rule configuration of the existing banking system, a user configures the business rules one by one according to product attributes, client attributes, borrowing attributes and the like of banking business, and combines the business rules into codes with execution logic, wherein the execution logic codes indicate rule conditions and actions of the business rules, for example, the user borrows the data according with certain rule conditions, and interest and transaction are reduced according to a preset reduction and exemption amount formula.
However, in this manner, the user needs to configure all the attributes related to the business rule one by writing codes, and needs to test the configured business rule, so that the requirement on the professional performance of the user is high and the workload of the user is high.
Disclosure of Invention
The embodiment of the invention provides a rule configuration method and device, which are used for reducing the requirements on the user specificity and reducing the workload of the user.
The rule configuration method provided by the embodiment of the invention is suitable for a banking system;
the method comprises the following steps:
acquiring configuration information input by a user; the configuration information comprises a rule condition attribute value and a rule result attribute value;
determining a rule template corresponding to the configuration information; the rule template is an execution logic which is preset in the banking system and has a rule result determined by rule conditions;
and calling a rule template corresponding to the configuration information, generating a rule character string corresponding to the configuration information and storing the rule character string corresponding to the configuration information into a rule database.
In the above technical solution, configuration information input by a user is obtained, and a corresponding rule template is called according to the configuration information, where the rule template is preset in a banking system and has execution logic for determining a rule result through a rule condition, and the generated rule string is execution logic for indicating a specific rule condition attribute value and a rule result attribute value, and the banking system can execute the corresponding logic according to the rule string. The rule template is a template after abstracting banking business, a user can only configure attribute values of rule conditions and attribute values of rule results of the banking business, a banking business system can combine the rule template to generate a character string with execution logic, the professional requirement on the user is reduced, and the workload of the user on business rule configuration is reduced. Furthermore, the business rule configured by the technical scheme does not need to be tested, and only logic correctness in the rule template is ensured in the initial stage.
Optionally, after the storing the rule string corresponding to the configuration information in the rule database, the method further includes:
obtaining an object to be matched; the object to be matched comprises a conditional attribute value to be matched;
determining a first rule character string matched with the object to be matched according to the condition attribute value to be matched and the rule condition attribute value indicated by each rule character string in the rule database;
and determining a rule result attribute value indicated by the first rule character string.
Optionally, the determining, according to the condition attribute value to be matched and the rule condition attribute value indicated by each rule string in the rule database, the first rule string matched with the object to be matched includes:
and according to the rule priority indicated by each rule string in the rule database, sequentially matching the condition attribute value to be matched with the rule condition attribute value indicated by each rule string one by one, and determining a first rule string matched with the object to be matched.
According to the technical scheme, the rule character string corresponding to the condition attribute value is matched from the rule database according to the condition attribute value of the object to be matched, and the rule result attribute value indicated by the rule character string is determined, so that a banking system can execute corresponding result actions.
Optionally, after the storing the rule string corresponding to the configuration information in the rule database, the method further includes:
acquiring modification information input by a user; the modification information is used for indicating modification of a second rule character string, and the second rule character string is any character string in the rule database;
determining a rule template corresponding to the modification information;
and calling a rule template corresponding to the modification information to generate a rule character string corresponding to the modification information, and replacing the rule character string corresponding to the modification information with the second rule character string.
In the technical scheme, when the business rule of the banking system is modified, a user can input modification information, the banking system generates a rule character string corresponding to the modification information according to the modification information, and replaces the original rule character string with the rule character string corresponding to the modification information, so that the rule character string is modified, the logic of the rule code is not required to be modified (rule configuration attribute and control logic are not required to be adjusted) by the user, and the modified code is not required to be tested.
Optionally, the rule condition attribute values are multiple, and the multiple rule condition attribute values at least include one or a combination of the following: customer attribute value, product attribute value, transaction object attribute value.
Correspondingly, the embodiment of the invention also provides a rule configuration device which is suitable for the banking system, and the device comprises:
the acquisition unit is used for acquiring configuration information input by a user; the configuration information comprises a rule condition attribute value and a rule result attribute value;
the determining unit is used for determining a rule template corresponding to the configuration information; the rule template is an execution logic which is preset in the banking system and has a rule result determined by rule conditions;
and the processing unit is used for calling the rule template corresponding to the configuration information, generating the rule character string corresponding to the configuration information and storing the rule character string corresponding to the configuration information into a rule database.
Optionally, the processing unit is further configured to:
after the rule character strings corresponding to the configuration information are stored in a rule database, controlling the acquisition unit to acquire an object to be matched; the object to be matched comprises a conditional attribute value to be matched;
determining a first rule character string matched with the object to be matched according to the condition attribute value to be matched and the rule condition attribute value indicated by each rule character string in the rule database;
and determining a rule result attribute value indicated by the first rule character string.
Optionally, the processing unit is specifically configured to:
and according to the rule priority indicated by each rule string in the rule database, sequentially matching the condition attribute value to be matched with the rule condition attribute value indicated by each rule string one by one, and determining a first rule string matched with the object to be matched.
Optionally, the processing unit is further configured to:
after the rule character strings corresponding to the configuration information are stored in a rule database, controlling the acquisition unit to acquire modification information input by a user; the modification information is used for indicating modification of a second rule character string, and the second rule character string is any character string in the rule database;
determining a rule template corresponding to the modification information;
and calling a rule template corresponding to the modification information to generate a rule character string corresponding to the modification information, and replacing the rule character string corresponding to the modification information with the second rule character string.
Optionally, the rule condition attribute values are multiple, and the multiple rule condition attribute values at least include one or a combination of the following: customer attribute value, product attribute value, transaction object attribute value.
Accordingly, an embodiment of the present invention further provides a computing device, including:
a memory for storing program instructions;
and the processor is used for calling the program instructions stored in the memory and executing the rule configuration method according to the obtained program.
Accordingly, an embodiment of the present invention further provides a computer-readable nonvolatile storage medium, which includes computer-readable instructions that, when read and executed by a computer, cause the computer to execute the rule configuration method described above.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings that are needed in the description of the embodiments will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a schematic diagram of a system architecture according to an embodiment of the present invention;
FIG. 2 is a visual interface provided by an embodiment of the present invention;
fig. 3 is a flow chart of a rule configuration method according to an embodiment of the present invention;
FIG. 4 is a flowchart illustrating another rule configuration method according to an embodiment of the present invention;
fig. 5 is a flow chart of a rule matching method according to an embodiment of the present invention;
fig. 6 is a schematic structural diagram of a rule configuration device according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention will be described in further detail below with reference to the accompanying drawings, and it is apparent that the described embodiments are only some embodiments of the present invention, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
In banking system, taking loan service system as an example, the whole loan process involves loan product attribute, loan client attribute, borrowing attribute, accounting transaction attribute, etc., and concretely, the loan product attribute includes: the payment period, the payment plan type, the payment sequence, the forward calculation and lifting rule, the five-stage classification and the like; the customer attributes include: enterprise scale, industry direction, credit line, etc.; the borrowing attribute includes: borrowing balance, borrowing state, overdue days, accumulated overdue days and the like; accounting transaction types include: payouts, repayment, interest meter withdrawals, verification and verification repayment, and the like. The user needs to configure all the attributes related to the business rules of banking business one by one in a mode of writing codes, and needs to test the configured business rules, so that the requirements on the specialization of the user are high and the workload of the user is high. And when changing for any business rule, the user needs to change the code in the background and test the changed code.
In order to reduce the complexity of the service rule configuration, reduce the requirement on the user specificity and reduce the user workload, the embodiment of the invention provides a service rule configuration method, specifically, various transactions in a banking system are abstracted into events, service requirements are abstracted into conditions (or rules), client attributes, product attributes and transaction object attributes are abstracted into configuration attributes, execution logic under condition branching is abstracted into actions, and high-abstraction service rules are realized according to the abstracted events, conditions, configuration attributes and actions, and when a transaction event is triggered, the transaction actions configured by the service rules are executed under the condition that the transaction objects are successfully matched with the transaction conditions (or rules).
Among them, events such as: paying, repayment, counting and lifting, repayment account changing and the like; conditions (or rules) such as: such as a free condition, a five-stage classification calculation rule condition, a repayment sequence rule and the like; configuration attributes are as follows: the accumulated overdue number of enterprises, the enterprise scale, the product accounting mechanism, the transaction object type, the borrowing term number, the interest rate and the like; the actions are as follows: a free transaction of the amount, an update borrowing five-level classification, a repayment transaction in a particular repayment order, etc. are performed.
Fig. 1 exemplarily shows a system architecture to which the rule configuration method provided by the embodiment of the present invention is applicable, where the system architecture may be a banking system, and the banking system may include a configuration server 101, a database 102, and a generation server 103;
the configuration server 101 may provide a visual interface for a user (service personnel or developer), through which the user configures configuration information of an event, as in fig. 2, which is a visual interface provided in an embodiment of the present invention, where the visual interface provides options such as an event type, a priority, a rule condition, an effective date, an end date, and an execution action for the user, and in addition, the visual interface may also display a configuration grammar sample and an attribute code supported by the configuration event. The configuration server 101 may store the configuration information in the database 102, and in a specific implementation, the database 102 may be selected as a relational database, and the configuration information may be stored in a rule configuration table of the relational database.
The user may also configure a rule template in the configuration server 101, which is execution logic with rule results determined by rule conditions, which the configuration server 101 may store in the database 102, marked by the name (name) of the rule template or the Identity (ID) of the rule template.
The generation server 103 is configured to match the configuration information loaded from the database 102 to the variables in the rule template, further compile a rule string with the actual application logic, and store the rule string in the database 102.
Based on the above description, fig. 3 illustrates an exemplary process of a rule configuration method according to an embodiment of the present invention, where the process may be performed by a rule configuration device, and the device may be located in the banking system.
As shown in fig. 3, the process specifically includes:
step 301, obtaining configuration information input by a user.
Configuration information may be entered by a user through a visual interface, and may include rule condition attribute values and rule result attribute values that may constitute a business rule expression, with the understanding that the rule result attribute values are executed when the rule condition attribute values are satisfied. The business rule expression may be a Drools language. In addition, the configuration information may be that the user selects a corresponding attribute in the visual interface and inputs an attribute value, that is, a selection window with a rule condition attribute and a selection window with a rule result attribute are displayed in the visual interface, the user selects an attribute of a rule condition in the selection window with the rule condition attribute and inputs a corresponding attribute value, and the user selects an attribute of a rule result in the selection window with the rule result attribute and inputs a corresponding attribute value, thereby completing the input of the configuration information.
The configuration information may also include event type, business rule priority, validity period, etc. of the event.
Step 302, determining a rule template corresponding to the configuration information.
The rule templates are execution logic which is preset in the banking system and has rule results determined by rule conditions, and in one implementation manner, different rule templates can be set for different banking businesses, and the rule templates are stored in the banking system. A rule file for storing rule templates may be created in advance in the Classes path of the banking system, and the created rule templates are stored in the rule file. When determining the rule template corresponding to the configuration information, the rule template corresponding to the configuration information can be determined based on banking business corresponding to the configuration information.
In another implementation, one rule template may be set for multiple banking systems, which has high abstraction and may be suitable for different banking.
In creating the rule templates, the rule templates may be created in accordance with a Drools rule engine, and in particular, the rule conditions and rule results may employ Drools language, which may support operators, comparison operators, regular expressions, and so on. The rule template comprises attributes (attributes), rule conditions and rule results, wherein the rule conditions in the rule template consist of one or more conditions, and when all conditions are met, the rule results are executed. The rule condition and rule result in the rule template are null values, and are used for providing corresponding logic templates for configuration information input by a user when the rule character string is generated.
Step 303, calling a rule template corresponding to the configuration information, generating a rule character string corresponding to the configuration information, and storing the rule character string corresponding to the configuration information into a rule database.
And calling a rule template corresponding to the configuration information, and correspondingly matching the corresponding rule condition attribute value and the rule result attribute value into the rule condition and the rule result of the rule template, so as to generate a rule character string with actual execution logic.
For example, the rule condition attribute value is "the customer is a small or mini-enterprise, the credit limit is 100 ten thousand or more and 1000 ten thousand or less", and the rule result attribute value is "the charging and exempting tax, the repayment mode is equal principal (RPT-02), and the grace period is 0 day". The corresponding rule condition is cure.scope in ('3', '4') & & cure.creditbussiness >1000000& & cure.creditbussiness <10000000; the corresponding rule results are: lotflag=1 & & lotflag. Pamethod= 'RPT-02' & lotflag. Graday=0.
The generation of the rule string with execution logic is:
Figure BDA0002186805590000081
in another example, the rule condition attribute value is "the client history overdue accumulated for more than 15 days, or the consecutive overdue days for more than 7 days, or there is currently overdue borrowing", and the rule result attribute value is "the release borrowing grace period is 0, and the number of repayment period is 3, and the repayment manner is equal cost (RPT-02)". The corresponding rule condition is cust.alloverdays >15||cust.con overdays >7||cust existonver= 'true'; the corresponding rule results are: graceday=0 & & lan. Period=3 &lan. Paymethod= 'RPT-02'.
The generation of the rule string with execution logic is:
Figure BDA0002186805590000091
in the above embodiment, configuration information input by a user is obtained, and a corresponding rule template is called according to the configuration information, where the rule template is preset in a banking system and has execution logic for determining a rule result through a rule condition, and the generated rule string is execution logic for indicating a specific rule condition attribute value and a rule result attribute value, and the banking system can execute corresponding logic according to the rule string. The rule template is a template after abstracting banking business, a user can only configure rule condition attribute values and rule result attribute values of the banking business, a banking business system can combine the rule template to generate a character string with execution logic, the professional requirement on the user is reduced, and the workload of the user on business rule configuration is reduced. Furthermore, the business rule configured by the technical scheme does not need to be tested, and only logic correctness in the rule template is ensured in the initial stage. In addition, character strings with execution logic are generated in the rule template based on the rule condition attribute values and the rule result attribute values, and are not configured one by one in a mode of writing codes, so that the efficiency and convenience of rule configuration are improved.
In one implementation, the rule database may be constructed into a Maven structure, specifically, a general and writePomXML () method of an org.kiie.api.build.kieFilesystem (kieFilesystem is a memory file system of Drools) API is called to generate the Maven structure project according to three elements of a unique mark Maven structure project, namely, a group (organization), an artificid and a version (version number) required by the Maven structure specified by a specific project. The rule string may be stored in a predetermined path in a format of drl to a Maven structural engineering, such as src/main/resources/190302122001100.Dr, that is, the rule string may be a rule string in a format of drl in the embodiment of the present invention. The rule database is constructed into a Maven structure, and corresponding rule character strings can be quickly searched from the rule database and used for matching objects to be matched.
In a specific implementation, as in the flowchart shown in fig. 4, after storing a plurality of configuration information in a rule configuration table of the database, starting a banking system, loading a system container of the banking system, querying each configuration information in the rule configuration table, loading a rule drl file stream (corresponding to a loading rule template), matching a rule condition attribute value, a rule result attribute value, a rule priority and a rule term in each configuration information to a variable of a corresponding rule template for each configuration information, compiling and generating drl rule character strings, generating rules of a Maven structure according to the drl rule character strings, and loading the rules into a memory.
The embodiment of the invention can also modify any one of the existing rule character strings in the rule database, and specifically acquire modification information input by a user, wherein the modification information is used for indicating to modify a second rule character string, the second rule character string is any character string in the rule database, a rule template corresponding to the modification information is determined, the rule template corresponding to the modification information is called, the rule character string corresponding to the modification information is generated, and the rule character string corresponding to the modification information is replaced by the second rule character string. The method for generating the rule string according to the modification information and the rule template is similar to the method for generating the rule string, and is not described again.
When the business rule of the banking system is modified, a user can input modification information, the banking system generates a rule character string corresponding to the modification information according to the modification information, and replaces the original rule character string with the rule character string corresponding to the modification information, so that the rule character string is modified, the logic of a rule code is not required to be modified (rule configuration attribute and control logic are not required to be adjusted) by the user, and the modified code is not required to be tested.
The embodiment of the invention has described the implementation manner of generating the rule character string (or modifying the rule character string) and storing the rule character string into the rule database in detail, on the basis of which, the embodiment of the invention provides a manner of using the rule character string in the rule database, specifically, the object to be matched is obtained, the object to be matched can be input and generated by a user through a visual interface, the object to be matched comprises a condition attribute value to be matched, and the first rule character string matched with the object to be matched can be determined according to the condition attribute value to be matched and the rule condition attribute value indicated by each rule character string in the rule database, and then the rule result attribute value indicated by the first rule character string is determined.
The condition attribute values to be matched and the rule condition attribute values indicated by the rule strings can be matched one by one in sequence according to the rule priority indicated by the rule strings in the rule database, and the first rule string matched with the object to be matched is determined.
In a specific implementation, a Drools rule engine may be utilized, where the object to be matched is a Fact (Fact object) to be matched in the Drools rule engine, and the Drools rule engine matches the Fact with rule condition attribute values indicated by drl rule strings in a rule database one by one, determines drl rule strings matched with the object to be matched, and executes rule result attribute values indicated by the matched drl rule strings. In the process shown in fig. 5, when a user triggers an event (such as payment, repayment, metering and lifting, etc.), the banking system creates a Fact under the event, queries a service database according to event object information such as a client ID, a borrowing ID, etc., assigns a client attribute, a product attribute, a borrowing attribute, etc. to the Fact, calls an API class method of Drools (such as org.kie.api.rule.stateless kiesessage.execute ()), carries out rule matching on the Fact by the Drools rule engine, matches the Fact one by one according to the priority of the rule, executes a rule result attribute value indicated by the drl rule attribute string if a drl rule string of the rule condition attribute value matched with the Fact exists, returns a service system execution result, and ends if a drl rule string of the rule condition attribute value matched with the Fact does not exist.
In the embodiment of the invention, the rule character string corresponding to the condition attribute value is matched from the rule database according to the condition attribute value of the object to be matched, and the rule result attribute value indicated by the rule character string is determined, so that the banking system can execute corresponding result actions.
Based on the same inventive concept, fig. 6 illustrates an exemplary structure of a rule configuration apparatus provided in an embodiment of the present invention, where the rule configuration apparatus is applicable to a banking system, and the rule configuration apparatus may perform a flow of a rule configuration method.
The device comprises:
an obtaining unit 601, configured to obtain configuration information input by a user; the configuration information comprises a rule condition attribute value and a rule result attribute value;
a determining unit 602, configured to determine a rule template corresponding to the configuration information; the rule template is an execution logic which is preset in the banking system and has a rule result determined by rule conditions;
and the processing unit 603 is configured to invoke a rule template corresponding to the configuration information, generate a rule string corresponding to the configuration information, and store the rule string corresponding to the configuration information in a rule database.
Optionally, the processing unit 603 is further configured to:
after the rule character strings corresponding to the configuration information are stored in a rule database, the obtaining unit 601 is controlled to obtain an object to be matched; the object to be matched comprises a conditional attribute value to be matched;
determining a first rule character string matched with the object to be matched according to the condition attribute value to be matched and the rule condition attribute value indicated by each rule character string in the rule database;
and determining a rule result attribute value indicated by the first rule character string.
Optionally, the processing unit 603 is specifically configured to:
and according to the rule priority indicated by each rule string in the rule database, sequentially matching the condition attribute value to be matched with the rule condition attribute value indicated by each rule string one by one, and determining a first rule string matched with the object to be matched.
Optionally, the processing unit 603 is further configured to:
after the rule character strings corresponding to the configuration information are stored in a rule database, the acquiring unit 601 is controlled to acquire modification information input by a user; the modification information is used for indicating modification of a second rule character string, and the second rule character string is any character string in the rule database;
determining a rule template corresponding to the modification information;
and calling a rule template corresponding to the modification information to generate a rule character string corresponding to the modification information, and replacing the rule character string corresponding to the modification information with the second rule character string.
Optionally, the rule condition attribute values are multiple, and the multiple rule condition attribute values at least include one or a combination of the following: customer attribute value, product attribute value, transaction object attribute value.
Based on the same inventive concept, an embodiment of the present invention further provides a computing device, including:
a memory for storing program instructions;
and the processor is used for calling the program instructions stored in the memory and executing the rule configuration method according to the obtained program.
Based on the same inventive concept, the embodiments of the present invention also provide a computer-readable nonvolatile storage medium including computer-readable instructions, which when read and executed by a computer, cause the computer to perform the rule configuration method described above.
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 flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations 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.
While preferred embodiments of the present invention have been described, additional variations and modifications in those embodiments may occur to those skilled in the art once they learn of the basic inventive concepts. It is therefore intended that the following claims be interpreted as including the preferred embodiments and all such alterations and modifications as fall within the scope of the invention.
It will be apparent to those skilled in the art that various modifications and variations can be made to the present invention without departing from the spirit or scope of the invention. Thus, it is intended that the present invention also include such modifications and alterations insofar as they come within the scope of the appended claims or the equivalents thereof.

Claims (8)

1. A rule configuration method, suitable for use in a banking system, the method comprising:
acquiring configuration information input by a user; the configuration information comprises a rule condition attribute value and a rule result attribute value;
determining a rule template corresponding to the configuration information according to banking business corresponding to the configuration information; the rule template is an execution logic which is preset in the banking system and is provided with a rule result determined by rule conditions, and the rule conditions and the rule result in the rule template adopt a Drools language;
calling a rule template corresponding to the configuration information to generate a rule character string corresponding to the configuration information;
calling a first API interface of a Drools rule engine to generate a rule database with a Maven structure;
storing the rule character strings corresponding to the configuration information into the rule database in a drl format according to a preset path, wherein the rule character strings stored in the rule database are drl rule character strings;
after the rule character strings corresponding to the configuration information are stored in the rule database according to the preset path in the drl format, the method further comprises the following steps:
acquiring a user trigger event, and creating a fact object according to the user trigger event;
inquiring a service database according to a client identifier and/or a borrowing identifier corresponding to the user trigger event so as to assign a client attribute, a product attribute and a borrowing attribute to the fact object;
calling a second API interface of the Drools rule engine, and delivering the fact object after assignment as an object to be matched to the Drools rule engine for rule matching;
the Drools rule engine matches the object to be matched with the rule condition attribute values indicated by each drl rule character string one by one according to the client attribute, the product attribute and the borrowing attribute in the object to be matched according to the rule priority sequence of each drl rule character string in the rule database;
the Drools rule engine, when determining a drl rule string that matches an object to be matched, executes the rule result attribute value indicated by the drl rule string that matches the object to be matched.
2. The method of claim 1, further comprising, after storing the rule string corresponding to the configuration information in a rule database:
acquiring modification information input by a user; the modification information is used for indicating modification of a second rule character string, and the second rule character string is any character string in the rule database;
determining a rule template corresponding to the modification information;
and calling a rule template corresponding to the modification information to generate a rule character string corresponding to the modification information, and replacing the rule character string corresponding to the modification information with the second rule character string.
3. A method according to claim 1 or 2, wherein the rule condition attribute value is a plurality of rule condition attribute values, the plurality of rule condition attribute values comprising at least one or a combination of:
customer attribute value, product attribute value, transaction object attribute value.
4. A rule configuration device adapted for use in a banking system, said device comprising:
the acquisition unit is used for acquiring configuration information input by a user; the configuration information comprises a rule condition attribute value and a rule result attribute value;
the determining unit is used for determining a rule template corresponding to the configuration information according to banking business corresponding to the configuration information; the rule template is an execution logic which is preset in the banking system and is provided with a rule result determined by rule conditions, and the rule conditions and the rule result in the rule template adopt a Drools language;
the processing unit is used for calling the rule template corresponding to the configuration information and generating a rule character string corresponding to the configuration information; calling a first API interface of a Drools rule engine to generate a rule database with a Maven structure; storing the rule character strings corresponding to the configuration information into the rule database in a drl format according to a preset path, wherein the rule character strings stored in the rule database are drl rule character strings;
the processing unit is further configured to:
acquiring a user trigger event, and creating a fact object according to the user trigger event;
inquiring a service database according to a client identifier and/or a borrowing identifier corresponding to the user trigger event so as to assign a client attribute, a product attribute and a borrowing attribute to the fact object;
calling a second API interface of the Drools rule engine, and delivering the fact object after assignment as an object to be matched to the Drools rule engine for rule matching;
the Drools rule engine matches the object to be matched with the rule condition attribute values indicated by each drl rule character string one by one according to the client attribute, the product attribute and the borrowing attribute in the object to be matched according to the rule priority sequence of each drl rule character string in the rule database;
the Drools rule engine, when determining a drl rule string that matches an object to be matched, executes the rule result attribute value indicated by the drl rule string that matches the object to be matched.
5. The apparatus of claim 4, wherein the processing unit is further to:
after the rule character strings corresponding to the configuration information are stored in a rule database, controlling the acquisition unit to acquire modification information input by a user; the modification information is used for indicating modification of a second rule character string, and the second rule character string is any character string in the rule database;
determining a rule template corresponding to the modification information;
and calling a rule template corresponding to the modification information to generate a rule character string corresponding to the modification information, and replacing the rule character string corresponding to the modification information with the second rule character string.
6. The apparatus of claim 4 or 5, wherein the rule condition attribute value is a plurality of rule condition attribute values, the plurality of rule condition attribute values comprising at least one or a combination of:
customer attribute value, product attribute value, transaction object attribute value.
7. A computing device, comprising:
a memory for storing program instructions;
a processor for invoking program instructions stored in said memory and for performing the method according to any of claims 1 to 3 in accordance with the obtained program.
8. A computer readable non-transitory storage medium comprising computer readable instructions which, when read and executed by a computer, cause the computer to perform the method of any of claims 1 to 3.
CN201910817941.7A 2019-08-30 2019-08-30 Rule configuration method and device Active CN110532536B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910817941.7A CN110532536B (en) 2019-08-30 2019-08-30 Rule configuration method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910817941.7A CN110532536B (en) 2019-08-30 2019-08-30 Rule configuration method and device

Publications (2)

Publication Number Publication Date
CN110532536A CN110532536A (en) 2019-12-03
CN110532536B true CN110532536B (en) 2023-07-14

Family

ID=68665687

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910817941.7A Active CN110532536B (en) 2019-08-30 2019-08-30 Rule configuration method and device

Country Status (1)

Country Link
CN (1) CN110532536B (en)

Families Citing this family (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111177214B (en) * 2019-12-19 2024-02-09 腾讯云计算(北京)有限责任公司 Event linkage processing method, device and system, electronic equipment and storage medium
CN111399818B (en) * 2020-03-17 2023-10-20 深圳市卡牛科技有限公司 Recommendation engine design method, recommendation engine design device, server and storage medium
CN112087486B (en) * 2020-07-30 2022-07-12 山东浪潮通软信息科技有限公司 Data integration method, equipment and medium for Internet of things equipment
CN112114970A (en) * 2020-09-28 2020-12-22 中国建设银行股份有限公司 Rule configuration method and device
CN113468239A (en) * 2021-06-23 2021-10-01 苏州琅润达检测科技有限公司 Method and system for realizing internet of things industry usage statistics based on rule engine
CN113568612B (en) * 2021-07-05 2024-03-08 金蝶软件(中国)有限公司 Service configuration method, device, computer equipment and storage medium
CN113553309A (en) * 2021-07-28 2021-10-26 恒安嘉新(北京)科技股份公司 Log template determination method and device, electronic equipment and storage medium
CN114969127B (en) * 2022-07-19 2022-10-28 中邮消费金融有限公司 Reconciliation method, reconciliation system and storage medium for automatically combining reconciliation transactions
CN116204177B (en) * 2023-03-17 2023-10-03 湖北坤盈数字科技有限公司 System service module development coupling assembly method and device and computer equipment

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2014085760A1 (en) * 2012-11-29 2014-06-05 Genesys Telecommunications Laboratories, Inc. Workload distribution with resource awareness
CN107220757A (en) * 2017-05-23 2017-09-29 上海最会保网络科技有限公司 A kind of system and method for rule configuration and parsing
CN108647049A (en) * 2018-03-18 2018-10-12 平安科技(深圳)有限公司 Configurableization system, method, equipment and the storage medium of rule-based engine
CN109086031A (en) * 2018-06-28 2018-12-25 阿里巴巴集团控股有限公司 A kind of operational decision making method and apparatus of rule-based engine
CN109144374A (en) * 2018-09-27 2019-01-04 范若愚 Method for processing business, system and relevant device based on visualization regulation engine

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2014085760A1 (en) * 2012-11-29 2014-06-05 Genesys Telecommunications Laboratories, Inc. Workload distribution with resource awareness
CN107220757A (en) * 2017-05-23 2017-09-29 上海最会保网络科技有限公司 A kind of system and method for rule configuration and parsing
CN108647049A (en) * 2018-03-18 2018-10-12 平安科技(深圳)有限公司 Configurableization system, method, equipment and the storage medium of rule-based engine
CN109086031A (en) * 2018-06-28 2018-12-25 阿里巴巴集团控股有限公司 A kind of operational decision making method and apparatus of rule-based engine
CN109144374A (en) * 2018-09-27 2019-01-04 范若愚 Method for processing business, system and relevant device based on visualization regulation engine

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
王世春."面向银行信贷的规则引擎系统设计与实现".《中国优秀硕士学位论文全文数据库》.2017,(第3期),第1-59页. *

Also Published As

Publication number Publication date
CN110532536A (en) 2019-12-03

Similar Documents

Publication Publication Date Title
CN110532536B (en) Rule configuration method and device
US11487529B2 (en) User interface that integrates plural client portals in plural user interface portions through sharing of one or more log records
EP3631618B1 (en) Automated dependency analyzer for heterogeneously programmed data processing system
US20180330433A1 (en) Attributing meanings to data concepts used in producing outputs
CN107924406A (en) Selection is used for the inquiry performed to real-time stream
US20210350262A1 (en) Automated decision platform
CN108268615B (en) Data processing method, device and system
CN111881042A (en) Automatic test script generation method and device and electronic equipment
US10606843B2 (en) Irreducible modules
US20140012830A1 (en) Data verification system
CN114969127B (en) Reconciliation method, reconciliation system and storage medium for automatically combining reconciliation transactions
CN111209283A (en) Data processing method and device
CN115269085A (en) Mobile bank page display method and device
AU2019404304B2 (en) Gain and loss computation for cryptocurrency transactions
WO2022005911A1 (en) A machine learning framework and method for using the same
US10013538B1 (en) Matching accounts identified in two different sources of account data
US20170316069A1 (en) Method of binding data and processes with the use of universal computing elements
US20220129283A1 (en) Methods, systems, and media for generating an updated workflow for an operation executable by a computing device
US20230107397A1 (en) Software orchestration framework for implementing application programming interfaces
CN113205421A (en) Accounting method and device for financial products
CN117149165A (en) Service code generation method, device and server
CN117396852A (en) High-speed host application tool
CN115829742A (en) Account record generation method and device
CN114416805A (en) Data checking method and device, computer equipment and storage medium
CN117668031A (en) Data checking method and device

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