Skip to content

Commit

Permalink
Merge pull request #52 from Project-Catcher/test-dj-db-connection
Browse files Browse the repository at this point in the history
test: 하트비트 추가
  • Loading branch information
pingu9 authored Dec 16, 2023
2 parents 73b5828 + d94f882 commit 7fc24d6
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import com.catcher.batch.datasource.CategoryJpaRepository;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
Expand All @@ -20,6 +21,7 @@ public class DBConnectionController {
private final CategoryJpaRepository categoryRepository;

@GetMapping
@Scheduled(fixedDelay = 180000L)
public String category() {
Category category = categoryRepository.findById(2L).orElse(null);

Expand Down

0 comments on commit 7fc24d6

Please sign in to comment.