public static String concatPaths(String prefix, @Nullable String path) {
        requireNonNull(prefix, "prefix");
        checkArgument(!prefix.isEmpty() && prefix.charAt(0) == '/',
                      "prefix: %s (expected: an absolute path starting with '/')", prefix);

        path = firstNonNull(path, "");
        if (path.isEmpty()) {
            return prefix;
        }

        if (prefix.length() == 1) { // means "/".equals(prefix)
            if (path.charAt(0) == '/') {
                return path; // Most requests will land here.
            }
            return simpleConcat("/", path);
        }

        return slowConcatPaths(prefix, path);
    }
Concatenates the specified {@code prefix} and {@code path} into an absolute path.

@throws IllegalArgumentException if {@code prefix} is not an absolute path prefix
core/src/main/java/com/linecorp/armeria/internal/common/ArmeriaHttpUtil.java