Skip to content

Commit b4e6fbf

Browse files
committed
Upgrade to Gradle 9.0 and Java21.
1 parent 882fae0 commit b4e6fbf

File tree

3 files changed

+5
-71
lines changed

3 files changed

+5
-71
lines changed

config/checkstyle/checkstyle.xml

Lines changed: 1 addition & 63 deletions
Original file line numberDiff line numberDiff line change
@@ -215,69 +215,7 @@ by Joshua Bloch in his book Effective Java -->
215215
-->
216216
</module>
217217
<!--
218-
WHITESPACE CHECKS
218+
Whitespace checks are disabled because they conflict with GoogleJavaFormat.
219219
-->
220-
<!-- FORK: Whitespace enforcement is handled by other tools in google3, but we need this policy
221-
to enforce consistency in GoB. -->
222-
<module name="Indentation">
223-
<property name="basicOffset" value="2"/>
224-
<property name="braceAdjustment" value="0"/>
225-
<property name="caseIndent" value="2"/>
226-
<property name="throwsIndent" value="4"/>
227-
<property name="lineWrappingIndentation" value="4"/>
228-
<property name="arrayInitIndent" value="2"/>
229-
</module>
230-
<!-- ENDFORK -->
231-
<module name="WhitespaceAround">
232-
<!-- Checks that various tokens are surrounded by whitespace.
233-
This includes most binary operators and keywords followed
234-
by regular or curly braces.
235-
-->
236-
<property name="tokens" value="ASSIGN, BAND, BAND_ASSIGN, BOR,
237-
BOR_ASSIGN, BSR, BSR_ASSIGN, BXOR, BXOR_ASSIGN, COLON, DIV, DIV_ASSIGN,
238-
EQUAL, GE, GT, LAND, LE, LITERAL_CATCH, LITERAL_DO, LITERAL_ELSE,
239-
LITERAL_FINALLY, LITERAL_FOR, LITERAL_IF, LITERAL_RETURN,
240-
LITERAL_SYNCHRONIZED, LITERAL_TRY, LITERAL_WHILE, LOR, LT, MINUS,
241-
MINUS_ASSIGN, MOD, MOD_ASSIGN, NOT_EQUAL, PLUS, PLUS_ASSIGN, QUESTION,
242-
SL, SL_ASSIGN, SR_ASSIGN, STAR, STAR_ASSIGN"/>
243-
<property name="severity" value="error"/>
244-
<property name="ignoreEnhancedForColon" value="false"/>
245-
</module>
246-
<module name="WhitespaceAfter">
247-
<!-- Checks that commas, semicolons and typecasts are followed by
248-
whitespace.
249-
-->
250-
<property name="tokens" value="COMMA, SEMI, TYPECAST"/>
251-
</module>
252-
<module name="NoWhitespaceAfter">
253-
<!-- Checks that there is no whitespace after various unary operators.
254-
Linebreaks are allowed.
255-
-->
256-
<property name="tokens" value="BNOT, DEC, DOT, INC, LNOT, UNARY_MINUS,
257-
UNARY_PLUS"/>
258-
<property name="allowLineBreaks" value="true"/>
259-
<property name="severity" value="error"/>
260-
</module>
261-
<module name="NoWhitespaceBefore">
262-
<!-- Checks that there is no whitespace before various unary operators.
263-
Linebreaks are allowed.
264-
-->
265-
<property name="tokens" value="SEMI, DOT, POST_DEC, POST_INC"/>
266-
<property name="allowLineBreaks" value="true"/>
267-
<property name="severity" value="error"/>
268-
</module>
269-
<module name="ParenPad">
270-
<!-- Checks that there is no whitespace before close parens or after
271-
open parens. Allows whitespace after open parens if it is followed
272-
by the end of a line or by the start of a comment. Allows whitespace
273-
before close parens if it is preceeded by the start of a line or by
274-
the end of a block comment.
275-
-->
276-
<metadata name="altname" value="ParenPad"/>
277-
<!-- FORK: This property isn't supported by the open-source implementation. -->
278-
<!-- <property name="ignoreComments" value="true"/> -->
279-
<!-- ENDFORK -->
280-
<property name="severity" value="warning"/>
281-
</module>
282220
</module>
283221
</module>
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-7.4.2-bin.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-9.0-bin.zip
44
zipStoreBase=GRADLE_USER_HOME
55
zipStorePath=wrapper/dists

lib/build.gradle

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,16 +14,12 @@
1414

1515
plugins {
1616
id 'java-library'
17-
// TODO upgrade this to https://plugins.gradle.org/plugin/com.gradleup.shadow
18-
id 'com.github.johnrengelman.shadow' version '7.1.2'
17+
id("com.gradleup.shadow") version "9.2.1"
1918
id 'com.github.sherter.google-java-format' version '0.9'
2019
id 'checkstyle'
2120
id 'maven-publish'
2221
id 'signing'
23-
24-
// v"2.2.5" is recommended, but it uses Java21 which is incompatible with other
25-
// plugins (e.g. "com.github.johnrengelman.shadow"), therefore, using latest compatible version
26-
id("com.google.cloud.artifactregistry.gradle-plugin") version "2.1.5"
22+
id("com.google.cloud.artifactregistry.gradle-plugin") version "2.2.5"
2723
}
2824

2925
googleJavaFormat {
@@ -149,7 +145,7 @@ java {
149145
publishing {
150146
publications {
151147
mavenJava(MavenPublication) {
152-
version = '1.1.0'
148+
version = '1.1.1'
153149
group = 'com.google.cloud.datalineage'
154150
artifactId = 'producerclient'
155151

0 commit comments

Comments
 (0)