pan3793 commented on code in PR #7029:
URL: https://github.com/apache/kyuubi/pull/7029#discussion_r2054547506


##########
kyuubi-server/src/main/scala/org/apache/kyuubi/server/metadata/jdbc/JDBCMetadataStore.scala:
##########
@@ -419,6 +419,129 @@ class JDBCMetadataStore(conf: KyuubiConf) extends 
MetadataStore with Logging {
     }
   }
 
+  private def insertKubernetesMetadata(metadata: KubernetesMetadata): Unit = {
+    val insertQuery =
+      s"""
+         |INSERT INTO $KUBERNETES_METADATA_TABLE(
+         |identifier,
+         |context,
+         |namespace,
+         |pod_name,
+         |app_id,
+         |app_name,
+         |app_state,
+         |app_error,
+         |create_time,
+         |update_time
+         |)
+         |SELECT ?, ?, ?, ?, ?, ?, ?, ?, ?, ?
+         |WHERE NOT EXISTS (
+         |  SELECT 1 FROM $KUBERNETES_METADATA_TABLE WHERE identifier = ?

Review Comment:
   BTW, do we need to consider the concurrency issue for the UPDATE case?



-- 
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: notifications-unsubscr...@kyuubi.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscr...@kyuubi.apache.org
For additional commands, e-mail: notifications-h...@kyuubi.apache.org

Reply via email to