{"action":"created","comment":{"url":"https://api.github.com/repos/gradle/gradle/pulls/comments/170571532","pull_request_review_id":99274586,"id":170571532,"diff_hunk":"@@ -0,0 +1,209 @@\n+/*\n+ * Copyright 2018 the original author or authors.\n+ *\n+ * Licensed under the Apache License, Version 2.0 (the \"License\");\n+ * you may not use this file except in compliance with the License.\n+ * You may obtain a copy of the License at\n+ *\n+ *      http://www.apache.org/licenses/LICENSE-2.0\n+ *\n+ * Unless required by applicable law or agreed to in writing, software\n+ * distributed under the License is distributed on an \"AS IS\" BASIS,\n+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n+ * See the License for the specific language governing permissions and\n+ * limitations under the License.\n+ */\n+package org.gradle.plugins.buildscan\n+\n+import com.gradle.scan.plugin.BuildScanExtension\n+import org.gradle.api.Plugin\n+import org.gradle.api.Project\n+import org.gradle.api.plugins.quality.Checkstyle\n+import org.gradle.api.plugins.quality.CodeNarc\n+import org.gradle.api.reporting.ReportContainer\n+import org.gradle.api.reporting.Reporting\n+import org.gradle.kotlin.dsl.the\n+import org.jsoup.Jsoup\n+import org.jsoup.parser.Parser\n+import org.gradle.api.internal.GradleInternal\n+import org.gradle.internal.classloader.ClassLoaderHierarchyHasher\n+import kotlin.concurrent.thread\n+\n+\n+class BuildScanConfigurationPlugin : Plugin<Project> {\n+    private\n+    val isCiServer = System.getenv().containsKey(\"CI\")\n+\n+    override fun apply(project: Project): Unit = project.run {\n+        apply {\n+            plugin(\"com.gradle.build-scan\")","path":"buildSrc/src/main/kotlin/org/gradle/plugins/buildscan/BuildScanConfigurationPlugin.kt","position":39,"original_position":39,"commit_id":"680b5036b569ef8fad05be6b4e8f848de8b80d55","original_commit_id":"680b5036b569ef8fad05be6b4e8f848de8b80d55","user":{"login":"wolfs","id":423186,"avatar_url":"https://avatars1.githubusercontent.com/u/423186?v=4","gravatar_id":"","url":"https://api.github.com/users/wolfs","html_url":"https://github.com/wolfs","followers_url":"https://api.github.com/users/wolfs/followers","following_url":"https://api.github.com/users/wolfs/following{/other_user}","gists_url":"https://api.github.com/users/wolfs/gists{/gist_id}","starred_url":"https://api.github.com/users/wolfs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wolfs/subscriptions","organizations_url":"https://api.github.com/users/wolfs/orgs","repos_url":"https://api.github.com/users/wolfs/repos","events_url":"https://api.github.com/users/wolfs/events{/privacy}","received_events_url":"https://api.github.com/users/wolfs/received_events","type":"User","site_admin":false},"body":"Why don't we apply the plugin by type, given that we now have the plugin on the classpath?","created_at":"2018-02-26T12:08:49Z","updated_at":"2018-02-26T12:31:47Z","html_url":"https://github.com/gradle/gradle/pull/4508#discussion_r170571532","pull_request_url":"https://api.github.com/repos/gradle/gradle/pulls/4508","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/gradle/gradle/pulls/comments/170571532"},"html":{"href":"https://github.com/gradle/gradle/pull/4508#discussion_r170571532"},"pull_request":{"href":"https://api.github.com/repos/gradle/gradle/pulls/4508"}}},"pull_request":{"url":"https://api.github.com/repos/gradle/gradle/pulls/4508","id":171151819,"html_url":"https://github.com/gradle/gradle/pull/4508","diff_url":"https://github.com/gradle/gradle/pull/4508.diff","patch_url":"https://github.com/gradle/gradle/pull/4508.patch","issue_url":"https://api.github.com/repos/gradle/gradle/issues/4508","number":4508,"state":"open","locked":false,"title":"Migrated buildscan configuration to Kotlin.","user":{"login":"hansd","id":37539,"avatar_url":"https://avatars2.githubusercontent.com/u/37539?v=4","gravatar_id":"","url":"https://api.github.com/users/hansd","html_url":"https://github.com/hansd","followers_url":"https://api.github.com/users/hansd/followers","following_url":"https://api.github.com/users/hansd/following{/other_user}","gists_url":"https://api.github.com/users/hansd/gists{/gist_id}","starred_url":"https://api.github.com/users/hansd/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hansd/subscriptions","organizations_url":"https://api.github.com/users/hansd/orgs","repos_url":"https://api.github.com/users/hansd/repos","events_url":"https://api.github.com/users/hansd/events{/privacy}","received_events_url":"https://api.github.com/users/hansd/received_events","type":"User","site_admin":false},"body":"I have migrated the build scan configuration to Kotlin. \r\n\r\nSome of the build scan configuration was written by the build-cache team. It would be great if the build-cache team could validate the build scan logic for the cache data. I have tried it out and could collect classloader specific data: https://e.grdev.net/s/yfaoh54pmwjxy/custom-values\r\n\r\nAlso in discussion with the build cache team we have agreed to delete the file`taskCacheDetailedDiagnosticsInit.gradle` without providing a replacement.\r\n\r\nIt would be great if the GE team could check the other parts of the build scan configuration. I have already discussed with Luke on how to avoid issues with auto-apply when using `--scan`. This pull request contains the solution Luke has proposed. In my manual testing it has worked fine.","created_at":"2018-02-24T01:19:44Z","updated_at":"2018-02-26T12:31:47Z","closed_at":null,"merged_at":null,"merge_commit_sha":"b280b7177102ba48054414b37d48cb8a0fb178f5","assignee":null,"assignees":[],"requested_reviewers":[{"login":"ldaley","id":17825,"avatar_url":"https://avatars0.githubusercontent.com/u/17825?v=4","gravatar_id":"","url":"https://api.github.com/users/ldaley","html_url":"https://github.com/ldaley","followers_url":"https://api.github.com/users/ldaley/followers","following_url":"https://api.github.com/users/ldaley/following{/other_user}","gists_url":"https://api.github.com/users/ldaley/gists{/gist_id}","starred_url":"https://api.github.com/users/ldaley/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ldaley/subscriptions","organizations_url":"https://api.github.com/users/ldaley/orgs","repos_url":"https://api.github.com/users/ldaley/repos","events_url":"https://api.github.com/users/ldaley/events{/privacy}","received_events_url":"https://api.github.com/users/ldaley/received_events","type":"User","site_admin":false},{"login":"bamboo","id":51689,"avatar_url":"https://avatars1.githubusercontent.com/u/51689?v=4","gravatar_id":"","url":"https://api.github.com/users/bamboo","html_url":"https://github.com/bamboo","followers_url":"https://api.github.com/users/bamboo/followers","following_url":"https://api.github.com/users/bamboo/following{/other_user}","gists_url":"https://api.github.com/users/bamboo/gists{/gist_id}","starred_url":"https://api.github.com/users/bamboo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bamboo/subscriptions","organizations_url":"https://api.github.com/users/bamboo/orgs","repos_url":"https://api.github.com/users/bamboo/repos","events_url":"https://api.github.com/users/bamboo/events{/privacy}","received_events_url":"https://api.github.com/users/bamboo/received_events","type":"User","site_admin":false},{"login":"eskatos","id":132773,"avatar_url":"https://avatars3.githubusercontent.com/u/132773?v=4","gravatar_id":"","url":"https://api.github.com/users/eskatos","html_url":"https://github.com/eskatos","followers_url":"https://api.github.com/users/eskatos/followers","following_url":"https://api.github.com/users/eskatos/following{/other_user}","gists_url":"https://api.github.com/users/eskatos/gists{/gist_id}","starred_url":"https://api.github.com/users/eskatos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eskatos/subscriptions","organizations_url":"https://api.github.com/users/eskatos/orgs","repos_url":"https://api.github.com/users/eskatos/repos","events_url":"https://api.github.com/users/eskatos/events{/privacy}","received_events_url":"https://api.github.com/users/eskatos/received_events","type":"User","site_admin":false},{"login":"lptr","id":495366,"avatar_url":"https://avatars2.githubusercontent.com/u/495366?v=4","gravatar_id":"","url":"https://api.github.com/users/lptr","html_url":"https://github.com/lptr","followers_url":"https://api.github.com/users/lptr/followers","following_url":"https://api.github.com/users/lptr/following{/other_user}","gists_url":"https://api.github.com/users/lptr/gists{/gist_id}","starred_url":"https://api.github.com/users/lptr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lptr/subscriptions","organizations_url":"https://api.github.com/users/lptr/orgs","repos_url":"https://api.github.com/users/lptr/repos","events_url":"https://api.github.com/users/lptr/events{/privacy}","received_events_url":"https://api.github.com/users/lptr/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[{"id":782821141,"url":"https://api.github.com/repos/gradle/gradle/labels/dogfood:kotlin-dsl","name":"dogfood:kotlin-dsl","color":"006b75","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/gradle/gradle/pulls/4508/commits","review_comments_url":"https://api.github.com/repos/gradle/gradle/pulls/4508/comments","review_comment_url":"https://api.github.com/repos/gradle/gradle/pulls/comments{/number}","comments_url":"https://api.github.com/repos/gradle/gradle/issues/4508/comments","statuses_url":"https://api.github.com/repos/gradle/gradle/statuses/680b5036b569ef8fad05be6b4e8f848de8b80d55","head":{"label":"gradle:hansd/buildscan-config","ref":"hansd/buildscan-config","sha":"680b5036b569ef8fad05be6b4e8f848de8b80d55","user":{"login":"gradle","id":124156,"avatar_url":"https://avatars2.githubusercontent.com/u/124156?v=4","gravatar_id":"","url":"https://api.github.com/users/gradle","html_url":"https://github.com/gradle","followers_url":"https://api.github.com/users/gradle/followers","following_url":"https://api.github.com/users/gradle/following{/other_user}","gists_url":"https://api.github.com/users/gradle/gists{/gist_id}","starred_url":"https://api.github.com/users/gradle/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gradle/subscriptions","organizations_url":"https://api.github.com/users/gradle/orgs","repos_url":"https://api.github.com/users/gradle/repos","events_url":"https://api.github.com/users/gradle/events{/privacy}","received_events_url":"https://api.github.com/users/gradle/received_events","type":"Organization","site_admin":false},"repo":{"id":302322,"name":"gradle","full_name":"gradle/gradle","owner":{"login":"gradle","id":124156,"avatar_url":"https://avatars2.githubusercontent.com/u/124156?v=4","gravatar_id":"","url":"https://api.github.com/users/gradle","html_url":"https://github.com/gradle","followers_url":"https://api.github.com/users/gradle/followers","following_url":"https://api.github.com/users/gradle/following{/other_user}","gists_url":"https://api.github.com/users/gradle/gists{/gist_id}","starred_url":"https://api.github.com/users/gradle/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gradle/subscriptions","organizations_url":"https://api.github.com/users/gradle/orgs","repos_url":"https://api.github.com/users/gradle/repos","events_url":"https://api.github.com/users/gradle/events{/privacy}","received_events_url":"https://api.github.com/users/gradle/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/gradle/gradle","description":"Adaptable, fast automation for all","fork":false,"url":"https://api.github.com/repos/gradle/gradle","forks_url":"https://api.github.com/repos/gradle/gradle/forks","keys_url":"https://api.github.com/repos/gradle/gradle/keys{/key_id}","collaborators_url":"https://api.github.com/repos/gradle/gradle/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/gradle/gradle/teams","hooks_url":"https://api.github.com/repos/gradle/gradle/hooks","issue_events_url":"https://api.github.com/repos/gradle/gradle/issues/events{/number}","events_url":"https://api.github.com/repos/gradle/gradle/events","assignees_url":"https://api.github.com/repos/gradle/gradle/assignees{/user}","branches_url":"https://api.github.com/repos/gradle/gradle/branches{/branch}","tags_url":"https://api.github.com/repos/gradle/gradle/tags","blobs_url":"https://api.github.com/repos/gradle/gradle/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/gradle/gradle/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/gradle/gradle/git/refs{/sha}","trees_url":"https://api.github.com/repos/gradle/gradle/git/trees{/sha}","statuses_url":"https://api.github.com/repos/gradle/gradle/statuses/{sha}","languages_url":"https://api.github.com/repos/gradle/gradle/languages","stargazers_url":"https://api.github.com/repos/gradle/gradle/stargazers","contributors_url":"https://api.github.com/repos/gradle/gradle/contributors","subscribers_url":"https://api.github.com/repos/gradle/gradle/subscribers","subscription_url":"https://api.github.com/repos/gradle/gradle/subscription","commits_url":"https://api.github.com/repos/gradle/gradle/commits{/sha}","git_commits_url":"https://api.github.com/repos/gradle/gradle/git/commits{/sha}","comments_url":"https://api.github.com/repos/gradle/gradle/comments{/number}","issue_comment_url":"https://api.github.com/repos/gradle/gradle/issues/comments{/number}","contents_url":"https://api.github.com/repos/gradle/gradle/contents/{+path}","compare_url":"https://api.github.com/repos/gradle/gradle/compare/{base}...{head}","merges_url":"https://api.github.com/repos/gradle/gradle/merges","archive_url":"https://api.github.com/repos/gradle/gradle/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/gradle/gradle/downloads","issues_url":"https://api.github.com/repos/gradle/gradle/issues{/number}","pulls_url":"https://api.github.com/repos/gradle/gradle/pulls{/number}","milestones_url":"https://api.github.com/repos/gradle/gradle/milestones{/number}","notifications_url":"https://api.github.com/repos/gradle/gradle/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/gradle/gradle/labels{/name}","releases_url":"https://api.github.com/repos/gradle/gradle/releases{/id}","deployments_url":"https://api.github.com/repos/gradle/gradle/deployments","created_at":"2009-09-09T18:27:19Z","updated_at":"2018-02-26T08:11:48Z","pushed_at":"2018-02-26T12:00:05Z","git_url":"git://github.com/gradle/gradle.git","ssh_url":"git@github.com:gradle/gradle.git","clone_url":"https://github.com/gradle/gradle.git","svn_url":"https://github.com/gradle/gradle","homepage":"https://gradle.org","size":201828,"stargazers_count":6327,"watchers_count":6327,"language":"Java","has_issues":true,"has_projects":false,"has_downloads":false,"has_wiki":true,"has_pages":false,"forks_count":2064,"mirror_url":null,"archived":false,"open_issues_count":941,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0"},"forks":2064,"open_issues":941,"watchers":6327,"default_branch":"master"}},"base":{"label":"gradle:master","ref":"master","sha":"6578ad7d364aeb90c083ea5360b10cd0ffd2fc2a","user":{"login":"gradle","id":124156,"avatar_url":"https://avatars2.githubusercontent.com/u/124156?v=4","gravatar_id":"","url":"https://api.github.com/users/gradle","html_url":"https://github.com/gradle","followers_url":"https://api.github.com/users/gradle/followers","following_url":"https://api.github.com/users/gradle/following{/other_user}","gists_url":"https://api.github.com/users/gradle/gists{/gist_id}","starred_url":"https://api.github.com/users/gradle/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gradle/subscriptions","organizations_url":"https://api.github.com/users/gradle/orgs","repos_url":"https://api.github.com/users/gradle/repos","events_url":"https://api.github.com/users/gradle/events{/privacy}","received_events_url":"https://api.github.com/users/gradle/received_events","type":"Organization","site_admin":false},"repo":{"id":302322,"name":"gradle","full_name":"gradle/gradle","owner":{"login":"gradle","id":124156,"avatar_url":"https://avatars2.githubusercontent.com/u/124156?v=4","gravatar_id":"","url":"https://api.github.com/users/gradle","html_url":"https://github.com/gradle","followers_url":"https://api.github.com/users/gradle/followers","following_url":"https://api.github.com/users/gradle/following{/other_user}","gists_url":"https://api.github.com/users/gradle/gists{/gist_id}","starred_url":"https://api.github.com/users/gradle/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gradle/subscriptions","organizations_url":"https://api.github.com/users/gradle/orgs","repos_url":"https://api.github.com/users/gradle/repos","events_url":"https://api.github.com/users/gradle/events{/privacy}","received_events_url":"https://api.github.com/users/gradle/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/gradle/gradle","description":"Adaptable, fast automation for all","fork":false,"url":"https://api.github.com/repos/gradle/gradle","forks_url":"https://api.github.com/repos/gradle/gradle/forks","keys_url":"https://api.github.com/repos/gradle/gradle/keys{/key_id}","collaborators_url":"https://api.github.com/repos/gradle/gradle/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/gradle/gradle/teams","hooks_url":"https://api.github.com/repos/gradle/gradle/hooks","issue_events_url":"https://api.github.com/repos/gradle/gradle/issues/events{/number}","events_url":"https://api.github.com/repos/gradle/gradle/events","assignees_url":"https://api.github.com/repos/gradle/gradle/assignees{/user}","branches_url":"https://api.github.com/repos/gradle/gradle/branches{/branch}","tags_url":"https://api.github.com/repos/gradle/gradle/tags","blobs_url":"https://api.github.com/repos/gradle/gradle/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/gradle/gradle/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/gradle/gradle/git/refs{/sha}","trees_url":"https://api.github.com/repos/gradle/gradle/git/trees{/sha}","statuses_url":"https://api.github.com/repos/gradle/gradle/statuses/{sha}","languages_url":"https://api.github.com/repos/gradle/gradle/languages","stargazers_url":"https://api.github.com/repos/gradle/gradle/stargazers","contributors_url":"https://api.github.com/repos/gradle/gradle/contributors","subscribers_url":"https://api.github.com/repos/gradle/gradle/subscribers","subscription_url":"https://api.github.com/repos/gradle/gradle/subscription","commits_url":"https://api.github.com/repos/gradle/gradle/commits{/sha}","git_commits_url":"https://api.github.com/repos/gradle/gradle/git/commits{/sha}","comments_url":"https://api.github.com/repos/gradle/gradle/comments{/number}","issue_comment_url":"https://api.github.com/repos/gradle/gradle/issues/comments{/number}","contents_url":"https://api.github.com/repos/gradle/gradle/contents/{+path}","compare_url":"https://api.github.com/repos/gradle/gradle/compare/{base}...{head}","merges_url":"https://api.github.com/repos/gradle/gradle/merges","archive_url":"https://api.github.com/repos/gradle/gradle/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/gradle/gradle/downloads","issues_url":"https://api.github.com/repos/gradle/gradle/issues{/number}","pulls_url":"https://api.github.com/repos/gradle/gradle/pulls{/number}","milestones_url":"https://api.github.com/repos/gradle/gradle/milestones{/number}","notifications_url":"https://api.github.com/repos/gradle/gradle/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/gradle/gradle/labels{/name}","releases_url":"https://api.github.com/repos/gradle/gradle/releases{/id}","deployments_url":"https://api.github.com/repos/gradle/gradle/deployments","created_at":"2009-09-09T18:27:19Z","updated_at":"2018-02-26T08:11:48Z","pushed_at":"2018-02-26T12:00:05Z","git_url":"git://github.com/gradle/gradle.git","ssh_url":"git@github.com:gradle/gradle.git","clone_url":"https://github.com/gradle/gradle.git","svn_url":"https://github.com/gradle/gradle","homepage":"https://gradle.org","size":201828,"stargazers_count":6327,"watchers_count":6327,"language":"Java","has_issues":true,"has_projects":false,"has_downloads":false,"has_wiki":true,"has_pages":false,"forks_count":2064,"mirror_url":null,"archived":false,"open_issues_count":941,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0"},"forks":2064,"open_issues":941,"watchers":6327,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/gradle/gradle/pulls/4508"},"html":{"href":"https://github.com/gradle/gradle/pull/4508"},"issue":{"href":"https://api.github.com/repos/gradle/gradle/issues/4508"},"comments":{"href":"https://api.github.com/repos/gradle/gradle/issues/4508/comments"},"review_comments":{"href":"https://api.github.com/repos/gradle/gradle/pulls/4508/comments"},"review_comment":{"href":"https://api.github.com/repos/gradle/gradle/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/gradle/gradle/pulls/4508/commits"},"statuses":{"href":"https://api.github.com/repos/gradle/gradle/statuses/680b5036b569ef8fad05be6b4e8f848de8b80d55"}},"author_association":"OWNER"}}
{"actor":{"display_login":"wolfs"}}