3

请教一下腾讯云流下载慢的问题?这个是为啥

 3 years ago
source link: https://www.v2ex.com/t/802334
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

V2EX  ›  Java

请教一下腾讯云流下载慢的问题?这个是为啥

  auto · 2 小时 29 分钟前 · 78 次点击

代码如下:文件存储在腾讯云上。

    @GetMapping("/test")
    public void test(@RequestParam(value = "path") String path, HttpServletResponse response) {
        try(InputStream inputStream = fileService.download(path)) {
            IOUtils.copy(inputStream, response.getOutputStream());
        } catch (IOException e) {
            log.error("异常", e);
        }
    }

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK