-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
69 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
package mvc.promiseme.common; | ||
|
||
import lombok.AllArgsConstructor; | ||
import lombok.Getter; | ||
import lombok.NoArgsConstructor; | ||
import org.springframework.beans.factory.annotation.Value; | ||
import org.springframework.stereotype.Component; | ||
|
||
@Component | ||
@Getter | ||
@AllArgsConstructor | ||
@NoArgsConstructor | ||
public class NaverKey { | ||
|
||
@Value("${ACCESS_KEY_ID}") | ||
private String accessKey; | ||
@Value("${KEY}") | ||
private String key; | ||
} |
6 changes: 6 additions & 0 deletions
6
src/main/java/mvc/promiseme/meeting/service/MeetingService.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
package mvc.promiseme.meeting.service; | ||
|
||
import org.springframework.web.multipart.MultipartFile; | ||
|
||
public interface MeetingService { | ||
} |
16 changes: 16 additions & 0 deletions
16
src/main/java/mvc/promiseme/meeting/service/MeetingServiceImpl.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
package mvc.promiseme.meeting.service; | ||
|
||
import lombok.RequiredArgsConstructor; | ||
import mvc.promiseme.common.NaverKey; | ||
import org.springframework.beans.factory.annotation.Autowired; | ||
import org.springframework.stereotype.Service; | ||
import org.springframework.transaction.annotation.Transactional; | ||
import org.springframework.web.multipart.MultipartFile; | ||
|
||
@Service | ||
@RequiredArgsConstructor | ||
@Transactional | ||
public class MeetingServiceImpl implements MeetingService { | ||
|
||
private final NaverKey naverKey; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
spring.config.import=db-application.properties | ||
spring.config.import=db-application.properties | ||
spring.profiles.include=api-key |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
package mvc.promiseme.common; | ||
|
||
import org.junit.jupiter.api.Test; | ||
import org.springframework.beans.factory.annotation.Autowired; | ||
import org.springframework.boot.test.context.SpringBootTest; | ||
|
||
import static org.junit.jupiter.api.Assertions.assertNotNull; | ||
|
||
@SpringBootTest | ||
public class ApiTest { | ||
|
||
@Autowired | ||
private NaverKey naverKey; | ||
|
||
@Test | ||
public void testNaverKeyValues() { | ||
assertNotNull(naverKey, "NaverKey instance should not be null"); | ||
|
||
System.out.println(naverKey.getAccessKey()); | ||
System.out.println(naverKey.getKey()); | ||
} | ||
} |