[go: up one dir, main page]
More Web Proxy on the site http://driver.im/

CN113760534A - Application service degradation method and device - Google Patents

Application service degradation method and device Download PDF

Info

Publication number
CN113760534A
CN113760534A CN202110236516.6A CN202110236516A CN113760534A CN 113760534 A CN113760534 A CN 113760534A CN 202110236516 A CN202110236516 A CN 202110236516A CN 113760534 A CN113760534 A CN 113760534A
Authority
CN
China
Prior art keywords
application service
hardware information
degradation
hardware
type corresponding
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
CN202110236516.6A
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.)
Beijing Jingdong Century Trading Co Ltd
Beijing Wodong Tianjun Information Technology Co Ltd
Original Assignee
Beijing Jingdong Century Trading Co Ltd
Beijing Wodong Tianjun Information 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 Beijing Jingdong Century Trading Co Ltd, Beijing Wodong Tianjun Information Technology Co Ltd filed Critical Beijing Jingdong Century Trading Co Ltd
Priority to CN202110236516.6A priority Critical patent/CN113760534A/en
Publication of CN113760534A publication Critical patent/CN113760534A/en
Pending legal-status Critical Current

Links

Images

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
    • 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
    • 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/54Interprogram communication
    • G06F9/542Event management; Broadcasting; Multicasting; Notifications

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Multimedia (AREA)
  • Debugging And Monitoring (AREA)

Abstract

The invention discloses an application service degradation method and device, and relates to the technical field of computers. One embodiment of the method comprises: acquiring hardware information; determining a degradation type corresponding to the hardware information according to the hardware information and preset hardware conditions corresponding to the degradation type; and degrading the application service according to the degradation type corresponding to the hardware information. The implementation method can degrade the application service in time and avoid providing invalid service.

Description

