CN115562674B - Load-aware software configuration parameter adjustment method - Google Patents

Load-aware software configuration parameter adjustment method Download PDF

Info

Publication number
CN115562674B
CN115562674B CN202211200545.8A CN202211200545A CN115562674B CN 115562674 B CN115562674 B CN 115562674B CN 202211200545 A CN202211200545 A CN 202211200545A CN 115562674 B CN115562674 B CN 115562674B
Authority
CN
China
Prior art keywords
configuration
rcv
software
source code
branch
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
CN202211200545.8A
Other languages
Chinese (zh)
Other versions
CN115562674A (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.)
National University of Defense Technology
Original Assignee
National University of Defense Technology
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 National University of Defense Technology filed Critical National University of Defense Technology
Priority to CN202211200545.8A priority Critical patent/CN115562674B/en
Publication of CN115562674A publication Critical patent/CN115562674A/en
Application granted granted Critical
Publication of CN115562674B publication Critical patent/CN115562674B/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/40Transformation of program code
    • G06F8/41Compilation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements 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/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5005Allocation of resources, e.g. of the central processing unit [CPU] to service a request
    • G06F9/5027Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals
    • G06F9/505Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals considering the load

Abstract

The invention discloses a method for adjusting load-aware software configuration parameters, which aims to solve the problem that the software configuration parameters cannot be automatically adjusted to cope with load-sensitive configuration faults at present. The technical proposal is as follows: constructing a configuration parameter adjustment system consisting of a configuration related branch interaction analysis module and a dynamic monitoring module; the configuration related branch interaction analysis module is used for positioning a configuration related branch interaction code segment in the software source code based on a static program analysis method so as to realize code instrumentation; when the software runs, the dynamic monitoring module automatically extracts constraint information which needs to be met by the configuration parameters under the influence of related loads, and when the software loads change, the value of the configuration parameters is automatically adjusted according to the configuration constraint information, so that load sensitive configuration faults are avoided. The invention can effectively obtain the configuration constraint information sensitive to the load, help the user to automatically adjust the value of the configuration parameter so as to meet the requirement of changing the load, and can avoid the configuration fault sensitive to the load.

Description

