Movatterモバイル変換


[0]ホーム

URL:


CN112685074A - Method for visually modifying redis configuration based on rules - Google Patents

Method for visually modifying redis configuration based on rules
Download PDF

Info

Publication number
CN112685074A
CN112685074ACN202011587272.8ACN202011587272ACN112685074ACN 112685074 ACN112685074 ACN 112685074ACN 202011587272 ACN202011587272 ACN 202011587272ACN 112685074 ACN112685074 ACN 112685074A
Authority
CN
China
Prior art keywords
parameters
modified
redis
configuration
configuration file
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.)
Pending
Application number
CN202011587272.8A
Other languages
Chinese (zh)
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.)
Unicloud Technology Co Ltd
Original Assignee
Unicloud Technology 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 Unicloud Technology Co LtdfiledCriticalUnicloud Technology Co Ltd
Priority to CN202011587272.8ApriorityCriticalpatent/CN112685074A/en
Publication of CN112685074ApublicationCriticalpatent/CN112685074A/en
Pendinglegal-statusCriticalCurrent

Links

Images

Landscapes

Abstract

The invention provides a visual method for modifying redis configuration based on rules, which selects parameters to be modified through a UI end, and the UI can carry out preliminary verification on the modified parameters; if the verification is qualified, a request is constructed and sent to the server side; the server checks the transmitted parameters, judges whether the parameters can be modified or not, if the parameters can be modified, connects the redis service node, and sets the parameters of the configuration file; and the server side circularly traverses all the parameters and writes the parameters back to the configuration file. The configuration method of the invention firstly clearly knows which parameters can be modified by the user through a visual UI service, and also displays the description of the parameters to the client in a more intuitive way, and most importantly, the modification range of the provided parameters greatly avoids the occurrence of unreasonable parameters which are modified and input by the user.

Description

