yuqi1129 commented on code in PR #12994:
URL: https://github.com/apache/gravitino/pull/12994#discussion_r3965825167
##########
core/src/main/java/org/apache/gravitino/storage/relational/mapper/provider/base/JobTemplateMetaBaseSQLProvider.java:
##########
@@ -137,10 +123,7 @@ public String updateJobTemplateMeta(
+ " last_version = #{newJobTemplateMeta.lastVersion},"
+ " deleted_at = #{newJobTemplateMeta.deletedAt}"
+ " WHERE job_template_id = #{oldJobTemplateMeta.jobTemplateId}"
- + " AND job_template_name = #{oldJobTemplateMeta.jobTemplateName}"
- + " AND metalake_id = #{oldJobTemplateMeta.metalakeId}"
+ " AND current_version = #{oldJobTemplateMeta.currentVersion}"
Review Comment:
Yes, this is intentional. The current job template create path uses
overwrite=false, so it cannot reuse a deleted template ID this way. This PR
keeps the existing overwrite behavior. If we add overwrite support to this path
later, we should also add a check to prevent ID reuse. Thanks for pointing this
out.
--
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]