Skip to content

Commit

Permalink
✨ feat: 레디스 연결
Browse files Browse the repository at this point in the history
  • Loading branch information
xxoznge committed May 26, 2024
1 parent ca6c8a5 commit 7c2a0b7
Show file tree
Hide file tree
Showing 10 changed files with 75 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
package com.ddabong.ddabongdotchiBE.domain.blacklist.controller;

public class BlacklistController {
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
package com.ddabong.ddabongdotchiBE.domain.blacklist.dto.request;

public record BlacklistCreateRequest() {
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
package com.ddabong.ddabongdotchiBE.domain.blacklist.dto.response;

public record BlacklistCreateResponse() {
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
package com.ddabong.ddabongdotchiBE.domain.blacklist.entity;

import jakarta.persistence.Column;
import jakarta.persistence.Entity;
import jakarta.persistence.GeneratedValue;
import jakarta.persistence.GenerationType;
import jakarta.persistence.Id;
import jakarta.persistence.Table;
import lombok.AccessLevel;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Getter;
import lombok.NoArgsConstructor;

@Builder
@NoArgsConstructor(access = AccessLevel.PROTECTED)
@AllArgsConstructor(access = AccessLevel.PRIVATE)
@Getter
@Entity
@Table(name = "blacklist")
public class Blacklist {

@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
@Column(name = "blacklist_id")
private Long id;

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
package com.ddabong.ddabongdotchiBE.domain.blacklist.exception;

public enum BlacklistErrorCode {
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
package com.ddabong.ddabongdotchiBE.domain.blacklist.exception;

import com.ddabong.ddabongdotchiBE.domain.global.BaseErrorCode;
import com.ddabong.ddabongdotchiBE.domain.global.CustomException;

public class BlacklistExceptionHandler extends CustomException {
public BlacklistExceptionHandler(BaseErrorCode code) {
super(code);
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
package com.ddabong.ddabongdotchiBE.domain.blacklist.repository;

import java.util.Optional;

import org.springframework.data.jpa.repository.JpaRepository;

import com.ddabong.ddabongdotchiBE.domain.blacklist.entity.Blacklist;

public interface BlacklistRepository extends JpaRepository<Blacklist, Long> {
Optional<Blacklist> findById(Long Id);
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
package com.ddabong.ddabongdotchiBE.domain.blacklist.service;

public class BlacklistQueryService {
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
package com.ddabong.ddabongdotchiBE.domain.blacklist.service;

public class BlacklistService {
}
4 changes: 2 additions & 2 deletions src/main/resources/application-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,5 @@ jwt:
refresh-expiration-time: 86400000

redis:
host: localhost
port: 6379
host: ${REDIS_HOSTNAME}
port: ${REDIS_PORT}

0 comments on commit 7c2a0b7

Please sign in to comment.