일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | |||
5 | 6 | 7 | 8 | 9 | 10 | 11 |
12 | 13 | 14 | 15 | 16 | 17 | 18 |
19 | 20 | 21 | 22 | 23 | 24 | 25 |
26 | 27 | 28 | 29 | 30 | 31 |
- aws
- Java 1.8
- mockito에러
- java 11
- springboottest spybean
- java version
- Only void methods can doNothing()
- easy
- yum install java
- java 1.8 11
- java 버전 변경
- mockito테스트
- parse
- No tests found for given includes
- OpenFeign
- log error
- java 여러개 버전
- JUnit
- error
- ssl프로토콜
- springboottest
- LeetCode
- 스프링부트테스트
- ssl이란?
- AWS CLI
- Medium
- java
- tls프로토콜확인
- springboot
- ssl프로토콜확인
- Today
- Total
목록분류 전체보기 (112)
쩨이엠 개발 블로그
RestTemplate 을 대신하여 OpenFeign을 적용해보기로 했다 1. Gradle 적용 plugins { id 'java' id 'org.springframework.boot' version '3.0.6' id 'io.spring.dependency-management' version '1.1.0' } ... dependencies { ... // OpenFeign implementation 'org.springframework.cloud:spring-cloud-starter-openfeign:4.0.3' } ext { set('springCloudVersion', "2022.0.3") } dependencyManagement { imports { mavenBom "org.springframew..
1. 현상 OpenFeign을 사용하기 위해 dependency들을 추가했다 dependencies { ... implementation 'org.springframework.cloud:spring-cloud-starter-openfeign' } dependencyManagement { imports { mavenBom "org.springframework.cloud:spring-cloud-dependencies:2020.0.3" } } 그리고 빌드했더니 빌드 실패가 뜨면서 이런 에러가 보였다 > Could not resolve all files for configuration ':compileClasspath'. > Could not find org.springframework.cloud:spring-..
i18n 의 messages.properties를 사용하는데 한글이 깨져나올때 해결 방법! 1. Preferences > Editor > File Encordings 에 들어간다 이 때 Default encoding for properties files 밑에 Transparent native-to-ascii conversion을 체크해주면! 왼쪽처럼 깨져보였던 한글이 잘 보이는것을 확인할 수 있다 체크를 했는데도 안된다면 Default encording이 UTF-8인지 확인해볼것! 끝!
1. 에러 JPA를 사용하던 중 ddl-auto를 update로 해놨더니 매번 스프링부트를 올릴 때마다 뭔가가 추가되던 도중 alter table adm_tags add constraint FKhrr3j1w5xn0ueh0s86u66dbjp foreign key (adm_faq_id) references adm_faqs (adm_faq_id) 이 alter 부분에서 밑의 콘솔 내용이 찍히면서 에러가 생겼다 GenerationTarget encountered exception accepting command : Error executing DDL " alter table adm_tags add constraint FKhrr3j1w5xn0ueh0s86u66dbjp foreign key (adm_faq_id) ..
Mysql에서 table에 쌓인 데이터 크기를 알고 싶은 경우 information_schema를 이용하면 알 수 있다 SELECT table_name, -- 테이블 명 table_rows, -- 전체 row 수 data_length, -- 저장된 데이터 크기 (Bytes) round(data_length/table_rows), -- 데이터 평균 크기(계산) avg_row_length -- 데이터 평균 크기(컬럼) FROM information_schema.TABLES WHERE table_name = '테이블명' AND 조건 GROUP BY table_name ORDER BY data_length DESC; data_length에서 table_rows로 나눠도 평균 크기를 알 수 있지만 avg_row_..
정말 오랜만에 개발 하려니까 run부터 안되는 현실 보통은 error 관련해서 디게 길게길게 말해주는데 intellij가 말이 짧아졌다 그래서 구글링해보니 java version 17쓸건데 없다고 한다 ..있는데? java -version 쳤을때 17.0.6 잘 나오는데..? 해서 찾아보니 Gradle JVM version을 못찾았을때 생기는 현상이라고 한다 IntelliJ > Preference > Build, Execution, Deployment > Build Tools > Gradle에 들어가서 Gradle JVM 쪽을 살펴보면 15라던지.. 15라던지.. 그런 java만 있고 17이 없을 수 있다 다운 받아 준 뒤 Apply 하면 끝 ! 그래도 안된다? 프로젝트 오른쪽 클릭 > Open Modu..
linux의 스케쥴러인 crontab을 쓰는 방법이다 기본 실행은 root 계정으로 실행되며 crontab 명령어를 사용해 조회 및 추가가 가능하다 기본 crontab 규칙 분 시 일 월 요일 쉘 * * * * * command - 분 ( 0 ~59 ) - 시 ( 0 ~ 23 ) - 일 ( 1 ~ 31 ) - 월 ( 1 ~ 12 or jan, feb, ...) - 요일 ( 0 ~ 6 or sun, mon, ... ) : 요일은 일요일(0)부터 시작 ex ) 매일 1시에 start.sh 실행 0 1 * * * 위치/start.sh 5분마다 start.sh 실행 */5 * * * * 위치/start.sh 6시간마다 start.sh 실행 0 */6 * * * 위치/start.sh root 계정으로 쉘 실행하기..
Mockito를 사용 할 때 분명히 되어야하는데 안될 때가 있다(? 테스트가 안될리가 없는데... 하고 살펴봤더니 UnneccessaryStubbingException이 나타났다 org.mockito.exceptions.misusing.UnnecessaryStubbingException: Unnecessary stubbings detected. Clean & maintainable test code requires zero unnecessary code. Following stubbings are unnecessary (click to navigate to relevant line of code): 1. -> at com.service.DashboardServiceTest.setLineStatus(Das..
Spring Project 중 SecurityConfig에서 ROLE을 줄 때 Admin은 User의 롤을 포함한다라는 정책을 줄 때 쓰는 방법 @Configuration @EnableWebSecurity public class SecurityConfig extends WebSecurityConfigurerAdapter { @Override public void configure(HttpSecurity http) throws Exception{ http.authorizeRequests() .mvcMatchers("/admin").hasRole("ADMIN") .mvcMatchers("/user").hasRole("USER") .expressionHandler(expressionHandler()); // ..
Springboot test 중 Assert를 썼음에도 불구하고 "No tests found for given includes:" 라는 문구가 뜨는 경우가 있다 이 때는 import가 제대로 되어있는지 확인한다 이렇게 되어있는 경우가 많다 jupiter.api 패키지 안에 있는 Test 어노테이션으로 변경하면 해결되는 간단한 이슈! 매번 까먹어서 이번에 다시 적어놓기