A
A
Andrew_Rocket2020-01-27 21:13:32
Java
Andrew_Rocket, 2020-01-27 21:13:32

Java Spring Boot how to specify workspace for server?

I set up a workspace for the server, when I use Java methods, folders and files are created where necessary, but when I use spring methods, namely the MultipartFile class, it starts to climb into the pace and does not find a directory there.

java.io.IOException: java.io.FileNotFoundException: C:\TEMP\tomcat.13602058053278793214.8080\work\Tomcat\localhost\ROOT\upload\78580ddf-26c8-431e-9dee-f38aacc876a6.img_2049.png

How to set up a spring for a specific workspace?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
Sergey Gornostaev, 2020-01-28
@Andrew_Rocket

In the Boot configuration, you can specify

spring.http.multipart.location=путь_к_нужному_каталогу

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question