CN109460291A - Electronic device, the method for controller perturbation server cluster and storage medium - Google Patents

Electronic device, the method for controller perturbation server cluster and storage medium Download PDF

Info

Publication number
CN109460291A
CN109460291A CN201811121915.2A CN201811121915A CN109460291A CN 109460291 A CN109460291 A CN 109460291A CN 201811121915 A CN201811121915 A CN 201811121915A CN 109460291 A CN109460291 A CN 109460291A
Authority
CN
China
Prior art keywords
time period
preset time
server
task
server cluster
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
CN201811121915.2A
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.)
Ping An Technology Shenzhen Co Ltd
Original Assignee
Ping An Technology Shenzhen 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 Ping An Technology Shenzhen Co Ltd filed Critical Ping An Technology Shenzhen Co Ltd
Priority to CN201811121915.2A priority Critical patent/CN109460291A/en
Publication of CN109460291A publication Critical patent/CN109460291A/en
Pending legal-status Critical Current

Links

Classifications

    • 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
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2209/00Indexing scheme relating to G06F9/00
    • G06F2209/50Indexing scheme relating to G06F9/50
    • G06F2209/508Monitor

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer And Data Communications (AREA)

Abstract

The present invention relates to loads to deploy, propose the method and storage medium of a kind of controller perturbation server cluster, if by monitoring that having server to execute in server cluster completes current first task, then in the first preset time period, so that the server maintains the first process instance for executing the first task, when first process instance includes the first process and the first operation;If monitoring, the process instance is in blank state in first preset time period, terminates first process, and when keeping in the second preset time period the described first operation;If monitoring in second preset time period, described first is in blank state when running, then when discharging the described first operation.Spatial cache can be realized to the resource in server cluster, improve the service performance and resource utilization of server cluster.In addition, the present invention also proposes a kind of electronic device and storage medium.

Description

Electronic device, the method for controller perturbation server cluster and storage medium
Technical field
The present invention relates to server cluster management domain more particularly to a kind of electronic devices, controller perturbation server cluster Method and storage medium.
Background technique
Currently, being configured generally according to the maximum traffic demand counted available in the resource management of cluster server Although resource, this resources employment methods are able to satisfy the demand of business, but will also result in the scene of vast resources waste.Such as gold The checking request of the short message verification code of user's transmission would generally be related to by melting in service industry, as user needs to log in online silver Capable, the big amount of money is transferred accounts, or when the operation such as withdrawal, can be related to sending the checking request of short message verification code.In order to prevent same The checking request received in one period reaches certain amount, leads to the inadequate resource of server cluster and causes not to client Good influence comes the available resources of configuration server cluster, this resource generally according to the obtained maximum user's operation capacity of statistics Configuration mode easily causes the waste of server resource.In addition, since different business scenarios needs server money to be used Source is not also identical, if therefore it is not high also to easily lead to resource utilization without elastic mechanism to the management of server resource The problem of occur.
Summary of the invention
In view of this, the present invention proposes the method and storage medium of a kind of electronic device, controller perturbation server cluster, energy Enough resources in server cluster realize spatial cache, improve the service performance and resource utilization of server cluster.
Firstly, to achieve the above object, the present invention proposes a kind of electronic device, the electronic device include memory and The processor connecting with the memory, the processor is for executing the controller perturbation server set stored on the memory The program of group, the program of the controller perturbation server cluster realize following steps when being executed by the processor:
If A1, monitoring there is server to execute the current first task of completion in server cluster, when first is default Between in section so that the server maintains the first process instance for executing the first task, first process instance includes the When one process and the first operation;
If A2, monitoring that the process instance is in blank state in first preset time period, terminate described First process, and when keeping in the second preset time period the described first operation;
If A3, monitoring in second preset time period, described first is in blank state when running, then discharges institute When stating the first operation.
Preferably, first process includes the processing that context is executed to main memory one or more and point of other resources Match;It is the instruction in a kind of execution user request or code when the described first operation, and clothes when providing operation for the code The code execution environments of business.
It preferably, include resource management layer and one group of hardware thread when the described first operation;First process is from resource Management level obtain the access to processing and other resources in server system.
Preferably, the initial time of second preset time period is the finish time of the first time period, described the Two preset time periods are greater than first preset time period.
Preferably, when the program of the controller perturbation server cluster is executed by the processor, following steps are also realized:
If receiving the first task or second task again, it is determined that each in the server cluster Whether first running example is maintained in server;
First running example is maintained in server if it is determined that having, and first running example is in blank state, Then the first task is distributed to first running example, or first running example first operation when on create fortune The process of row second task;
If maintaining first running example in serverless backup, it is determined that each server in the server cluster In whether maintain described first operation when;
If it is determined that have maintained in server described first operation when, it is determined that this first operation when on creation operation institute State the process of first task or second task.
In addition, to achieve the goals above, a kind of method that the present invention also proposes controller perturbation server cluster, the side Method includes the following steps:
If S1, monitoring there is server to execute the current first task of completion in server cluster, when first is default Between in section so that the server maintains the first process instance for executing the first task, first process instance includes the When one process and the first operation;
If S2, monitoring that the process instance is in blank state in first preset time period, terminate described First process, and when keeping in the second preset time period the described first operation;
If S3, monitoring in second preset time period, described first is in blank state when running, then discharges institute When stating the first operation.
Preferably, first process includes the processing that context is executed to main memory one or more and point of other resources Match;It is the instruction in a kind of execution user request or code when the described first operation, and clothes when providing operation for the code The code execution environments of business.
It preferably, include resource management layer and one group of hardware thread when the described first operation;First process is from resource Management level obtain the access to processing and other resources in server system.
Preferably, the initial time of second preset time period is the finish time of the first time period, described the Two preset time periods are greater than first preset time period.
In addition, to achieve the above object, the present invention also proposes a kind of computer readable storage medium, described computer-readable Storage medium is stored with the program of controller perturbation server cluster, and the program of the controller perturbation server cluster can be by least one A processor executes, so that at least one described processor executes the step of the method for controller perturbation server cluster as described above Suddenly.
The method and storage medium of electronic device, controller perturbation server cluster proposed by the invention, if passing through monitoring There is server to execute into server cluster and complete current first task, then in the first preset time period, so that the service Device maintains the first process instance for executing the first task, and first process instance includes the first process and the first operation When;If monitoring, the process instance is in blank state in first preset time period, terminates first process, And when keeping the described first operation in the second preset time period;If monitoring in second preset time period, described Blank state is in when one operation, then when discharging the described first operation.It can realize that caching is empty to the resource in server cluster Between, improve the service performance and resource utilization of server cluster.
Detailed description of the invention
Fig. 1 is the schematic diagram of the optional hardware structure of electronic device one proposed by the present invention;
Fig. 2 is the program module signal of the program of elastic control server cluster in one embodiment of electronic device of the present invention Figure;
Fig. 3 is the implementation flow chart of the method preferred embodiment of controller perturbation server cluster of the present invention.
The embodiments will be further described with reference to the accompanying drawings for the realization, the function and the advantages of the object of the present invention.
Specific embodiment
In order to make the objectives, technical solutions, and advantages of the present invention clearer, with reference to the accompanying drawings and embodiments, right The present invention is further elaborated.It should be appreciated that described herein, specific examples are only used to explain the present invention, not For limiting the present invention.Based on the embodiments of the present invention, those of ordinary skill in the art are not before making creative work Every other embodiment obtained is put, shall fall within the protection scope of the present invention.
It should be noted that the description for being related to " first ", " second " etc. in the present invention is used for description purposes only, and cannot It is interpreted as its relative importance of indication or suggestion or implicitly indicates the quantity of indicated technical characteristic.Define as a result, " the One ", the feature of " second " can explicitly or implicitly include at least one of the features.In addition, the skill between each embodiment Art scheme can be combined with each other, but must be based on can be realized by those of ordinary skill in the art, when technical solution Will be understood that the combination of this technical solution is not present in conjunction with there is conflicting or cannot achieve when, also not the present invention claims Protection scope within.
As shown in fig.1, being the optional hardware structure schematic diagram of electronic device one proposed by the present invention.In the present embodiment, Electronic device 10 may include, but be not limited only to, and connection memory 11, processor 12, net can be in communication with each other by communication bus 14 Network interface 13.It should be pointed out that Fig. 1 illustrates only the electronic device 10 with component 11-14, it should be understood that simultaneously All components shown realistic are not applied, the implementation that can be substituted is more or less component.
Wherein, memory 11 includes at least a type of computer readable storage medium, computer readable storage medium Including flash memory, hard disk, multimedia card, card-type memory (for example, SD or DX memory etc.), random access storage device (RAM), quiet State random access storage device (SRAM), electrically erasable programmable read-only memory (EEPROM), can be compiled read-only memory (ROM) Journey read-only memory (PROM), magnetic storage, disk, CD etc..In some embodiments, memory 11 can be electronics dress Set 10 internal storage unit, such as the hard disk or memory of electronic device 10.In further embodiments, memory 11 can also be with It is the outer packet storage device of electronic device 10, such as the plug-in type hard disk being equipped on electronic device 10, intelligent memory card (Smart Media Card, SMC), secure digital (Secure Digital, SD) card, flash card (Flash Card) etc..Certainly, it stores Device 11 can also both including electronic device 10 internal storage unit and also including its outer packet storage device.In the present embodiment, storage Device 11 is installed on the operating system and types of applications software of electronic device 10, such as controller perturbation server set commonly used in storage The program etc. of group.In addition, memory 11 can be also used for temporarily storing the Various types of data that has exported or will export.
Processor 12 can be in some embodiments central processing unit (Central Processing Unit, CPU), Controller, microcontroller, microprocessor or other data processing chips.Processor 12 is commonly used in control electronic device 10 Overall operation.In the present embodiment, program code or processing data of the processor 12 for being stored in run memory 11, such as The program etc. of the controller perturbation server cluster of operation.
Network interface 13 may include radio network interface or wired network interface, and network interface 13 is commonly used in filling in electronics It sets and establishes communication connection between 10 and other electronic equipments.
Communication bus 14 is for realizing the communication connection between component 11-13.
Fig. 1 illustrates only the electronic device 10 of the program with component 11-14 and controller perturbation server cluster, still It should be understood that, it is not required that implement all components shown, the implementation that can be substituted is more or less component.
Optionally, electronic device 10 can also include user interface (not shown in figure 1), and user interface may include display Device, input unit such as keyboard, wherein user interface can also be including standard wireline interface and wireless interface etc..
Optionally, in some embodiments, display can be light-emitting diode display, liquid crystal display, touch control type LCD and show Device and OLED touch device etc..Further, display is alternatively referred to as display screen or display unit, for being shown in electronic device Information is handled in 10 and for showing visual user interface.
Optionally, in some embodiments, electronic device 10 can also include that audio unit (does not show in audio unit Fig. 1 Out), audio unit can be in call signal reception pattern, call mode, logging mode, speech recognition mould in electronic device 10 When under the isotypes such as formula, broadcast reception mode, received or storage audio data is converted into audio signal;Further Ground, electronic device 10 can also include audio output unit, and the audio signal that audio output unit converts audio unit exports, And audio output unit can also provide the relevant audio output of specific function that executes to electronic device 10 (such as calling is believed Number receive sound, message sink sound etc.), audio output unit may include loudspeaker, buzzer etc..
Optionally, in some embodiments, electronic device 10 can also include alarm unit (not shown), alarm list Member can provide output and the generation of event is notified electron device 10.Typical event may include calling reception, message Reception, key signals input, touch input etc..Other than audio or video export, alarm unit can be with different sides Formula provides output with the generation of notification event.For example, alarm unit can provide output in the form of vibration, exhaled when receiving Cry, message or it is some other can make electronic device 10 enter communication pattern when, alarm unit can provide tactile output (that is, Vibration) to notify to user.
In one embodiment, the program of the controller perturbation server cluster stored in memory 11 is executed by processor 12 When, realize following operation:
A1, if monitoring, having server to execute in server cluster completes current first task, when first is default Between in section so that the server maintains the first process instance for executing the first task, first process instance (instance) when being run including the first process and first;
Specifically, in the present embodiment, first process includes executing context (i.e. line to main memory one or more Journey) processing and other resources distribution.
It is the instruction in a kind of execution user request or code when the described first operation, and provides operation for the code When the code execution environments that service.The service provided when specifically, according to the first operation is different, when being further divided into core operation It is serviced when service and enhancing operation, service may include the function of such as process, thread and memory management when the core is run Can, the enhancing run when service may include for example error handle with establish safety and internuncial function.In this implementation In example, service is the function of management of process when the operation.
It further, in the present embodiment, include resource management layer and one group of hardware thread when the described first operation.It uses Resource management layer and hardware thread allow to execute task from first process and coexist with first process The task of any other process.It is operated in conjunction with resource management layer when the first operation to allow first process to obtain server Processor and other resources, such as hardware thread.
Specifically, first process is obtained from resource management layer to the processing and other resource (examples in server system Such as, hardware thread) access.First process is performed first task using the processing and other resources.
In the present embodiment, if monitoring, having server to execute in server cluster completes current first task, In first preset time period, when so that the server keeping executing the first process and the first operation of the first task.Specifically, First preset time period is too long, and to will lead to for the first process instance standby time too long, wastes system resource, described first is pre- If period too short the first different processes that will lead in the first process instance frequently first operation when on substitute, increase The expense of system.Therefore, the first preset time period needs are preset according to actual process instance use state, In the present embodiment, first preset time period is 1 minute.In this way, if being received again in first preset time period The request of the first task is executed, then the request of the execution first task can be distributed to the process instance and be executed. The utilization efficiency of process instance is improved, reduces and destroys and create the occupied system consumption of process instance.
Step S2, if monitoring, the process instance is in blank state in first preset time period, terminates First process, and when keeping in the second preset time period the described first operation;
Specifically, if monitoring, the process instance is in blank state in first preset time period, illustrates The request for continuing to execute the first task is not received by first preset time period, at this point, then terminating described One process.
It should be noted that a variety of processes can be run in certain type of operation.For example, being led in financial service Domain runs different service requests when the operation of java class usually can be used (runtime), and the fortune of Python can be used When row (runtime), different data analysis requests is run, if transaction data is analyzed, deposit data analysis etc..In the present embodiment In, such as short message verification code request and recognition of face request are when can operate in the operation of java class on (runtime).Cause This, in the present embodiment, when keeping the described first operation in the second preset time period, in this way, when in the second preset time period The request for second task that executes inside is received, and needed for process needed for executing second task and executing the first task Run phase simultaneously, then can in the described first operation on establish the process for executing second task.When improving operation (runtime) utilization efficiency, and reduce the system consumption of (runtime) release and creation when running.Specifically, described The initial time of two preset time periods is the finish time of the first time period, and second preset time period is greater than described the One preset time period.But second preset time period be also not easy it is too long, the present embodiment be 5 minutes.Usually described first is pre- If time and second preset time are required to be obtained according to a large amount of running example data statistics.
For example, in this example, it is assumed that the first task is to obtain the request of short message verification code, second task For the request of recognition of face, then the execution context number of the first task need to be only discharged in second preset time period According to, while according to the application programming interface (API) that provides when the described first operation or programming language feature and corresponding Tool obtains the execution context data of the second task, carries out when creating second task, and running by described first Second task.
Step S3, if monitoring in second preset time period, described first is in blank state when running, then releases When putting the described first operation.
Further, if receiving the first task or second task again, it is determined that the server set First running example whether is maintained in each server in group;
First running example is maintained in server if it is determined that having, and first running example is in blank state, Then the first task is distributed to first running example, or first running example first operation when on create fortune The process of row second task;
If maintaining first running example in serverless backup, it is determined that each server in the server cluster In whether maintain described first operation when;
If it is determined that have maintained in server described first operation when, it is determined that this first operation when on creation operation institute State the process of first task or second task.
It is to be appreciated that due to the process that would generally run multiple business when operation, so in the present embodiment, in order to keep away Exempt from the idle overlong time of process instance, the request for executing first task is not received by the first preset time period, or When the second task of execution for receiving and not identical process instance needed for executing the first task, described in end first first into Journey, and when saving in second preset time period the described first operation, so that other business process can continue to described It is executed in when the first operation.Further, due to occupying excess resource when operation, long-play may cause the operation luck Row waste vast resources, causes resource when other operations inadequate, so needing to discharge in second preset time period should When the first operation.Release and newly-built frequency when the described first operation are less than first process.
By above-mentioned thing embodiment it is found that electronic device proposed by the present invention, if by monitoring there are clothes in server cluster Device of being engaged in executes and completes current first task, then in the first preset time period so that the server maintain execution this first First process instance of task, when first process instance includes the first process and the first operation;If monitoring described The process instance is in blank state in one preset time period, then terminates first process, and in the second preset time period When interior the described first operation of holding;If monitoring in second preset time period, described first is in vacant shape when running State, then when discharging the described first operation.Spatial cache can be realized to the resource in server cluster, improve server cluster Service performance and resource utilization.
In addition, the program of controller perturbation server cluster of the invention is different according to the function that its each section is realized, it can It is described with program module with the same function.It please refers to shown in Fig. 2, is elastic in one embodiment of electronic device of the present invention The program module schematic diagram of the program of control server cluster.In the present embodiment, the program foundation of controller perturbation server cluster The difference for the function that its each section is realized can be divided into monitoring modular 201, ending module 202 and release module 203.By above description it is found that the so-called program module of the present invention is the series of computation machine journey for referring to complete specific function Sequence instruction segment, than program more suitable for describing implementation procedure of the program of controller perturbation server cluster in electronic device 10. The functions or operations step that the module 201-203 is realized is similar as above, and and will not be described here in detail, illustratively, such as Wherein:
Monitoring modular 201 is used for
If monitoring has server to execute in server cluster complete current first task, in the first preset time period It is interior so that the server maintain execute the first task the first process instance, first process instance include first into When journey and the first operation;
If ending module 202 is for monitoring that the process instance is in vacant shape in first preset time period State then terminates first process, and when keeping in the second preset time period the described first operation;
If release module 203, for monitoring in second preset time period, described first is in vacant when running State, then when discharging the described first operation.
In addition, a kind of method that the present invention also proposes controller perturbation server cluster, please refers to shown in Fig. 3, the elasticity The method of control server cluster includes the following steps:
S301, if monitoring, having server to execute in server cluster completes current first task, default first In period, so that the server maintains the first process instance for executing the first task, first process instance (instance) when being run including the first process and first;
Specifically, in the present embodiment, first process includes executing context (i.e. line to main memory one or more Journey) processing and other resources distribution.
It is the instruction in a kind of execution user request or code when the described first operation, and provides operation for the code When the code execution environments that service.The service provided when specifically, according to the first operation is different, when being further divided into core operation It is serviced when service and enhancing operation, service may include the function of such as process, thread and memory management when the core is run Can, the enhancing run when service may include for example error handle with establish safety and internuncial function.In this implementation In example, service is the function of management of process when the operation.
It further, in the present embodiment, include resource management layer and one group of hardware thread when the described first operation.It uses Resource management layer and hardware thread allow to execute task from first process and coexist with first process The task of any other process.It is operated in conjunction with resource management layer when the first operation to allow first process to obtain server Processor and other resources, such as hardware thread.
Specifically, first process is obtained from resource management layer to the processing and other resource (examples in server system Such as, hardware thread) access.First process is performed first task using the processing and other resources.
In the present embodiment, if monitoring, having server to execute in server cluster completes current first task, In first preset time period, when so that the server keeping executing the first process and the first operation of the first task.Specifically, First preset time period is too long, and to will lead to for the first process instance standby time too long, wastes system resource, described first is pre- If period too short the first different processes that will lead in the first process instance frequently first operation when on substitute, increase The expense of system.Therefore, the first preset time period needs are preset according to actual process instance use state, In the present embodiment, first preset time period is 1 minute.In this way, if being received again in first preset time period The request of the first task is executed, then the request of the execution first task can be distributed to the process instance and be executed. The utilization efficiency of process instance is improved, reduces and destroys and create the occupied system consumption of process instance.
Step S302, if monitoring, the process instance is in blank state in first preset time period, is tied The first process of Shu Suoshu, and when keeping in the second preset time period the described first operation;
Specifically, if monitoring, the process instance is in blank state in first preset time period, illustrates The request for continuing to execute the first task is not received by first preset time period, at this point, then terminating described One process.
It should be noted that a variety of processes can be run in certain type of operation.For example, being led in financial service Domain runs different service requests when the operation of java class usually can be used (runtime), and the fortune of Python can be used When row (runtime), different data analysis requests is run, if transaction data is analyzed, deposit data analysis etc..In the present embodiment In, such as short message verification code request and recognition of face request are when can operate in the operation of java class on (runtime).Cause This, in the present embodiment, when keeping the described first operation in the second preset time period, in this way, when in the second preset time period The request for second task that executes inside is received, and needed for process needed for executing second task and executing the first task Run phase simultaneously, then can in the described first operation on establish the process for executing second task.When improving operation (runtime) utilization efficiency, and reduce the system consumption of (runtime) release and creation when running.Specifically, described The initial time of two preset time periods is the finish time of the first time period, and second preset time period is greater than described the One preset time period.But second preset time period be also not easy it is too long, the present embodiment be 5 minutes.Usually described first is pre- If time and second preset time are required to be obtained according to a large amount of running example data statistics.
For example, in this example, it is assumed that the first task is to obtain the request of short message verification code, second task For the request of recognition of face, then the execution context number of the first task need to be only discharged in second preset time period According to, while according to the application programming interface (API) that provides when the described first operation or programming language feature and corresponding Tool obtains the execution context data of the second task, carries out when creating second task, and running by described first Second task.
Step S303, if monitoring in second preset time period, described first is in blank state when running, then When discharging the described first operation.
Further, if receiving the first task or second task again, it is determined that the server set First running example whether is maintained in each server in group;
First running example is maintained in server if it is determined that having, and first running example is in blank state, Then the first task is distributed to first running example, or first running example first operation when on create fortune The process of row second task;
If maintaining first running example in serverless backup, it is determined that each server in the server cluster In whether maintain described first operation when;
If it is determined that have maintained in server described first operation when, it is determined that this first operation when on creation operation institute State the process of first task or second task.
It is to be appreciated that due to the process that would generally run multiple business when operation, so in the present embodiment, in order to keep away Exempt from the idle overlong time of process instance, the request for executing first task is not received by the first preset time period, or When the second task of execution for receiving and not identical process instance needed for executing the first task, described in end first first into Journey, and when saving in second preset time period the described first operation, so that other business process can continue to described It is executed in when the first operation.Further, due to occupying excess resource when operation, long-play may cause the operation luck Row waste vast resources, causes resource when other operations inadequate, so needing to discharge in second preset time period should When the first operation.Release and newly-built frequency when the described first operation are less than first process.
By above-mentioned thing embodiment it is found that the method for controller perturbation server cluster proposed by the present invention, if by monitoring There is server to execute in server cluster and complete current first task, then in the first preset time period, so that the server The first process instance for executing the first task is maintained, when first process instance includes the first process and the first operation; If monitoring, the process instance is in blank state in first preset time period, terminates first process, and When keeping the described first operation in the second preset time period;If monitoring in second preset time period, described first Blank state is in when operation, then when discharging the described first operation.Spatial cache can be realized to the resource in server cluster, Improve the service performance and resource utilization of server cluster.
In addition, the present invention also proposes a kind of computer readable storage medium, stored on the computer readable storage medium It is realized when the program of the program of flexible control server cluster, the controller perturbation server cluster is executed by processor as follows Operation:
If monitoring has server to execute in server cluster complete current first task, in the first preset time period It is interior so that the server maintain execute the first task the first process instance, first process instance include first into When journey and the first operation;
If monitoring, the process instance is in blank state in first preset time period, terminates described first Process, and when keeping in the second preset time period the described first operation;
If monitoring in second preset time period, described first is in blank state when running, then described in release When the first operation.
The specific implementation process of computer readable storage medium of the present invention, with above-mentioned electronic device and controller perturbation service The specific implementation process of the method for device cluster is similar, and details are not described herein.
By above-mentioned analysis it is found that computer readable storage medium proposed by the present invention, if by monitoring server set There is server to execute in group and complete current first task, then in the first preset time period, so that the server is maintained and held First process instance of the row first task, when first process instance includes the first process and the first operation;If monitoring The process instance is in blank state in first preset time period, then terminates first process, and pre- second If keep the described first operation in the period;If monitoring in second preset time period, described first operation when at In blank state, then when discharging the described first operation.Spatial cache can be realized to the resource in server cluster, improve service The service performance and resource utilization of device cluster.
Through the above description of the embodiments, those skilled in the art can be understood that above-described embodiment side Method can be realized by means of software and necessary general hardware platform, naturally it is also possible to by hardware, but in many cases The former is more preferably embodiment.Based on this understanding, technical solution of the present invention substantially in other words does the prior art The part contributed out can be embodied in the form of software products, which is stored in a storage medium In (such as ROM/RAM, magnetic disk, CD), including some instructions are used so that a terminal device (can be mobile phone, computer, clothes Business device, air conditioner or the network equipment etc.) execute method described in each embodiment of the present invention.The above is only of the invention excellent Embodiment is selected, is not intended to limit the scope of the invention, it is all using made by description of the invention and accompanying drawing content etc. Structure or equivalent process transformation are imitated, is applied directly or indirectly in other relevant technical fields, and is similarly included in the present invention Scope of patent protection in.

