CN113254063A - Gray level verification filter and filtering method - Google Patents

Gray level verification filter and filtering method Download PDF

Info

Publication number
CN113254063A
CN113254063A CN202110733129.3A CN202110733129A CN113254063A CN 113254063 A CN113254063 A CN 113254063A CN 202110733129 A CN202110733129 A CN 202110733129A CN 113254063 A CN113254063 A CN 113254063A
Authority
CN
China
Prior art keywords
calling
parameters
flow control
new version
scene
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202110733129.3A
Other languages
Chinese (zh)
Other versions
CN113254063B (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.)
Sichuan XW Bank Co Ltd
Original Assignee
Sichuan XW Bank 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 Sichuan XW Bank Co Ltd filed Critical Sichuan XW Bank Co Ltd
Priority to CN202110733129.3A priority Critical patent/CN113254063B/en
Publication of CN113254063A publication Critical patent/CN113254063A/en
Application granted granted Critical
Publication of CN113254063B publication Critical patent/CN113254063B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/71Version control; Configuration management
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3688Test management for test execution, e.g. scheduling of test suites

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Stored Programmes (AREA)

Abstract

The invention belongs to the technical field of computers, and particularly relates to a gray scale verification filter which comprises a flow control proportion, calling times and parameters of a gray scale method expected to be executed, wherein the flow control proportion, the calling times and the parameters are set in the filter; randomly generating 1 integer M smaller than N according to the flow control proportion; generating 1 flow control value R, wherein R is less than or equal to N; the calling times are the maximum calling time value MAX preset in the new version, and the actual calling time value CUR of each scene to the new version is compared with the maximum calling time value MAX; setting parameters of the expected execution gray method in the filter, converting parameter variables of the expected execution gray method into method entry objects by utilizing a reflection technology, comparing non-empty parameters of the converted objects with parameters of the calling method entry objects, and passing parameter scene verification with the same comparison. The service scenes verified by the three items can call the new version, so that only a small part of the service scenes call the new version, and stable and safe transition of iterative upgrade is realized.

Description

