FANNG1 commented on code in PR #11071:
URL: https://github.com/apache/gravitino/pull/11071#discussion_r3278379038


##########
flink-connector/v1.20/flink/build.gradle.kts:
##########
@@ -0,0 +1,207 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *  http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+import org.gradle.api.tasks.SourceSetContainer
+
+plugins {
+  `maven-publish`
+  id("java")
+  id("idea")
+}
+
+repositories {
+  mavenCentral()
+}
+
+val commonProject = project(":flink-connector:flink-common")
+val commonSourceSets = commonProject.extensions.getByType<SourceSetContainer>()
+val commonTestOutput = commonSourceSets.named("test").get().output
+val flinkVersion: String = libs.versions.flink20.get()

Review Comment:
   Fixed in ff82056ce. The Flink 1.20 connector module now uses 
`libs.versions.flink120`, `iceberg4flink120`, `paimon4flink120`, and 
`libs.flinkjdbc120`.



##########
flink-connector/v1.20/flink-runtime/build.gradle.kts:
##########
@@ -0,0 +1,90 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *  http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar
+
+plugins {
+  `maven-publish`
+  id("java")
+  id("idea")
+  alias(libs.plugins.shadow)
+}
+
+repositories {
+  mavenCentral()
+}
+
+val flinkVersion: String = libs.versions.flink20.get()

Review Comment:
   Fixed in ff82056ce. Renamed the new Flink 1.19/1.20 version catalog aliases 
to the explicit `119`/`120` form, including `flink120`, `flinkjdbc120`, 
`iceberg4flink120`, and `paimon4flink120`.



##########
flink-connector/v1.19/flink/build.gradle.kts:
##########
@@ -0,0 +1,207 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *  http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+import org.gradle.api.tasks.SourceSetContainer
+
+plugins {
+  `maven-publish`
+  id("java")
+  id("idea")
+}
+
+repositories {
+  mavenCentral()
+}
+
+val commonProject = project(":flink-connector:flink-common")
+val commonSourceSets = commonProject.extensions.getByType<SourceSetContainer>()
+val commonTestOutput = commonSourceSets.named("test").get().output
+val flinkVersion: String = libs.versions.flink19.get()
+val flinkMajorVersion: String = flinkVersion.substringBeforeLast(".")
+val icebergVersion: String = libs.versions.iceberg4flink19.get()
+val paimonVersion: String = libs.versions.paimon4flink19.get()
+val scalaVersion: String = "2.12"
+val artifactName = 
"${rootProject.name}-flink-${flinkMajorVersion}_$scalaVersion"
+
+dependencies {
+  implementation(commonProject)
+
+  compileOnly(project(":clients:client-java-runtime", configuration = 
"shadow"))
+  
compileOnly("org.apache.iceberg:iceberg-flink-runtime-$flinkMajorVersion:$icebergVersion")
+  
compileOnly("org.apache.flink:flink-connector-hive_$scalaVersion:$flinkVersion")
+  compileOnly("org.apache.flink:flink-table-common:$flinkVersion")
+  compileOnly("org.apache.flink:flink-table-api-java:$flinkVersion")
+  
compileOnly("org.apache.paimon:paimon-flink-$flinkMajorVersion:$paimonVersion")
+  compileOnly(libs.flinkjdbc19)
+  compileOnly(libs.hive2.common) {
+    exclude("org.eclipse.jetty.aggregate", "jetty-all")
+    exclude("org.eclipse.jetty.orbit", "javax.servlet")
+  }
+
+  testImplementation(project(":api"))
+  testImplementation(project(":catalogs:catalog-jdbc-common")) {
+    exclude("org.apache.logging.log4j")
+  }
+  testImplementation(project(":clients:client-java"))
+  testImplementation(project(":core"))
+  testImplementation(project(":common"))
+  testImplementation(project(":integration-test-common", "testArtifacts"))
+  testImplementation(project(":server"))
+  testImplementation(project(":server-common"))
+  testImplementation(project(":flink-connector:flink-common", "testArtifacts"))
+  testImplementation(libs.awaitility)
+  testImplementation(libs.junit.jupiter.api)
+  testImplementation(libs.junit.jupiter.params)

Review Comment:
   Fixed in ff82056ce. I sorted the local project test dependencies and the 
version-catalog test dependencies consistently in both the Flink 1.19 and 1.20 
module Gradle files.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to