亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來(lái)到蟲(chóng)蟲(chóng)下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲(chóng)蟲(chóng)下載站

?? alert.java

?? 優(yōu)秀的客戶關(guān)系管理系統(tǒng)
?? JAVA
?? 第 1 頁(yè) / 共 4 頁(yè)
字號(hào):
package com.ideas.alert;

import java.util.Date;
import java.sql.*;
import com.ideas.util.*;
import com.ideas.communicate.*;
import com.ideas.data.DBAccess;
import java.util.*;

public class Alert
{
    /**html格式報(bào)警內(nèi)容,同時(shí)擁有幾個(gè)主機(jī),就有幾個(gè)數(shù)組元素*/
    public static String[] HtmlContent = new String[Configuration.UnixClientIP.
        length];
    /**{101}格式報(bào)警內(nèi)容*/
    public static String[] TokenContent = new String[Configuration.UnixClientIP.
        length];
    /**報(bào)警自動(dòng)處理恢復(fù)內(nèi)容*/
    public static String[] AutoRunContent = new String[Configuration.UnixClientIP.
        length];

    /**
     *得到客戶化警報(bào)信息,html格式
     * @return
     */

    public static String getAlertTime(String server,String ipaddress)
    {
        Vector pgV = DBAccess.getGivingTimesData("select timestamp from sybaselog where server='"+server+"' and ipaddress='" + ipaddress + "' order by timestamp desc", 1);
        return (String)pgV.elementAt(0);
    }