Application service degradation method and device
Technical Field
The present invention relates to the field of computer technologies, and in particular, to a method and an apparatus for degrading an application service.
Background
In an actual application scenario, the distributed system calls an application service located in a computer cluster based on an application service registry. When a computer in the cluster is abnormal, the application service running on the computer generally needs to be degraded, such as application service offline or interface current limiting.
The prior art monitors information such as CPU usage, network rate, etc. of a computer using an operating system and degrades an application service based on the information.
However, when the computer is suddenly powered down or forcibly restarted, the operating system cannot timely notify the application service or the application service registry of service degradation.
Disclosure of Invention
In view of this, embodiments of the present invention provide an application service degradation method and apparatus, which can degrade an application service in time and avoid providing an invalid service.
In a first aspect, an embodiment of the present invention provides an application service degradation method applied to a BMC (Baseboard Management Controller), including:
acquiring hardware information;
determining a degradation type corresponding to the hardware information according to the hardware information and preset hardware conditions corresponding to the degradation type;
and degrading the application service according to the degradation type corresponding to the hardware information.
Alternatively,
the hardware information comprises: an event log;
determining a degradation type corresponding to the hardware information according to the hardware information and a preset hardware condition corresponding to the degradation type, wherein the determining the degradation type corresponding to the hardware information comprises:
and matching the event type in the event log with the event type corresponding to the degradation type, and determining the degradation type corresponding to the event log.
Alternatively,
the hardware information comprises: a health indicator of the hardware;
determining a degradation type corresponding to the hardware information according to the hardware information and a preset hardware condition corresponding to the degradation type, wherein the determining the degradation type corresponding to the hardware information comprises:
and matching the health index of the hardware with the health index range corresponding to the degradation type, and determining the degradation type corresponding to the health index of the hardware.
Alternatively,
the degradation type corresponding to the hardware information is current limit;
the degrading the application service according to the degradation type corresponding to the hardware information comprises the following steps:
and sending the hardware information to the application service so that the application service limits the interface flow according to the hardware information and a preset interface flow limiting strategy.
Alternatively,
the sending the hardware information to the application service includes:
and sending the hardware information to the application service through the ipmitool.
Alternatively,
the degradation type corresponding to the hardware information is current limit;
the degrading the application service according to the degradation type corresponding to the hardware information comprises the following steps:
and sending the hardware information to the application service so that the application service limits log output according to the hardware information and a preset log degradation strategy.
Alternatively,
the degradation type corresponding to the hardware information is offline;
further comprising: acquiring an IP and an interface identifier of the application service from an operating system;
the degrading the application service according to the degradation type corresponding to the hardware information comprises the following steps:
and sending the IP and the interface identification of the application service to an application service registration center so that the application service registration center can log off the interface of the application service according to the IP and the interface identification of the application service.
In a second aspect, an embodiment of the present invention provides an application service degradation apparatus, applied to a BMC, including:
the acquisition module is configured to acquire hardware information;
the determining module is configured to determine a degradation type corresponding to the hardware information according to the hardware information and preset hardware conditions corresponding to the degradation type;
and the degradation module is configured to degrade the application service according to the degradation type corresponding to the hardware information.
In a third aspect, an embodiment of the present invention provides an electronic device, including:
one or more processors;
a storage device for storing one or more programs,
when executed by the one or more processors, cause the one or more processors to implement a method as in any one of the embodiments described above.
In a fourth aspect, the present invention provides a computer readable medium, on which a computer program is stored, and when the program is executed by a processor, the computer program implements the method according to any one of the above embodiments.
One embodiment of the above invention has the following advantages or benefits: the method is applied to BMC, and the BMC is independent of hardware and an operating system, so that even if a computer is suddenly powered off or forcibly restarted, the method can still degrade the application service in time. In addition, the method can realize different degradation types such as interface current limiting, application service offline and the like according to hardware information, can provide a more detailed degradation scheme aiming at the load condition of hardware, and improves the reliability of the application service.
Further effects of the above-mentioned non-conventional alternatives will be described below in connection with the embodiments.
Drawings
The drawings are included to provide a better understanding of the invention and are not to be construed as unduly limiting the invention. Wherein:
FIG. 1 is a flow diagram of a method for application service downgrade, according to an embodiment of the present invention;
FIG. 2 is a flow diagram of a method for application service downgrade, according to another embodiment of the present invention;
FIG. 3 is a flow diagram of a method for application service downgrade, according to yet another embodiment of the present invention;
fig. 4 is a schematic diagram of an application service degradation apparatus according to an embodiment of the present invention;
FIG. 5 is an exemplary system architecture diagram in which embodiments of the present invention may be employed;
fig. 6 is a schematic block diagram of a computer system suitable for use in implementing a terminal device or server of an embodiment of the invention.
Detailed Description
Exemplary embodiments of the present invention are described below with reference to the accompanying drawings, in which various details of embodiments of the invention are included to assist understanding, and which are to be considered as merely exemplary. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the invention. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
In the prior art, an operating system monitors load parameters of computer hardware and determines whether to downgrade an application service based on the load parameters. For example, the operating system monitors CPU usage and notifies the application service registry to take the application service off-line when CPU usage exceeds 90%.
However, if the computer is powered off or restarted, the operating system cannot notify the application service registry of timely offline application service.
In view of this, as shown in fig. 1, an embodiment of the present invention provides an application service degradation method applied to BMC, including:
step 101: hardware information is acquired.
The BMC is independent of hardware and an operating system, and has independent computing chips, storage structures, battery power supplies, network interfaces and the like. In the embodiment of the invention, the BMC can interact with different hardware to acquire information of the different hardware. Specifically, the hardware may include: magnetic disk, network card, fan, power adapter, bus controller and CPU. The hardware information may include: CPU temperature, fan speed, power adapter voltage, etc. The hardware information can be actively reported by hardware, and can also be actively acquired by the BMC according to actual requirements.
Step 102: and determining the degradation type corresponding to the hardware information according to the hardware information and preset hardware conditions corresponding to the degradation type.
In the embodiment of the invention, different degradation types correspond to different hardware conditions, and the acquired hardware information is matched with various hardware conditions to determine the degradation type corresponding to the hardware information. The types of degradation include: current limiting and inserting. Limiting includes limiting interface traffic and limiting log output. For example, the traffic of one interface is reduced. Offline refers to stopping the service provided by the interface.
It should be noted that it may also be determined from the hardware information that the application service does not need to be degraded, and the application service maintains the current state to operate.
Step 103: and degrading the application service according to the degradation type corresponding to the hardware information.
The method is applied to BMC, and the BMC is independent of hardware and an operating system, so that even if a computer is suddenly powered off or forcibly restarted, the method can still degrade the application service in time. In addition, the method can realize different degradation types such as interface current limiting, application service offline and the like according to hardware information, can provide a more detailed degradation scheme aiming at the load condition of hardware, and improves the reliability of the application service.
In one embodiment of the invention, the hardware information comprises: an event log;
determining the degradation type corresponding to the hardware information according to the hardware information and preset hardware conditions corresponding to the degradation type, wherein the determining comprises the following steps:
and matching the event type in the event log with the event type corresponding to the degradation type, and determining the degradation type corresponding to the event log.
The embodiment of the invention can check whether the hardware reports the Event Log (Event Log) at certain time intervals, for example, every 5 seconds. The event log includes an event identifier and an event type, wherein the event type includes info (general information), warning (warning), and error (serious exception). The event identification is used to identify the source of the event log.
In an embodiment of the present invention, the hardware condition is an event type corresponding to a downgrade type. The corresponding relation between the event type and the degradation type can be determined according to actual requirements. For example, if the event type is info, the application service maintains the existing state; if the event type is warning, the corresponding degradation type is current limit; if the event type is error, the corresponding degradation type is down. In an actual application scenario, the degradation type corresponding to the event type error may be adjusted to be limited, or the degradation type corresponding to the event type warning may be adjusted to be offline.
The same event type for different hardware can correspond to the same degradation type, and can also correspond to different degradation types to adapt to the difference of different hardware. For example, the degradation type corresponding to the event type error of the CPU is offline, and the degradation type corresponding to the event type error of the network card is limited.
The embodiment of the invention can execute the corresponding degradation strategy for the application service according to the event type, and the event log can reflect the running state of the hardware, so the embodiment of the invention can more effectively adjust the application service
In one embodiment of the invention, the hardware information comprises: a health indicator of the hardware;
determining the degradation type corresponding to the hardware information according to the hardware information and preset hardware conditions corresponding to the degradation type, wherein the determining comprises the following steps:
and matching the health index of the hardware with the health index range corresponding to the degradation type, and determining the degradation type corresponding to the health index of the hardware.
The health index of the hardware is used for measuring the health degree of the hardware, and comprises the following steps: CPU temperature, network card inflow and outflow rate, power adapter voltage, fan speed, etc. In the embodiment of the present invention, the hardware condition refers to a health index range, such as a CPU temperature range, a power adapter voltage range, and the like. Different degradation types correspond to different health index ranges, for example, the current limit corresponds to a CPU temperature range of (60 ℃ -90 ℃), and the lower line corresponds to a CPU temperature range of more than 90 ℃.
The embodiment of the invention adjusts the application service based on the health degree of the hardware, considers the difference of the health degrees of different hardware, adjusts the application service more timely and improves the reliability of the application service.
In one embodiment of the invention, the degradation type corresponding to the hardware information is current limit;
according to the degradation type corresponding to the hardware information, degrading the application service, comprising:
and sending the hardware information to an application service so that the application service limits the interface flow according to the hardware information and a preset interface flow limiting strategy.
The application service can perform current limiting on part of interfaces of the application service according to a pre-configured interface current limiting strategy, not only considers the running state of hardware, but also ensures the availability of the application service.
In the embodiment of the present invention, sending the hardware information to the application service includes:
and sending the hardware information to the application service through the ipmitool.
The embodiment of the invention sends the hardware information to the application service through the existing ipmitool without additional development tools. The Ipomitool runs in an operating system, and sends hardware information to the application service based on the semaphore of the operating system, so that excessive output hardware information is prevented, and the performance of the application service is reduced.
In one embodiment of the invention, the degradation type corresponding to the hardware information is current limit;
according to the degradation type corresponding to the hardware information, degrading the application service, comprising:
and sending the hardware information to an application service so that the application service limits log output according to the hardware information and a preset log degradation strategy.
In the embodiment of the invention, the application service can slow down or terminate the log output, because the log output consumes the resources of hardware, and under the condition of larger hardware load, the log output can be reduced, so that the application service can be ensured to process the service request. The embodiment of the invention sends the hardware information to the application service through the ipmitool.
In one embodiment of the invention, the degradation type corresponding to the hardware information is offline;
further comprising: acquiring an IP and an interface identifier of an application service from an operating system;
according to the degradation type corresponding to the hardware information, degrading the application service, comprising:
and sending the IP and the interface identifier of the application service to an application service registration center so that the application service registration center can log off the line of the interface of the application service according to the IP and the interface identifier of the application service.
When the hardware has a serious problem, the application service cannot provide service to the outside, and at this time, the application service needs to be offline, for example, the CPU temperature exceeds 90 ℃. The embodiment of the invention obtains the IP and the interface identification of the application service from the application service running in the operating system through the ipmitool. The application service registry may drop one or more interfaces of the application service based on the IP and interface identification of the application service, and the dropped interface will terminate providing the service. The embodiment of the invention can timely log off the line interface service and avoid providing invalid service.
As shown in fig. 2, an embodiment of the present invention provides an application service degradation method applied to BMC, including:
step 201: and acquiring the IP and the interface identification of the application service from the operating system.
And after the application service is started, providing the IP and the interface identification of the application service to an application service degradation device running on the BMC through the ipmitool. The application service downgrade means stores the IP and interface identification of the application service in a cache.
Step 202: and acquiring the event log and the health index of the hardware.
The method can be implemented by a program running on the BMC. The method can acquire event logs and health indexes of hardware such as a CPU, a network card, a disk, a power adapter, a fan, a memory socket and the like based on the BMC. The embodiment of the present invention is described by taking a CPU as an example.
The CPU obtains an event log and a health index of the CPU through an ipmi protocol, wherein the event type of the event log is error (serious abnormity), and the health index of the CPU is the temperature of the CPU at 95 ℃.
Step 203: and matching the event type in the event log with the event type corresponding to the degradation type, and determining the degradation type corresponding to the event log.
The preset corresponding relation between the event type and the degradation type comprises the following steps: info (general info) corresponds to no degradation, warning corresponds to current limit, error corresponds to offline.
In the embodiment of the invention, the downgrade type corresponding to the event log is offline.
Step 204: and matching the health index of the hardware with the health index range corresponding to the degradation type, and determining the degradation type corresponding to the health index of the hardware.
The preset corresponding relation between the CPU temperature range and the degradation type comprises the following steps: the temperature of the CPU is less than 60 ℃ and is not degraded correspondingly, the temperature range of the CPU (60-90 ℃) is limited correspondingly, and the temperature range of the CPU is more than 90 ℃ and is off-line correspondingly.
The temperature range of the CPU corresponding to the current limiting is (60 ℃ -90 ℃), and the temperature range of the CPU corresponding to the lower line is more than 90 ℃.
In the embodiment of the invention, the degradation type corresponding to the health index of the hardware is offline.
Step 205: and determining the degradation type corresponding to the hardware information according to the degradation type corresponding to the event log and the degradation type corresponding to the health index of the hardware.
In the embodiment of the present invention, since the hardware information includes the event log and the health index of the hardware at the same time, in order to avoid that the degradation types determined by the event log and the health index of the hardware are inconsistent, and thus the application service cannot be degraded, the priority of the event log and the health index of the hardware may be preset in the embodiment of the present invention, and if the degradation types determined by the event log and the health index of the hardware are different, the degradation type corresponding to the hardware information with a high priority is taken as the standard.
Step 206: and sending the IP and the interface identifier of the application service to an application service registration center so that the application service registration center can log off the line of the interface of the application service according to the IP and the interface identifier of the application service.
The application service registration center will get off the line of the interface of the application service according to the IP and the interface identification of the application service, and the front end will obtain the interface of the available application service from the application service registration center and send the service request to the interface of the available application service.
The embodiment of the invention can determine whether the application service needs to be offline according to the health index of the hardware and the event log, and the method runs in the BMC, is independent of an operating system and can timely offline the application service.
As shown in fig. 3, an embodiment of the present invention provides an application service degradation method applied to BMC, including:
step 301: and acquiring the IP and the interface identification of the application service from the operating system.
Step 302: an event log is obtained.
In the embodiment of the invention, when a bad track occurs on a disk, an event log is generated, and the event type can be warning.
Step 303: and matching the event type in the event log with the event type corresponding to the degradation type, and determining the degradation type corresponding to the event log.
The preset corresponding relation between the event type and the degradation type comprises the following steps: info (general info) corresponds to no degradation, warning corresponds to current limit, error corresponds to offline.
In the embodiment of the invention, the degradation type corresponding to the event log is the current limit.
Step 304: and sending the event log to an application service through the ipmitool so that the application service limits log output according to the event log and a preset log degradation strategy.
In an actual application scenario, the application service may perform degradation according to different degradation policies, for example, a log degradation policy may be used to limit log output, or an interface flow limiting policy may be used to limit interface flow. The application service may determine the degradation policy corresponding to the hardware information according to the hardware type or the event type.
As shown in fig. 4, an application service downgrading apparatus according to an embodiment of the present invention is applied to BMC, and includes:
an obtaining module 401 configured to obtain hardware information;
a determining module 402, configured to determine a degradation type corresponding to the hardware information according to the hardware information and a preset hardware condition corresponding to the degradation type;
and the degradation module 403 is configured to degrade the application service according to the degradation type corresponding to the hardware information.
In one embodiment of the invention, the hardware information comprises: an event log;
the determining module 402 is configured to match event types in the event log with event types corresponding to the demotion types, and determine the demotion type corresponding to the event log.
In one embodiment of the invention, the hardware information comprises: a health indicator of the hardware;
the determining module 402 is configured to match the health indicator of the hardware with a health indicator range corresponding to the degradation type, and determine the degradation type corresponding to the health indicator of the hardware.
In one embodiment of the invention, the degradation type corresponding to the hardware information is current limit;
and the downgrading module 403 is configured to send the hardware information to the application service, so that the application service limits the interface traffic according to the hardware information and a preset interface traffic limiting policy.
In one embodiment of the invention, the downgrading module 403 is configured to send the hardware information to the application service through ipmitool.
In one embodiment of the invention, the degradation type corresponding to the hardware information is current limit;
and the downgrading module 403 is configured to send the hardware information to the application service, so that the application service limits log output according to the hardware information and a preset log downgrading policy.
In one embodiment of the invention, the degradation type corresponding to the hardware information is offline;
an obtaining module 401 configured to obtain an IP and an interface identifier of an application service from an operating system;
and the degradation module is configured to send the IP and the interface identifier of the application service to the application service registration center so that the application service registration center can log off the interface of the application service according to the IP and the interface identifier of the application service.
An embodiment of the present invention provides an electronic device, including:
one or more processors;
a storage device for storing one or more programs,
when the one or more programs are executed by the one or more processors, the one or more processors are caused to implement the method of any of the embodiments as described above.
An embodiment of the present invention provides a computer-readable medium, on which a computer program is stored, wherein the computer program is configured to implement the method according to any one of the above embodiments when executed by a processor.
Fig. 5 illustrates an exemplary system architecture 500 to which an application service degradation method or application service degradation apparatus of an embodiment of the present invention may be applied.
As shown in fig. 5, the system architecture 500 may include terminal devices 501, 502, 503, a network 504, and a server 505. The network 504 serves to provide a medium for communication links between the terminal devices 501, 502, 503 and the server 505. Network 504 may include various connection types, such as wired, wireless communication links, or fiber optic cables, to name a few.
The user may use the terminal devices 501, 502, 503 to interact with a server 505 over a network 504 to receive or send messages or the like. The terminal devices 501, 502, 503 may have installed thereon various communication client applications, such as shopping-like applications, web browser applications, search-like applications, instant messaging tools, mailbox clients, social platform software, etc. (by way of example only).
The terminal devices 501, 502, 503 may be various electronic devices having a display screen and supporting web browsing, including but not limited to smart phones, tablet computers, laptop portable computers, desktop computers, and the like.
The server 505 may be a server providing various services, such as a background management server (for example only) providing support for shopping websites browsed by users using the terminal devices 501, 502, 503. The backend management server may analyze and perform other processing on the received data such as the product information query request, and feed back a processing result (for example, target push information, product information — just an example) to the terminal device.
It should be noted that the application service degradation method provided by the embodiment of the present invention is generally executed by the server 505, and accordingly, the application service degradation apparatus is generally disposed in the server 505.
It should be understood that the number of terminal devices, networks, and servers in fig. 5 is merely illustrative. There may be any number of terminal devices, networks, and servers, as desired for implementation.
Referring now to FIG. 6, a block diagram of a computer system 600 suitable for use with a terminal device implementing an embodiment of the invention is shown. The terminal device shown in fig. 6 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present invention.
As shown in fig. 6, the computer system 600 includes a Central Processing Unit (CPU)601 that can perform various appropriate actions and processes according to a program stored in a Read Only Memory (ROM)602 or a program loaded from a storage section 608 into a Random Access Memory (RAM) 603. In the RAM 603, various programs and data necessary for the operation of the system 600 are also stored. The CPU 601, ROM 602, and RAM 603 are connected to each other via a bus 604. An input/output (I/O) interface 605 is also connected to bus 604.
The following components are connected to the I/O interface 605: an input portion 606 including a keyboard, a mouse, and the like; an output portion 607 including a display such as a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and the like, and a speaker; a storage section 608 including a hard disk and the like; and a communication section 609 including a network interface card such as a LAN card, a modem, or the like. The communication section 609 performs communication processing via a network such as the internet. The driver 610 is also connected to the I/O interface 605 as needed. A removable medium 611 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 610 as necessary, so that a computer program read out therefrom is mounted in the storage section 608 as necessary.
In particular, according to the embodiments of the present disclosure, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method illustrated in the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network through the communication section 609, and/or installed from the removable medium 611. The computer program performs the above-described functions defined in the system of the present invention when executed by the Central Processing Unit (CPU) 601.
It should be noted that the computer readable medium shown in the present invention can be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present invention, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In the present invention, however, a computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, fiber optic cable, RF, etc., or any suitable combination of the foregoing.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The modules described in the embodiments of the present invention may be implemented by software or hardware. The described modules may also be provided in a processor, which may be described as: a processor includes a sending module, an obtaining module, a determining module, and a first processing module. The names of these modules do not form a limitation on the modules themselves in some cases, and for example, the sending module may also be described as a "module sending a picture acquisition request to a connected server".
As another aspect, the present invention also provides a computer-readable medium that may be contained in the apparatus described in the above embodiments; or may be separate and not incorporated into the device. The computer readable medium carries one or more programs which, when executed by a device, cause the device to comprise:
acquiring hardware information;
determining a degradation type corresponding to the hardware information according to the hardware information and preset hardware conditions corresponding to the degradation type;
and degrading the application service according to the degradation type corresponding to the hardware information.
According to the technical scheme of the embodiment of the invention, the method is applied to the BMC, and the BMC is independent of hardware and an operating system, so that even if a computer is suddenly powered off or forcibly restarted, the method can still degrade the application service in time. In addition, the method can realize different degradation types such as interface current limiting, application service offline and the like according to hardware information, can provide a more detailed degradation scheme aiming at the load condition of hardware, and improves the reliability of the application service.
The above-described embodiments should not be construed as limiting the scope of the invention. Those skilled in the art will appreciate that various modifications, combinations, sub-combinations, and substitutions can occur, depending on design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