Method for visually modifying redis configuration based on rules
Technical Field
The invention belongs to the technical field of software file configuration, and particularly relates to a method for visually modifying redis configuration based on rules.
Background
In the current design implementation, if a user modifies a configuration file of redis, only a client based on the redis can modify the configuration file, and there is no clear rule to direct the user to modify the configured value. Unless the user needs to spend a great deal of time and effort to learn the parameters that can be modified. Embodied in selectable values, rules, etc.
In the present situation, if a user wants to modify a configuration parameter in a redis, a command needs to be executed at a client of the redis, and there is no reference to which to select, for example, a name of the parameter, an optional value of the parameter, and the like.
The prior art has the following defects:
1: a great deal of effort is required to understand the meaning of parameters in the existing redis, and the values that can be changed;
2: the method is operated by a pure command line, and no interface UI is displayed friendly;
3: can only be added via the command line; time consuming and cumbersome, and requires time to understand the meaning of the parameters and the range of values that can be changed.
Disclosure of Invention
In view of this, the present invention is directed to a method for visually modifying a redis configuration based on rules, so as to solve the problem that a configuration file in the prior art can only be added through a command line; time consuming and cumbersome, and requires time to understand the meaning of the parameters and the range of values that can be changed.
In order to achieve the purpose, the technical scheme of the invention is realized as follows:
a method of visualizing rule-based modification of a redis configuration, comprising the steps of:
s1, selecting parameters to be modified through a UI end, and carrying out preliminary verification on the modified parameters through the UI end;
s2, if the verification is qualified, a request is constructed and sent to the server side;
s3, the server checks the transmitted parameters, judges whether the parameters can be modified, if so, connects the redis service node, and sets the parameters of the configuration file;
and S4, the server side circularly traverses all the parameters and writes the parameters back to the configuration file.
Further, the parameters modified in step S1 may be single or multiple.
Further, the parameters include types and values.
Further, the verification process in step S1 is: and comparing the parameters modified by the UI with a preset range to judge whether the parameters are in the range.
Further, the procedure of checking the transmitted parameters in step S3 is as follows: the server checks according to the defined configuration file, if the parameters are all parameters which can be modified, the parameters are extracted according to the set json data, and the parameters are compared with the defined numerical value range through the transmitted parameter values.
Further, the configuration file parameter setting process in S4 is as follows: the server will connect to the redis node and execute a command for the configset parameter value, which is a command of the redis itself, with the aim that the config set is set for the parameters of the configuration file.
Compared with the prior art, the method for modifying the redis configuration based on the visualization rules has the following advantages:
(1) the configuration method of the invention firstly clearly knows which parameters can be modified by the user through a visual UI service, and also displays the description of the parameters to the client in a more intuitive way, and most importantly, the modification range of the provided parameters greatly avoids the occurrence of unreasonable parameters which are modified and input by the user.
(2) The configuration method of the invention simultaneously shields the operation of the redis bottom layer, and enables the user to directly complete the desired change at the UI end.
(3) Compared with the traditional command line, the description of the UI end is simpler and easier to understand, and a user only needs to select the UI end to display for operation according to the guidance.
(4) According to the configuration method, UI visualization is more excellent for user experience.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate an embodiment of the invention and, together with the description, serve to explain the invention and not to limit the invention. In the drawings:
fig. 1 is a flowchart of a method for visualizing a rule-based modified redis configuration according to an embodiment of the present invention.
Detailed Description
It should be noted that the embodiments and features of the embodiments may be combined with each other without conflict.
In the description of the present invention, it is to be understood that the terms "center", "longitudinal", "lateral", "up", "down", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inner", "outer", and the like, indicate orientations or positional relationships based on those shown in the drawings, and are used only for convenience in describing the present invention and for simplicity in description, and do not indicate or imply that the referenced devices or elements must have a particular orientation, be constructed and operated in a particular orientation, and thus, are not to be construed as limiting the present invention. Furthermore, the terms "first", "second", etc. are used for descriptive purposes only and are not to be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first," "second," etc. may explicitly or implicitly include one or more of that feature. In the description of the present invention, "a plurality" means two or more unless otherwise specified.
In the description of the present invention, it should be noted that, unless otherwise explicitly specified or limited, the terms "mounted," "connected," and "connected" are to be construed broadly, e.g., as meaning either a fixed connection, a removable connection, or an integral connection; can be mechanically or electrically connected; they may be connected directly or indirectly through intervening media, or they may be interconnected between two elements. The specific meaning of the above terms in the present invention can be understood by those of ordinary skill in the art through specific situations.
The present invention will be described in detail below with reference to the embodiments with reference to the attached drawings.
As shown in fig. 1, a method for visualizing a rule-based modified redis configuration includes the following steps:
s1, selecting parameters to be modified through a UI end, and carrying out preliminary verification on the modified parameters through the UI end;
s2, if the verification is qualified, a request is constructed and sent to the server side;
s3, the server checks the transmitted parameters, judges whether the parameters can be modified, if so, connects the redis service node, and sets the parameters of the configuration file;
and S4, the server side circularly traverses all the parameters and writes the parameters back to the configuration file.
The parameters modified in step S1 may be single or multiple.
The parameters comprise types and numerical values.
The verification process in step S1 is: and comparing the parameters modified by the UI with a preset range to judge whether the parameters are in the range.
The procedure of checking the passed parameters in step S3 is as follows: the server checks according to the defined configuration file, if the parameters are all parameters which can be modified, the parameters are extracted according to the set json data, and the parameters are compared with the defined numerical value range through the transmitted parameter values.
The configuration file parameter setting process in S4 is as follows: the server will connect to the redis node and execute a command for the configset parameter value, which is a command of the redis itself, with the aim that the config set is set for the parameters of the configuration file.
The specific method comprises the following steps:
selecting parameters to be modified through a UI end, selecting and modifying single or multiple parameters, and the UI can carry out preliminary verification on the modified parameters, firstly, verifying whether the parameters meet the conditions, specifically comprising types and numerical values, because the default can provide the range of selectable values and checking whether the range of the selectable values is in; after the UI end passes through the parameter range, a request is constructed and sent to the server end after parameter value checking, the server firstly checks the transmitted parameters according to a defined configuration file, and generally, the server has a preset parameter list to define which parameters can be modified;
if all are modifiable, they are extracted from the set json data, and the incoming values must satisfy the defined conditions by comparing the incoming parameter values with the already defined range of values. All checks are correct, the server will connect the redis nodes and execute the command of config set parameter value, which is the command of the redis itself, aiming at that config set is just setting the parameters of the configuration file, for example, we set config set dbfilename dump. rdb is just setting the name of the persistent text of the redis. And finally, after all the parameters are executed in a traversal cycle, uniformly writing the parameters back to the configuration file.
The above description is only for the purpose of illustrating the preferred embodiments of the present invention and is not to be construed as limiting the invention, and any modifications, equivalents, improvements and the like that fall within the spirit and principle of the present invention are intended to be included therein.

Claims (6)

