Example #1
0
    def get_aliases(self, namespace, start_time, end_time):
        start_alias = self.get_alias(
            namespace,
            _round_datetime_down(kronos_time_to_datetime(start_time)))
        end_alias = self.get_alias(namespace,
                                   kronos_time_to_datetime(end_time))

        aliases = set()

        for value in self.es.indices.get_aliases(
                index=self.get_alias(namespace, '*')).itervalues():
            aliases.update(value['aliases'])

        return filter(lambda a: a >= start_alias and a <= end_alias, aliases)
Example #2
0
  def get_aliases(self, namespace, start_time, end_time):
    start_alias = self.get_alias(
      namespace,
      _round_datetime_down(kronos_time_to_datetime(start_time)))
    end_alias = self.get_alias(namespace,
                               kronos_time_to_datetime(end_time))

    aliases = set()

    for value in self.es.indices.get_aliases(
      index=self.get_alias(namespace, '*')).itervalues():
      aliases.update(value['aliases'])

    return filter(lambda a: a >= start_alias and a <= end_alias, aliases)
Example #3
0
        def actions():
            for _id, event in events:
                dt = kronos_time_to_datetime(uuid_to_kronos_time(_id))
                start_dts_to_add.add(_round_datetime_down(dt))
                event['_index'] = index
                event['_type'] = stream
                event[LOGSTASH_TIMESTAMP_FIELD] = dt.isoformat()

                yield event
Example #4
0
    def actions():
      for _id, event in events:
        dt = kronos_time_to_datetime(uuid_to_kronos_time(_id))
        start_dts_to_add.add(_round_datetime_down(dt))
        event['_index'] = index
        event['_type'] = stream
        event[LOGSTASH_TIMESTAMP_FIELD] = dt.isoformat()

        yield event