{"action":"created","comment":{"url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/pulls/comments/113544005","pull_request_review_id":34942171,"id":113544005,"diff_hunk":"@@ -0,0 +1,288 @@\n+# encoding: utf-8\n+require \"logstash/filters/base\"\n+require \"logstash/namespace\"\n+require \"lru_redux\"\n+require \"rest-client\"\n+require \"uri\"\n+require \"logstash/json\"\n+\n+# Kubernetes collects logs in files on each of its minion hosts. The filenames for\n+# these log files are structured to contain various information including the pod\n+# name, container id, namespace, etc...\n+#\n+# This plugin parses the information from these filenames, uses the information to\n+# query the kubernetes API for more information such as labels, and log format, and\n+# caches this information for fast subsequent lookups for matching filename parameters.\n+#\n+# The data collected is then added to the logstash event under the target field\n+# specified and returned for further processing or output.\n+#\n+# === Configuration\n+#\n+# The following is a basic configuration. Assuming your Kubernetes cluster does\n+# not require basic auth and it is running locally at http://127.0.0.1:8001, there\n+# are no required configuration options.\n+#\n+# Most users will at least want to specify an API server which would be done like so...\n+#\n+# [source, ruby]\n+# -----------------------------------------------------------------\n+# kubernetes_metadata {\n+#   api => \"https://your.kube.api.server\"\n+# }\n+# -----------------------------------------------------------------\n+#\n+# === Example Input/Output\n+#\n+# Given a log file: `/logs/kube-logs/ssl-manager-535881469-x6hmm_storj-prod_ssl-manager-c817d2905d339677288ff73375856a066d4b4d8d45482e1f2e234428d217eb19.log`\n+#\n+# and the contents:\n+# [source, json]\n+# -----------------------------------------------------------------\n+# {\"log\":\"10.244.1.1 - - [25/Jan/2017:14:51:38 +0000] \\\"GET / HTTP/1.1\\\" 200 0 \\\"-\\\" \\\"GoogleHC/1.0\\\" \\\"-\\\"\\n\",\"stream\":\"stdout\",\"time\":\"2017-01-25T14:51:38.65719468Z\"}\n+# -----------------------------------------------------------------\n+#\n+# You would end up with an output of...\n+#\n+# [source, ruby]\n+# -----------------------------------------------------------------\n+# {\n+#   \"path\" => \"/logs/kube-logs/ssl-manager-535881469-x6hmm_storj-prod_ssl-manager-c817d2905d339677288ff73375856a066d4b4d8d45482e1f2e234428d217eb19.log\",\n+#   \"kubernetes\" => {\n+#     \"log_format_stdout\" => \"default\",\n+#     \"pod\" => \"ssl-manager-535881469-x6hmm\",\n+#     \"container_name\" => \"ssl-manager\",\n+#     \"log_format_stderr\" => \"default\",\n+#     \"namespace\" => \"storj-prod\",\n+#     \"replication_controller\" => \"ssl-manager-535881469\",\n+#     \"annotations\" => {\n+#       \"kubernetes_io-created-by\" => \"{\\\"kind\\\":\\\"SerializedReference\\\",\\\"apiVersion\\\":\\\"v1\\\",\\\"reference\\\":{\\\"kind\\\":\\\"ReplicaSet\\\",\\\"namespace\\\":\\\"storj-prod\\\",\\\"name\\\":\\\"ssl-manager-535881469\\\",\\\"uid\\\":\\\"aca823ae-e271-11e6-99b2-42010a800002\\\",\\\"apiVersion\\\":\\\"extensions\\\",\\\"resourceVersion\\\":\\\"19491631\\\"}}\\n\"\n+#     },\n+#     \"container_id\" => \"c817d2905d339677288ff73375856a066d4b4d8d45482e1f2e234428d217eb19\",\n+#     \"labels\" => {\n+#       \"app\" => \"ssl-manager\",\n+#       \"pod-template-hash\" => \"535881469\",\n+#       \"version\" => \"latest\"\n+#     }\n+#   },\n+#   \"@timestamp\" => 2017-02-13T02:33:11.702Z,\n+#   \"@version\" => \"1\",\n+#   \"host\" => \"floptop.local\",\n+#   \"message\" => \"{\\\"log\\\":\\\"10.244.1.1 - - [25/Jan/2017:14:51:38 +0000] \\\\\\\"GET / HTTP/1.1\\\\\\\" 200 0 \\\\\\\"-\\\\\\\" \\\\\\\"GoogleHC/1.0\\\\\\\" \\\\\\\"-\\\\\\\"\\\\n\\\",\\\"stream\\\":\\\"stdout\\\",\\\"time\\\":\\\"2017-01-25T14:51:38.65719468Z\\\"}\",\n+#   \"tags\" => []\n+# }\n+# -----------------------------------------------------------------\n+#\n+\n+class LogStash::Filters::KubernetesMetadata < LogStash::Filters::Base\n+\n+  attr_accessor :lookup_cache\n+\n+  config_name \"kubernetes_metadata\"\n+\n+  # The source field name which contains full path to kubelet log file.\n+  config :source, :validate => :string, :default => \"path\"\n+\n+  # The target field name to write event kubernetes metadata.\n+  config :target, :validate => :string, :default => \"kubernetes\"\n+\n+  # Auth for hitting the Kubernetes API. This can be either basic auth or\n+  # Bearer auth. It should be formated like the following\n+  # [source, ruby]\n+  # -----------------------------------------------------------------\n+  # auth => { # Authentication for your API in the form of either basic or bearer auth\n+  #   basic => {\n+  #     user => \"mykubeusername\"\n+  #     pass => \"superwonderfulsecurepassword\"\n+  #   }\n+  #\n+  #   # ...or...\n+  #\n+  #   bearer  => {\n+  #     key => \"mybearerkeystring\"\n+  #   }\n+  # }\n+  # -----------------------------------------------------------------\n+  config :auth, :validate => :hash, :default => {}\n+\n+  # Kubernetes API URL\n+  config :api, :validate => :string, :default => \"http://127.0.0.1:8001\"\n+\n+  # Default log format\n+  config :default_log_format, :validate => :string, :default => \"default\"\n+\n+  public\n+  def register\n+    @logger.debug(\"Registering Kubernetes Filter plugin\")\n+    self.lookup_cache ||= LruRedux::ThreadSafeCache.new(1000, 900)\n+    @logger.debug(\"Created cache...\")\n+  end\n+\n+  # this is optimized for the single container case. it caches based on filename to avoid the\n+  # filename munging on every event.\n+\n+  public\n+  def filter(event)\n+    @logger.debug(\"event is: #{event}\")\n+    path = event.get(@source)\n+\n+    # Ensure that the path parameter has been defined so that we can find the required metadata\n+    if (path.nil? || path.empty?)\n+      event.tag(\"_kubeparsefailure\")\n+      return\n+    end\n+\n+    @logger.debug(\"Log entry has source field, beginning processing for Kubernetes\")\n+\n+    metadata = {}\n+    cached_metadata = lookup_cache[path]\n+    file_metadata = get_file_info(path)\n+\n+    # If we were unable to extract metadata from the file name, return\n+    return unless file_metadata\n+\n+    if cached_metadata\n+      metadata = file_metadata.merge(cached_metadata)\n+    else\n+      @logger.debug(\"Trying to get kubernetes file info, it was not cached\");\n+      @logger.debug(\"kubernetes file info got: #{metadata}\")\n+\n+      pod = file_metadata['pod']\n+      namespace = file_metadata['namespace']\n+      name = file_metadata['container_name']\n+\n+      return unless pod and namespace and name\n+\n+      if data = get_kubernetes(namespace, pod)\n+        metadata = file_metadata.merge(data)\n+        set_log_formats(metadata)\n+        lookup_cache[path] = metadata\n+      end\n+      @logger.debug(\"metadata within lookup_cache[path]: #{metadata}\")\n+    end\n+\n+\n+    @logger.debug(\"metadata after unless lookup_cache[path] is: #{metadata}\")\n+    @logger.debug(\"config after unless lookup_cache[path] is: #{config}\")\n+\n+    event.set(@target, metadata)\n+    return filter_matched(event)\n+  end\n+\n+  def set_log_formats(metadata)\n+    begin\n+      #return if metadata['annotations'].empty?\n+\n+      format = {\n+        'stderr' => @default_log_format,\n+        'stdout' => @default_log_format\n+      }\n+      a = metadata['annotations']\n+      n = metadata['container_name']\n+\n+      # check for log-format-<stream>-<name>, log-format-<name>, log-format-<stream>, log-format\n+      # in annotations\n+      %w{ stderr stdout }.each do |t|\n+        [ \"log-format-#{t}-#{n}\", \"log-format-#{n}\", \"log-format-#{t}\", \"log-format\" ].each do |k|\n+          if v = a[k]\n+            format[t] = v\n+            break\n+          end\n+        end\n+      end\n+\n+      metadata['log_format_stderr'] = format['stderr']\n+      metadata['log_format_stdout'] = format['stdout']\n+      @logger.debug(\"kubernetes metadata => #{metadata}\")\n+\n+    rescue => e\n+      @logger.warn(\"Error setting log format: #{e}\")\n+    end\n+  end\n+\n+  # based on https://github.com/vaijab/logstash-filter-kubernetes/blob/master/lib/logstash/filters/kubernetes.rb\n+  def get_file_info(path)\n+    parts = path.split(File::SEPARATOR).last.gsub(/.log$/, '').split('_')\n+    if parts.length != 3 || parts[2].start_with?('POD-')\n+      return nil\n+    end\n+    kubernetes = {}\n+    kubernetes['replication_controller'] = parts[0].gsub(/-[0-9a-z]*$/, '')\n+    kubernetes['pod'] = parts[0]\n+    kubernetes['namespace'] = parts[1]\n+    kubernetes['container_name'] = parts[2].gsub(/-[0-9a-z]*$/, '')\n+    kubernetes['container_id'] = parts[2].split('-').last\n+    return kubernetes\n+  end\n+\n+  def sanatize_keys(data)\n+    return {} unless data\n+\n+    parsed_data = {}\n+    data.each do |k,v|\n+      new_key = k.gsub(/\\.|,/, '_')\n+        .gsub(/\\//, '-')\n+      parsed_data[new_key] = v\n+    end\n+\n+    return parsed_data\n+  end\n+\n+  def get_kubernetes(namespace, pod)\n+\n+    begin\n+      @logger.debug(\"Attempting to query the Kubernetes API\")\n+\n+      url = [ @api, 'api/v1/namespaces', namespace, 'pods', pod ].join(\"/\")\n+\n+      rest_opts = {\n+        verify_ssl: false\n+      }\n+\n+      if @auth\n+        if @auth['basic']\n+          @logger.debug(\"Found basic auth for Kubernetes API\")\n+\n+          basic_user = @auth['basic']['user']\n+          basic_pass = @auth['basic']['pass']","path":"lib/logstash/filters/kubernetes_metadata.rb","position":259,"original_position":247,"commit_id":"5c600591f15c5e0b8544c4d5ab25d87b74b09434","original_commit_id":"9bac7e984c6bf15e26125d90dc74fabc7c74d94d","user":{"login":"phutchins","id":1074345,"avatar_url":"https://avatars0.githubusercontent.com/u/1074345?v=3","gravatar_id":"","url":"https://api.github.com/users/phutchins","html_url":"https://github.com/phutchins","followers_url":"https://api.github.com/users/phutchins/followers","following_url":"https://api.github.com/users/phutchins/following{/other_user}","gists_url":"https://api.github.com/users/phutchins/gists{/gist_id}","starred_url":"https://api.github.com/users/phutchins/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/phutchins/subscriptions","organizations_url":"https://api.github.com/users/phutchins/orgs","repos_url":"https://api.github.com/users/phutchins/repos","events_url":"https://api.github.com/users/phutchins/events{/privacy}","received_events_url":"https://api.github.com/users/phutchins/received_events","type":"User","site_admin":false},"body":"Moved to a flat auth_basic_user, etc... approach and using built in config validation which should work better.","created_at":"2017-04-26T19:40:43Z","updated_at":"2017-04-26T19:40:43Z","html_url":"https://github.com/logstash-plugins/logstash-filter-kubernetes_metadata/pull/1#discussion_r113544005","pull_request_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/pulls/1","_links":{"self":{"href":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/pulls/comments/113544005"},"html":{"href":"https://github.com/logstash-plugins/logstash-filter-kubernetes_metadata/pull/1#discussion_r113544005"},"pull_request":{"href":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/pulls/1"}}},"pull_request":{"url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/pulls/1","id":105696867,"html_url":"https://github.com/logstash-plugins/logstash-filter-kubernetes_metadata/pull/1","diff_url":"https://github.com/logstash-plugins/logstash-filter-kubernetes_metadata/pull/1.diff","patch_url":"https://github.com/logstash-plugins/logstash-filter-kubernetes_metadata/pull/1.patch","issue_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/issues/1","number":1,"state":"open","locked":false,"title":"Initial code commit","user":{"login":"phutchins","id":1074345,"avatar_url":"https://avatars0.githubusercontent.com/u/1074345?v=3","gravatar_id":"","url":"https://api.github.com/users/phutchins","html_url":"https://github.com/phutchins","followers_url":"https://api.github.com/users/phutchins/followers","following_url":"https://api.github.com/users/phutchins/following{/other_user}","gists_url":"https://api.github.com/users/phutchins/gists{/gist_id}","starred_url":"https://api.github.com/users/phutchins/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/phutchins/subscriptions","organizations_url":"https://api.github.com/users/phutchins/orgs","repos_url":"https://api.github.com/users/phutchins/repos","events_url":"https://api.github.com/users/phutchins/events{/privacy}","received_events_url":"https://api.github.com/users/phutchins/received_events","type":"User","site_admin":false},"body":"","created_at":"2017-02-10T20:09:02Z","updated_at":"2017-04-26T19:40:43Z","closed_at":null,"merged_at":null,"merge_commit_sha":"ca23fa9ac2420c640002ccf8043513270ae5f7d2","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/pulls/1/commits","review_comments_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/pulls/1/comments","review_comment_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/pulls/comments{/number}","comments_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/issues/1/comments","statuses_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/statuses/5c600591f15c5e0b8544c4d5ab25d87b74b09434","head":{"label":"phutchins:master","ref":"master","sha":"5c600591f15c5e0b8544c4d5ab25d87b74b09434","user":{"login":"phutchins","id":1074345,"avatar_url":"https://avatars0.githubusercontent.com/u/1074345?v=3","gravatar_id":"","url":"https://api.github.com/users/phutchins","html_url":"https://github.com/phutchins","followers_url":"https://api.github.com/users/phutchins/followers","following_url":"https://api.github.com/users/phutchins/following{/other_user}","gists_url":"https://api.github.com/users/phutchins/gists{/gist_id}","starred_url":"https://api.github.com/users/phutchins/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/phutchins/subscriptions","organizations_url":"https://api.github.com/users/phutchins/orgs","repos_url":"https://api.github.com/users/phutchins/repos","events_url":"https://api.github.com/users/phutchins/events{/privacy}","received_events_url":"https://api.github.com/users/phutchins/received_events","type":"User","site_admin":false},"repo":{"id":81602192,"name":"logstash-filter-kubernetes_metadata-1","full_name":"phutchins/logstash-filter-kubernetes_metadata-1","owner":{"login":"phutchins","id":1074345,"avatar_url":"https://avatars0.githubusercontent.com/u/1074345?v=3","gravatar_id":"","url":"https://api.github.com/users/phutchins","html_url":"https://github.com/phutchins","followers_url":"https://api.github.com/users/phutchins/followers","following_url":"https://api.github.com/users/phutchins/following{/other_user}","gists_url":"https://api.github.com/users/phutchins/gists{/gist_id}","starred_url":"https://api.github.com/users/phutchins/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/phutchins/subscriptions","organizations_url":"https://api.github.com/users/phutchins/orgs","repos_url":"https://api.github.com/users/phutchins/repos","events_url":"https://api.github.com/users/phutchins/events{/privacy}","received_events_url":"https://api.github.com/users/phutchins/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/phutchins/logstash-filter-kubernetes_metadata-1","description":"Logstash filter for parsing kubernetes metadata and adding to log entries","fork":true,"url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1","forks_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/forks","keys_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/keys{/key_id}","collaborators_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/teams","hooks_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/hooks","issue_events_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/issues/events{/number}","events_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/events","assignees_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/assignees{/user}","branches_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/branches{/branch}","tags_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/tags","blobs_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/git/refs{/sha}","trees_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/git/trees{/sha}","statuses_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/statuses/{sha}","languages_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/languages","stargazers_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/stargazers","contributors_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/contributors","subscribers_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/subscribers","subscription_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/subscription","commits_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/commits{/sha}","git_commits_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/git/commits{/sha}","comments_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/comments{/number}","issue_comment_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/issues/comments{/number}","contents_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/contents/{+path}","compare_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/compare/{base}...{head}","merges_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/merges","archive_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/downloads","issues_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/issues{/number}","pulls_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/pulls{/number}","milestones_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/milestones{/number}","notifications_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/labels{/name}","releases_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/releases{/id}","deployments_url":"https://api.github.com/repos/phutchins/logstash-filter-kubernetes_metadata-1/deployments","created_at":"2017-02-10T20:04:26Z","updated_at":"2017-02-10T20:07:40Z","pushed_at":"2017-04-26T19:17:00Z","git_url":"git://github.com/phutchins/logstash-filter-kubernetes_metadata-1.git","ssh_url":"git@github.com:phutchins/logstash-filter-kubernetes_metadata-1.git","clone_url":"https://github.com/phutchins/logstash-filter-kubernetes_metadata-1.git","svn_url":"https://github.com/phutchins/logstash-filter-kubernetes_metadata-1","homepage":null,"size":14,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"logstash-plugins:master","ref":"master","sha":"e56998aebc347a1501b012b9967b8c7f3c9bf7e4","user":{"login":"logstash-plugins","id":8961934,"avatar_url":"https://avatars2.githubusercontent.com/u/8961934?v=3","gravatar_id":"","url":"https://api.github.com/users/logstash-plugins","html_url":"https://github.com/logstash-plugins","followers_url":"https://api.github.com/users/logstash-plugins/followers","following_url":"https://api.github.com/users/logstash-plugins/following{/other_user}","gists_url":"https://api.github.com/users/logstash-plugins/gists{/gist_id}","starred_url":"https://api.github.com/users/logstash-plugins/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/logstash-plugins/subscriptions","organizations_url":"https://api.github.com/users/logstash-plugins/orgs","repos_url":"https://api.github.com/users/logstash-plugins/repos","events_url":"https://api.github.com/users/logstash-plugins/events{/privacy}","received_events_url":"https://api.github.com/users/logstash-plugins/received_events","type":"Organization","site_admin":false},"repo":{"id":81600964,"name":"logstash-filter-kubernetes_metadata","full_name":"logstash-plugins/logstash-filter-kubernetes_metadata","owner":{"login":"logstash-plugins","id":8961934,"avatar_url":"https://avatars2.githubusercontent.com/u/8961934?v=3","gravatar_id":"","url":"https://api.github.com/users/logstash-plugins","html_url":"https://github.com/logstash-plugins","followers_url":"https://api.github.com/users/logstash-plugins/followers","following_url":"https://api.github.com/users/logstash-plugins/following{/other_user}","gists_url":"https://api.github.com/users/logstash-plugins/gists{/gist_id}","starred_url":"https://api.github.com/users/logstash-plugins/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/logstash-plugins/subscriptions","organizations_url":"https://api.github.com/users/logstash-plugins/orgs","repos_url":"https://api.github.com/users/logstash-plugins/repos","events_url":"https://api.github.com/users/logstash-plugins/events{/privacy}","received_events_url":"https://api.github.com/users/logstash-plugins/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/logstash-plugins/logstash-filter-kubernetes_metadata","description":"Logstash filter for parsing kubernetes metadata and adding to log entries","fork":false,"url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata","forks_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/forks","keys_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/keys{/key_id}","collaborators_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/teams","hooks_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/hooks","issue_events_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/issues/events{/number}","events_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/events","assignees_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/assignees{/user}","branches_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/branches{/branch}","tags_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/tags","blobs_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/git/refs{/sha}","trees_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/git/trees{/sha}","statuses_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/statuses/{sha}","languages_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/languages","stargazers_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/stargazers","contributors_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/contributors","subscribers_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/subscribers","subscription_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/subscription","commits_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/commits{/sha}","git_commits_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/git/commits{/sha}","comments_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/comments{/number}","issue_comment_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/issues/comments{/number}","contents_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/contents/{+path}","compare_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/compare/{base}...{head}","merges_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/merges","archive_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/downloads","issues_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/issues{/number}","pulls_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/pulls{/number}","milestones_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/milestones{/number}","notifications_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/labels{/name}","releases_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/releases{/id}","deployments_url":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/deployments","created_at":"2017-02-10T19:48:12Z","updated_at":"2017-02-10T19:48:12Z","pushed_at":"2017-04-26T19:17:02Z","git_url":"git://github.com/logstash-plugins/logstash-filter-kubernetes_metadata.git","ssh_url":"git@github.com:logstash-plugins/logstash-filter-kubernetes_metadata.git","clone_url":"https://github.com/logstash-plugins/logstash-filter-kubernetes_metadata.git","svn_url":"https://github.com/logstash-plugins/logstash-filter-kubernetes_metadata","homepage":null,"size":0,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":1,"forks":1,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/pulls/1"},"html":{"href":"https://github.com/logstash-plugins/logstash-filter-kubernetes_metadata/pull/1"},"issue":{"href":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/issues/1"},"comments":{"href":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/issues/1/comments"},"review_comments":{"href":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/pulls/1/comments"},"review_comment":{"href":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/pulls/1/commits"},"statuses":{"href":"https://api.github.com/repos/logstash-plugins/logstash-filter-kubernetes_metadata/statuses/5c600591f15c5e0b8544c4d5ab25d87b74b09434"}}}}
{"actor":{"display_login":"phutchins"}}