CN202011587272.8A2020-12-282020-12-28Method for visually modifying redis configuration based on rulesPendingCN112685074A (en)

Priority Applications (1)

Application NumberPriority DateFiling DateTitle
CN202011587272.8ACN112685074A (en)2020-12-282020-12-28Method for visually modifying redis configuration based on rules

Applications Claiming Priority (1)

Application NumberPriority DateFiling DateTitle
CN202011587272.8ACN112685074A (en)2020-12-282020-12-28Method for visually modifying redis configuration based on rules

Publications (1)

Publication NumberPublication Date
CN112685074Atrue CN112685074A (en)2021-04-20

Family

ID=75454735

Family Applications (1)

Application NumberTitlePriority DateFiling Date
CN202011587272.8APendingCN112685074A (en)2020-12-282020-12-28Method for visually modifying redis configuration based on rules

Country Status (1)

CountryLink
CN (1)CN112685074A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN116339804A (en)*2023-01-192023-06-27蔷薇大树科技有限公司 Method of batch configuration

Citations (5)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN1790257A (en)*2004-12-132006-06-21华为技术有限公司Method for uniformly configuring configuration files
CN1862538A (en)*2006-02-272006-11-15华为技术有限公司Data configuration system and method for implementing data configuration
US20110154237A1 (en)*2009-12-182011-06-23Roche Diagnostics Operations, Inc.Methods, systems and computer readable media for modifying parameters of a configuration file
CN103516529A (en)*2012-06-202014-01-15中兴通讯股份有限公司Management method, device and system of configuration files
CN111522543A (en)*2020-04-162020-08-11科大国创云网科技有限公司Visual application component arrangement method and system

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN1790257A (en)*2004-12-132006-06-21华为技术有限公司Method for uniformly configuring configuration files
CN1862538A (en)*2006-02-272006-11-15华为技术有限公司Data configuration system and method for implementing data configuration
US20110154237A1 (en)*2009-12-182011-06-23Roche Diagnostics Operations, Inc.Methods, systems and computer readable media for modifying parameters of a configuration file
CN103516529A (en)*2012-06-202014-01-15中兴通讯股份有限公司Management method, device and system of configuration files
CN111522543A (en)*2020-04-162020-08-11科大国创云网科技有限公司Visual application component arrangement method and system

Cited By (1)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN116339804A (en)*2023-01-192023-06-27蔷薇大树科技有限公司 Method of batch configuration

Similar Documents

PublicationPublication DateTitle
US9178909B2 (en)Graphical representation of a port security state
US7937432B2 (en)State transition management according to a workflow management policy
JP4932842B2 (en) Network connectivity and radio conditions in the announcement area
US9210049B2 (en)Intelligent infrastructure management user device
US8655275B2 (en)Device setup extension for applications
US10126910B2 (en)Trust map management and user interface
WO2015187480A1 (en)Plugin system for integration of third party real-time medical lab information
CN102638455A (en)Method and device for processing network element object information in three-dimensional (3D) topology view
CN112685074A (en)Method for visually modifying redis configuration based on rules
CN103975347A (en)Management system and method that manage operation
CN106656663A (en)Bit flip fault injection method and system for CAN (Controller Area Network) bus data link layer
CN103428007A (en)Method and device for establishing communication group
CN112242909B (en)Method and device for generating management template, electronic equipment and storage medium
JP2009086837A (en) Parameter setting system and parameter setting program
JP2004070886A (en) Setting method of disk array device, program, information processing device, and disk array device
CN110866054A (en)Label configuration method and device and computer storage medium
WO2022083702A1 (en)Vehicle diagnosis data display method and system, and mobile terminal and storage medium
CN106736071A (en)Welding system and welding system control method
JP2011002836A (en)Display device and display method therefor
CN106059786A (en)Network card performance optimizing device, system and method
CN114816640A (en) A visual configuration system based on the power control object of the control terminal
US20060126530A1 (en)Indicating a configuring status
CN111585804A (en)Router automatic configuration system, router automatic configuration method and automatic test system
KR102072135B1 (en)System and method for setting detection of network function virtualization
CN109684841B (en)Method and device for scanning knowledge base

Legal Events

DateCodeTitleDescription
PB01Publication
PB01Publication
SE01Entry into force of request for substantive examination
SE01Entry into force of request for substantive examination
RJ01Rejection of invention patent application after publication
RJ01Rejection of invention patent application after publication

Application publication date:20210420


[8]ページ先頭

©2009-2025 Movatter.jp