    public static String getMsg(String hostip, String hostname)
    {
        String date = new Timestamp(new Date().getTime()).toString();
        String init = hostname + "(" + hostip + ") 狀態(tài)報(bào)告:";
        String msg = init;
        if(AlertProperties.isNotAction(AlertProperties.cpu_busy_level))
        { //cpu
            try
            {
                Vector v = DBAccess.getGivingTimesData(
                    "select idle from cpu where ipaddress='" + hostip +
                    "'  order by id desc",
                    AlertProperties.cpu_busy_times);
                int cputimes = 0;
                for(; cputimes < AlertProperties.cpu_busy_times; cputimes++)
                {
                    int busy = 100 - Integer.parseInt( (String)v.elementAt(cputimes));
                    if(busy > AlertProperties.cpu_busy_min)
                    {
                        continue;
                    }
                    else
                    {
                        break;
                    }
                }
                if( (cputimes == AlertProperties.cpu_busy_times))
                {
                    msg += WarningMsg.CPU_MSG;
                }
            }
            catch(NullPointerException ne)
            {}
            catch(Exception e)
            {
                System.err.println("在生成\"CPU\"警報(bào)數(shù)據(jù)時(shí)產(chǎn)生異常");
                e.printStackTrace();
            }
        }

        if(AlertProperties.isNotAction(AlertProperties.pg_use_level))
        { //pg
            try
            {
                String[] value = DBAccess.getLatestData(
                    "select totalsize,inuse from pg where ipaddress='" + hostip +
                    "'  order by id desc");
                if(Integer.parseInt(Tools.findNumberInString(value[1])) * 100 /
                   Integer.parseInt(Tools.findNumberInString(value[0])) >
                   AlertProperties.pg_use_min)
                {
                    msg += WarningMsg.PG_MSG;
                }
            }
            catch(NullPointerException e)
            {}
            catch(Exception e)
            {
                System.err.println("在生成\"頁(yè)交換空間\"警報(bào)數(shù)據(jù)時(shí)產(chǎn)生異常");
                e.printStackTrace();
            }
        }

        if(AlertProperties.isNotAction(AlertProperties.disk_io_level))
        { //diskio
            try
            {
                Vector v = DBAccess.getGivingTimesData(
                    "select act from diskio where ipaddress='" + hostip +
                    "'  order by id desc",
                    AlertProperties.disk_io_times);
                int diskiotimes = 0;
                for(; diskiotimes < AlertProperties.disk_io_times; diskiotimes++)
                {
                    float act = Float.parseFloat( (String)v.elementAt(diskiotimes));
                    if(act > AlertProperties.disk_io_min)
                    {
                        continue;
                    }
                    else
                    {
                        break;
                    }

                }
                if(diskiotimes == AlertProperties.disk_io_times)
                {
                    msg += WarningMsg.DISKIO_MSG;
                }
            }
            catch(NullPointerException ne)
            {}
            catch(Exception e)
            {
                System.err.println("在生成\"系統(tǒng)硬盤\"警報(bào)數(shù)據(jù)時(shí)產(chǎn)生異常");
                e.printStackTrace();
            }
        }

        if(AlertProperties.isNotAction(AlertProperties.fs_use_level))
        { //fs
            try
            {
                String[] timestamp = DBAccess.getLatestData(
                    "select timestamp from fs where ipaddress='" + hostip +
                    "' order by id desc");
                Vector result = DBAccess.getBatchData(
                    "select used from fs where ipaddress='" + hostip +
                    "' and timestamp='" + timestamp[0] + "'");
                for(int i = 0; i < result.size(); i++)
                {
                    String temp = (String)result.elementAt(i);
                    int value = Integer.parseInt(temp);
                    if( (value > AlertProperties.fs_use_min) &&
                       (AlertProperties.fs_use_level == AlertProperties.WARNING))
                    {
                        msg += WarningMsg.FS_MSG;
                        break;
                    }
                }
            }
            catch(NullPointerException ne)
            {}
            catch(Exception e)
            {
                System.err.println("在生成\"文件系統(tǒng)\"警報(bào)數(shù)據(jù)時(shí)產(chǎn)生異常");
                e.printStackTrace();
            }

            if(AlertProperties.isNotAction(AlertProperties.engine_busy_level))
            {
                try
                { //engine 計(jì)算engine的平均值
                    Vector timestampV = DBAccess.getGivingTimesData(
                        "select timestamp from engine where ipaddress='" + hostip +
                        "'  group by timestamp order by id desc",
                        AlertProperties.engine_busy_times);
                    int i = 0;
                    for(; i < timestampV.size(); i++)
                    {
                        String timestamp = (String)timestampV.elementAt(i);
                        Vector usagesV = DBAccess.getBatchData(
                            "select usages from engine where ipaddress='" + hostip +
                            "' and timestamp='" + timestamp + "'");
                        float total = 0;
                        for(int t = 0; t < usagesV.size(); t++)
                        {
                            total += Float.parseFloat( (String)usagesV.elementAt(t));
                        }
                        float avg = total / usagesV.size();
                        if(avg > AlertProperties.engine_busy_min)
                        {
                            continue;
                        }
                        else
                        {
                            break;
                        }
                    }
                    if(i == AlertProperties.engine_busy_times)
                    {
                        msg += WarningMsg.ENGINE_MSG;
                    }
                }
                catch(NullPointerException ne)
                {}
                catch(Exception e)
                {
                    System.err.println("在生成\"Sybase Engine\"警報(bào)數(shù)據(jù)時(shí)產(chǎn)生異常");
                    e.printStackTrace();
                }
            }
        }

        if(AlertProperties.isNotAction(AlertProperties.Sybase_tranx_level))
        {
            try
            { //sybtransaction status
                String[] timestamp = DBAccess.getLatestData(
                    "select distinct timestamp from sybtran where ipaddress='" + hostip +
                    "' order by id desc");
                Vector result = DBAccess.getBatchData(
                    "select runtime from sybtran where ipaddress='" + hostip +
                    "' and timestamp='" + timestamp[0] + "'");
                for(int i = 0; i < result.size(); i++)
                {
                    int status = Integer.parseInt( (String)result.elementAt(i));
                    if(status > AlertProperties.Sybase_tranx_min)
                    {
                        msg += WarningMsg.TRANX_MSG;
                        break;
                    }
                }
            }
            catch(NumberFormatException nfe)
            {}
            catch(NullPointerException ne)
            {}
            catch(Exception e)
            {
                System.err.println("在生成\"sybtran\"警報(bào)數(shù)據(jù)時(shí)產(chǎn)生異常");
                e.printStackTrace();
            }
        }

        if(AlertProperties.isNotAction(AlertProperties.sfs_server_level))
        {
            try
            { //sfs_server
                String[] timestamp = DBAccess.getLatestData(
                    "select timestamp from cicsfs where ipaddress='" + hostip +
                    "' order by id desc");
                Vector result = DBAccess.getBatchData(
                    "select status from cicsfs where ipaddress='" + hostip +
                    "' and timestamp='" + timestamp[0] + "'");
                for(int i = 0; i < result.size(); i++)
                {
                    String status = (String)result.elementAt(i);
                    if(!status.equalsIgnoreCase(AlertProperties.sfs_server_normal))
                    {
                        msg += WarningMsg.SFSSERVER_MSG;
                        break;
                    }
                }
            }
            catch(NullPointerException ne)
            {}
            catch(Exception e)
            {
                System.err.println("在生成\"CICS FS Server\"警報(bào)數(shù)據(jù)時(shí)產(chǎn)生異常");
                e.printStackTrace();
            }
        }

        if(AlertProperties.isNotAction(AlertProperties.sfs_server_warninglog_level))
        {
            try
            { //sfs server 的warning數(shù)
                String[] warnings = DBAccess.getLatestData(
                    "select warning from sfserror where ipaddress='" + hostip +
                    "' order by id desc");
                int warning = Integer.parseInt(warnings[0]);
                if(warning > AlertProperties.sfs_server_warninglog_min)
                {
                    msg += WarningMsg.SFSSERVER_WARNINGLOG_MSG;
                }
            }
            catch(NullPointerException ne)
            {}
            catch(Exception e)
            {
                System.err.println("在生成\"CICS FS Server\"警報(bào)數(shù)據(jù)時(shí)產(chǎn)生異常");
                e.printStackTrace();
            }
        }

        if(AlertProperties.isNotAction(AlertProperties.sfs_server_errorlog_level))
        {
            try
            { //sfs server 的error數(shù)
                String[] warnings = DBAccess.getLatestData(
                    "select error from sfserror where ipaddress='" + hostip +
                    "' order by id desc");
                int error = Integer.parseInt(warnings[0]);
                if(error > AlertProperties.sfs_server_errorlog_min)
                {
                    msg += WarningMsg.SFSSERVER_ERRORLOG_MSG;
                }
            }
            catch(NullPointerException ne)
            {}
            catch(Exception e)
            {
                System.err.println("在生成\"CICS FS Server\"警報(bào)數(shù)據(jù)時(shí)產(chǎn)生異常");
                e.printStackTrace();
            }
        }

        if(AlertProperties.isNotAction(AlertProperties.region_level))
        {
            try
            { //cicsregions status
                String[] timestamp = DBAccess.getLatestData(
                    "select timestamp from cicsregions where ipaddress='" + hostip +
                    "' order by id desc");
                Vector result = DBAccess.getBatchData(
                    "select status from cicsregions where ipaddress='" + hostip +
                    "' and timestamp='" + timestamp[0] + "'");
                for(int i = 0; i < result.size(); i++)
                {
                    String status = ( (String)result.elementAt(i)).trim();
                    if(!status.equalsIgnoreCase(AlertProperties.region_normal.trim()))
                    {
                        msg += WarningMsg.CICSREGIONS_MSG;
                        break;
                    }
                }
            }
            catch(NullPointerException ne)
            {}
            catch(Exception e)
            {
                System.err.println("在生成\"CICS regions \"警報(bào)數(shù)據(jù)時(shí)產(chǎn)生異常");
                e.printStackTrace();
            }
        }

?? 快捷鍵說(shuō)明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
在线不卡欧美精品一区二区三区| 精品国内二区三区| 国产成人激情av| 国产欧美日韩在线看| 欧美卡1卡2卡| 欧美精选一区二区| 欧美日韩免费不卡视频一区二区三区 | 欧美一区二区三区视频在线| 欧美人牲a欧美精品| 欧美日韩精品一区二区三区四区| 欧洲精品中文字幕| 精品视频一区二区三区免费| 欧美丝袜自拍制服另类| 欧美日韩中文字幕一区二区| 欧美色电影在线| 在线不卡一区二区| 日韩美女天天操| 久久在线观看免费| 国产人成亚洲第一网站在线播放| 欧美极品另类videosde| 国产精品日产欧美久久久久| 亚洲久本草在线中文字幕| 玉足女爽爽91| 午夜婷婷国产麻豆精品| 老汉av免费一区二区三区| 激情综合五月婷婷| 成人app网站| 91看片淫黄大片一级| 欧美精品一区二区三区蜜桃视频 | 日韩国产一区二| 麻豆精品久久久| 成人在线一区二区三区| 日本高清不卡视频| 91精品国产一区二区人妖| 精品少妇一区二区三区免费观看| 久久久av毛片精品| 亚洲欧美日韩在线| 奇米四色…亚洲| 国产成人精品免费看| 在线观看国产91| 精品免费视频.| 中文字幕视频一区| 午夜精品久久久久| 韩国三级在线一区| 色综合中文综合网| 午夜视频在线观看一区二区三区| 日韩精品五月天| 国产成人精品免费在线| 欧美无人高清视频在线观看| 亚洲精品一线二线三线无人区| 国产精品国产自产拍高清av王其 | 91高清视频免费看| 欧美tickling网站挠脚心| 中文字幕一区二区三区av| 视频一区二区三区入口| 粉嫩久久99精品久久久久久夜| 欧美午夜在线观看| 国产亚洲欧美日韩日本| 五月婷婷激情综合| 成人精品视频一区| 综合久久久久综合| 毛片av一区二区三区| 91亚洲国产成人精品一区二三| 欧美一区二区精品| 亚洲精选视频免费看| 国产一区二区三区久久悠悠色av | 亚洲欧美另类在线| 国精产品一区一区三区mba桃花 | 日韩免费成人网| 亚洲欧美国产三级| 国产精品中文字幕一区二区三区| 欧美午夜免费电影| 国产精品欧美一区喷水| 男人的j进女人的j一区| 在线视频你懂得一区| 欧美极品美女视频| 国产一区二区主播在线| 欧美精品久久99| 亚洲日本一区二区| 高清不卡在线观看| 精品日韩一区二区三区| 五月天欧美精品| 色婷婷av一区二区三区软件| 国产精品久久久久久久久快鸭| 日韩精品乱码免费| 欧美日韩一区二区三区免费看 | 天天色图综合网| 91搞黄在线观看| 综合色天天鬼久久鬼色| 高清不卡在线观看av| 欧美精品一区二区三区蜜臀 | 欧美色图激情小说| 亚洲欧美一区二区久久| 9l国产精品久久久久麻豆| 欧美精品一区男女天堂| 久国产精品韩国三级视频| 777奇米成人网| 午夜欧美大尺度福利影院在线看| 色综合色狠狠天天综合色| 中文字幕五月欧美| 欧美成人性战久久| 日本女人一区二区三区| 在线成人午夜影院| 丝袜美腿成人在线| 91精品国产丝袜白色高跟鞋| 午夜精品一区二区三区三上悠亚| 欧美影视一区在线| 亚洲福利电影网| 欧美日韩国产免费一区二区| 亚洲图片有声小说| 欧美日韩免费在线视频| 五月婷婷综合在线| 91麻豆精品国产91久久久资源速度 | 国产成人av福利| 日本一区二区在线不卡| 成人黄色免费短视频| 中文字幕精品在线不卡| www.欧美精品一二区| 亚洲免费在线视频一区 二区| 色综合久久久久久久久久久| 一区二区高清在线| 欧美喷水一区二区| 美女mm1313爽爽久久久蜜臀| 精品对白一区国产伦| 国内外精品视频| 亚洲国产成人一区二区三区| 99热在这里有精品免费| 中文字幕一区二区三区在线观看 | 风间由美一区二区三区在线观看| 国产精品免费视频一区| 色综合久久88色综合天天6| 亚洲男同性视频| 91精品国产色综合久久不卡电影 | 久久99久久99| 日本一区二区三区dvd视频在线| 成人av一区二区三区| 亚洲人吸女人奶水| 欧美丰满嫩嫩电影| 国产美女精品人人做人人爽| 中文字幕在线观看一区二区| 在线观看视频91| 久久国产免费看| 中文字幕中文在线不卡住| 欧美视频在线一区二区三区| 青椒成人免费视频| 中文字幕第一区第二区| 欧美日韩小视频| 韩国成人精品a∨在线观看| 国产精品九色蝌蚪自拍| 7777精品伊人久久久大香线蕉的 | 国产天堂亚洲国产碰碰| 一本色道综合亚洲| 久久99国产精品麻豆| 亚洲视频在线观看一区| 日韩欧美一区电影| caoporen国产精品视频| 日产国产欧美视频一区精品| 中文字幕的久久| 欧美一区二区网站| 97精品国产露脸对白| 99热精品国产| 精品在线播放免费| 亚洲免费av高清| 久久久精品日韩欧美| 欧美日韩亚洲综合一区| 丁香啪啪综合成人亚洲小说 | 国产69精品久久777的优势| 日韩av网站免费在线| 亚洲视频每日更新| 国产亚洲va综合人人澡精品| 欧美精品久久99| 色婷婷久久一区二区三区麻豆| 国产精品一区一区三区| 三级在线观看一区二区| 亚洲精品视频免费看| 久久久久久久久久久电影| 欧美片在线播放| 色婷婷综合久久久中文字幕| 国产寡妇亲子伦一区二区| 日韩 欧美一区二区三区| 国产精品久久久久久久午夜片| 欧美老女人第四色| 色噜噜夜夜夜综合网| 国产精品自产自拍| 国产精品久久久久一区二区三区| 日韩精品一区二区三区老鸭窝| 97久久精品人人做人人爽50路| 日本不卡视频一二三区| 亚洲成国产人片在线观看| 欧美国产1区2区| 日韩欧美一区电影| 日韩欧美亚洲一区二区| 色天天综合色天天久久| 国产99久久久国产精品潘金| 一区二区免费看| 国产精品成人免费在线| 精品日韩99亚洲| 在线播放中文一区| 91福利国产精品| 99在线视频精品|