CN107943868B - 支持***信息友好查看的数据库中间件的方法及设备 - Google Patents

支持***信息友好查看的数据库中间件的方法及设备 Download PDF

Info

Publication number
CN107943868B
CN107943868B CN201711106717.4A CN201711106717A CN107943868B CN 107943868 B CN107943868 B CN 107943868B CN 201711106717 A CN201711106717 A CN 201711106717A CN 107943868 B CN107943868 B CN 107943868B
Authority
CN
China
Prior art keywords
database
middleware
database middleware
standard sql
sql statement
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
CN201711106717.4A
Other languages
English (en)
Other versions
CN107943868A (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.)
SF Technology Co Ltd
Original Assignee
SF 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 SF Technology Co Ltd filed Critical SF Technology Co Ltd
Priority to CN201711106717.4A priority Critical patent/CN107943868B/zh
Publication of CN107943868A publication Critical patent/CN107943868A/zh
Application granted granted Critical
Publication of CN107943868B publication Critical patent/CN107943868B/zh
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/25Integrating or interfacing systems involving database management systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/34Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment
    • G06F11/3452Performance evaluation by statistical analysis
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/242Query formulation
    • G06F16/2433Query languages
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/28Databases characterised by their database models, e.g. relational or object models
    • G06F16/284Relational databases
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2201/00Indexing scheme relating to error detection, to error correction, and to monitoring
    • G06F2201/80Database-specific techniques

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Databases & Information Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Evolutionary Biology (AREA)
  • Probability & Statistics with Applications (AREA)
  • Computer Hardware Design (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Quality & Reliability (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Mathematical Physics (AREA)
  • Computational Linguistics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

支持***信息友好查看的数据库中间件的方法及设备,包括步骤:S1,通过标准sql语句进行查询。所述设备用于实现所述方法。通过管理端口输入由标准sql语句构成的命令进行查询,既方便又实用。

Description

支持***信息友好查看的数据库中间件的方法及设备
技术领域
本发明涉及数据库中间件,尤其涉及支持***信息友好查看的数据库中间件的方法及设备。
背景技术
随着互联网业务量飞速发展,数据量猛增,单机MySQL无法满足互联网业务性能需求。同时scale-up方案通过提升硬件配置来提高性能,其方案昂贵,也只能满足一段时间业务量,无法从根本上解决问题,业界采用scale-out方案,通过将数据进行水平拆分,让数据均衡到后台多台MySQL机器中,通过增加机器来提升整个MySQL集群并发计算能力,来满足互联网快速发展的需求,其技术手段是分库分表,其中以MyCat为代表的分布式中间件技术最为典型。
然而,在使用MyCat过程中依旧依旧存在***信息查看不友好的问题。
发明内容
为了解决上述技术问题,本发明提出支持***信息友好查看的数据库中间件的方法及设备,其技术方案为:
支持***信息友好查看的数据库中间件的方法,其特征在于,包括步骤:
S1,通过标准sql语句进行查询。
所述标准sql语句由管理端口输入。
所述步骤S1包括步骤:
S11,将标准sql语句异步记录至H2DB数据库中;
S12,周期性异步统计步骤S11中所述的标准sql语句执行情况。
所述步骤S1还包括步骤:
S13,周期性异步采集所述数据库中间件信息。
支持***信息友好查看的数据库中间件的设备,包括存储有计算机程序的计算机可读介质,所述程序被运行用于执行:
S1,通过标准sql语句进行查询。
本发明的有益效果是:通过管理端口输入由标准sql语句构成的命令进行查询,既方便又实用。
附图说明
图1示出了根据本申请的实施例的支持sql友好查看***信息的结构示意图。
具体实施方式
为了更好的了解本发明的技术方案,下面结合附图1对本发明作进一步说明。
支持***信息友好查看的数据库中间件的方法,其特征在于,包括步骤:
S1,通过标准sql语句进行查询。
所述标准sql语句由管理端口输入。
如图1所示,为了支持sql友好查看***信息,以标准sql语句作为查询语句。
由图1可知,步骤S1包括步骤:1,异步记录SQL***H2DB数据库中:
启一个线程负责将经过MyCat-X的SQL会异步被写入H2DB数据库中,用于以后做统计分析,提供数据供9066端口查询。
MyCat-X为支持***信息友好查看的分布式数据库中间件。即为根据本发明技术方案对现有的MyCat进行改进后所获取的新的分布式数据库中间件,是基于社区MyCat基础做了二次开发,重新命名为MyCat-X。
2,周期性异步采集MyCat-X信息:
启一个线程负责采集MyCat-X运行信息(包括内存使用情况,连接池,后端DB心跳信息等)写入H2DB数据库中,提供数据供9066端口查询。
3,周期性异步统计标准sql语句在MyCat-X中的执行情况:
启一个线程周期性基于步骤1记录的SQL做统计,比如SQL执行时间最长的TOP10SQL执行影响结果集最大的TOP 10,SQL执行次数的TOP 10,SQL读写比例等。
步骤2与步骤3中的周期性指的是遵循各自设定的时间周期内进行异步采集或者异步统计相关信息。步骤2与步骤3中的所述的周期性所遵循的周期并不一定相同。
社区MyCat-X在运行过程,会记录各种运行信息,这些运行信息在管理端口(9066)通过传统show@@命令查看其输出形式不友好,查看不方便。我们希望能提供一种灵活,友好的查看各种运行信息,受数据库的启发,通过标准的SQL语句查询方式能很好的满足我们的要求,因此,在MyCAT-X里面引入了H2DB小型嵌入式数据库。让其运行过程中的信息,直接写入或者定时写入H2DB数据库,这样通过9066端口输入查询命令(标准sql语句),转发到H2DB数据库查询引擎中,H2DB数据库将结果返回给用户。这样既方便又实用。
支持***信息友好查看的数据库中间件的设备,包括存储有计算机程序的计算机可读介质,所述程序被运行用于执行上述方法。
以上描述仅为本申请的较佳实施例以及对所运用技术原理的说明。本领域技术人员应当理解,本申请中所涉及的发明范围,并不限于上述技术特征的特定组合而成的技术方案,同时也应涵盖在不脱离所述发明构思的情况下,由上述技术特征或其等同特征进行任意组合而形成的其它技术方案。例如上述特征与本申请中公开的(但不限于)具有类似功能的技术特征进行互相替换而形成的技术方案。

Claims (3)

1.支持***信息友好查看的数据库中间件的方法,其特征在于,包括步骤:
S1,通过标准sql语句经由H2DB数据库进行查询数据库中间件的运行信息和/或所述标准sql语句在所述数据库中间件中的执行情况;
所述步骤S1包括步骤:
S11,将经过所述数据库中间件的标准sql语句异步记录至所述数据库中间件内的H2DB数据库中;
S12,周期性异步采集数据库中间件运行信息并将所述数据库中间件运行信息记录至所述数据库中间件内的H2DB数据库中;
所述周期性是指遵循各自设定的时间周期内进行异步采集或异步统计相关信息;
所述标准sql语句由管理端口输入。
2.根据权利要求1所述的支持***信息友好查看的数据库中间件的方法,其特征在于,所述步骤S1还包括步骤:
S13,周期性异步统计步骤S11中的所述标准sql语句在所述数据库中间件中的执行情况。
3.支持***信息友好查看的数据库中间件的设备,包括存储有计算机程序的计算机可读介质,其特征在于,所述程序被运行用于执行:
S1,通过标准sql语句经由H2DB数据库进行查询数据库中间件的运行信息和/或所述标准sql语句在所述数据库中间件中的执行情况;
所述步骤S1包括步骤:
S11,将经过所述数据库中间件的标准sql语句异步记录至所述数据库中间件内的H2DB数据库中;
S12,周期性异步采集数据库中间件运行信息并将所述数据库中间件运行信息记录至所述数据库中间件内的H2DB数据库中;
所述标准sql语句由管理端口输入。
CN201711106717.4A 2017-11-10 2017-11-10 支持***信息友好查看的数据库中间件的方法及设备 Active CN107943868B (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201711106717.4A CN107943868B (zh) 2017-11-10 2017-11-10 支持***信息友好查看的数据库中间件的方法及设备

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201711106717.4A CN107943868B (zh) 2017-11-10 2017-11-10 支持***信息友好查看的数据库中间件的方法及设备

Publications (2)

Publication Number Publication Date
CN107943868A CN107943868A (zh) 2018-04-20
CN107943868B true CN107943868B (zh) 2021-12-24

Family

ID=61934816

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201711106717.4A Active CN107943868B (zh) 2017-11-10 2017-11-10 支持***信息友好查看的数据库中间件的方法及设备

Country Status (1)

Country Link
CN (1) CN107943868B (zh)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101183377A (zh) * 2007-12-10 2008-05-21 华中科技大学 一种基于消息中间件的高可用性数据库集群
CN101201842A (zh) * 2007-10-30 2008-06-18 北京航空航天大学 数字博物馆网格及其构造方法
CN103793749A (zh) * 2014-02-27 2014-05-14 四川物联恒安安全技术研究有限公司 安全生产综合监管平台数据传输方法

Family Cites Families (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9183153B2 (en) * 2012-05-04 2015-11-10 Battelle Memorial Institute Method and system for managing power grid data
US9339201B2 (en) * 2012-10-08 2016-05-17 Tosense, Inc. Database and algorithm for evaluating efficacy of an electrophysiology procedure
CN104063425B (zh) * 2014-06-04 2017-09-19 五八同城信息技术有限公司 通过数据库中间件查询数据的方法和数据库中间件
US10277414B2 (en) * 2014-07-18 2019-04-30 Oracle International Corporation Communication gateway services in a networked message distribution system
CN104598531B (zh) * 2014-12-25 2019-05-07 广东电子工业研究院有限公司 一种基于触发器的异构关系型数据库间增量数据迁移方法
CN106686031B (zh) * 2015-11-09 2020-02-07 广东华邦云计算股份有限公司 将应用升级为SaaS模式的方法及装置
US10782987B2 (en) * 2015-12-04 2020-09-22 Quest Software Inc. Distributed database driver middleware
CN106503087A (zh) * 2016-10-12 2017-03-15 郑州云海信息技术有限公司 一种用于分布式数据访问的数据库中间件
CN106528293A (zh) * 2016-11-04 2017-03-22 武汉斗鱼网络科技有限公司 一种访问数据库的方法及装置

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101201842A (zh) * 2007-10-30 2008-06-18 北京航空航天大学 数字博物馆网格及其构造方法
CN101183377A (zh) * 2007-12-10 2008-05-21 华中科技大学 一种基于消息中间件的高可用性数据库集群
CN103793749A (zh) * 2014-02-27 2014-05-14 四川物联恒安安全技术研究有限公司 安全生产综合监管平台数据传输方法

Also Published As

Publication number Publication date
CN107943868A (zh) 2018-04-20

Similar Documents

Publication Publication Date Title
US20060173878A1 (en) Efficient processing of time series data
US20110113117A1 (en) Asynchronous Collection and Correlation of Trace and Communications Event Data
WO2020062980A1 (zh) 文件访问追踪方法、装置、存储介质及终端
CN105373541B (zh) 数据库的数据操作请求的处理方法和***
JP2006508476A5 (zh)
CN110569214A (zh) 用于日志文件的索引构建方法、装置及电子设备
CN109471851B (zh) 数据处理方法、装置、服务器和存储介质
CN105493028A (zh) 用于云分析的数据一致性和回退
CN111930975A (zh) 船舶航行数据回放和分析***与方法
CN110505495A (zh) 多媒体资源抽帧方法、装置、服务器及存储介质
CN103514274A (zh) 非关系型数据库HBase的数据迁移方法
CN101610303A (zh) 多媒体数据自动备份方法及***
JP2008310634A (ja) データベース検索装置及びデータベース検索プログラム
CN105550375A (zh) 一种异构数据的整合方法及***
CN112463886A (zh) 一种数据处理方法、装置、电子设备及存储介质
WO2023246638A1 (zh) 信息处理方法、装置、可穿戴设备和电子设备
Wang et al. Sharkdb: An in-memory storage system for massive trajectory data
CN103799997A (zh) 基于图像识别的生理监测参数的记录方法及***
WO2017107679A1 (zh) 一种历史信息展示方法及装置
CN102187340B (zh) 断点信息管理方法和断点信息管理器
CN113918535A (zh) 一种数据读取方法、装置、设备及存储介质
CN103152633A (zh) 一种关键词的识别方法及装置
US20120317133A1 (en) Task context recovery
CN111460178A (zh) 一种基于知识图谱的区块链可视化***
CN107943868B (zh) 支持***信息友好查看的数据库中间件的方法及设备

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