This is an automated email from the ASF dual-hosted git repository.
morningman pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/doris.git
The following commit(s) were added to refs/heads/master by this push:
new e62286d44c [minor](fe) ignore expired alter job when replay, to save
memory (#18508)
e62286d44c is described below
commit e62286d44c25e15dd888767d0e6875e294637b81
Author: Mingyu Chen <[email protected]>
AuthorDate: Mon Apr 10 18:37:27 2023 +0800
[minor](fe) ignore expired alter job when replay, to save memory (#18508)
Skip expired alter job when replay
---
fe/fe-core/src/main/java/org/apache/doris/catalog/Env.java | 4 ++++
regression-test/suites/query_p2/system/test_query_sys_tables.groovy | 4 ++--
2 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/fe/fe-core/src/main/java/org/apache/doris/catalog/Env.java
b/fe/fe-core/src/main/java/org/apache/doris/catalog/Env.java
index d1bea53bc1..9ac1027efc 100755
--- a/fe/fe-core/src/main/java/org/apache/doris/catalog/Env.java
+++ b/fe/fe-core/src/main/java/org/apache/doris/catalog/Env.java
@@ -1795,6 +1795,10 @@ public class Env {
newChecksum ^= size;
for (int i = 0; i < size; i++) {
AlterJobV2 alterJobV2 = AlterJobV2.read(dis);
+ if (alterJobV2.isExpire()) {
+ LOG.info("alter job {} is expired, type: {}, ignore it",
alterJobV2.getJobId(), alterJobV2.getType());
+ continue;
+ }
if (type == JobType.ROLLUP || type == JobType.SCHEMA_CHANGE) {
if (type == JobType.ROLLUP) {
this.getMaterializedViewHandler().addAlterJobV2(alterJobV2);
diff --git
a/regression-test/suites/query_p2/system/test_query_sys_tables.groovy
b/regression-test/suites/query_p2/system/test_query_sys_tables.groovy
index 58d77a297a..fd82529b41 100644
--- a/regression-test/suites/query_p2/system/test_query_sys_tables.groovy
+++ b/regression-test/suites/query_p2/system/test_query_sys_tables.groovy
@@ -87,6 +87,6 @@ suite("test_query_sys_tables_p2", "p2") {
for (int i = 1; i <= 10; i++) {
def dbName = dbPrefix + i.toString()
- sql "DROP DATABASE `${dbName}`"
+ sql "DROP DATABASE IF EXISTS `${dbName}` FORCE"
}
-}
\ No newline at end of file
+}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]