Claims (10)

1. An application service degradation method applied to a Baseboard Management Controller (BMC) comprises the following steps:
acquiring hardware information;
determining a degradation type corresponding to the hardware information according to the hardware information and preset hardware conditions corresponding to the degradation type;
and degrading the application service according to the degradation type corresponding to the hardware information.
2. The method of claim 1,
the hardware information comprises: an event log;
determining a degradation type corresponding to the hardware information according to the hardware information and a preset hardware condition corresponding to the degradation type, wherein the determining the degradation type corresponding to the hardware information comprises:
and matching the event type in the event log with the event type corresponding to the degradation type, and determining the degradation type corresponding to the event log.
3. The method of claim 1,
the hardware information comprises: a health indicator of the hardware;
determining a degradation type corresponding to the hardware information according to the hardware information and a preset hardware condition corresponding to the degradation type, wherein the determining the degradation type corresponding to the hardware information comprises:
and matching the health index of the hardware with the health index range corresponding to the degradation type, and determining the degradation type corresponding to the health index of the hardware.
4. The method of claim 1,
the degradation type corresponding to the hardware information is current limit;
the degrading the application service according to the degradation type corresponding to the hardware information comprises the following steps:
and sending the hardware information to the application service so that the application service limits the interface flow according to the hardware information and a preset interface flow limiting strategy.
5. The method of claim 4,
the sending the hardware information to the application service includes:
and sending the hardware information to the application service through the ipmitool.
6. The method of claim 1,
the degradation type corresponding to the hardware information is current limit;
the degrading the application service according to the degradation type corresponding to the hardware information comprises the following steps:
and sending the hardware information to the application service so that the application service limits log output according to the hardware information and a preset log degradation strategy.
7. The method of claim 1,
the degradation type corresponding to the hardware information is offline;
further comprising: acquiring an IP and an interface identifier of the application service from an operating system;
the degrading the application service according to the degradation type corresponding to the hardware information comprises the following steps:
and sending the IP and the interface identification of the application service to an application service registration center so that the application service registration center can log off the interface of the application service according to the IP and the interface identification of the application service.
8. An application service degradation device, applied to BMC, comprising:
the acquisition module is configured to acquire hardware information;
the determining module is configured to determine a degradation type corresponding to the hardware information according to the hardware information and preset hardware conditions corresponding to the degradation type;
and the degradation module is configured to degrade the application service according to the degradation type corresponding to the hardware information.
9. An electronic device, comprising:
one or more processors;
a storage device for storing one or more programs,
when executed by the one or more processors, cause the one or more processors to implement the method of any one of claims 1-7.
10. A computer-readable medium, on which a computer program is stored, which, when being executed by a processor, carries out the method according to any one of claims 1-7.
CN202110236516.6A 2021-03-03 2021-03-03 Application service degradation method and device Pending CN113760534A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110236516.6A CN113760534A (en) 2021-03-03 2021-03-03 Application service degradation method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110236516.6A CN113760534A (en) 2021-03-03 2021-03-03 Application service degradation method and device