Claims (10)

1. a kind of electronic device, which is characterized in that the electronic device includes memory and the processing that connect with the memory Device, the processor are used to execute the program of the controller perturbation server cluster stored on the memory, the controller perturbation The program of server cluster realizes following steps when being executed by the processor:
If A1, monitoring there is server to execute the current first task of completion in server cluster, in the first preset time period It is interior so that the server maintain execute the first task the first process instance, first process instance include first into When journey and the first operation;
If A2, monitoring that the process instance is in blank state in first preset time period, terminates described first Process, and when keeping in the second preset time period the described first operation;
If A3, monitoring in second preset time period, when the described first operation, is in blank state, then discharges described the When one operation.
2. electronic device as described in claim 1, which is characterized in that first process includes holding to main memory one or more The processing of row context and the distribution of other resources;Described first operation when be it is a kind of execution user request in instruction or generation Code, and the code execution environments serviced when operation are provided for the code.
3. electronic device as described in claim 1, which is characterized in that include resource management layer and one group when the described first operation Hardware thread;First process obtains the access to processing and other resources in server system from resource management layer.
4. electronic device as described in claim 1, which is characterized in that the initial time of second preset time period is described The finish time of first time period, second preset time period are greater than first preset time period.
5. the electronic device as described in claim 1-4 is any, which is characterized in that the program of the controller perturbation server cluster When being executed by the processor, following steps are also realized:
If receiving the first task or second task again, it is determined that each service in the server cluster Whether first running example is maintained in device;
First running example is maintained in server if it is determined that having, and first running example is in blank state, then will The first task is distributed to first running example, or first running example first operation when on creation operation institute State the process of the second task;
If maintaining first running example in serverless backup, it is determined that be in each server in the server cluster It is no maintain described first operation when;
If it is determined that having when maintaining the described first operation in server, it is determined that creation operation described the in first operation The process of one task or second task.
6. a kind of method of controller perturbation server cluster, which is characterized in that described method includes following steps:
If S1, monitoring there is server to execute the current first task of completion in server cluster, in the first preset time period It is interior so that the server maintain execute the first task the first process instance, first process instance include first into When journey and the first operation;
If S2, monitoring that the process instance is in blank state in first preset time period, terminates described first Process, and when keeping in the second preset time period the described first operation;
If S3, monitoring in second preset time period, when the described first operation, is in blank state, then discharges described the When one operation.
7. the method for controller perturbation server cluster as claimed in claim 6, which is characterized in that
First process includes the processing that context is executed to main memory one or more and the distribution of other resources;Described first Be when operation it is a kind of execution user request in instruction or code, and provided for the code serviced when operation code execution Environment.
8. the method for controller perturbation server cluster as claimed in claim 7, which is characterized in that include when the described first operation Resource management layer and one group of hardware thread;First process from resource management layer obtain in server system processing and its The access of his resource.
9. the method for controller perturbation server cluster as claimed in claim 8, which is characterized in that second preset time period Initial time be the first time period finish time, second preset time period be greater than first preset time Section.
10. a kind of computer readable storage medium, the flexible control server cluster of computer-readable recording medium storage Program, the program of the controller perturbation server cluster can execute by least one processor, so that described at least one The step of managing the method for controller perturbation server cluster of the device execution as described in any one of claim 6-9.
CN201811121915.2A 2018-09-26 2018-09-26 Electronic device, the method for controller perturbation server cluster and storage medium Pending CN109460291A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811121915.2A CN109460291A (en) 2018-09-26 2018-09-26 Electronic device, the method for controller perturbation server cluster and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811121915.2A CN109460291A (en) 2018-09-26 2018-09-26 Electronic device, the method for controller perturbation server cluster and storage medium

