{"action":"opened","number":2433,"pull_request":{"url":"https://api.github.com/repos/elastic/beats/pulls/2433","id":83666282,"html_url":"https://github.com/elastic/beats/pull/2433","diff_url":"https://github.com/elastic/beats/pull/2433.diff","patch_url":"https://github.com/elastic/beats/pull/2433.patch","issue_url":"https://api.github.com/repos/elastic/beats/issues/2433","number":2433,"state":"open","locked":false,"title":"[WIP] Introduce simple string matcher","user":{"login":"urso","id":75886,"avatar_url":"https://avatars.githubusercontent.com/u/75886?v=3","gravatar_id":"","url":"https://api.github.com/users/urso","html_url":"https://github.com/urso","followers_url":"https://api.github.com/users/urso/followers","following_url":"https://api.github.com/users/urso/following{/other_user}","gists_url":"https://api.github.com/users/urso/gists{/gist_id}","starred_url":"https://api.github.com/users/urso/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/urso/subscriptions","organizations_url":"https://api.github.com/users/urso/orgs","repos_url":"https://api.github.com/users/urso/repos","events_url":"https://api.github.com/users/urso/events{/privacy}","received_events_url":"https://api.github.com/users/urso/received_events","type":"User","site_admin":false},"body":"Match further optimizes special regular expressions, trying to replace\r\nspecial regular patterns with more performance string searches.\r\n\r\nbenchmark results:\r\n\r\nrun 1:\r\n```\r\nBenchmarkBeginning/Matcher=Regex-4     \t 1000000       \t      1521 ns/op\r\nBenchmarkBeginning/Matcher=Match-4     \t10000000       \t       132 ns/op\r\nBenchmarkBeginningSpace/Matcher=Regex-4                \t 1000000       \t      1368 ns/op\r\nBenchmarkBeginningSpace/Matcher=Match-4                \t10000000       \t       135 ns/op\r\nBenchmarkBeginningDate/Matcher=Regex-4                 \t 1000000       \t      1757 ns/op\r\nBenchmarkBeginningDate/Matcher=Match-4                 \t 1000000       \t      1889 ns/op\r\nBenchmarkStringPatternRegex/Matcher=Regex-4            \t 1000000       \t      1314 ns/op\r\nBenchmarkStringPatternRegex/Matcher=Match-4            \t 5000000       \t       266 ns/op\r\nBenchmarkStringPatternDotStarRegex/Matcher=Regex-4             \t   30000       \t     37084 ns/op\r\nBenchmarkStringPatternDotStarRegex/Matcher=Match-4             \t 5000000       \t       257 ns/op\r\n```\r\n\r\nrun 2:\r\n```\r\nBenchmarkBeginning/Matcher=Regex-4     \t 1000000       \t      1413 ns/op\r\nBenchmarkBeginning/Matcher=Match-4     \t10000000       \t       135 ns/op\r\nBenchmarkBeginningSpace/Matcher=Regex-4                \t 1000000       \t      1300 ns/op\r\nBenchmarkBeginningSpace/Matcher=Match-4                \t10000000       \t       144 ns/op\r\nBenchmarkBeginningDate/Matcher=Regex-4                 \t 1000000       \t      1918 ns/op\r\nBenchmarkBeginningDate/Matcher=Match-4                 \t 1000000       \t      1727 ns/op\r\nBenchmarkStringPatternRegex/Matcher=Regex-4            \t 1000000       \t      1300 ns/op\r\nBenchmarkStringPatternRegex/Matcher=Match-4            \t 5000000       \t       262 ns/op\r\nBenchmarkStringPatternDotStarRegex/Matcher=Regex-4             \t   50000       \t     36425 ns/op\r\nBenchmarkStringPatternDotStarRegex/Matcher=Match-4             \t 5000000       \t       254 ns/op\r\n```\r\n\r\nIn `BenchmarkBeginningDate` benchmark the regular expression can not be optimized (yet?), resulting in `Regex` and `Match` tests, both executing full regular expression.","created_at":"2016-09-01T16:36:06Z","updated_at":"2016-09-01T16:36:06Z","closed_at":null,"merged_at":null,"merge_commit_sha":"b5b9ab98949f906cd1eb62a4e0429573c868ed80","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/elastic/beats/pulls/2433/commits","review_comments_url":"https://api.github.com/repos/elastic/beats/pulls/2433/comments","review_comment_url":"https://api.github.com/repos/elastic/beats/pulls/comments{/number}","comments_url":"https://api.github.com/repos/elastic/beats/issues/2433/comments","statuses_url":"https://api.github.com/repos/elastic/beats/statuses/b6c33a94653d4d05407582374a4084ff307a656f","head":{"label":"urso:enh/string-matcher","ref":"enh/string-matcher","sha":"b6c33a94653d4d05407582374a4084ff307a656f","user":{"login":"urso","id":75886,"avatar_url":"https://avatars.githubusercontent.com/u/75886?v=3","gravatar_id":"","url":"https://api.github.com/users/urso","html_url":"https://github.com/urso","followers_url":"https://api.github.com/users/urso/followers","following_url":"https://api.github.com/users/urso/following{/other_user}","gists_url":"https://api.github.com/users/urso/gists{/gist_id}","starred_url":"https://api.github.com/users/urso/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/urso/subscriptions","organizations_url":"https://api.github.com/users/urso/orgs","repos_url":"https://api.github.com/users/urso/repos","events_url":"https://api.github.com/users/urso/events{/privacy}","received_events_url":"https://api.github.com/users/urso/received_events","type":"User","site_admin":false},"repo":{"id":40138298,"name":"beats","full_name":"urso/beats","owner":{"login":"urso","id":75886,"avatar_url":"https://avatars.githubusercontent.com/u/75886?v=3","gravatar_id":"","url":"https://api.github.com/users/urso","html_url":"https://github.com/urso","followers_url":"https://api.github.com/users/urso/followers","following_url":"https://api.github.com/users/urso/following{/other_user}","gists_url":"https://api.github.com/users/urso/gists{/gist_id}","starred_url":"https://api.github.com/users/urso/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/urso/subscriptions","organizations_url":"https://api.github.com/users/urso/orgs","repos_url":"https://api.github.com/users/urso/repos","events_url":"https://api.github.com/users/urso/events{/privacy}","received_events_url":"https://api.github.com/users/urso/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/urso/beats","description":"Open Source Real-Time Packet Analyzer","fork":true,"url":"https://api.github.com/repos/urso/beats","forks_url":"https://api.github.com/repos/urso/beats/forks","keys_url":"https://api.github.com/repos/urso/beats/keys{/key_id}","collaborators_url":"https://api.github.com/repos/urso/beats/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/urso/beats/teams","hooks_url":"https://api.github.com/repos/urso/beats/hooks","issue_events_url":"https://api.github.com/repos/urso/beats/issues/events{/number}","events_url":"https://api.github.com/repos/urso/beats/events","assignees_url":"https://api.github.com/repos/urso/beats/assignees{/user}","branches_url":"https://api.github.com/repos/urso/beats/branches{/branch}","tags_url":"https://api.github.com/repos/urso/beats/tags","blobs_url":"https://api.github.com/repos/urso/beats/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/urso/beats/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/urso/beats/git/refs{/sha}","trees_url":"https://api.github.com/repos/urso/beats/git/trees{/sha}","statuses_url":"https://api.github.com/repos/urso/beats/statuses/{sha}","languages_url":"https://api.github.com/repos/urso/beats/languages","stargazers_url":"https://api.github.com/repos/urso/beats/stargazers","contributors_url":"https://api.github.com/repos/urso/beats/contributors","subscribers_url":"https://api.github.com/repos/urso/beats/subscribers","subscription_url":"https://api.github.com/repos/urso/beats/subscription","commits_url":"https://api.github.com/repos/urso/beats/commits{/sha}","git_commits_url":"https://api.github.com/repos/urso/beats/git/commits{/sha}","comments_url":"https://api.github.com/repos/urso/beats/comments{/number}","issue_comment_url":"https://api.github.com/repos/urso/beats/issues/comments{/number}","contents_url":"https://api.github.com/repos/urso/beats/contents/{+path}","compare_url":"https://api.github.com/repos/urso/beats/compare/{base}...{head}","merges_url":"https://api.github.com/repos/urso/beats/merges","archive_url":"https://api.github.com/repos/urso/beats/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/urso/beats/downloads","issues_url":"https://api.github.com/repos/urso/beats/issues{/number}","pulls_url":"https://api.github.com/repos/urso/beats/pulls{/number}","milestones_url":"https://api.github.com/repos/urso/beats/milestones{/number}","notifications_url":"https://api.github.com/repos/urso/beats/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/urso/beats/labels{/name}","releases_url":"https://api.github.com/repos/urso/beats/releases{/id}","deployments_url":"https://api.github.com/repos/urso/beats/deployments","created_at":"2015-08-03T17:25:21Z","updated_at":"2016-05-31T08:47:31Z","pushed_at":"2016-09-01T16:32:53Z","git_url":"git://github.com/urso/beats.git","ssh_url":"git@github.com:urso/beats.git","clone_url":"https://github.com/urso/beats.git","svn_url":"https://github.com/urso/beats","homepage":"https://www.elastic.co/products/beats/packetbeat","size":39987,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"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":"elastic:master","ref":"master","sha":"5ac21bf3154af3a0bb56cb0d64c44f794b094630","user":{"login":"elastic","id":6764390,"avatar_url":"https://avatars.githubusercontent.com/u/6764390?v=3","gravatar_id":"","url":"https://api.github.com/users/elastic","html_url":"https://github.com/elastic","followers_url":"https://api.github.com/users/elastic/followers","following_url":"https://api.github.com/users/elastic/following{/other_user}","gists_url":"https://api.github.com/users/elastic/gists{/gist_id}","starred_url":"https://api.github.com/users/elastic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/elastic/subscriptions","organizations_url":"https://api.github.com/users/elastic/orgs","repos_url":"https://api.github.com/users/elastic/repos","events_url":"https://api.github.com/users/elastic/events{/privacy}","received_events_url":"https://api.github.com/users/elastic/received_events","type":"Organization","site_admin":false},"repo":{"id":16554739,"name":"beats","full_name":"elastic/beats","owner":{"login":"elastic","id":6764390,"avatar_url":"https://avatars.githubusercontent.com/u/6764390?v=3","gravatar_id":"","url":"https://api.github.com/users/elastic","html_url":"https://github.com/elastic","followers_url":"https://api.github.com/users/elastic/followers","following_url":"https://api.github.com/users/elastic/following{/other_user}","gists_url":"https://api.github.com/users/elastic/gists{/gist_id}","starred_url":"https://api.github.com/users/elastic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/elastic/subscriptions","organizations_url":"https://api.github.com/users/elastic/orgs","repos_url":"https://api.github.com/users/elastic/repos","events_url":"https://api.github.com/users/elastic/events{/privacy}","received_events_url":"https://api.github.com/users/elastic/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/elastic/beats","description":":tropical_fish: Beats - Lightweight shippers for Elasticsearch & Logstash ","fork":false,"url":"https://api.github.com/repos/elastic/beats","forks_url":"https://api.github.com/repos/elastic/beats/forks","keys_url":"https://api.github.com/repos/elastic/beats/keys{/key_id}","collaborators_url":"https://api.github.com/repos/elastic/beats/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/elastic/beats/teams","hooks_url":"https://api.github.com/repos/elastic/beats/hooks","issue_events_url":"https://api.github.com/repos/elastic/beats/issues/events{/number}","events_url":"https://api.github.com/repos/elastic/beats/events","assignees_url":"https://api.github.com/repos/elastic/beats/assignees{/user}","branches_url":"https://api.github.com/repos/elastic/beats/branches{/branch}","tags_url":"https://api.github.com/repos/elastic/beats/tags","blobs_url":"https://api.github.com/repos/elastic/beats/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/elastic/beats/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/elastic/beats/git/refs{/sha}","trees_url":"https://api.github.com/repos/elastic/beats/git/trees{/sha}","statuses_url":"https://api.github.com/repos/elastic/beats/statuses/{sha}","languages_url":"https://api.github.com/repos/elastic/beats/languages","stargazers_url":"https://api.github.com/repos/elastic/beats/stargazers","contributors_url":"https://api.github.com/repos/elastic/beats/contributors","subscribers_url":"https://api.github.com/repos/elastic/beats/subscribers","subscription_url":"https://api.github.com/repos/elastic/beats/subscription","commits_url":"https://api.github.com/repos/elastic/beats/commits{/sha}","git_commits_url":"https://api.github.com/repos/elastic/beats/git/commits{/sha}","comments_url":"https://api.github.com/repos/elastic/beats/comments{/number}","issue_comment_url":"https://api.github.com/repos/elastic/beats/issues/comments{/number}","contents_url":"https://api.github.com/repos/elastic/beats/contents/{+path}","compare_url":"https://api.github.com/repos/elastic/beats/compare/{base}...{head}","merges_url":"https://api.github.com/repos/elastic/beats/merges","archive_url":"https://api.github.com/repos/elastic/beats/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/elastic/beats/downloads","issues_url":"https://api.github.com/repos/elastic/beats/issues{/number}","pulls_url":"https://api.github.com/repos/elastic/beats/pulls{/number}","milestones_url":"https://api.github.com/repos/elastic/beats/milestones{/number}","notifications_url":"https://api.github.com/repos/elastic/beats/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/elastic/beats/labels{/name}","releases_url":"https://api.github.com/repos/elastic/beats/releases{/id}","deployments_url":"https://api.github.com/repos/elastic/beats/deployments","created_at":"2014-02-05T19:01:02Z","updated_at":"2016-09-01T14:40:47Z","pushed_at":"2016-09-01T13:30:22Z","git_url":"git://github.com/elastic/beats.git","ssh_url":"git@github.com:elastic/beats.git","clone_url":"https://github.com/elastic/beats.git","svn_url":"https://github.com/elastic/beats","homepage":"https://www.elastic.co/products/beats","size":46097,"stargazers_count":3131,"watchers_count":3131,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":544,"mirror_url":null,"open_issues_count":290,"forks":544,"open_issues":290,"watchers":3131,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/elastic/beats/pulls/2433"},"html":{"href":"https://github.com/elastic/beats/pull/2433"},"issue":{"href":"https://api.github.com/repos/elastic/beats/issues/2433"},"comments":{"href":"https://api.github.com/repos/elastic/beats/issues/2433/comments"},"review_comments":{"href":"https://api.github.com/repos/elastic/beats/pulls/2433/comments"},"review_comment":{"href":"https://api.github.com/repos/elastic/beats/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/elastic/beats/pulls/2433/commits"},"statuses":{"href":"https://api.github.com/repos/elastic/beats/statuses/b6c33a94653d4d05407582374a4084ff307a656f"}},"merged":false,"mergeable":true,"mergeable_state":"clean","merged_by":null,"comments":0,"review_comments":0,"commits":1,"additions":354,"deletions":0,"changed_files":2}}
{"actor":{"display_login":"urso"}}