Skip to content

Commit

Permalink
Fix: 레디스 설정
Browse files Browse the repository at this point in the history
  • Loading branch information
flowerdonk authored and ah9mon committed Aug 8, 2023
1 parent 72b5546 commit 4dc6bba
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 13 deletions.
12 changes: 0 additions & 12 deletions src/main/java/com/anywayclear/config/RedisConfig.java
Original file line number Diff line number Diff line change
@@ -1,18 +1,11 @@
package com.anywayclear.config;

import com.anywayclear.entity.Alarm;
import com.anywayclear.service.RedisSubscribeService;
import io.lettuce.core.pubsub.StatefulRedisPubSubConnection;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.data.redis.connection.AbstractRedisConnection;
import org.springframework.data.redis.connection.MessageListener;
import org.springframework.data.redis.connection.RedisConnection;
import org.springframework.data.redis.connection.RedisConnectionFactory;
import org.springframework.data.redis.connection.lettuce.LettuceConnectionFactory;
import org.springframework.data.redis.connection.lettuce.LettuceConnectionProvider;
import org.springframework.data.redis.connection.lettuce.LettuceSubscription;
import org.springframework.data.redis.core.RedisTemplate;
import org.springframework.data.redis.listener.RedisMessageListenerContainer;
import org.springframework.data.redis.listener.adapter.MessageListenerAdapter;
Expand All @@ -39,11 +32,6 @@ public RedisConnectionFactory redisConnectionFactory() {
return new LettuceConnectionFactory(host, port);
}

// @Bean
// public LettuceSubscription lettuceSubscription() {
// return new LettuceSubscription(MessageListener listener, StatefulRedisPubSubConnection<byte[], byte[]> pubsubConnection, LettuceConnectionProvider connectionProvider);
//
// }
/*
* [RedisTemplate bean]
* RedisTemplate: java Object를 redis에 저장하는 경우 사용
Expand Down
1 change: 0 additions & 1 deletion src/main/java/com/anywayclear/config/SecurityConfig.java
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@ public SecurityFilterChain securityFilterChain(HttpSecurity httpSecurity) throws
httpSecurity
.authorizeHttpRequests(authorize -> authorize
.antMatchers(HttpMethod.OPTIONS).permitAll() // OPTIONS 메서드는 모두 허용
.antMatchers("/api/alarms/**").authenticated()
.anyRequest().permitAll() // 모든 요청 권한 허용 (추후 권한 설정해야함)
);

Expand Down

0 comments on commit 4dc6bba

Please sign in to comment.