Gray level verification filter and filtering method
Technical Field
The invention belongs to the technical field of computers, and particularly relates to a gray level verification filter and a filtering method.
Background
Under the design of a large-scale distributed system, the design of the mainstream system at present adopts micro-servitization. RPC and MQ are commonly used between services for synchronous or asynchronous interaction. In some iterative task scenarios, a time window plus production environment and a mode of gray scale verification environment rolling distribution are often adopted.
However, the existing mainstream gray level flow verification scheme does not have the functions of controllable verification data and controllable service scene, so in the gray level verification link, due to the problem handling process and the limitation of timely effectiveness, a large number of abnormal conditions may occur or no abnormal conditions occur, but the service is not performed according to the normal expected logic; due to the timeliness of the business verification, a large number of potential hazard abnormal conditions can occur, which are unacceptable for the financial system.
At present, in some services which are developed agilely, iteration is frequent, one version comprises various iteration requirements, when a problem occurs in a gray scale verification environment, one requirement often cannot be returned to the original version directly, the problem needs to be repaired again, and the gray scale verification environment is tested and dealt with quickly, so that a long time flow exists, and the problem occurring in the gray scale verification cannot be responded and dealt with quickly.
Disclosure of Invention
The invention provides a gray scale verification filter and a filtering method, which aim to solve the technical problems in the background art.
In order to achieve the purpose, the invention provides the following technical scheme:
a gray level verification filter includes a gray level control variable set in the filter for filtering a service scene;
the gray control variable comprises a flow control proportion, calling times and parameters of a gray method expected to be executed;
the flow control proportion generates 1 integer M smaller than N for each service scene based on a probability random theory, wherein N is an integer; generating 1 flow control value R, wherein R is less than or equal to N;
the calling times are gray level calling time control variables, namely a preset maximum calling time value MAX in a new version; comparing the actual calling frequency value CUR of each scene to the new version with the maximum calling frequency MAX;
the filter is also provided with parameters of the expected execution gray method, the reflection technology is utilized to convert the parameter variables of the expected execution gray method into method entry objects, the non-empty parameters of the converted objects are compared with the parameters of the calling method entry objects, and if the comparison conditions are consistent, the objects are verified through the parameter scene.
Preferably, the value of N is 10 times of the flow control value R.
Still further, the system also comprises a control interface used for setting specific parameters of the flow control proportion, the parameters of the expected gray scale execution method and the calling times.
By setting the control interface, the flow control proportion, the parameters of the expected execution gray method and the calling times can be changed according to the actual situation, so that the method is more flexible and has stronger practicability.
A gray scale verification method comprises the following steps:
step 1: defining a flow control proportion, and generating 1 integer M smaller than N based on a probability random theory in each service scene, wherein N is an integer; generating 1 flow control value R, wherein R is less than or equal to N;
step 2: judging whether the randomly generated M is larger than R, if any one service scene is larger than R, executing the following steps, and directly calling the original version by the service scene; if M generated by any service scene based on the probability random theory is less than or equal to R, executing step 3;
and step 3: defining a calling time control variable for the new version, namely presetting a maximum calling time value MAX of each service scene to the new version;
and 4, step 4: judging whether the actual calling frequency value CUR of each scene to the new version is smaller than a preset maximum calling frequency value MAX or not; if the CUR is less than MAX, executing step 5; if the CUR is greater than or equal to the MAX, the following steps are not executed, and the original version is directly called by the service scene; defining the actual calling frequency value CUR of the new version as an atomic variable, and realizing atomic self-increment once calling;
and 5: the parameter variables of the expected execution gray scale method of each service scene are converted into method entry objects by utilizing a reflection technology, the non-empty parameters of the converted objects are compared with the parameters of the calling method entry objects, the comparison condition is consistent, the reference scene calls a new version, and if the comparison condition is inconsistent, the scene calls an old version.
Step 6: defining the actual calling frequency value CUR of the new version as an atomic variable, and realizing atomic self-increment once calling;
preferably, the value of N is 10 times of the flow control value R.
Compared with the prior art, the invention has the beneficial effects that: 1. the invention sets the flow control proportion, the calling times and the parameters of the expected execution gray scale method; most service scenes are filtered in the previous period, only a small number of service scenes are needed to call a new version, and under the safe and reliable conditions, the working personnel gradually open parameters through a control interface, so that the gray level verification result is reliable and stable, and stable and safe transition of iterative upgrading is realized.
2. Because the service scenes for calling the new version at the early stage are few, the abnormal condition of the service verification is simple and controllable to process, the response is rapid, the version rollback is not needed, and the influence on the dependent service is small.
3. The gray level verification is controllable through the combination of the control interface and the filter, and the comprehensiveness, accuracy and influence range controllability of the business verification are ensured by combining the verification method of the business scene coverage gray level verification.
Drawings
FIG. 1 is a schematic view of the filter interception 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.
Referring to fig. 1, a preferred embodiment of the present invention will be described in detail;
a gray level verification filter includes a gray level control variable set in the filter for filtering a service scene;
the gray control variable comprises a flow control proportion, calling times and parameters of a gray method expected to be executed;
the flow control proportion generates 1 integer M smaller than N based on a probability random theory, wherein N is an integer; generating 1 flow control value R, wherein R is less than or equal to N; n = 1000; r = 100; the M is a random number generated by the filter aiming at each service scene;
the calling times are gray level calling time control variables, namely a preset maximum calling time value MAX in a new version; comparing the actual calling frequency value CUR of each scene to the new version with the maximum calling frequency MAX;
the parameters of the expected execution gray scale method convert the parameter variables of the expected execution gray scale method into method entry objects by utilizing a reflection technology, the non-empty parameters of the converted objects are compared with the parameters of the calling method entry objects, and if the comparison conditions are consistent, the objects are verified through parameter scenes.
Preferably, the value of N is 10 times of the flow control value R.
And further, the system also comprises a control interface used for setting specific parameters of the flow control proportion, the parameters of the expected gray scale execution method and the calling times.
A gray scale verification method comprises the following steps:
step 1: defining a flow control proportion, generating 1 integer M smaller than N (N = 1000) for each service scene based on probability random theory, and then generating 1 flow control value R (R = 100);
step 2: judging whether the randomly generated M is greater than R (R = 100), if any one service scene is greater than R (R = 100) based on the probability random theory, not executing the following steps, and directly calling the original version by the service scene; if M generated by any service scene based on the probability random theory is less than or equal to R (R = 100), executing step 3;
for example: if the randomly generated integer M is equal to 50, then M is less than R, then step 3 may be performed; if the randomly generated integer M is equal to 200, if M is larger than R, the following steps are not executed, and the original version is directly called by the service scene;
and step 3: defining a calling time control variable for the new version, namely presetting a maximum calling time value MAX, MAX =100, of each service scene to the new version;
and 4, step 4: judging whether the value CUR of the actual calling times of the new version of each scene is smaller than a preset maximum calling time value MAX (MAX = 100); if the CUR is less than MAX (MAX = 100), performing step 5; if the CUR is greater than or equal to MAX (MAX = 100), the following steps are not executed, and the original version is directly called by the service scene;
for example: if the actual calling times CUR = 50; if the CUR is smaller than MAX, the step 5 is executed through the verification of the step; if the actual calling times CUR = 101; if CUR is greater than MAX, the verification of the step is not passed, and the old version is directly called.
And 5: the parameter variables of the expected execution gray scale method of each service scene are converted into method entry objects by utilizing a reflection technology, the non-empty parameters of the converted objects are compared with the parameters of the calling method entry objects, the comparison condition is consistent, the reference scene calls a new version, and if the comparison condition is inconsistent, the scene calls an old version.
For example: the parameters for which the gray scale method is desired to be performed are set to amt =1000 (transaction amount), cardFlag = his bank card (bank card type).
If the loan request transaction amount at =1000 and cardFlag = his bank card, the service scenario calls a new version through scenario parameter control conditions.
If the transaction amount of the money putting request at this time is amt =1001 and cardFlag = his bank card, the condition of scene parameter control is not passed at this time; the business scenario calls the old version.
Step 6: and defining the actual calling frequency value CUR of the new version as an atomic variable, and realizing atomic self-increment once calling. The atomic self-increment is that the value CUR of the actual calling times of the corresponding service scene is added with 1 every time the new version is called; that is, when CUR =50, CUR is less than MAX; and after it passes the scene parameter control condition of step 5, CUR = 51;
it will be evident to those skilled in the art that the invention is not limited to the details of the foregoing illustrative embodiments, and that the present invention may be embodied in other specific forms without departing from the spirit or essential attributes thereof. The present embodiments are therefore to be considered in all respects as illustrative and not restrictive, the scope of the invention being indicated by the appended claims rather than by the foregoing description, and all changes which come within the meaning and range of equivalency of the claims are therefore intended to be embraced therein. Any reference sign in a claim should not be construed as limiting the claim concerned.
Furthermore, it should be understood that although the present description refers to embodiments, not every embodiment may contain only a single embodiment, and such description is for clarity only, and those skilled in the art should integrate the description, and the embodiments may be combined as appropriate to form other embodiments understood by those skilled in the art.

