File tree Expand file tree Collapse file tree
src/main/java/com/back/web7_9_codecrete_be/global/storage Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ package com .back .web7_9_codecrete_be .global .storage ;
2+
3+ import org .springframework .web .multipart .MultipartFile ;
4+
5+ public interface FileStorageService {
6+ //임시 구현
7+ String upload (MultipartFile file );
8+ }
Original file line number Diff line number Diff line change 1+ package com .back .web7_9_codecrete_be .global .storage ;
2+
3+ import org .springframework .stereotype .Service ;
4+ import org .springframework .web .multipart .MultipartFile ;
5+
6+ import java .util .UUID ;
7+
8+ @ Service
9+ public class S3FileStorageService implements FileStorageService {
10+ @ Override
11+ public String upload (MultipartFile file ) {
12+
13+ // 임시 URL 생성
14+ String fakeFileName = UUID .randomUUID () + "_" + file .getOriginalFilename ();
15+
16+ return "https://dummy-cdn.codecrete.com/profile/" + fakeFileName ;
17+ }
18+ }
You can’t perform that action at this time.
0 commit comments