Load-aware software configuration parameter adjustment method
Technical Field
The invention relates to the field of configuration constraint extraction and configuration fault prevention in large-scale software, in particular to a method for adjusting load-aware software configuration parameters.
Background
With the continuous progress of society, software systems have been widely used in various fields, playing a vital role in modern society, and playing an important role. The configuration plays an important role in improving the functional diversity, the customizable and the adaptability of the software as an important component of the software. The software user can customize different functions by using configuration to select libraries, strategies, rules and the like which are realized differently, and effectively control the resource use of the software so as to adapt to different environments and workloads and meet different requirements of the user. At present, in order to adapt to the load environment and the application demand change, large-scale software systems are developed towards a high configurable direction, so that the reliability and the usability of software services are improved.
However, with the continuous increase of the software scale and the increasing complexity of the running environment, the software user experiences the influence of the corresponding configuration fault while experiencing the convenience of configuration, so that the service failure of the software system frequently occurs, and the software user gradually draws the wide attention of the industry. The load-sensitive configuration faults, namely the configuration faults caused by legal configuration values of the software under a specific load, occupy a large proportion of the software configuration faults. Zuoning Yin et al found in the investigation of the current situation of four common open source base software and one commercial base software configuration fault, the values of the relevant configuration parameters in 46.3% -61.9% of cases all meet the constraint of the corresponding legal value range, but still cause the configuration fault of the software system. The Tianyin Xu et al also found through investigation that up to 53.3% of configuration failures in three open source software and one commercial software were caused by improper values of configuration parameters related to runtime environment and load.
Currently, the existing configuration parameter adjustment technology focuses on configuration-oriented performance optimization, represented by "Understanding and auto-adjusting performance-sensitive configurations (understanding and automatically adjusting performance sensitive configuration parameters)" published by Shu Wang et al in ASPLOS2018 and "White-box analysis over machine learning: modeling performance of configurable systems (configurable software performance model building research based on White box analysis and machine learning)" published by Miguel Velez et al in ICSE2021, a method for describing a relationship model between configuration parameter values and software performance is mainly searched or built, and a configuration parameter value combination for optimizing software performance is quickly searched in a huge value space of software configuration parameters, so that corresponding configuration parameter values are adjusted to improve software performance. However, the above methods all require that legal value ranges of configuration parameters be provided in advance, and the existing methods for obtaining the value ranges of the configuration parameters mainly comprise two types of work. The first type of work is represented by "Do Not Blame Users for Misconfigurations (without user blame for configuration faults)" published by Tianyin Xu et al in SOSP2013, and configuration item constraint information is extracted from software source codes mainly through a static analysis technology, so that a user is guided to set configuration item values in a legal range, and configuration faults caused by artificial factors are prevented. Such work is based primarily on static analysis implementations, and does not take into account the impact of software load on configuration constraints, and thus may lead to load-sensitive configuration failures in the software during configuration parameter adjustment. The second category of work, represented by "Testing Configuration Changes in Context to Prevent Production Failures (test configuration modification in context to prevent production failures)" issued by Xudong Sun et al in OSDI2020, is to avoid configuration failures in the production environment by leveraging the existing test cases of the software system to detect false configuration modifications in advance. However, such work currently simulates only a simple running context, and cannot truly simulate the diverse loads and complex context that a software system faces in a production environment, as well as limited capability for load-sensitive configuration fault prevention.
In summary, how to automatically adjust the configuration parameters of the software sensitive to the load, so as to help the user to effectively cope with the configuration faults sensitive to the load, and improve the reliability of the software, which is a hotspot problem under discussion by those skilled in the art.
Disclosure of Invention
The invention aims to solve the technical problem of providing a load-aware software configuration parameter adjustment method, which solves the problems that the existing software configuration parameter adjustment method does not consider the constraint influence of load on configuration parameters, so that the software configuration parameters cannot be automatically adjusted, the load-sensitive configuration faults cannot be dealt with, and the software reliability is low.
The invention carries out code instrumentation by configuring relevant branch interaction code segments (namely code segments for interacting relevant program variables (simply called configuration variables) and other program variables in branch sentences to influence the running behavior of the software) in the software source code, thereby effectively monitoring the relevant state of the program when the software runs, extracting load sensitive configuration constraint, and adjusting configuration values according to the load sensitive configuration constraint so as to prevent load sensitive configuration faults and timely recovering the normal running of the software.
In order to solve the technical problems, the technical scheme of the invention is as follows: firstly, constructing a configuration parameter adjustment system consisting of a configuration related branch interaction analysis module and a dynamic monitoring module; then, a configuration related branch interaction analysis module reads in a software source code and a configuration parameter name, configures a variable name > binary pair file, and positions a configuration related branch interaction code segment in the software source code based on a static program analysis method to realize code instrumentation; when the software runs, the dynamic monitoring module continuously reads the content of an output file of the instrumentation code during running, constraint information which is required to be met by the configuration parameters under the influence of related loads is automatically extracted, and when the software load changes, the value of the configuration parameters is automatically adjusted according to the configuration constraint information, so that load sensitive configuration faults are avoided.
The invention comprises the following steps:
the first step, a configuration parameter adjusting system is constructed, and the configuration parameter adjusting system consists of a configuration related branch interaction analysis module and a dynamic monitoring module. The configuration related branch interaction analysis module reads in a software source code F and a configuration information file (a binary pair list of < configuration parameter name and configuration variable name > is stored) from a file system, identifies and positions configuration related branch interactions in the software source code F, performs code instrumentation, and outputs the software source code F' after instrumentation into the file system; compiling and linking the F 'by a user to obtain executable software F'; the dynamic monitoring module monitors the output of F 'in a file system during running, extracts and outputs configuration constraint information under the influence of current load, and automatically adjusts the value of a configuration parameter according to relevant configuration constraint information when the current configuration value does not meet the configuration constraint information due to the change of F' load.
The second step, the relevant branch interaction analysis module is configured to read the software source code F and the configuration information file from the file system, locate and identify relevant branch interaction code segments from the software source code F, insert a program probe at the relevant branch interaction code segment position, and output the software source code F' after insertion to the file system, the method is as follows:
2.1 configuration related Branch interaction analysis Module reads in a stored configuration information File from the File System, the configuration information File storing<Configuration parameter name, configuration variable name>Binary pair list, obtaining all configuration parameter names and corresponding configuration variable binary pair sets CS, CS= { in the software source code F from the configuration information file<cn 1 ,cv 1 >,<cn 2 ,cv 2 >,...,<cn n ,cv n >,...,<cn N ,cv N >} wherein cn n For the nth configuration parameter name, cv in CS n For cn in CS n Corresponding configuration variable name, cn in software source code n And cv n Binary pair relationships are disclosed by Shulin Zhou et al, "ConfMapper" in QRS 2016: automated Variable Finding for Configuration Items in Source Code (ConfMapper: automatic searching for configuration variables corresponding to configuration parameters from software Source code) "the slave software Source codeThe method is established by automatically searching configuration parameters corresponding to configuration variables, wherein N is the total number of the configuration parameters in the software source code F, and N is more than or equal to 1 and less than or equal to N;
2.2 resolving the software Source code F by using the Clang front end (version 10.0.0 and above) of the LLVM compiler framework to generate an abstract syntax Tree (Abstract Syntax Tree) AST corresponding to the software Source code F root ,AST root Each node in the software source code F represents a structure in the software source code F, such as a whole source code (transitionunitdecl), a function statement (FunctionDecl), an If branch statement (IfStmt), a function call (CallExpr), a constant string (stringl), binary calculation (binaryoplator), a single variable (DeclRefExpr), a structure body variable (MemberExpr) and the like, and the different structures represent corresponding dependencies in a tree structure, for example, for If branch statements in one function statement, the corresponding IfStmt node is located in a subtree with the FunctionDecl node as a root node;
2.3 in abstract syntax tree AST root Middle positioning and cv 1 ,cv 2 ,...,cv n ,...,cv N The related branch interaction method specifically comprises the following steps:
2.3.1 in the abstract syntax tree AST root Related traversal interfaces (traversal interfaces in the form of VisitNodeType) provided by Clang (version 10.0.0 and above) are used, wherein NodeType refers to node types in an abstract syntax tree, specific types are as described in step 2.2, interfaces used in the traversal process comprise VisitFunctionDecl, visitStringLiteral and the like for traversing nodes of functional Decl and StringLiteral types respectively, and detailed interface information can be seen in Clang interface information document "https:// Clang. Llvm. Org/doxygen/classlang_1_1R eclosiveASTIView #") traversal AST root Positioning uses cv 1 ,cv 2 ,...,cv n ,...,cv N And add to the configuration variable usage location set CL 1 ,CL 2 ,...,CL n ,...,CL N CL in (1) n Representing AST root Uses cv n Code location, CL of (C) n ={cl n1 ,cl n2 ,...,cl nj ,...,cl nJ [ wherein cl ] nj Represent cv n In AST root The J-th used position of (2), J is cv n In AST root The total number of the using positions is more than or equal to 1 and less than or equal to J;
2.3.2 initializing variable n=1;
2.3.3 initializing variable j=1, initializing cv n Is related to the candidate branch interaction set candbi n = { }, initialize cv n Related set of alternate configuration variables, alternate_CV n ={};
2.3.4 checking cv n And cl nj Whether the use conditions in the following three scenes are satisfied or not is judged by the following steps:
2.3.4.1 if cv n Directly used in the branching condition of the branch statement br of the software source code F (If statement, while statement, switch statement in the software source code F) (i.e., control flow direction of control program execution after operation as part of branching judgment condition), br is added to cv n Is related to the candidate branch interaction set candbi n Middle, turn 2.3.5, otherwise turn 2.3.4.2;
2.3.4.2 if cv n Assigned to other program variables lv, and lv is directly used in the branching condition of branch statement br, br is added to cv n Is related to the candidate branch interaction set candbi n In (c), and adding lv to cv n Related set of alternate configuration variables, alternate_CV n Transferring to 2.3.5; otherwise turning to 2.3.4.3;
2.3.4.3 if the function func has I (I.gtoreq.1) parameters in total, and cv n Is used by the function func as the ith parameter (I is more than or equal to 1 and less than or equal to I), and in the implementation of the function func, the ith parameter param corresponding to the function func i Is used directly in the branching condition of the branching statement br (the number of parameters of the function implementation is consistent with the number of real parameters of the function call, indicating the parameter param of the function func i Corresponding to the ith parameter when the function func was called), then br is added to cv n Is related to the candidate branch interaction set candbi n And param is to i Added to cv n Related set of alternate configuration variables, alternate_CV n Transferring to 2.3.5; otherwiseDirectly transferring to 2.3.5;
2.3.5 let j=j+1, if J is less than or equal to J, turn to 2.3.4; otherwise get cv n Related candidate branch interaction set cand_bi n ,Cand_BI n ={cand_bi n1 ,cand_bi n2 ,..,cand_bi nk ,...,cand_bi nK }, where candbi nk Is cand_BI n Cv in the collection n K is cand_BI n Middle cv n K is more than or equal to 1 and less than or equal to K, and 2.3.6;
2.3.6 pair cv n Related candidate branch interaction set cand_bi n Analyzing and identifying the branch condition and branch processing type of the related branch statement to obtain five-tuple<cn n ,rcv n ,ps nk ,op nk ,loc nk >,cn n Is cv n Configuration parameter name, rcv of (c) n Is cv n The value at this position, ps nk Is equal to cv n Interactive program state valuing, op nk Is equal to cv n Interactive corresponding operator, loc nk For the code position of the branch statement where the compare_condition is located, the compare_condition is a contain cv n Or comprise cv n Logical expressions in leaf nodes of the corresponding location spare configuration variables acv; according to five-tuple<cn n ,rcv n ,ps nk ,op nk ,loc nk >Information in software source code AST root Loc of (C) nk The position is subject to pile inserting, and the position of the pile inserting in the software source code F is recorded; the method comprises the following steps:
2.3.6.1 initializing variable k=1;
2.3.6.2 acquisition of cand_bi through the interface getCond () provided by Clang (version 10.0.0 and above) nk Branch condition of (2), and taking branch condition as binary operator according to non-leaf node&&The form of logical expressions of (representation and operation) or (representation or operation) leaf nodes are parsed into binary tree, and then configuration variable cv is contained n (or contain cv n Standby configuration variable acv at the corresponding location (acv ε, alternate_CV n ) Leaf segment of (a)The logical expression in the dot is noted as compare_condition, and other is adjacent to and used by the compare_condition&&All leaf nodes connected by the nodes are connected by using AND operation, and the connected logic expression is marked as pre-condition;
2.3.6.3 it is checked whether only cv is included in the compare_condition n Or comprise cv n Standby configuration variable acv at the corresponding location (acv ε, alternate_CV n ) Constant, and other configuration variables cv m (m is more than or equal to 1 and less than or equal to N, m is not equal to N), and if yes, turning to 2.3.6.7; otherwise, go to 2.3.6.4;
2.3.6.4 transform the compare_condition to get cv n Or cv n The alternate configuration variable acv in the corresponding location is moved to the left of the compare_condition expression operator, all other operands are moved to the right of the compare_condition expression operator, and the expression right statement is noted as ps nk The expression operation is marked as op nk Recording the code position of the branch statement where the compare_condition is located as loc nk The cv appearing in the current compare_condition is processed n Or acv is denoted as rcv n
2.3.6.5 fetch cand_bi through the interface getth () provided by Clang (version 10.0.0 and above) nk And checks whether any of the following three cases is included in the handle_block: i) Error handling related log statements, ii) jump statements, and jump tag names containing keywords describing errors, iii) error handling related function calls, if any, jump 2.3.6.6; if none of the three cases are included, turn 2.3.6.7;
2.3.6.6 according to five-tuple<cn n ,rcv n ,ps nk ,op nk ,loc nk >Information in software source code AST root Loc of (C) nk The location is subject to instrumentation, and the main function of the instrumentation code segment is to record cn when the software source code F runs n 、rcv n 、ps nk 、op nk The four kinds of information are output to a file system; for example, a five-tuple on configuration parameter "LimmitRequestFields" in HttpdWeb server softwareExamples are as follows<“LimitRequestFields”,r->server->limit_req_fields,++fields_read,≥,server/protocol.c:1187>Cn in this example n Configuring parameter names LimmitRequest fields, rcv for character strings n For a numerical type program variable
Figure BDA0003872274550000061
Figure BDA0003872274550000062
ps nk For the numerical type program variable ++ fields read ,op nk Is equal to or more than loc nk The string type code location information, in this example server/protocol. C:1187, recording the position of the pile in the software source code F;
2.3.6.7 let k=k+1, if K is less than or equal to K, turn to 2.3.6.2; otherwise, turning to 2.3.7;
2.3.7 let n=n+1, if N is less than or equal to N, turn to 2.3.3; otherwise, turning to 2.4;
and 2.4, the software source code F is completely inserted, and the inserted software source code F' is output to the file system.
Thirdly, compiling and linking the F ' manually to obtain executable software F ', and running the software F '.
The fourth step, the dynamic monitoring module monitors the output of F 'in the file system, extracts the configuration constraint information under the influence of the current load, and automatically adjusts the configuration parameter value according to the related configuration constraint information when the configuration value in F' does not meet the constraint condition, the method is:
4.1 the dynamic monitoring module monitors the output in the file system within F "a period of time T (customizable, default t=1 second);
4.2 initializing variable n=1;
4.3 dynamic monitoring Module checking cn within time T n All the monitoring information sequences related<rcv n ,ps n1 ,op n1 ,loc n1 >,<rcv n ,ps n2 ,op n2 ,loc n2 >,...,<rcv n ,ps ns ,op ns ,loc ns >,...,<rcv n ,ps nS ,op nS ,loc nS >Whether the value of the configuration variable and the value of the program state interacted with the configuration variable meet the size relation of the corresponding operator description of the configuration variable interaction or not, wherein S is the output of F' and cn in T time n The total amount of the monitoring information that is relevant,<rcv n ,ps ns ,op ns ,loc ns >s is more than or equal to 1 and less than or equal to S for the S-th monitoring information; if the S pieces of monitoring information are all satisfied, checking; if the unsatisfied monitoring information exists in the S pieces of monitoring information, using a minimum program state threshold value min_threshold to record the minimum value of the program state values interacted with the configuration variables in all the unsatisfied monitoring information, and using a maximum program state threshold value max_threshold to record the maximum value of the program state values interacted with the configuration variables in all the unsatisfied monitoring information, wherein the method comprises the following steps:
4.3.1 initializing variable s=1, initializing variable minimum program state threshold min_threshold= infinity, maximum program state threshold max_threshold= -1;
4.3.2 check rcv n And ps ns Whether or not the value of (2) satisfies op ns The described size relation is as follows:
4.3.2.1 check op ns Operator type, if op ns Is equal to or more than 4.3.2.2; if op ns Is'>"turn 4.3.2.4; if op ns Is less than or equal to 4.3.2.6; if op ns Is "<", turn 4.3.2.8;
4.3.2.2 if rcv n Value and ps ns The value satisfies rcv n ≥ps ns Turning to 4.3.3; otherwise turning to 4.3.2.3;
4.3.2.3 ps of ns >max_threshold, max_threshold=ps ns And 4.3.3; otherwise, directly converting to 4.3.3;
4.3.2.4 if rcv n Value and ps ns The value satisfies rcv n >ps ns Turning to 4.3.3; otherwise turning to 4.3.2.5;
4.3.2.5 ps of ns >max_threshold, max_threshold=ps ns And 4.3.3; whether or notThen go directly to 4.3.3;
4.3.2.6 if rcv n Value and ps ns The value satisfies rcv n ≤ps ns Turning to 4.3.3; otherwise turning to 4.3.2.7;
4.3.2.7 ps of ns <min_threshold, in principle let min_threshold=ps ns And 4.3.3; otherwise, directly converting to 4.3.3;
4.3.2.8 if rcv n Value and ps ns The value satisfies rcv n <ps ns Turning to 4.3.3; otherwise turning to 4.3.2.9;
4.3.2.9 ps of ns < min_threshold, let min_threshold=ps ns And 4.3.3; otherwise, directly converting to 4.3.3;
4.3.3 let s=s+1, if S is less than or equal to S, turn to 4.3.2; otherwise, turning to 4.4;
4.4 dynamic monitoring Module in combination with monitoring information sequence<rcv n ,ps n1 ,op n1 ,loc n1 >,<rcv n ,ps n2 ,op n2 ,loc n2 >,...,<rcv n ,ps ns ,op ns ,loc ns >,...,<rcv n ,ps nS ,op nS ,loc nS >For configuration variable rcv n The value is adjusted, and the method comprises the following steps:
if min_threshold is not equal to infinity, rcv is calculated n The corresponding configuration parameter is reduced to
Figure BDA0003872274550000071
Figure BDA0003872274550000072
Turning to 4.5; if max_threshold is not equal to-1, rcv is calculated n The corresponding configuration parameter value is increased to +.>
Figure BDA0003872274550000073
Turning to 4.5;
4.5, let n=n+1, if N is less than or equal to N, turn to 4.3; otherwise, ending the current adjustment period, if the user stops running F', turning to a fifth step; otherwise, turning to 4.1 starts the next period adjustment.
And fifthly, the automatic adjustment of the configuration parameters in the F' by the dynamic monitoring module is finished.
Compared with the prior art, the invention has the following beneficial effects:
1. the invention can obtain the configuration constraint information of load sensitivity. Compared with the configuration constraint information extracted by a static analysis method in the work of 'Do Not Blame Users for Misconfigurations (without blading users for configuration faults)' published by Tianyin Xu et al in SOSP2013, the configuration constraint information extracted by the method is more accurate; compared with the dynamic configuration constraint extraction method by simulation execution of the work of 'Testing Configuration Changes in Context to Prevent Production Failures (test configuration modification in context to prevent production failure)' issued by Xudong Sun et al in OSDI2020, the present invention can obtain configuration constraint information of load influence in a real production environment.
2. The invention provides a method for adjusting software configuration to adapt to load change, which can help a user to automatically adjust the value of configuration parameters so as to meet the requirement of changing load, can avoid load-sensitive configuration faults and has good application scenes.
Drawings
FIG. 1 is a logical block diagram of a configuration parameter adjustment system constructed in a first step of the present invention.
Fig. 2 is a general flow chart of the present invention.
Detailed Description
The present invention will be described below with reference to fig. 2 by taking the configuration parameter "limit requests fields" in Httpd Web server software (as software source code F) as an example.
The first step, a configuration parameter adjusting system is constructed, and the configuration parameter adjusting system consists of a configuration related branch interaction analysis module and a dynamic monitoring module. The configuration related branch interaction analysis module reads in the Httpd software source code F and a configuration information file (a binary pair list of < configuration parameter name and configuration variable name > is stored) from the file system, identifies and positions the configuration related branch interaction in the Httpd software source code F, and carries out code instrumentation, and the instrumented Httpd software source code F' is output to the file system; compiling and linking the F 'by a user to obtain Httpd executable software F'; when running software F '', the dynamic monitoring module monitors the output of F '', extracts and outputs configuration constraint information under the influence of current load, and automatically adjusts the value of the configuration parameter according to the related configuration constraint information when the current configuration value does not meet the configuration constraint information due to the change of the load of F ''.
The second step, the relevant branch interaction analysis module is configured to read the Httpd software source code F and the Httpd configuration information file from the file system, locate and identify relevant branch interaction code segments from the Httpd software source code F, insert a program probe at the position of the relevant branch interaction code segments, and output the software source code F' after being inserted into the file system, wherein the method comprises the steps of:
2.1 configuration related Branch interaction analysis Module reads in and stores Httpd software configuration information File from File System, the configuration information File stores<Configuration parameter name, configuration variable name>Binary pair list, obtaining all configuration parameter names and corresponding configuration variable binary pair sets CS, CS= { in the software source code F from the configuration information file<cn 1 ,cv 1 >,<cn 2 ,cv 2 >,...,<cn n ,cv n >,...,<cn N ,cv N >} wherein cn n For the nth configuration parameter name, cv in CS n For cn in CS n Corresponding configuration variable name, cn in software source code n And cv n Binary pair relationships are disclosed by Shulin Zhou et al, "ConfMapper" in QRS 2016: automated Variable Finding for Configuration Items in Source Code (ConfMapper: automatic searching of configuration parameters corresponding to configuration variables from software source code) "the method of automatic searching of configuration parameters corresponding to configuration variables from software source code is established, N is the total number of configuration parameters in software source code F, N=131 (configuration variable binary pair information containing configuration parameters of" LimitteEquests fields "), and N is 1-N;
2.2 parsing Httpd software Source code F using Clang front-end (version 10.0.0 and above) of LLVM compiler framework to generateF-corresponding abstract syntax tree (Abstract Syntax Tree) AST root ,AST root Each node in the software source code F represents a structure in the software source code F, such as a whole source code (transitionunitdecl), a function statement (FunctionDecl), an If branch statement (IfStmt), a function call (CallExpr), a constant string (string link), binary calculation (binary operator), and the like, and the different structures represent corresponding dependencies in a tree structure, for example, for the If branch statement in one function statement, the corresponding IfStmt node is located in a subtree with the FunctionDecl node as a root node;
2.3 in abstract syntax tree AST root Middle positioning and cv 1 ,cv 2 ,...,cv n ,...,cv N The related branch interaction method specifically comprises the following steps:
2.3.1 in the abstract syntax tree AST root Related traversal interfaces (traversal interfaces in the form of visitytype) provided by Clang (version 10.0.0 and above, wherein nodypype refers to node types in abstract syntax tree, specific types are as described in step 2.2, and interfaces used in traversal process include VisitFunctionDecl, visitStringLiteral and the like for traversing nodes of functional decl and stringlink types respectively) traverse AST root Positioning uses cv 1 ,cv 2 ,...,cv n ,...,cv N And add to the configuration variable usage location set CL 1 ,CL 2 ,...,CL n ,...,CL N CL in (1) n Representing AST root Uses cv n Code location, CL of (C) n ={cl n1 ,cl n2 ,...,cl nj ,...,cl nJ [ wherein cl ] nj Represent cv n In AST root The J-th used position of (2), J is cv n In AST root The total number of positions used (J corresponds to each cv n All will be different because n=131, and the value of J may change every time for N cycles later), 1.ltoreq.j.ltoreq.j;
2.3.2 initializing variable n=1;
2.3.3 initializing variable j=1, initializing cv n Phase of (2)Candidate branch interaction set candbi for the gateway n = { }, initialize cv n Related set of alternate configuration variables, alternate_CV n ={};
2.3.4 checking cv n And cl nj Whether the use conditions in the following three scenes are satisfied or not is judged by the following steps:
2.3.4.1 if cv n Directly used in the branching condition of the branch statement br of the software source code F (If statement, while statement, switch statement in the software source code F) (i.e., control flow direction of control program execution after operation as part of branching judgment condition), br is added to cv n Is related to the candidate branch interaction set candbi n Middle, turn 2.3.5, otherwise turn 2.3.4.2;
2.3.4.2 if cv n Assigned to other program variables lv, and lv is directly used in the branching condition of branch statement br, br is added to cv n Is related to the candidate branch interaction set candbi n In (c), and adding lv to cv n Related set of alternate configuration variables, alternate_CV n Transferring to 2.3.5; otherwise turning to 2.3.4.3;
2.3.4.3 if the function func shares I (I is not less than 1) (I corresponds to the parameters of related function calls occurring in the software source code, the number of different function call parameters is different), and cv n Is used by the function func as the ith parameter (I is more than or equal to 1 and less than or equal to I), and in the implementation of the function func, the ith parameter param corresponding to the function func i Is used directly in the branching condition of the branching statement br (the number of parameters of the function implementation is consistent with the number of real parameters of the function call, indicating the parameter param of the function func i Corresponding to the ith parameter when the function func was called), then br is added to cv n Is related to the candidate branch interaction set candbi n And param is to i Added to cv n Related set of alternate configuration variables, alternate_CV n Transferring to 2.3.5; otherwise, directly transferring to 2.3.5;
2.3.5 let j=j+1, if J is less than or equal to J, turn to 2.3.4; otherwise get cv n Related candidate branch interaction set cand_bi n ,Cand_BI n ={cand_bi n1 ,cand_bi n2 ,..,cand_bi nk ,...,cand_bi nK }, where candbi nk Is cand_BI n Cv in the collection n K is cand_BI n Middle cv n K is more than or equal to 1 and less than or equal to K, (K corresponds to each cv) n Different for each time K may change during n cycles) to 2.3.6;
2.3.6 pair cv n Related candidate branch interaction set cand_bi n The method for analyzing and identifying the branch condition and the branch processing type of the related branch statement comprises the following steps:
2.3.6.1 initializing variable k=1;
2.3.6.2 acquisition of cand_bi through the interface getCond () provided by Clang (version 10.0.0 and above) nk Branch condition of (2), and taking branch condition as binary operator according to non-leaf node&&The form of logical expressions of (representation and operation) or (representation or operation) leaf nodes are parsed into binary tree, and then configuration variable cv is contained n (or contain cv n Standby configuration variable acv at the corresponding location (acv ε, alternate_CV n ) A logical expression in a leaf node is denoted as compare_condition, and other is adjacent to and used by the compare_condition&&All leaf nodes connected by the nodes are connected by using AND operation, and the connected logic expression is marked as pre-condition;
2.3.6.3 it is checked whether only cv is included in the compare_condition n Or comprise cv n Standby configuration variable acv at the corresponding location (acv ε, alternate_CV n ) Constant, and other configuration variables cv m (m is more than or equal to 1 and less than or equal to N, m is not equal to N), and if yes, turning to 2.3.6.7; otherwise, go to 2.3.6.4;
2.3.6.4 transform the compare_condition to get cv n Or cv n The alternate configuration variable acv in the corresponding location is moved to the left of the compare_condition expression operator, all other operands are moved to the right of the compare_condition expression operator, and the expression right statement is noted as ps nk The expression operation is marked as op nk To which the compare_condition is locatedThe code position of the branch statement is recorded as loc nk The cv appearing in the current compare_condition is processed n Or acv is denoted as rcv n
2.3.6.5 fetch cand_bi through the interface getth () provided by Clang (version 10.0.0 and above) nk And checks whether any of the following three cases is included in the handle_block: i) Error handling related log statements, ii) jump statements, and jump tag names containing keywords describing errors, iii) error handling related function calls, if any, jump 2.3.6.6; if none of the three cases are included, turn 2.3.6.7;
2.3.6.6 according to five-tuple<cn n ,rcv n ,ps nk ,op nk ,loc nk >Information in software source code AST root Loc of (C) nk The location is subject to instrumentation, and the main function of the instrumentation code segment is to record cn when the software source code F runs n (configuration parameter name), rcv n (value of configuration variable at this position), ps nk (program state value interacting with configuration variables), op nk Four types of information (corresponding operators interacted with the configuration variables) are output to a file system; for the configuration parameter "LimmitRequestFields" in HttpdWeb server software, one example of five-tuple information is as follows<“LimitRequestFields”,r->server->limit_req_fields,++fields-read,≥,server/protocol.c:1187>;
2.3.6.7 let k=k+1, if K is less than or equal to K, turn to 2.3.6.2; otherwise, turning to 2.3.7;
2.3.7 let n=n+1, if N is less than or equal to N, turn to 2.3.3; otherwise, turning to 2.4;
2.4 instrumentation of Httpd software source code F is completed, 36 program probes (including program probes for the use position of configuration parameter "LimmitRequestFields" in F) are instrumented in total, and instrumented software source code F' is output to the file system.
Thirdly, compiling and linking the F ' manually to obtain executable software F ', and running the software F '.
The fourth step, the dynamic monitoring module monitors the output of F 'in the file system, extracts the configuration constraint information under the influence of the current load, and automatically adjusts the configuration parameter value according to the related configuration constraint information when the configuration value in F' does not meet the constraint condition, the method is:
4.1 the dynamic monitoring module monitors the output in the file system within a period of time T of F "(t=1 second);
4.2 initializing variable n=1;
4.3 dynamic monitoring Module checking cn within time T n All the monitoring information sequences related<rcv n ,ps n1 ,op n1 ,loc n1 >,<rcv n ,ps n2 ,op n2 ,loc n2 >,...,<rcv n ,ps ns ,op ns ,loc ns >,...,<rcv n ,ps nS ,op nS ,loc nS >Wherein S is the value of F' output and cn in T time n The total amount of the monitoring information that is relevant,<rcv n ,ps ns ,op ns ,loc ns >s is more than or equal to 1 and less than or equal to S for the S-th monitoring information; if the S pieces of monitoring information are all satisfied, checking; if the unsatisfied monitoring information exists in the S pieces of monitoring information, using a minimum program state threshold value min_threshold to record the minimum value of the program state values interacted with the configuration variables in all the unsatisfied monitoring information, and using a maximum program state threshold value max_threshold to record the maximum value of the program state values interacted with the configuration variables in all the unsatisfied monitoring information, wherein the method comprises the following steps:
4.3.1 initializing variable s=1, initializing variable minimum program state threshold min_threshold= infinity, maximum program state threshold max_threshold= -1;
4.3.2 when cn n When the value is "LimittRequest fields", rcv is checked n And ps ns Whether or not the value of (2) satisfies op ns The described size relation is as follows:
4.3.2.1 instrumentation process for configuration parameter "LimmitRequest fieldsThe related quintuple information in (5) is as described in step 2.3.6.6, indicating op ns If the value is 'more than or equal to', checking rcv n Value and ps ns Whether or not the value satisfies rcv n ≥ps ns If so, turning to 4.3.3; otherwise turning to 4.3.2.2;
4.3.2.2 ps of ns >max_threshold, max_threshold=ps ns And 4.3.3; otherwise, directly converting to 4.3.3;
4.3.3 let s=s+1, if S is less than or equal to S, turn to 4.3.2; otherwise, turning to 4.4;
4.4 dynamic monitoring Module in combination with monitoring information sequence<rcv n ,ps n1 ,op n1 ,loc n1 >,<rcv n ,ps n2 ,op n2 ,loc n2 >,...,<rcv n ,ps ns ,op ns ,loc ns >,...,<rcv n ,ps nS ,op nS ,loc nS >Configuration variable rcv corresponding to configuration parameter LimittRequestFields n (configuration parameter "LimittRequestFields" corresponds to variable "r>server->limit_req_fields ") because max_threshold is not equal to-1 (see 4.3.2.2, which causes a change in program state when a change in software load occurs, which in turn causes a change in max_threshold), rcv will be n The corresponding configuration parameter is increased to
Figure BDA0003872274550000121
Figure BDA0003872274550000122
Turning to 4.5.
4.5, let n=n+1, if N is less than or equal to N, turn to 4.3; otherwise, ending the current adjustment period, if the user stops running F', turning to a fifth step; otherwise, turning to 4.1 starts the next period adjustment.
And fifthly, the dynamic monitoring module finishes the automatic adjustment of the configuration parameter ' LimmitRequest fields ' in the F '.
If the Httpd Web server software is not adjusted according to the configuration parameters of the second step and the fourth step of the present invention, the Httpd Web server may have a load-sensitive configuration fault when faced with the following scenarios, where the specific scenarios and fault expressions are described as follows: the HttpdWeb server is in a lower load at first, the number of fields in an http request header of a user accessing the HttpdWeb server is less, and when the number of fields is lower than the value of a configuration parameter of LimmitRequestFields, the Httpd Web server can normally provide services; when the number of fields in an http request header of a user access server is increased at a certain moment and exceeds the value of a configuration parameter of 'LimmitRequest fields', the Httpd Web server cannot provide service for the user and returns a '400 error' error code to the user, so that configuration faults occur;
if the configuration parameters are adjusted according to the second step and the fourth step of the invention aiming at the Httpd software source code, when the number of fields in the http request header of the user access server is increased, the value of the configuration parameter LimmitRequestFields is automatically adjusted and increased, so that the configuration parameter LimittRequestFields meets the constraint condition that the number of fields in the http request header is greater than that of the user, and the adjustment of the configuration parameters of load perception is realized, thereby preventing the configuration faults of load sensitivity.

