<commit_before>input {

  file {
    path => "/opt/log/nova.log"
    type => "nova"
  }

  file {
    path => "/opt/log/glance.log"
    type => "glance"
    start_position => beginning
  }

  file {
    path => "/opt/log/neutron.log"
    type => "neutron"
    start_position => beginning
  }

  file {
    path => "/opt/log/cinder.log"
    type => "cinder"
    start_position => beginning
  }

  file {
    path => "/opt/log/keystone.log"
    type => "keystone"
    start_position => beginning
  }
}

filter {

  grok {
    break_on_match => true
    match => [
      "message", "%{TIMESTAMP_ISO8601:timestamp} %{LOGLEVEL:loglevel} %{HOSTNAME:openstack_hostname} %{DATA:openstack_component}: %{GREEDYDATA:message}",
      "message", "%{TIMESTAMP_ISO8601:timestamp} %{LOGLEVEL:loglevel} %{HOSTNAME:openstack_hostname} %{DATA:openstack_component} %{GREEDYDATA:message}"
    ]
    add_tag => "openstack_logs"
  }

}
<commit_msg>Added horizon logs to logstash config<commit_after>input {

  file {
    path => "/opt/log/nova.log"
    type => "nova"
    start_position => beginning
  }

  file {
    path => "/opt/log/glance.log"
    type => "glance"
    start_position => beginning
  }

  file {
    path => "/opt/log/neutron.log"
    type => "neutron"
    start_position => beginning
  }

  file {
    path => "/opt/log/cinder.log"
    type => "cinder"
    start_position => beginning
  }

  file {
    path => "/opt/log/keystone.log"
    type => "keystone"
    start_position => beginning
  }

  file {
    path => "/opt/log/horizon.log"
    type => "horizon"
    start_position => beginning
  }

}

filter {

  grok {
    break_on_match => true
    match => [
      "message", "%{TIMESTAMP_ISO8601:timestamp} %{LOGLEVEL:loglevel} %{HOSTNAME:openstack_hostname} %{DATA:openstack_component}: %{GREEDYDATA:message}",
      "message", "%{TIMESTAMP_ISO8601:timestamp} %{LOGLEVEL:loglevel} %{HOSTNAME:openstack_hostname} %{DATA:openstack_component} %{GREEDYDATA:message}"
    ]
    add_tag => "openstack_logs"
  }

}

{'fraction_non_alphanumeric': 0.1572139303482587, 'fraction_numerical': 0.007960199004975124, 'mean_word_length': 3.062626262626263, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 41, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4328359', 'n_tokens_mistral': 753, 'n_tokens_neox': 711, 'n_words': 120}