Publications (1)

Publication Number Publication Date
CN109460291A true CN109460291A (en) 2019-03-12

Family

ID=65606888

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811121915.2A Pending CN109460291A (en) 2018-09-26 2018-09-26 Electronic device, the method for controller perturbation server cluster and storage medium

Country Status (1)

Country Link
CN (1) CN109460291A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115237608A (en) * 2022-09-21 2022-10-25 之江实验室 Multi-mode scheduling system and method based on unified computing power of multiple clusters

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6314114B1 (en) * 1998-06-23 2001-11-06 Oracle Corporation Distributed resource management
CN1625170A (en) * 2003-12-03 2005-06-08 华为技术有限公司 Method for realizing large number of user on-line simultaneously of universal group radio operation
CN1755634A (en) * 2004-09-29 2006-04-05 国际商业机器公司 Method, system for supporting a large number of intermittently used application clusters
US7634542B1 (en) * 2005-07-01 2009-12-15 Sprint Communications Company L.P. System and method to manage service instances for request processing
US10013273B1 (en) * 2016-06-22 2018-07-03 Amazon Technologies, Inc. Virtual machine termination management

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6314114B1 (en) * 1998-06-23 2001-11-06 Oracle Corporation Distributed resource management
CN1625170A (en) * 2003-12-03 2005-06-08 华为技术有限公司 Method for realizing large number of user on-line simultaneously of universal group radio operation
CN1755634A (en) * 2004-09-29 2006-04-05 国际商业机器公司 Method, system for supporting a large number of intermittently used application clusters
US7634542B1 (en) * 2005-07-01 2009-12-15 Sprint Communications Company L.P. System and method to manage service instances for request processing
US10013273B1 (en) * 2016-06-22 2018-07-03 Amazon Technologies, Inc. Virtual machine termination management

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115237608A (en) * 2022-09-21 2022-10-25 之江实验室 Multi-mode scheduling system and method based on unified computing power of multiple clusters