Publications (1)

Publication Number Publication Date
CN113760534A true CN113760534A (en) 2021-12-07

Family

ID=78786662

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110236516.6A Pending CN113760534A (en) 2021-03-03 2021-03-03 Application service degradation method and device

Country Status (1)

Country Link
CN (1) CN113760534A (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110865889A (en) * 2018-08-27 2020-03-06 北京高绎信息技术有限公司 Method and apparatus for transferring events between components
CN111045844A (en) * 2019-11-08 2020-04-21 苏州浪潮智能科技有限公司 Fault degradation method and device
CN111107039A (en) * 2018-10-26 2020-05-05 北京国双科技有限公司 Communication method, device and system based on TCP connection
CN112187505A (en) * 2020-08-17 2021-01-05 杭州安恒信息技术股份有限公司 Adaptive service degradation method, electronic device and storage medium
CN112398700A (en) * 2020-12-07 2021-02-23 平安普惠企业管理有限公司 Service degradation method and device, storage medium and computer equipment

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110865889A (en) * 2018-08-27 2020-03-06 北京高绎信息技术有限公司 Method and apparatus for transferring events between components
CN111107039A (en) * 2018-10-26 2020-05-05 北京国双科技有限公司 Communication method, device and system based on TCP connection
CN111045844A (en) * 2019-11-08 2020-04-21 苏州浪潮智能科技有限公司 Fault degradation method and device
CN112187505A (en) * 2020-08-17 2021-01-05 杭州安恒信息技术股份有限公司 Adaptive service degradation method, electronic device and storage medium
CN112398700A (en) * 2020-12-07 2021-02-23 平安普惠企业管理有限公司 Service degradation method and device, storage medium and computer equipment

Similar Documents

Publication Publication Date Title
CN111131505A (en) Data transmission method, equipment, system, device and medium based on P2P network
CN111510466B (en) Data updating method and device for client, electronic equipment and readable medium
CN113364795B (en) Data transmission method and proxy server
CN112596920A (en) Message processing method and device, electronic equipment and storage medium
CN110881224B (en) Network long connection method, device, equipment and storage medium
CN109428926B (en) Method and device for scheduling task nodes
CN110896362A (en) Fault detection method and device
CN111831503B (en) Monitoring method based on monitoring agent and monitoring agent device
US20120005051A1 (en) Semi-Automated Customer Model-Based Service Deployment Into Data Centers
US8793783B2 (en) Dynamic allocation of network security credentials for alert notification recipients
CN110620806A (en) Information generation method and device
CN110275701B (en) Data processing method, device, medium and computing equipment
CN113220342A (en) Centralized configuration method and device, electronic equipment and storage medium
CN113760534A (en) Application service degradation method and device
CN114257632B (en) Method and device for reconnecting broken wire, electronic equipment and readable storage medium
CN112948138A (en) Method and device for processing message
CN114745276B (en) Switch bandwidth adjusting method and device, electronic equipment and computer readable medium
CN113076175B (en) Memory sharing method and device for virtual machine
CN113626152A (en) Proxy method and device for accessing distributed cluster
CN112688982B (en) User request processing method and device
CN115190125A (en) Monitoring method and device for cache cluster
CN113282455A (en) Monitoring processing method and device
CN113742617A (en) Cache updating method and device
CN112788075A (en) Business service monitoring method and device
CN115118762B (en) Session processing method, client and system

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