CN112486765B - Java application interface management method, system and device and computer readable storage medium - Google Patents

Java application interface management method, system and device and computer readable storage medium Download PDF

Info

Publication number
CN112486765B
CN112486765B CN202011338296.XA CN202011338296A CN112486765B CN 112486765 B CN112486765 B CN 112486765B CN 202011338296 A CN202011338296 A CN 202011338296A CN 112486765 B CN112486765 B CN 112486765B
Authority
CN
China
Prior art keywords
time
application interface
java application
activity
liveness
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202011338296.XA
Other languages
Chinese (zh)
Other versions
CN112486765A (en
Inventor
王蒴
高隆林
李希明
孟庆凯
曲鸣
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shandong Civic Se Commercial Middleware Co ltd
Original Assignee
Shandong Civic Se Commercial Middleware 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 Shandong Civic Se Commercial Middleware Co ltd filed Critical Shandong Civic Se Commercial Middleware Co ltd
Priority to CN202011338296.XA priority Critical patent/CN112486765B/en
Publication of CN112486765A publication Critical patent/CN112486765A/en
Application granted granted Critical
Publication of CN112486765B publication Critical patent/CN112486765B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3003Monitoring arrangements specially adapted to the computing system or computing system component being monitored
    • G06F11/302Monitoring arrangements specially adapted to the computing system or computing system component being monitored where the computing system component is a software system
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3051Monitoring arrangements for monitoring the configuration of the computing system or of the computing system component, e.g. monitoring the presence of processing resources, peripherals, I/O links, software programs
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/32Monitoring with visual or acoustical indication of the functioning of the machine
    • G06F11/324Display of status information
    • G06F11/327Alarm or error message display

Abstract

The application discloses a java application interface management method, a system, a device and a computer readable storage medium, comprising: acquiring liveness data of a java application interface; wherein the activity data comprises calling times, response states and response time; obtaining the current liveness of the java application interface by using the liveness data and a preset liveness calculation rule; judging whether the current activity of the java application interface exceeds a preset activity threshold value or not; and if the activity threshold is exceeded, alarming. According to the method and the device, the activeness data of the java application interface are actively acquired, the activeness of the java application interface is judged, the load degree of the java application interface can be found in advance, the alarm is given to the user in time, and the fault caused by overlarge load of the java application interface is reduced.

Description

Java application interface management method, system and device and computer readable storage medium
Technical Field
The present invention relates to the field of distributed storage, and in particular, to a method, a system, an apparatus, and a computer-readable storage medium for managing java application interfaces.
Background
Java is a cross-platform, object-oriented programming language suitable for distributed computing environments. With the development of internet technology, more and more web applications are developed using Java language due to the rich nature of Java. with the increase of the number of users, the service usage degree of the web application is higher and higher, the number of times of calling corresponding interfaces of the corresponding service is more and more, and the performance requirements of the application are higher and more.
Java application interface liveness refers to the level of activity of a web application interface developed based on the Java language. The activity degree of the interface is comprehensively analyzed by acquiring the calling times and the response state of the application interface in unit time and matching with the life cycle of the application and the calling weight of the interface.
In the prior art, the activity of the Java application interface cannot be monitored, so that errors are often caused due to the fact that the application interface cannot bear access pressure, and further application errors are caused, and user experience is reduced.
Therefore, a method for carrying out early discovery and early warning on the java interface with high load is needed.
Disclosure of Invention
In view of this, the present invention provides a java application interface management method, system, apparatus and computer readable storage medium, which can perform early discovery and early warning on a java interface with a high load. The specific scheme is as follows:
a java application interface management method comprises the following steps:
acquiring liveness data of a java application interface; the activity data comprises calling times, response states and response time;
obtaining the current liveness of the java application interface by using the liveness data and a preset liveness calculation rule;
judging whether the current activity of the java application interface exceeds a preset activity threshold value or not;
and if the activity threshold is exceeded, alarming.
Optionally, the process of obtaining the current activity of the java application interface by using the activity data and a preset activity calculation rule includes:
obtaining the weight value from the weight table; wherein the weight values comprise an access success weight, an access error weight and a response time weight;
obtaining the current activity of the java application interface by using the activity data, the weight value and an activity calculation formula;
wherein, the activity calculation formula is as follows: current liveness = ((N-M)/N) × access success weight + ((E-B)/N) × access error weight + (T/a) × response time weight;
in the formula, N is the response success time of the current time, M is the response success time of the last statistical time, E is the interface response error time of the current time, B is the response error time of the last statistical time, T is the statistical response time of this time, and a is the average response time of the interface.
The invention also discloses a java application interface management system, which comprises:
the data acquisition module is used for acquiring liveness data of the java application interface; wherein the activity data comprises calling times, response states and response time;
the liveness calculation module is used for obtaining the current liveness of the java application interface by utilizing the liveness data and a preset liveness calculation rule;
the activity judgment module is used for judging whether the current activity of the java application interface exceeds a preset activity threshold value or not;
and the warning module is used for warning if the activity judgment module judges that the current activity of the java application interface exceeds the activity threshold.
Optionally, the activity calculation module includes:
a weight obtaining unit for obtaining a weight value from a weight table; wherein the weight values comprise an access success weight, an access error weight and a response time weight;
the liveness calculation unit is used for obtaining the current liveness of the java application interface by utilizing the liveness data, the weight value and the liveness calculation formula;
wherein, the activity calculation formula is as follows: current liveness = ((N-M)/N) × access success weight + ((E-B)/N) × access error weight + (T/a) × response time weight;
in the formula, N is the response success time of the current time, M is the response success time of the last statistical time, E is the interface response error time of the current time, B is the response error time of the last statistical time, T is the statistical response time of this time, and a is the average response time of the interface.
The invention also discloses a java application interface management device, which comprises:
a memory for storing a computer program;
a processor for executing the computer program to implement the java application interface management method as described above.
The invention also discloses a computer readable storage medium, on which a computer program is stored, which, when executed by a processor, implements the java application interface management method as described above.
In the invention, the java application interface management method comprises the following steps: acquiring liveness data of a java application interface; the activity data comprises calling times, response states and response time; obtaining the current liveness of the java application interface by using the liveness data and a preset liveness calculation rule; judging whether the current activity of the java application interface exceeds a preset activity threshold value or not; and if the activity threshold is exceeded, alarming.
The method and the system actively acquire the activity data of the java application interface and judge the activity of the java application interface, so that the load degree of the java application interface can be found in advance, an alarm can be given to a user in time, and the fault caused by overlarge load of the java application interface can be reduced.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the provided drawings without creative efforts.
Fig. 1 is a schematic flow chart of a java application interface management method disclosed in the embodiment of the present invention;
fig. 2 is a schematic structural diagram of another java application interface management system according to the embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The embodiment of the invention discloses a java application interface management method, which is shown in figure 1 and comprises the following steps:
s11: and acquiring liveness data of the java application interface.
Specifically, in order to check the activity condition of the java application interface, check whether the load of the java application interface is too high or surplus, it is necessary to acquire activity data that can reflect the activity of the java application interface, where the activity data includes data such as the number of calls, the response state, and the response time of the java application interface, and specifically, the number of successful time responses and the number of erroneous time responses of the java application interface may be included.
It can be understood that the calling times reflect the number of times the java application interface is used, the survival time reflects the time length of the java application interface used once, the response state reflects whether the java application interface is available, and the response time reflects the response speed of the java application interface.
Specifically, the activity data acquired each time can be stored in a corresponding database, so that the activity data can be used as historical data on one hand, and the subsequent activity calculation is facilitated on the other hand.
Furthermore, an interceptor in the javaweb can be utilized to acquire the interface activity data in the interceptor, and the activity data is acquired in an interface mode.
S12: and obtaining the current activity of the java application interface by using the activity data and a preset activity calculation rule.
Specifically, after the activity data is obtained, the current activity of the java application interface can be calculated by using the activity data according to a preset activity calculation rule.
Specifically, because the java application interface includes multiple types of data related to the activity, a weight value may be set for each type of data, the weight value may be recorded in a weight table in advance, and a preset activity calculation formula may be used to calculate the specific activity, for example, the activity calculation formula is: current liveness = ((N-M)/N) × access success weight + ((E-B)/N) × access error weight + (T/a) × response time weight;
in the formula, N is the response success number of the current time, M is the response success number of the last statistical time, E is the interface response error number of the current time, B is the response error number of the last statistical time, T is the statistical response time of this time, and a is the interface average response time, wherein the weight values include an access success weight, an access error weight and a response time weight.
Specifically, the activity calculation method may specifically be S121 to S122; wherein the content of the first and second substances,
s121: obtaining the weight value from the weight table;
s122: and obtaining the current activity of the java application interface by using the activity data, the weight value and the activity calculation formula.
Specifically, of course, according to the actual application, the specific activity calculation manner may be adjusted, and parameters and/or adjustment weights may be added.
It should be noted that, in order to calculate the liveness, the last-time liveness data needs to be recorded, each-time liveness data is the liveness of the java application interface in unit time, and the unit time may be 10 seconds.
The interface response times can be obtained according to the call times, and whether the response is successful or wrong can be determined according to the response state, so that the data such as the response success times of the current time, the response success times of the last statistical time, the interface response error times of the current time, the response error times of the last statistical time, the response time of the current statistical time, the average response time of the interface and the like can be determined by utilizing the call times, the response state and the response time in the activity data.
Furthermore, when calculating the activity of the interface, firstly, the number of calls of the interface should be paid attention to, and secondly, the response time of the interface is taken as the number of calls, where a higher number of calls indicates a higher activity of the interface in unit time, but when the interface fails to call or the response time is too long, the number of calls of the interface is affected, for example, if the interface is frequently called in unit time, but the interface always fails to call, the subsequent interface call is affected, for example, if a user views data on an inquiry page, the data cannot be always obtained, and the user abandons the interface in a period of time; the longer the response time, the next invocation of the interface will be affected. For this reason, the numerical relationship among the three weight values of the access success weight, the access error weight and the response time weight can be set as the access success weight > the access error weight > the response time weight >0, and the weight allocation can restore the real activity of the interface to the maximum extent.
S13: judging whether the current activity of the java application interface exceeds a preset activity threshold value or not;
s14: and if the activity degree exceeds the activity degree threshold value, alarming.
Specifically, after the current activity is calculated, the current activity can be judged according to a preset activity threshold, and if the current activity exceeds the activity threshold, it is indicated that the load of the current java application interface is too large, an alarm is required, and operation and maintenance personnel are prompted to perform corresponding actions, for example, the load of the current java application interface is reduced.
Specifically, if the activity threshold is not exceeded, no special action is performed, and normal operation is continuously maintained.
Therefore, the embodiment of the invention actively acquires the activity data of the java application interface and judges the activity of the java application interface, so that the load degree of the java application interface can be found out in advance, the alarm can be given to the user in time, and the fault caused by overlarge load of the java application interface can be reduced.
Correspondingly, the embodiment of the present invention further discloses a java application interface management system, which is shown in fig. 2 and includes:
the data acquisition module is used for acquiring liveness data of the java application interface; the activity data comprises calling times, response states and response time;
the liveness calculation module is used for obtaining the current liveness of the java application interface by utilizing the liveness data and a preset liveness calculation rule;
the activity judging module is used for judging whether the current activity of the java application interface exceeds a preset activity threshold value or not;
and the alarm module is used for giving an alarm if the activity judgment module judges that the current activity of the java application interface exceeds the activity threshold.
Therefore, the embodiment of the invention actively acquires the activity data of the java application interface and judges the activity of the java application interface, so that the load degree of the java application interface can be found in advance, the alarm can be given to a user in time, and the fault caused by overlarge load of the java application interface can be reduced.
Specifically, the activity calculation module may include a weight obtaining unit and an activity calculation unit; wherein the content of the first and second substances,
a weight obtaining unit for obtaining a weight value from a weight table; wherein, the weight value comprises an access success weight, an access error weight and a response time weight;
the liveness calculation unit is used for obtaining the current liveness of the java application interface by utilizing the liveness data, the weight value and the liveness calculation formula;
wherein, the activity calculation formula is as follows: current liveness = ((N-M)/N) × access success weight + ((E-B)/N) × access error weight + (T/a) × response time weight;
in the formula, N is the response success number of the current time, M is the response success number of the last statistical time, E is the interface response error number of the current time, and B is the response error number of the last statistical time.
In addition, the embodiment of the invention also discloses a java application interface management device, which comprises:
a memory for storing a computer program;
a processor for executing a computer program to implement the java application interface management method as described above.
In addition, the embodiment of the invention also discloses a computer readable storage medium, wherein a computer program is stored on the computer readable storage medium, and when being executed by a processor, the computer program realizes the java application interface management method.
Finally, it should also be noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrases "comprising a," "8230," "8230," or "comprising" does not exclude the presence of additional like elements in a process, method, article, or apparatus that comprises the element.
Those of skill would further appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware, computer software, or combinations of both, and that the various illustrative components and steps have been described above generally in terms of their functionality in order to clearly illustrate this interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
The technical content provided by the present invention is described in detail above, and the principle and the implementation of the present invention are explained by applying specific examples herein, and the description of the above examples is only used to help understanding the method of the present invention and the core idea thereof; meanwhile, for a person skilled in the art, according to the idea of the present invention, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present invention.

Claims (4)

1. A java application interface management method is characterized by comprising the following steps:
acquiring liveness data of a java application interface; wherein the activity data comprises calling times, response states and response time;
obtaining the current liveness of the java application interface by using the liveness data and a preset liveness calculation rule;
judging whether the current activity of the java application interface exceeds a preset activity threshold value or not;
if the activity degree exceeds the activity degree threshold value, alarming;
the process of obtaining the current liveness of the java application interface by using the liveness data and a preset liveness calculation rule includes:
obtaining the weight value from the weight table; wherein the weight values comprise an access success weight, an access error weight and a response time weight;
obtaining the current activity of the java application interface by using the activity data, the weight value and an activity calculation formula;
wherein, the activity calculation formula is as follows: current liveness = ((N-M)/N) × access success weight + ((E-B)/N) × access error weight + (T/a) × response time weight;
in the formula, N is the response success time of the current time, M is the response success time of the last statistical time, E is the interface response error time of the current time, B is the response error time of the last statistical time, T is the statistical response time of this time, and a is the average response time of the interface.
2. A java application interface management system, comprising:
the data acquisition module is used for acquiring liveness data of the java application interface; wherein the activity data comprises calling times, response states and response time;
the liveness calculation module is used for obtaining the current liveness of the java application interface by utilizing the liveness data and a preset liveness calculation rule;
the activity degree judging module is used for judging whether the current activity degree of the java application interface exceeds a preset activity degree threshold value or not;
the alarm module is used for giving an alarm if the activity judgment module judges that the current activity of the java application interface exceeds the activity threshold;
the liveness calculation module comprises:
a weight obtaining unit for obtaining a weight value from a weight table; wherein the weight values comprise an access success weight, an access error weight and a response time weight;
the liveness calculation unit is used for obtaining the current liveness of the java application interface by utilizing the liveness data, the weight value and the liveness calculation formula;
wherein, the activity calculation formula is as follows: current liveness = ((N-M)/N) × access success weight + ((E-B)/N) × access error weight + (T/a) × response time weight;
in the formula, N is the response success time of the current time, M is the response success time of the last statistical time, E is the interface response error time of the current time, B is the response error time of the last statistical time, T is the statistical response time of this time, and a is the average response time of the interface.
3. A java application interface management apparatus, comprising:
a memory for storing a computer program;
a processor for executing the computer program to implement the java application interface management method as claimed in claim 1.
4. A computer-readable storage medium, wherein a computer program is stored thereon, which, when executed by a processor, implements the java application interface management method as recited in claim 1.
CN202011338296.XA 2020-11-25 2020-11-25 Java application interface management method, system and device and computer readable storage medium Active CN112486765B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011338296.XA CN112486765B (en) 2020-11-25 2020-11-25 Java application interface management method, system and device and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011338296.XA CN112486765B (en) 2020-11-25 2020-11-25 Java application interface management method, system and device and computer readable storage medium

Publications (2)

Publication Number Publication Date
CN112486765A CN112486765A (en) 2021-03-12
CN112486765B true CN112486765B (en) 2022-11-11

Family

ID=74934708

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011338296.XA Active CN112486765B (en) 2020-11-25 2020-11-25 Java application interface management method, system and device and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN112486765B (en)

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109951466A (en) * 2019-03-08 2019-06-28 新华三信息安全技术有限公司 Port flow monitoring method, device, electronic equipment and machine readable storage medium

Family Cites Families (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5034955B2 (en) * 2008-01-08 2012-09-26 富士通株式会社 Performance evaluation simulation apparatus, performance evaluation simulation method, and performance evaluation simulation program
US8281322B2 (en) * 2008-11-18 2012-10-02 At&T Intellectual Property I, L.P. Adaptive application interface management
US8776033B2 (en) * 2010-12-23 2014-07-08 International Business Machines Corporation Batch dispatch of java native interface calls
WO2015136624A1 (en) * 2014-03-11 2015-09-17 株式会社日立製作所 Application performance monitoring method and device
US10198348B2 (en) * 2015-08-13 2019-02-05 Spirent Communications, Inc. Method to configure monitoring thresholds using output of load or resource loadings
CN105677772B (en) * 2015-12-30 2019-07-09 赛尔网络有限公司 The statistical method and device of interconnection port URL liveness between a kind of ISP
US10191792B2 (en) * 2016-03-04 2019-01-29 International Business Machines Corporation Application abnormality detection
US10268514B1 (en) * 2016-03-22 2019-04-23 Amazon Technologies, Inc. Performance analysis of stateless compute functions using function call intercept
US10608901B2 (en) * 2017-07-12 2020-03-31 Cisco Technology, Inc. System and method for applying machine learning algorithms to compute health scores for workload scheduling
CN108182134A (en) * 2017-12-29 2018-06-19 顺丰科技有限公司 A kind of general-purpose interface monitoring method, device and equipment, storage medium
CN108683604B (en) * 2018-04-03 2021-11-26 平安科技(深圳)有限公司 Concurrent access control method, terminal device, and medium
CN109726062B (en) * 2018-05-14 2021-10-15 网联清算有限公司 Off-line method of proxy server and control server
CN108874624B (en) * 2018-05-31 2023-03-28 康键信息技术(深圳)有限公司 Server, method for monitoring Java process and storage medium
CN109214908A (en) * 2018-07-06 2019-01-15 深圳市买买提信息科技有限公司 A kind of monitoring method and relevant apparatus

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109951466A (en) * 2019-03-08 2019-06-28 新华三信息安全技术有限公司 Port flow monitoring method, device, electronic equipment and machine readable storage medium

Also Published As

Publication number Publication date
CN112486765A (en) 2021-03-12

Similar Documents

Publication Publication Date Title
CN110138837B (en) Request processing method and device, computer equipment and storage medium
US7962914B2 (en) Method and apparatus for load balancing of distributed processing units based on performance metrics
CN109586952B (en) Server capacity expansion method and device
US7865614B2 (en) Method and apparatus for load balancing with server state change awareness
US20070233866A1 (en) Method and system for dynamically allocating servers to compute-resources using capacity thresholds
CN112988398A (en) Micro-service dynamic scaling and migration method and device
CN110990245A (en) Micro-service operation state judgment method and device based on call chain data
CN112069237A (en) Management system of cluster database connection pool
CN112486765B (en) Java application interface management method, system and device and computer readable storage medium
US20040268176A1 (en) System and method for testing servers and taking remedial action
CN114490078A (en) Dynamic capacity reduction and expansion method, device and equipment for micro-service
CN111400049A (en) Resource adjusting method and device
CN112187924A (en) Service request method, device, equipment and computer storage medium
CN112565228A (en) Client network analysis method and device
CN108234658B (en) Method and device for sensing health condition of server cluster and server
CN115695435A (en) Method and device for dynamically adjusting node flow, electronic equipment and storage medium
CN114153553A (en) High-availability control method and system for virtual machine and related components
CN112749064A (en) Method and system for predicting and self-healing fault of software application service
US20190068471A1 (en) Dynamic asynchronous communication management
CN112084392A (en) Busyness acquisition method of business system and related components
CN110955579A (en) Ambari-based large data platform monitoring method
CN110944051B (en) Method and device for realizing load balance, electronic equipment and storage medium
CN116996517B (en) Load balancing method, device, electronic equipment and medium
CN113225225B (en) Root mirror image detection method, device and system, electronic equipment and storage medium
CN116719632B (en) Task scheduling method, device, equipment and 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
GR01 Patent grant
GR01 Patent grant