@PostMapping(path = "/upload", consumes = MediaType.MULTIPART_FORM_DATA_VALUE)
    public String downloadFile(@RequestPart("file") final FilePart filePart) throws IOException {
        LOGGER.info("file name: {}", filePart.filename());
        Path tempFile = Files.createTempFile(String.valueOf(System.currentTimeMillis()), filePart.filename());
        filePart.transferTo(tempFile.toFile());
        try (BufferedReader bufferedReader = new BufferedReader(new FileReader(tempFile.toFile()))) {
            String line = bufferedReader.readLine();
            while (Objects.nonNull(line)) {
                LOGGER.info(line);
                line = bufferedReader.readLine();
            }
        }
        return "OK";
    }
upload file and print.

@param filePart upload file
@return OK
@throws IOException io exception
shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/controller/HttpTestController.java