Similar Documents

Publication Publication Date Title
CN107729139B (en) Method and device for concurrently acquiring resources
CN108536538A (en) Processor core dispatching method, device, terminal and storage medium
CN108462760A (en) Electronic device, cluster access domain name automatic generation method and storage medium
CN108449410A (en) Information management method, system and relevant apparatus in a kind of cloud platform
CN110049113A (en) Service message processing method and device
CN109684073A (en) Electronic device, cloud service resource allocation methods and storage medium
CN109766172B (en) Asynchronous task scheduling method and device
CN110300067A (en) Queue regulation method, device, equipment and computer readable storage medium
CN101025698A (en) Apparatus for forcibly terminating thread blocked on input/output operation and method for the same
CN108446171A (en) Electronic device, distributed system execute method for allocating tasks and storage medium
CN111858007A (en) Task scheduling method and device based on message middleware
CN102541661A (en) Wait on address synchronization interface
CN109800083A (en) A kind of method, apparatus, system and storage medium that micro services collaboration is called
CN110222535A (en) Processing unit, method and the storage medium of block chain configuration file
CN108415925A (en) Electronic device, data call daily record generation and querying method and storage medium
CN105550041A (en) Mobile terminal control method and device
CN108681481A (en) The processing method and processing device of service request
CN109992415B (en) Container dispatching method and dispatching system
CN109561134B (en) Electronic device, distributed cluster service distribution method and storage medium
CN107391274A (en) The processing method and processing device of deferred information
CN110333916A (en) Request message processing method, device, computer system and readable storage medium storing program for executing
CN109460291A (en) Electronic device, the method for controller perturbation server cluster and storage medium
CN109005465B (en) Bullet screen message distribution method, device, equipment and storage medium
CN116032614A (en) Container network micro-isolation method, device, equipment and medium
CN109634806A (en) Electronic device, server cluster monitoring method and storage medium

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