Claims (6)

1. A gray scale verification filter comprising a gray scale control variable for filtering a service scene set in the filter;
the gray control variable comprises a flow control proportion, calling times and parameters of a gray method expected to be executed;
the flow control proportion generates 1 integer M smaller than N based on a probability random theory, wherein N is an integer; generating 1 flow control value R, wherein R is less than or equal to N;
the calling times are gray level calling time control variables, namely a preset maximum calling time value MAX in a new version; comparing the actual calling frequency value CUR of each scene to the new version with the maximum calling frequency MAX;
the parameters of the expected execution gray scale method convert the parameter variables of the expected execution gray scale method of each service scene into method entry objects by using a reflection technology, and the non-empty parameters of the converted objects are compared with the parameters of the calling method entry objects.
2. A gamma verification filter as claimed in claim 1, wherein: and the value of N is 10 times of the flow control value R.
3. A gamma verification filter as claimed in claim 1 or claim 2 wherein: and the control interface is used for setting the flow control proportion, parameters of the expected execution gray scale method and specific parameters of the calling times.
4. A gray level verification filtering method is characterized in that: the method comprises the following steps:
step 1: defining a flow control proportion, and generating 1 integer M smaller than N based on a probability random theory in each service scene, wherein N is an integer; generating 1 flow control value R, wherein R is less than or equal to N;
step 2: judging whether the randomly generated M is larger than R, if any one service scene is larger than R, executing the following steps, and directly calling the original version by the service scene; if M generated by any service scene based on the probability random theory is less than or equal to R, executing step 3;
and step 3: defining a calling time control variable for the new version, namely presetting a maximum calling time value MAX of each service scene to the new version;
and 4, step 4: judging whether the actual calling frequency value CUR of each scene to the new version is smaller than a preset maximum calling frequency value MAX or not; if the CUR is less than MAX, executing step 5; if the CUR is greater than or equal to the MAX, the following steps are not executed, and the original version is directly called by the service scene;
and 5: the parameter variables of the expected execution gray scale method of each service scene are converted into method entry objects by utilizing a reflection technology, the non-empty parameters of the converted objects are compared with the parameters of the calling method entry objects, the comparison condition is consistent, the reference scene calls a new version, and if the comparison condition is inconsistent, the scene calls an old version.
5. The gray scale verification filtering method according to claim 4, wherein: further comprising the step 6: and defining the actual calling frequency value CUR of the new version as an atomic variable, and realizing atomic self-increment once calling.
6. A gray scale verification filtering method according to claim 4 or 5, characterized in that: and the value of N is 10 times of the flow control value R.
CN202110733129.3A 2021-06-30 2021-06-30 Gray level verification filter and filtering method Active CN113254063B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110733129.3A CN113254063B (en) 2021-06-30 2021-06-30 Gray level verification filter and filtering method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110733129.3A CN113254063B (en) 2021-06-30 2021-06-30 Gray level verification filter and filtering method

