@contract
    def select_host_states(self, host_id, start_time, end_time):
        hs = self.host_states
        sel = select([hs.c.timestamp, hs.c.state]). \
            where(and_(hs.c.host_id == host_id,
                       hs.c.timestamp >= start_time,
                       hs.c.timestamp <= end_time)). \
            order_by(hs.c.id.asc())
        return [(x[0], int(x[1])) 
                for x in self.connection.execute(sel).fetchall()]
Simple wrapper to return a SimpleStore.
dataset/ETHPy150Open beloglazov/openstack-neat/utils/db.py/Database.select_host_states--crossover with--dataset/ETHPy150Open ganeti/ganeti/lib/backend.py/_GetConfig