zoukankan      html  css  js  c++  java
  • InfluxDB学习之InfluxDB的基本概念

     

    一、与传统数据库中的名词做比较

    influxDB中的名词 传统数据库中的概念
    database 数据库
    measurement 数据库中的表
    points 表里面的一行数据

    二、InfluxDB中独有的概念

    1)Point

    Point由时间戳(time)、数据(field)、标签(tags)组成。

    Point相当于传统数据库里的一行数据,如下表所示:

    Point属性 传统数据库中的概念
    time 每个数据记录时间,是数据库中的主索引(会自动生成)
    fields 各种记录值(没有索引的属性)也就是记录的值:温度, 湿度
    tags 各种有索引的属性:地区,海拔
    2)series

    所有在数据库中的数据,都需要通过图表来展示,而这个series表示这个表里面的数据,可以在图表上画成几条线:通过tags排列组合算出来。

    如下所示:

    复制代码
    >show series from cpu
    key
    cpu,cpu=cpu-total,host=ResourcePool-0246-billing07
    cpu,cpu=cpu-total,host=billing07
    cpu,cpu=cpu0,host=ResourcePool-0246-billing07
    cpu,cpu=cpu0,host=billing07
    cpu,cpu=cpu1,host=ResourcePool-0246-billing07
    cpu,cpu=cpu1,host=billing07
    cpu,cpu=cpu10,host=ResourcePool-0246-billing07
    cpu,cpu=cpu10,host=billing07
    cpu,cpu=cpu11,host=ResourcePool-0246-billing07
    cpu,cpu=cpu11,host=billing07
    cpu,cpu=cpu12,host=ResourcePool-0246-billing07
    cpu,cpu=cpu12,host=billing07
    cpu,cpu=cpu13,host=ResourcePool-0246-billing07
    cpu,cpu=cpu13,host=billing07
    cpu,cpu=cpu14,host=ResourcePool-0246-billing07
    cpu,cpu=cpu14,host=billing07
    cpu,cpu=cpu15,host=ResourcePool-0246-billing07
    cpu,cpu=cpu15,host=billing07
    cpu,cpu=cpu16,host=ResourcePool-0246-billing07
    cpu,cpu=cpu17,host=ResourcePool-0246-billing07
    cpu,cpu=cpu18,host=ResourcePool-0246-billing07
    cpu,cpu=cpu19,host=ResourcePool-0246-billing07
    cpu,cpu=cpu2,host=ResourcePool-0246-billing07
    cpu,cpu=cpu2,host=billing07
    cpu,cpu=cpu20,host=ResourcePool-0246-billing07
    cpu,cpu=cpu21,host=ResourcePool-0246-billing07
    cpu,cpu=cpu22,host=ResourcePool-0246-billing07
    cpu,cpu=cpu23,host=ResourcePool-0246-billing07
    cpu,cpu=cpu3,host=ResourcePool-0246-billing07
    cpu,cpu=cpu3,host=billing07
    cpu,cpu=cpu4,host=ResourcePool-0246-billing07
    cpu,cpu=cpu4,host=billing07
    cpu,cpu=cpu5,host=ResourcePool-0246-billing07
    cpu,cpu=cpu5,host=billing07
    cpu,cpu=cpu6,host=ResourcePool-0246-billing07
    cpu,cpu=cpu6,host=billing07
    cpu,cpu=cpu7,host=ResourcePool-0246-billing07
    cpu,cpu=cpu7,host=billing07
    cpu,cpu=cpu8,host=ResourcePool-0246-billing07
    cpu,cpu=cpu8,host=billing07
    cpu,cpu=cpu9,host=ResourcePool-0246-billing07
    cpu,cpu=cpu9,host=billing07
    复制代码
  • 相关阅读:
    实现连续测试,要做的事情【译】
    Go语言HTTPServer开发的六种实现
    JSON必知必会【PDF+视频教程】
    给JSONObject添加自定义遍历方法
    利用守护线程隐式关闭线程池
    从错误中学习
    Groovy动态添加方法和属性及Spock单测
    持续测试、持续集成、持续交付、持续部署和DevOps
    有关OAuth 2.0简化模式中步骤D-F的解释
    Spring笔记(五):bean的自动装配
  • 原文地址:https://www.cnblogs.com/gaoguangjun/p/8512996.html
Copyright © 2011-2022 走看看