Publications (2)

Publication Number Publication Date
CN113254063A true CN113254063A (en) 2021-08-13
CN113254063B CN113254063B (en) 2021-09-21

Family

ID=77190263

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110733129.3A Active CN113254063B (en) 2021-06-30 2021-06-30 Gray level verification filter and filtering method

Country Status (1)

Country Link
CN (1) CN113254063B (en)

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109542410A (en) * 2018-11-29 2019-03-29 江苏满运软件科技有限公司 Rule engine system, method, equipment and storage medium
CN109564542A (en) * 2016-08-08 2019-04-02 索尼公司 Information processing unit, information processing method, program and information processing system
CN109814910A (en) * 2018-12-14 2019-05-28 深圳壹账通智能科技有限公司 Automate gray scale dissemination method, device, computer system and storage medium
CN111475365A (en) * 2019-12-10 2020-07-31 南京新贝金服科技有限公司 Label type AB testing method and system based on cookie
CN111600930A (en) * 2020-04-09 2020-08-28 网宿科技股份有限公司 Micro-service request traffic management method, device, server and storage medium
CN111858312A (en) * 2020-06-24 2020-10-30 广州亚美信息科技有限公司 Page display method and device of application program, computer equipment and storage medium
CN111897542A (en) * 2020-08-31 2020-11-06 北京三快在线科技有限公司 Method and device for gray scale release
CN112000348A (en) * 2020-07-28 2020-11-27 金蝶医疗软件科技有限公司 Control method and device for service gray release and computer equipment
CN112073320A (en) * 2020-11-12 2020-12-11 深圳壹账通智能科技有限公司 API (application program interface) gray level release method and device based on cloud gateway and computer equipment
CN112087325A (en) * 2020-08-21 2020-12-15 烽火通信科技股份有限公司 Gray scale publishing method, device, equipment and readable storage medium

