Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[style](fe)the last step of fe CheckStyle #10134

Merged
merged 10 commits into from
Jun 17, 2022
Prev Previous commit
Next Next commit
Merge branch 'upstream_master' into remove_some_rules
  • Loading branch information
morrySnow committed Jun 16, 2022
commit bec09ae9f4e832866041de4eb70254197a0f8623
2 changes: 2 additions & 0 deletions fe/check/checkstyle/suppressions.xml
Original file line number Diff line number Diff line change
Expand Up @@ -54,4 +54,6 @@ under the License.
<suppress files="org[\\/]apache[\\/]doris[\\/]load[\\/]loadv2[\\/]dpp[\\/]SparkRDDAggregator\.java" checks="OneTopLevelClass" />
<suppress files="org[\\/]apache[\\/]doris[\\/]catalog[\\/]FunctionSet\.java" checks="LineLength" />
<suppress files="org[\\/]apache[\\/]doris[\\/]common[\\/]ErrorCode\.java" checks="LineLength" />
<suppress files="org[\\/]apache[\\/]doris[\\/]udf[\\/]UdafExecutor\.java" checks="NoFinalizer" />
<suppress files="org[\\/]apache[\\/]doris[\\/]udf[\\/]UdfExecutor\.java" checks="NoFinalizer" />
</suppressions>
Original file line number Diff line number Diff line change
Expand Up @@ -64,16 +64,15 @@
import java.net.URLClassLoader;
import java.security.MessageDigest;
import java.security.NoSuchAlgorithmException;
import java.util.HashMap;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.Set;

// create a user define function
public class CreateFunctionStmt extends DdlStmt {
private static final Logger LOG = LogManager.getLogger(CreateFunctionStmt.class);
@Deprecated
public static final String OBJECT_FILE_KEY = "object_file";
public static final String FILE_KEY = "file";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,6 @@
package org.apache.doris.analysis;

import org.apache.doris.catalog.Catalog;
import org.apache.doris.catalog.Column;
import org.apache.doris.catalog.ScalarType;
import org.apache.doris.common.ErrorCode;
import org.apache.doris.common.ErrorReport;
import org.apache.doris.common.UserException;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -284,8 +284,9 @@ public void completeSchedCtx(TabletSchedCtx tabletCtx,
continue;
}

if (!Config.be_rebalancer_fuzzy_test && !clusterStat.isMoreBalanced(tabletCtx.getSrcBackendId(), beStat.getBeId(),
tabletCtx.getTabletId(), tabletCtx.getTabletSize(), tabletCtx.getStorageMedium())) {
if (!Config.be_rebalancer_fuzzy_test && !clusterStat.isMoreBalanced(
tabletCtx.getSrcBackendId(), beStat.getBeId(), tabletCtx.getTabletId(),
tabletCtx.getTabletSize(), tabletCtx.getStorageMedium())) {
continue;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -175,8 +175,8 @@ private void classifyBackendByLoad(TStorageMedium medium) {
continue;
}

if (Math.abs(beStat.getLoadScore(medium) - avgLoadScore) / avgLoadScore
> Config.balance_load_score_threshold) {

if (Config.be_rebalancer_fuzzy_test) {
if (beStat.getLoadScore(medium) > avgLoadScore) {
beStat.setClazz(medium, Classification.HIGH);
highCounter++;
Expand Down
6 changes: 3 additions & 3 deletions fe/fe-core/src/main/java/org/apache/doris/common/Config.java
Original file line number Diff line number Diff line change
Expand Up @@ -1655,13 +1655,13 @@ public class Config extends ConfigBase {
public static boolean enable_multi_catalog = false; // 1 min

/**
* If set to TRUE, FE will:
* If set to TRUE, FE will:
* 1. divide BE into high load and low load(no mid load) to force triggering tablet scheduling;
* 2. ignore whether the cluster can be more balanced during tablet scheduling;
*
* It's used to test the reliability in single replica case when tablet scheduling are frequent.
* It's used to test the reliability in single replica case when tablet scheduling are frequent.
* Default is false.
*/
*/
@ConfField(mutable = false, masterOnly = true)
public static boolean be_rebalancer_fuzzy_test = false;
}
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
import org.apache.doris.nereids.operators.OperatorType;
import org.apache.doris.nereids.operators.plans.JoinType;
import org.apache.doris.nereids.trees.expressions.Expression;
import org.apache.doris.nereids.trees.plans.Plan;

import java.util.Objects;
import java.util.Optional;
Expand Down
2 changes: 2 additions & 0 deletions fe/fe-core/src/main/java/org/apache/doris/task/CloneTask.java
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,8 @@ public String toString() {
sb.append(", visible version(hash): ").append(visibleVersion);
sb.append(", src backend: ").append(srcBackends.get(0).getHost())
.append(", src path hash: ").append(srcPathHash);
sb.append(", src backend: ").append(srcBackends.get(0).getHost()).append(", src path hash: ")
.append(srcPathHash);
sb.append(", dest backend: ").append(backendId).append(", dest path hash: ").append(destPathHash);
return sb.toString();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -206,13 +206,11 @@ public UdfExecutor(byte[] thriftParams) throws Exception {
init(jarFile, className, retType, parameterTypes);
}

// CHECKSTYLE OFF
@Override
protected void finalize() throws Throwable {
close();
super.finalize();
}
// CHECKSTYLE ON

/**
* Close the class loader we may have created.
Expand Down
You are viewing a condensed version of this merge commit. You can view the full changes here.