def alarm_get_all(self, uuid=None, alarm_id=None, entity_type_id=None, entity_instance_id=None, severity=None, alarm_type=None, limit=None, include_suppress=False):
    query = model_query(models.Alarm, read_deleted='no')
    query = query.order_by(asc(models.Alarm.severity), asc(models.Alarm.entity_instance_id), asc(models.Alarm.id))
    if (uuid is not None):
        query = query.filter(models.Alarm.uuid.contains(uuid))
    if (alarm_id is not None):
        query = query.filter(models.Alarm.alarm_id.contains(alarm_id))
    if (entity_type_id is not None):
        query = query.filter(models.Alarm.entity_type_id.contains(entity_type_id))
    if (entity_instance_id is not None):
        query = query.filter(models.Alarm.entity_instance_id.contains(entity_instance_id))
    if (severity is not None):
        query = query.filter(models.Alarm.severity.contains(severity))
    if (alarm_type is not None):
        query = query.filter(models.Alarm.alarm_type.contains(alarm_type))
    query = add_alarm_filter_by_event_suppression(query, include_suppress)
    query = add_alarm_mgmt_affecting_by_event_suppression(query)
    query = add_alarm_degrade_affecting_by_event_suppression(query)
    if (limit is not None):
        query = query.limit(limit)
    alarm_list = []
    try:
        alarm_list = query.all()
    except UnicodeDecodeError:
        LOG.error('UnicodeDecodeError occurred, return an empty alarm list.')
    return alarm_list
def alarm_get_all(self, uuid=None, alarm_id=None, entity_type_id=None, entity_instance_id=None, severity=None, alarm_type=None, limit=None, include_suppress=False):
    query = model_query(models.Alarm, read_deleted='no')
    query = query.order_by(asc(models.Alarm.severity), asc(models.Alarm.entity_instance_id), asc(models.Alarm.id))
    if (uuid is not None):
        query = query.filter(models.Alarm.uuid.contains(uuid))
    if (alarm_id is not None):
        query = query.filter(models.Alarm.alarm_id.contains(alarm_id))
    if (entity_type_id is not None):
        query = query.filter(models.Alarm.entity_type_id.contains(entity_type_id))
    if (entity_instance_id is not None):
        query = query.filter(models.Alarm.entity_instance_id.contains(entity_instance_id))
    if (severity is not None):
        query = query.filter(models.Alarm.severity.contains(severity))
    if (alarm_type is not None):
        query = query.filter(models.Alarm.alarm_type.contains(alarm_type))
    query = add_alarm_filter_by_event_suppression(query, include_suppress)
    query = add_alarm_mgmt_affecting_by_event_suppression(query)
    query = add_alarm_degrade_affecting_by_event_suppression(query)
    if (limit is not None):
        query = query.limit(limit)
    alarm_list = []
    try:
        alarm_list = query.all()
    except UnicodeDecodeError:
        LOG.error('UnicodeDecodeError occurred, return an empty alarm list.')
    return alarm_list