Patent Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109564542A (en) * 2016-08-08 2019-04-02 索尼公司 Information processing unit, information processing method, program and information processing system
US20190138435A1 (en) * 2016-08-08 2019-05-09 Sony Corporation Information processing apparatus, information processing method, program, and information processing system
CN109542410A (en) * 2018-11-29 2019-03-29 江苏满运软件科技有限公司 Rule engine system, method, equipment and storage medium
CN109814910A (en) * 2018-12-14 2019-05-28 深圳壹账通智能科技有限公司 Automate gray scale dissemination method, device, computer system and storage medium
CN111475365A (en) * 2019-12-10 2020-07-31 南京新贝金服科技有限公司 Label type AB testing method and system based on cookie
CN111600930A (en) * 2020-04-09 2020-08-28 网宿科技股份有限公司 Micro-service request traffic management method, device, server and storage medium
CN111858312A (en) * 2020-06-24 2020-10-30 广州亚美信息科技有限公司 Page display method and device of application program, computer equipment and storage medium
CN112000348A (en) * 2020-07-28 2020-11-27 金蝶医疗软件科技有限公司 Control method and device for service gray release and computer equipment
CN112087325A (en) * 2020-08-21 2020-12-15 烽火通信科技股份有限公司 Gray scale publishing method, device, equipment and readable storage medium
CN111897542A (en) * 2020-08-31 2020-11-06 北京三快在线科技有限公司 Method and device for gray scale release
CN112073320A (en) * 2020-11-12 2020-12-11 深圳壹账通智能科技有限公司 API (application program interface) gray level release method and device based on cloud gateway and computer equipment

Non-Patent Citations (4)

* Cited by examiner, † Cited by third party
Title
SUHRID SATYAL等: ""Business process improvement with the AB-BPM methodology"", 《INFORMATION SYSTEMS》 *
东方陨: ""灰度发布详细架构图&测试方案"", 《HTTPS://BLOG.CSDN.NET/WEIXIN_42498050/ARTICLE/DETAILS/81484939》 *
热云数据: ""灰度测试试验流量"洗牌""", 《HTTPS://ZHUANLAN.ZHIHU.COM/P/129257680》 *
颜振东: ""移动应用灰度发布系统的设计与实现"", 《中国优秀博硕士学位论文全文数据库(硕士) 信息科技辑》 *

Also Published As

Publication number Publication date
CN113254063B (en) 2021-09-21

Similar Documents

Publication Publication Date Title
CN110827032B (en) Intelligent wind control decision method and system and service processing method and system
CN111091358B (en) Unified processing method and system for multiple payment channels
CN111585913B (en) Service flow limiting method based on recovery token and storage medium
CN108845866A (en) The method and apparatus for handling distributed transaction
CN112132674A (en) Transaction processing method and device
CN106503420A (en) The multi-party reconciliation assessment of hospital and supervisory systems and method
CN113254063B (en) Gray level verification filter and filtering method
CN110991992B (en) Processing method and device of business process information, storage medium and electronic equipment
CN106780034A (en) Unilateral account scale domination method and system
CN108021360B (en) Rule processing method, code processing method and related equipment
CN107277108B (en) Method, device and system for processing messages at nodes of block chain
US10341369B2 (en) Security system monitoring techniques by mapping received security score with newly identified security score
CN115080449A (en) Test method, device, equipment, medium and program product
WO2023034791A1 (en) Systems and methods for programmable payments enabled by triggers based on mutual validation
Azamuke et al. Scenario-based synthetic dataset generation for mobile money transactions
CN115375435A (en) Block chain-based dynamic account transaction processing method and device
CN114219629A (en) Fund collection method, device, equipment and medium
CN111161070A (en) Alliance chain optimization method and device based on Ether house
CN114255127A (en) Accounting consistency processing method and device for distributed system
CN112950384A (en) Processing system, method, computer equipment and storage medium based on cache technology
CN109471672A (en) A kind of browser plug-in front and back component interaction method
US11922421B2 (en) Systems and methods for pattern identification with enhanced event stream processing
US20210209597A1 (en) Intelligent Systems for Identifying Transactions Associated with an Institution Impacted by an Event
CN115471041B (en) Identification method, device, equipment and storage medium of black product account
US11461297B1 (en) Ensuring database integrity using a data flow in a graph, such as for use by a wireless telecommunications service provider

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