Skip to content

Commit 8686891

Browse files
authored
Bump version of develocity-agent-adapters and prepare for release (gradle#376)
* Bump to develocity-agent-adapters v1.2 * Fix and extend CustomDevelocityConfig examples
1 parent 6590f9d commit 8686891

File tree

4 files changed

+31
-8
lines changed

4 files changed

+31
-8
lines changed

Diff for: build.gradle.kts

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ repositories {
2020
}
2121

2222
dependencies {
23-
implementation("com.gradle:develocity-gradle-plugin-adapters:1.1")
23+
implementation("com.gradle:develocity-gradle-plugin-adapters:1.2")
2424

2525
testImplementation(platform("org.junit:junit-bom:5.12.1"))
2626
testImplementation("org.junit.jupiter:junit-jupiter")

Diff for: release/changes.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
- [NEW] TBD
1+
- [FIX] Use latest release of develocity-agent-adapters. This addresses classloader issues with DV injection.

Diff for: release/version.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2.1.1
1+
2.2

Diff for: src/main/java/com/gradle/CustomDevelocityConfig.java

+28-5
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ void configureDevelocity(DevelocityAdapter develocity) {
1616
develocity.setServer("https://enterprise-samples.gradle.com");
1717
develocity.setAllowUntrustedServer(false);
1818
19+
develocity.setProjectId("ccud-injection");
1920
*/
2021
}
2122

@@ -25,15 +26,37 @@ void configureBuildScanPublishing(BuildScanAdapter buildScan) {
2526
boolean isCiServer = System.getenv().containsKey("CI");
2627
2728
buildScan.publishAlways();
28-
buildScan.capture(capture -> capture.setTaskInputFiles(true));
2929
buildScan.setUploadInBackground(!isCiServer);
3030
31-
*/
31+
buildScan.tag("CUSTOM_TAG");
32+
buildScan.link("custom-link", "https://enterprise-samples.gradle.com/faq");
33+
buildScan.value("Custom Value Key", "Custom value");
34+
35+
buildScan.capture(capture -> {
36+
capture.setFileFingerprints(true);
37+
capture.setBuildLogging(false);
38+
capture.setTestLogging(false);
39+
});
40+
41+
buildScan.obfuscation(obfuscation -> {
42+
obfuscation.hostname(s -> "FIXED-HOSTNAME");
43+
obfuscation.username(s -> "FIXED-USERNAME");
44+
});
45+
46+
buildScan.background(adapter -> {
47+
adapter.tag("BACKGROUND_TAG");
48+
});
49+
50+
buildScan.buildFinished(adapter -> {
51+
buildScan.tag("BUILD_FINISHED_TAG");
52+
});
53+
54+
*/
3255
}
3356

3457
void configureBuildCache(BuildCacheConfigurationAdapter buildCache) {
35-
3658
/* Example of build cache configuration
59+
3760
boolean isCiServer = System.getenv().containsKey("CI");
3861
3962
// Enable the local build cache for all local and CI builds
@@ -43,9 +66,9 @@ void configureBuildCache(BuildCacheConfigurationAdapter buildCache) {
4366
// Only permit store operations to the remote build cache for CI builds
4467
// Local builds will only read from the remote build cache
4568
buildCache.getRemote().setEnabled(true);
46-
buildCache.getRemote().setStoreEnabled(isCiServer);
69+
buildCache.getRemote().setPush(isCiServer);
4770
48-
*/
71+
*/
4972
}
5073

5174
}

0 commit comments

Comments
 (0)