# !/usr/bin/env python
# -*- coding: utf-8 -*-
import cx_Oracle
import os
from pyecharts.faker import Faker
from pyecharts import options as opts
from pyecharts.charts import Pie
from pyecharts.faker import Faker
from pyecharts import options as opts
from pyecharts.charts import Bar
from pyecharts.globals import ThemeType
from pyecharts.charts import Bar, Page
from pyecharts.components import Table
from pyecharts.options import ComponentTitleOpts
os.environ['NLS_LANG'] = 'SIMPLIFIED CHINESE_CHINA.UTF8'
import datetime # 导入日期时间模块
import re
page = Page()
conn = cx_Oracle.connect('esbdata/xx@10.2.120.142/esbdb')
sql1="select /*+parallel(t 8)*/ b.description, count(*) \
from esb2_trans_log t ,servicesystem b \
where t.trans_date >= trunc(sysdate) \
and (t.respmsg like '%Read timed out%' or t.respmsg like '%异常%' or t.respmsg like '%超时%' or t.respmsg like '%通讯%失败%' or