class NumberOfPartitionsSysCheck extends AbstractSysCheck {

    private static final int ID = 2;
    private static final String DESCRIPTION =
        "The total number of partitions of one or more partitioned tables should" +
        " not be greater than 1000. A large amount of shards can significantly reduce performance.";

    private static final int PARTITIONS_THRESHOLD = 1000;
    private final Schemas schemas;

    @Inject
    public NumberOfPartitionsSysCheck(Schemas schemas) {
        super(ID, DESCRIPTION, Severity.MEDIUM);
        this.schemas = schemas;
    }

    @Override
    public boolean isValid() {<FILL_FUNCTION_BODY>}

    boolean validateDocTablesPartitioning(SchemaInfo schemaInfo) {
        for (TableInfo tableInfo : schemaInfo.getTables()) {
            DocTableInfo docTableInfo = (DocTableInfo) tableInfo;
            if (docTableInfo.isPartitioned() && docTableInfo.partitions().size() > PARTITIONS_THRESHOLD) {
                return false;
            }
        }
        return true;
    }

}

        for (SchemaInfo schemaInfo : schemas) {
            if (schemaInfo instanceof DocSchemaInfo && !validateDocTablesPartitioning(schemaInfo)) {
                return false;
            }
        }
        return true;
    
<methods>public void <init>(int, java.lang.String, io.crate.expression.reference.sys.check.SysCheck.Severity) ,public CompletableFuture<?> computeResult() ,public java.lang.String description() ,public static java.lang.String getLinkedDescription(int, java.lang.String, java.lang.String) ,public int id() ,public abstract boolean isValid() ,public io.crate.expression.reference.sys.check.SysCheck.Severity severity() <variables>public static final java.lang.String CLUSTER_CHECK_LINK_PATTERN,private final non-sealed java.lang.String description,private final non-sealed int id,private final non-sealed io.crate.expression.reference.sys.check.SysCheck.Severity severity