Problems encountered in RestTemplate request upload API

the project uses the API of RestTemplate to request other projects. When requesting the upload interface, you need to do
FileSystemResource resource = new FileSystemResource (new File (filePath)); convert the file to FileSystemResource. Now my file is down from the server, that is, the InputStream type. How to deal with this.
what I can think of right now is to download it to the disk of the project server, read the request, and then delete it. (disadvantage: may cause more and more junk files on the server, because deletion may fail)-sharp-sharp-sharp problem description

the environmental background of the problems and what methods you have tried

related codes

/ / Please paste the code text below (do not replace the code with pictures)

what result do you expect? What is the error message actually seen?

May.17,2022

try InputStreamResource or ByteArrayResource as the parameter of formdata

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e48a78-652e9.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e48a78-652e9.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?