Advertisement
Guest User

Untitled

a guest
Jul 18th, 2019
146
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.68 KB | None | 0 0
  1. @Configuration
  2. @EnableFilesystemStores
  3. public class AudioConfiguration {
  4.  
  5.     private static Path filesystemRoot() {
  6.         return Paths.get("src", "main", "java", "com", "example", "demo2", "sounds");
  7.     }
  8.  
  9.     @Bean
  10.     public FileSystemResourceLoader fsResourceLoader() throws Exception {
  11.         return new FileSystemResourceLoader(filesystemRoot().toAbsolutePath().toString());
  12.     }
  13.  
  14.     public static Path getPath() {
  15.         return filesystemRoot();
  16.     }
  17. }
  18.  
  19.  
  20. @StoreRestResource(path = "sounds")
  21. public interface SoundsContentStore extends Store<String> {
  22. }
  23. // .properties
  24. spring.servlet.multipart.max-file-size=200MB
  25. spring.servlet.multipart.max-request-size=215MB
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement