32 lines
743 B
Python
32 lines
743 B
Python
from sqlalchemy import (
|
|
Column,
|
|
Integer,
|
|
Float,
|
|
ForeignKey
|
|
)
|
|
|
|
from models.common.base import BaseModel
|
|
|
|
|
|
class nureport(BaseModel):
|
|
"""
|
|
description: Nutanix utilization report
|
|
"""
|
|
__tablename__ = "tnru_report"
|
|
_s_collection_name = "nureport"
|
|
_s_class_name = "utilization"
|
|
|
|
id = Column(Integer, primary_key=True, autoincrement=True, index=True)
|
|
cpu_avg = Column(Float, nullable=False)
|
|
cpu_peak = Column(Float, nullable=False)
|
|
mem_avg = Column(Float, nullable=False)
|
|
mem_peak = Column(Float, nullable=False)
|
|
storage = Column(Float, nullable=False)
|
|
|
|
pelement_id = Column(
|
|
Integer,
|
|
ForeignKey("tnrpe_report.id"),
|
|
nullable=False,
|
|
index=True
|
|
)
|