Claims (9)

1. The method for adjusting the load-aware software configuration parameters is characterized by comprising the following steps:
firstly, constructing a configuration parameter adjusting system, wherein the configuration parameter adjusting system consists of a configuration related branch interaction analysis module and a dynamic monitoring module; the configuration related branch interaction analysis module reads in the software source code F and the configuration information file from the file system, identifies and positions the configuration related branch interaction in the software source code F, performs code instrumentation, and outputs the software source code F' after instrumentation to the file system; compiling and linking the F 'by a user to obtain executable software F'; the dynamic monitoring module monitors the output of F 'in a file system during running, extracts and outputs configuration constraint information under the influence of current load, and automatically adjusts the value of a configuration parameter according to relevant configuration constraint information when the current configuration value does not meet the configuration constraint information due to the change of F' load;
the second step, the relevant branch interaction analysis module is configured to read the software source code F and the configuration information file from the file system, locate and identify relevant branch interaction code segments from the software source code F, insert a program probe at the relevant branch interaction code segment position, and output the software source code F' after insertion to the file system, the method is as follows:
2.1 the configuration related branch interaction analysis module reads in a configuration information file from a file system, wherein the configuration information file stores < configuration parameter names, configuration variable names > binary pair list, and obtains all configuration parameter names and corresponding configuration variable binary pair sets CS in a software source code F from the configuration information file, wherein CS= { < cn 1 ,cv 1 >,<cn 2 ,cv 2 >,...,<cn n ,cv n >,...,<cn N ,cv N >, wherein cn n For the nth configuration parameter name, cv in CS n For cn in CS n The corresponding configuration variable names in the software source code, N is the total number of configuration parameters in the software source code F, and N is more than or equal to 1 and less than or equal to N;
2.2 resolving the software source code F by using the Clang front end of the LLVM compiler framework to generate an abstract syntax tree AST corresponding to the software source code F root ,AST root Each node in the tree represents a structure in the software source code F, and the different structures represent corresponding subordinate relations in the tree structure;
2.3 in abstract syntax tree AST root Middle positioning and cv 1 ,cv 2 ,...,cv n ,...,cv N The related branch interaction method specifically comprises the following steps:
2.3.1 in the abstract syntax tree AST root Traversing AST using related traversal interface provided by Clang root Positioning uses cv 1 ,cv 2 ,...,cv n ,...,cv N And add to the configuration variable usage location set CL 1 ,CL 2 ,...,CL n ,...,CL N CL in (1) n Representing AST root Uses cv n Code location, CL of (C) n ={cl n1 ,cl n2 ,...,cl nj ,...,cl nJ [ wherein cl ] nj Represent cv n In AST root The J-th used position of (2), J is cv n In AST root The total number of the using positions is more than or equal to 1 and less than or equal to J;
2.3.2 initializing variable n=1;
2.3.3 initializing variable j=1, initializing cv n Is related to the candidate branch interaction set candbi n = { }, initialize cv n Related set of alternate configuration variables, alternate_CV n ={};
2.3.4 checking cv n And cl nj Whether the use conditions in the following three scenes are satisfied or not is judged by the following steps:
2.3.4.1 if cv n Directly used in the branch condition of branch statement br of software source code F, i.e. as part of branch judgment condition to control flow direction of program execution after operation, add br to cv n Is related to the candidate branch interaction set candbi n Middle, turn 2.3.5, otherwise turn 2.3.4.2;
2.3.4.2 if cv n Assigned to other program variables lv, and lv is directly used in the branching condition of branch statement br, br is added to cv n Is related to the candidate branch interaction set candbi n In (c), and adding lv to cv n Related set of alternate configuration variables, alternate_CV n Transferring to 2.3.5; otherwise turning to 2.3.4.3;
2.3.4.3 if the function func has I parameters, I is equal to or greater than 1, and cv n The function func is used as the I parameter, I is more than or equal to 1 and less than or equal to I, and in the implementation of the function func, the I parameter param corresponding to the function func i Directly used in the branching condition of the branch statement br, br is added to cv n Is related to the candidate branch interaction set candbi n And param is to i Added to cv n Related set of alternate configuration variables, alternate_CV n Transferring to 2.3.5; otherwise, directly transferring to 2.3.5;
2.3.5 let j=j+1, if J is less than or equal to J, turn to 2.3.4; otherwise get cv n Related candidate branch interaction set cand_bi n ,Cand_BI n ={cand_bi n1 ,cand_bi n2 ,..,cand_bi nk ,...,cand_bi nK }, where candbi nk Is cand_BI n Cv in the collection n K is cand_BI n Middle cv n K is more than or equal to 1 and less than or equal to K, and 2.3.6;
2.3.6 pair cv n Related candidate branch interaction set cand_bi n Analyzing and identifying the branch condition and branch processing type of the related branch statement to obtain five-tuple < cn n ,rcv n ,ps nk ,op nk ,loc nk >,rcv n For configuration variable cv n The value at this position, ps nk For and configure variable cv n Interactive program state valuing, op nk For and configure variable cv n Interactive corresponding operator, loc nk For the code position of the branch statement where the compare_condition is located, the compare_condition is a contain cv n Or comprise cv n Logical expressions in leaf nodes of the corresponding location spare configuration variables acv; according to five-tuple < cn n ,rcv n ,ps nk ,op nk ,loc nk The information is in software source code AST root Loc of (C) nk The position is subject to instrumentation, and the instrumentation code segment functions to record cn when the software source code F runs n 、rcv n 、ps nk 、op nk The four types of information are output to a file system, and the position of the inserted pile in the software source code F is recorded;
2.3.7 let n=n+1, if N is less than or equal to N, turn to 2.3.3; otherwise, turning to 2.4;
2.4, completing the instrumentation of the software source code F, and outputting the software source code F' after the instrumentation to a file system;
thirdly, compiling and linking the F ' manually to obtain executable software F ', and running the software F ';
the fourth step, the dynamic monitoring module monitors the output of F 'in the file system, extracts the configuration constraint information under the influence of the current load, and automatically adjusts the configuration parameter value according to the related configuration constraint information when the configuration value in F' does not meet the constraint condition, the method is:
4.1 the dynamic monitoring module monitors the output in the file system within a period of time T of F';
4.2 initializing variable n=1;
4.3 dynamic monitoring Module checking cn within time T n All relevant monitoring information sequences < rcv n ,ps n1 ,op n1 ,loc n1 >,<rcv n ,ps n2 ,op n2 ,loc n2 >,...,<rcv n ,ps ns ,op ns ,loc ns >,...,<rcv n ,ps nS ,op nS ,loc nS In > the configuration variable value, whether the program state value interacted with the configuration variable satisfies the corresponding operator description size relationship of the configuration variable interaction, wherein S is the output of F' and cn in T time n Total number of relevant monitoring information, < rcv n ,ps ns ,op ns ,loc ns The S-th monitoring information is more than or equal to 1 and less than or equal to S; if the S pieces of monitoring information are all satisfied, checking and turning to 4.4; if unsatisfied monitoring information exists in the S pieces of monitoring information, using a minimum program state threshold value min_threshold to record the minimum value of the program state values interacted with the configuration variables in all the unsatisfied monitoring information, using a maximum program state threshold value max_threshold to record the maximum value of the program state values interacted with the configuration variables in all the unsatisfied monitoring information, and switching to 4.4;
4.4 dynamic monitoring Module combines monitoring information sequence < rcv n ,ps n1 ,op n1 ,loc n1 >,<rcv n ,ps n2 ,op n2 ,loc n2 >,...,<rcv n ,ps ns ,op ns ,loc ns >,...,<rcv n ,ps nS ,op nS ,loc nS Configuration variable rcv > pairs n The value is adjusted, and the method comprises the following steps:
if min_threshold is not equal to infinity, rcv is calculated n The corresponding configuration parameter is reduced to
Figure FDA0003872274540000031
Figure FDA0003872274540000032
Turning to 4.5; if max_threshold is equal to 1, rcv will be n The corresponding configuration parameter value is increased to +.>
Figure FDA0003872274540000033
Turning to 4.5;
4.5, let n=n+1, if N is less than or equal to N, turn to 4.3; otherwise, ending the current adjustment period, if the user stops running F', turning to a fifth step; otherwise, turning to 4.1 to start the next period adjustment;
and fifthly, the automatic adjustment of the configuration parameters in the F' by the dynamic monitoring module is finished.
2. The method for load-aware software configuration parameter adjustment of claim 1, wherein said cn is 2.1 steps n And cv n The binary pair relation is established by a method for automatically searching configuration parameters from software source codes to correspond to configuration variables.
3. The method of claim 1, wherein said Clang front end is 10.0.0 version and above.
4. The method for adjusting load-aware software configuration parameters according to claim 1, wherein said AST is 2.2 steps root The structure in the software source code F represented by the node in (a) comprises: the whole source code is integrally transitionUnitDecl, a function statement FunctionDecl, if branch statement IfStmt, a function call CallExpr, a constant string StringLiteral, a binary calculation BinaryOpera, a single variable DeclRefExpr and a structural variable Member Expr.
5. The method for adjusting load-aware software configuration parameters according to claim 1, wherein the related traversal interface provided by Clang in step 2.3.1 refers to a traversal interface in the form of VisitNodeType, wherein nododetype refers to a node type in an abstract syntax tree.
6. The method for adjusting load-aware software configuration parameters according to claim 1, wherein the branch statement br of the software source code F in step 2.3.4.1 refers to If statement, while statement, switch statement in the software source code F.
7. The method for load-aware software configuration parameter adjustment of claim 1, wherein said pairing cv of step 2.3.6 n Related candidate branch interaction set cand_bi n Analyzing and identifying the branch condition and branch processing type of the related branch statement to obtain five-tuple < cn n ,rcv n ,ps nk ,op nk ,loc nk According to quintuple information, in software source code AST root Loc of (C) nk The method for inserting piles at the positions comprises the following steps:
2.3.6.1 initializing variable k=1;
2.3.6.2 acquisition of cand_bi through the interface getCond () provided by Clang nk Branch condition of (2), and taking branch condition as binary and operator according to non-leaf node&&Or operator, the leaf nodes are all in the form of logical expressions and are resolved into binary trees, and then contain configuration variables cv n Or comprise cv n The logical expression in the leaf node of the corresponding location spare configuration variable acv is noted as compare_condition, acv ε, alternate_CV n Other adjacent to the compare_condition and use&&All leaf nodes connected by the nodes are connected by using AND operation, and the connected logic expression is marked as pre-condition;
2.3.6.3 it is checked whether only cv is included in the compare_condition n Or comprise cv n Standby configuration variables acv, constants, and other configuration variables cv at corresponding locations m M is more than or equal to 1 and less than or equal to N, and m is not equal to N; if yes, go to 2.3.6.7; otherwise, go to 2.3.6.4;
2.3.6.4 transform the compare_condition to get cv n Or cv n The alternate configuration variable acv in the corresponding location is moved to the left of the compare_condition expression operator, moving all other operandsTo the right of the compare_condition expression operator and record the expression right statement as ps nk The expression operation is marked as op nk Recording the code position of the branch statement where the compare_condition is located as loc nk The cv appearing in the current compare_condition is processed n Or acv is denoted as rcv n
2.3.6.5 get candbi through the interface getth () provided by Clang nk And checks whether any of the following three cases is included in the handle_block: i) Error handling related log statements, ii) jump statements, and jump tag names containing keywords describing errors, iii) error handling related function calls, if any, jump 2.3.6.6; if none of the three cases are included, turn 2.3.6.7;
2.3.6.6 according to five-tuple < cn n ,rcv n ,ps nk ,op nk ,loc nk The information is in software source code AST root Loc of (C) nk The position is subject to instrumentation, and the instrumentation code segment functions to record the configuration parameter name cn when the software source code F runs n The value rcv of the configuration variable at this position n Program state value ps interacting with configuration variables nk Corresponding operators op interacting with configuration variables nk The four types of information are output to a file system, and the position of the pile in the software source code F is recorded;
2.3.6.7 let k=k+1, if K is less than or equal to K, turn to 2.3.6.2; otherwise, ending.
8. A method of load-aware software configuration parameter adjustment according to claim 1, characterized in that step 4.1 the t=1 seconds.
9. The method for adjusting load-aware software configuration parameters as defined in claim 1, wherein said dynamic monitoring module checks cn during time T in step 4.3 n All relevant monitoring information sequences < rcv n ,ps n1 ,op n1 ,loc n1 >,<rcv n ,ps n2 ,op n2 ,loc n2 >,...,<rcv n ,ps ns ,op ns ,loc ns >,...,<rcv n ,ps nS ,op nS ,loc nS The method for judging whether the configuration variable value and the program state value interacted with the configuration variable satisfy the size relation of the corresponding operator description of the configuration variable interaction in the process is as follows:
4.3.1 initializing variable s=1, initializing variable minimum program state threshold min_threshold= infinity, maximum program state threshold max_threshold= -1;
4.3.2 check rcv n And ps ns Whether or not the value of (2) satisfies op ns The described size relation is as follows:
4.3.2.1 check op ns Operator type, if op ns Is equal to or more than 4.3.2.2; if op ns "turn 4.3.2.4" >; if op ns Is less than or equal to 4.3.2.6; if op ns Is "<", turn 4.3.2.8;
4.3.2.2 if rcv n Value and ps ns The value satisfies rcv n ≥ps ns Turning to 4.3.3; otherwise turning to 4.3.2.3;
4.3.2.3 ps of ns Max_threshold, max_threshold=ps ns And 4.3.3; otherwise, directly converting to 4.3.3;
4.3.2.4 if rcv n Value and ps ns The value satisfies rcv n >ps ns Turning to 4.3.3; otherwise turning to 4.3.2.5;
4.3.2.5 ps of ns Max_threshold, max_threshold=ps ns And 4.3.3; otherwise, directly converting to 4.3.3;
4.3.2.6 if rcv n Value and ps ns The value satisfies rcv n ≤ps ns Turning to 4.3.3; otherwise turning to 4.3.2.7;
4.3.2.7 ps of ns < min_threshold, let min_threshold=ps ns And 4.3.3; otherwise, directly converting to 4.3.3;
4.3.2.8 if rcv n Value and ps ns The value satisfies rcv n <ps ns Turning to 4.3.3; otherwise turning to 4.3.2.9;
4.3.2.9 ps of ns < min_threshold, let min_threshold=ps ns And 4.3.3; otherwise, directly converting to 4.3.3;
4.3.3 let s=s+1, if S is less than or equal to S, turn to 4.3.2; otherwise, ending.
CN202211200545.8A 2022-09-29 2022-09-29 Load-aware software configuration parameter adjustment method Active CN115562674B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211200545.8A CN115562674B (en) 2022-09-29 2022-09-29 Load-aware software configuration parameter adjustment method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211200545.8A CN115562674B (en) 2022-09-29 2022-09-29 Load-aware software configuration parameter adjustment method

