Skip to content

Fix incorrect error message template of Preconditions.check* #642

@dbw9580

Description

@dbw9580

Preconditions.checkArgument and friends take an optional message template that can have format specifier %s only. Any other format specifiers like %d are not recognized and output as is. See guava doc: https://guava.dev/releases/31.1-jre/api/docs/com/google/common/base/Preconditions.html

There are several places across the code base that are using %d etc., in the error message template, e.g.

https://github.com/Alluxio/alluxio/blob/6982d6c759e7180c9b1ae00ea7e6c5229765ff2e/core/server/worker/src/main/java/alluxio/worker/block/UfsInputStreamCache.java#L278

Find across the code base such occurrences and fix them.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions