{"action":"created","issue":{"url":"https://api.github.com/repos/sbt/sbt/issues/2547","repository_url":"https://api.github.com/repos/sbt/sbt","labels_url":"https://api.github.com/repos/sbt/sbt/issues/2547/labels{/name}","comments_url":"https://api.github.com/repos/sbt/sbt/issues/2547/comments","events_url":"https://api.github.com/repos/sbt/sbt/issues/2547/events","html_url":"https://github.com/sbt/sbt/pull/2547","id":147276732,"number":2547,"title":"Improve performance for DefaultParsers.validID(String)","user":{"login":"pauldraper","id":1403271,"avatar_url":"https://avatars.githubusercontent.com/u/1403271?v=3","gravatar_id":"","url":"https://api.github.com/users/pauldraper","html_url":"https://github.com/pauldraper","followers_url":"https://api.github.com/users/pauldraper/followers","following_url":"https://api.github.com/users/pauldraper/following{/other_user}","gists_url":"https://api.github.com/users/pauldraper/gists{/gist_id}","starred_url":"https://api.github.com/users/pauldraper/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pauldraper/subscriptions","organizations_url":"https://api.github.com/users/pauldraper/orgs","repos_url":"https://api.github.com/users/pauldraper/repos","events_url":"https://api.github.com/users/pauldraper/events{/privacy}","received_events_url":"https://api.github.com/users/pauldraper/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2016-04-10T23:05:55Z","updated_at":"2016-10-03T02:37:56Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/sbt/sbt/pulls/2547","html_url":"https://github.com/sbt/sbt/pull/2547","diff_url":"https://github.com/sbt/sbt/pull/2547.diff","patch_url":"https://github.com/sbt/sbt/pull/2547.patch"},"body":"`DefaultParsers.validID` is called *a lot*. (I think mostly from KeyIndex).\r\n\r\nWhen loading the following project, it is called about 300k times .\r\n\r\n**project/build.sbt**\r\n\r\n```scala\r\naddSbtPlugin(\"com.typesafe.play\" % \"sbt-plugin\" % \"2.3.8\")\r\n\r\nresolvers += Resolver.typesafeRepo(\"releases\")\r\n```\r\n\r\n**build.sbt**\r\n\r\n```scala\r\nlazy val a = project.enablePlugins(PlayScala)\r\n\r\nlazy val b = project.enablePlugins(PlayScala)\r\n\r\nlazy val c = project.enablePlugins(PlayScala)\r\n\r\nlazy val d = project.enablePlugins(PlayScala)\r\n\r\nlazy val e = project.enablePlugins(PlayScala)\r\n\r\nlazy val f = project.enablePlugins(PlayScala)\r\n\r\nlazy val g = project.enablePlugins(PlayScala)\r\n\r\nlazy val h = project.enablePlugins(PlayScala)\r\n\r\nlazy val i = project.enablePlugins(PlayScala)\r\n\r\nlazy val j = project.enablePlugins(PlayScala)\r\n\r\nlazy val k = project.enablePlugins(PlayScala)\r\n\r\nlazy val l = project.enablePlugins(PlayScala)\r\n\r\nlazy val m = project.enablePlugins(PlayScala)\r\n\r\nlazy val n = project.enablePlugins(PlayScala)\r\n\r\nlazy val o = project.enablePlugins(PlayScala)\r\n\r\nlazy val p = project.enablePlugins(PlayScala)\r\n\r\nlazy val q = project.enablePlugins(PlayScala)\r\n\r\nlazy val r = project.enablePlugins(PlayScala)\r\n\r\nlazy val s = project.enablePlugins(PlayScala)\r\n\r\nlazy val t = project.enablePlugins(PlayScala)\r\n\r\nlazy val u = project.enablePlugins(PlayScala)\r\n\r\nlazy val v = project.enablePlugins(PlayScala)\r\n\r\nlazy val w = project.enablePlugins(PlayScala)\r\n\r\nlazy val x = project.enablePlugins(PlayScala)\r\n\r\nlazy val y = project.enablePlugins(PlayScala)\r\n\r\nlazy val z = project.enablePlugins(PlayScala)\r\n\r\nlazy val all = project.aggregate(a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t, u, v, w, x, y, z)\r\n\r\nlazy val consonants = project.aggregate(b, c, d, f, g, h, j, k, l, m, p, q, r, s, t, v, w, x, y, z)\r\n\r\nlazy val noel = project.aggregate(a, b, c, d, e, f, g, h, i, j, k, m, n, o, p, q, r, s, t, u, v, w, x, y, z)\r\n\r\nlazy val improvementOfEnglish = project.aggregate(a, b, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t, u, v, w, z)\r\n\r\nlazy val periodicTable = project.aggregate(a, b, c, d, e, f, g, h, i, k, l, m, n, o, p, q, r, s, t, u, v, w, z)\r\n```\r\n\r\nAfter this change, the load time after compilation is about 10% faster for me (down from 8-9s to 7-8s)."},"comment":{"url":"https://api.github.com/repos/sbt/sbt/issues/comments/251015619","html_url":"https://github.com/sbt/sbt/pull/2547#issuecomment-251015619","issue_url":"https://api.github.com/repos/sbt/sbt/issues/2547","id":251015619,"user":{"login":"pauldraper","id":1403271,"avatar_url":"https://avatars.githubusercontent.com/u/1403271?v=3","gravatar_id":"","url":"https://api.github.com/users/pauldraper","html_url":"https://github.com/pauldraper","followers_url":"https://api.github.com/users/pauldraper/followers","following_url":"https://api.github.com/users/pauldraper/following{/other_user}","gists_url":"https://api.github.com/users/pauldraper/gists{/gist_id}","starred_url":"https://api.github.com/users/pauldraper/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pauldraper/subscriptions","organizations_url":"https://api.github.com/users/pauldraper/orgs","repos_url":"https://api.github.com/users/pauldraper/repos","events_url":"https://api.github.com/users/pauldraper/events{/privacy}","received_events_url":"https://api.github.com/users/pauldraper/received_events","type":"User","site_admin":false},"created_at":"2016-10-03T02:37:56Z","updated_at":"2016-10-03T02:37:56Z","body":"Ping."}}
{"actor":{"display_login":"pauldraper"}}