Publications (2)

Publication Number Publication Date
CN115562674A CN115562674A (en) 2023-01-03
CN115562674B true CN115562674B (en) 2023-05-02

Family

ID=84742404

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211200545.8A Active CN115562674B (en) 2022-09-29 2022-09-29 Load-aware software configuration parameter adjustment method

Country Status (1)

Country Link
CN (1) CN115562674B (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108804136A (en) * 2018-05-31 2018-11-13 中国人民解放军国防科技大学 Configuration item type constraint inference method based on name semantics
CN109154896A (en) * 2016-04-29 2019-01-04 思杰系统有限公司 System and method for service chaining load balance
CN114866300A (en) * 2022-04-22 2022-08-05 中国人民解放军国防科技大学 Network protocol software state variable identification method based on replay analysis

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10310969B2 (en) * 2017-05-31 2019-06-04 Oracle International Corporation Systems and methods for test prediction in continuous integration environments

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109154896A (en) * 2016-04-29 2019-01-04 思杰系统有限公司 System and method for service chaining load balance
CN108804136A (en) * 2018-05-31 2018-11-13 中国人民解放军国防科技大学 Configuration item type constraint inference method based on name semantics
CN114866300A (en) * 2022-04-22 2022-08-05 中国人民解放军国防科技大学 Network protocol software state variable identification method based on replay analysis

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
ConfInLog: Leveraging Software Logs to Infer Configuration Constraints;Shulin Zhou等;《2021 IEEE/ACM 29th International Conference on Program Comprehension (ICPC)》;1-12 *
Dependable Policy Enforcement in Traditional Non-SDN Networks;Olufemi Odegbile等;《2019 IEEE 39th International Conference on Distributed Computing Systems (ICDCS)》;1-5 *
面向性能优化的配置故障诊断技术研究;李云峰;《中国优秀硕士学位论文全文数据库 信息科技辑》;I138-397 *

Also Published As

Publication number Publication date
CN115562674A (en) 2023-01-03

Similar Documents

Publication Publication Date Title
CN110399133B (en) JavaScript code optimization method based on front-end byte code technology
US8312440B2 (en) Method, computer program product, and hardware product for providing program individuality analysis for source code programs
US8819649B2 (en) Profile guided just-in-time (JIT) compiler and byte code generation
CN110737899A (en) machine learning-based intelligent contract security vulnerability detection method
US11385898B2 (en) Task orchestration method for data processing, orchestrator, device and readable storage medium
CN103164331B (en) A kind of leak detection method of application program and device
CN108897676B (en) Flight guidance control software reliability analysis system and method based on formalization rules
CN108255837B (en) SQL parser and method
CN110554954B (en) Test case selection method combining static dependency and dynamic execution rule
CN103577324A (en) Static detection method for privacy information disclosure in mobile applications
CN110780879B (en) Decision execution method, device, equipment and medium based on intelligent compiling technology
CN112463586A (en) Method and medium for automatically generating application program interface test case
CN105183629A (en) Diagnosis system and diagnosis method for analyzing performance of PHP application software, and performance management platform thereof
CN103186463A (en) Method and system for determining testing range of software
CN109885493A (en) A kind of automation combination frame reflected based on Android platform and Java
CN115562674B (en) Load-aware software configuration parameter adjustment method
WO2004051470A1 (en) Program automatic converting method and program automatic converting device
CN109445306B (en) Automatic associated parameter interpretation method and system based on rule configuration analysis
CN110764783B (en) Method, device, equipment and storage medium for generating information acquisition tool
CN111897687A (en) Interface checking method, device, equipment and storage medium
CN109308256A (en) A kind of java dynamically analyzing of program method, equipment and storage medium
US11983091B2 (en) Adaptively generated program model
CN115168188A (en) Program testing method, program testing device, storage medium and electronic equipment
US11656976B2 (en) System and method for element locator recommendations for a UI application
KR102413994B1 (en) Method for visualizing software source code after modifying it for improving performance and device thereof

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