from sqlalchemy import create_engine ,Integer,String,Column
from DBSession import Base


class InstanceList(Base):
    __tablename__ = 'instance_list'
    id = Column(Integer, primary_key=True)
    instance_id = Column(String(32))
    instance_name = Column(String(32))
    ipadd = Column(String(32))
    server_name = Column(String(32))
    status = Column(Integer)


    def __init__(self):
        print(self.id)

    def __repr__(self):
        return '<EAVideoIBPInfo %r>' % self.id

class IntfaceList(Base):
    __tablename__ = 'interface_list'
    id = Column(Integer, primary_key=True)
    app_type = Column(String(32))
    interface_url = Column(String(32))
    qps = Column(Integer)
    avg_time = Column(Integer)



    def __init__(self):
        print(self.id)

    def __repr__(self):
        return '<EAVideoIBPInfo %r>' % self.id

class app_info(Base):
    __tablename__ = 'app_info'
    id = Column(Integer, primary_key=True)
    app_name = Column(String(32))
    app_type = Column(Integer)



    def __init__(self):
        print(self.id)

    def __repr__(self):
        return '<EAVideoIBPInfo %r>' % self.id