에러 상황@GetMapping("/findByID/{userId}")public ResponseEntity findByID(@PathVariable("userId") Long userId) { Optional userEntity = userService.findByUserId(userId); if (userEntity.isEmpty()) { return ResponseEntity.status(HttpStatus.NOT_FOUND).build(); } ResponseUser returnValue = new ModelMapper().map(userEntity, ResponseUser.class); return ResponseEntity.status(HttpStatus...
error 상황io.jsonwebtoken.security.WeakKeyException: The specified key byte array is 192 bits which is not secure enough for any JWT HMAC-SHA algorithm. The JWT JWA Specification (RFC 7518, Section 3.2) states that keys used with HMAC-SHA algorithms MUST have a size >= 256 bits (the key size must be greater than or equal to the hash output size). Consider using the Jwts.SIG.HS256.key() builder (..
ERROR 내용 터미널에서 kafka connect를 실행한다. 직접 설치한 파일로 실행할 경우에는 설정파일이 etc가 아니라 config에 있다!!! (이럴경우에는 아래 코드 etc를 config로 바꿔서 하면 된다.) /c/kafka_demo/confluent-6.1.0 $ ./bin/windows/connect-distributed.bat ./etc/kafka/connect-distributed.properties 터미널에서 connect를 다운로드 했을 경우, 에러가 뜬다. ERROR Could not read configuration file from URL 해결 config폴더에서 실행하는 것을 etc폴더로 바꿔준다. connect-distributed.bat에서 아래 코드를 추가한다. rem..
ERROR 내용 application.yml에 아래 내용대로 했는데 h2에서 테이블이 생성되지 않았다. spring: application: name: user-service h2: console: enabled: true # console 사용하겠다 settings: web-allow-others: true # 외부접속허용하겠다. path: /h2-console # 접속하고자 하는 웹브라우저의 h2콘솔 주소 datasource: driver-class-name: org.h2.Driver url: jdbc:h2:mem:testDB 해결 해결 방법을 찾아보니 방법1) 들여쓰기를 잘해라 아래를 참고하여 들여쓰기를 해보자.. spring: application: name: user-service h2: con..
ERROR 내용 git add . 를 하려 했더니 오류가 떳다. 원인 이건 보통 맥 / 리눅스를 쓰는 개발자와 윈도우 쓰는 개발자가 Git으로 협업할 때 발생하는 Whitespace 에러라고 한다. 유닉스 시스템에서는 한 줄의 끝이 LF(Line Feed)로 이루어지는 반면, 윈도우에서는 줄 하나가 CR(Carriage Return)와 LF(Line Feed), 즉 CRLF로 이루어지는데 Git이 이 둘 중 어느 쪽을 선택할지 혼란이 온 것이다. 💡 LF (Line-Feed) LF는 Line-Feed의 약자이다.단어가 타자기에서 비롯되었듯이, 커서는 그 자리에 둔 상태에서 종이만 한 줄을 올리는 동작을 말한다. Mac, Linux(Unix)에서 사용되는 줄바꿈 문자열(\n)이다. 💡 CRLF (Carri..
ERROR 내용 터미널에서 mvn spring-boot:run 을 했을 때 이런 에러 내용이 뜬다면 main class를 찾지 못한 것이다. Execution default-cli of goal org.springframework.boot:spring-boot-maven-plugin:3.2.1:run failed: Unable to find a single main class from the following candidates [com.example.firstserivce.FirstServiceApplication, com.example.firstserivce.FirstSerivceApplication] -> [Help 1] 해결 메인 클래스 명시적 설정을 해주면 된다. pom.xml 파일에서 spri..
ERROR 내용 maven으로 프로젝트를 생성했다. 터미널에서 mvn --version으로 버전을 확인하려 했으나.. maven 설치를 안해둔 상황.. IntellJ는 maven을 자동으로 설치해주지 않는다. 그래서 maven 설치를 했다. cmd 에서는 maven 버전확인이 되는데, 터미널에서는 오류가 뜸.. https://www.inflearn.com/course/%EC%8A%A4%ED%94%84%EB%A7%81-%ED%81%B4%EB%9D%BC%EC%9A%B0%EB%93%9C-%EB%A7%88%EC%9D%B4%ED%81%AC%EB%A1%9C%EC%84%9C%EB%B9%84%EC%8A%A4# 해결 "시스템 환경 변수 편집"에 들어가서 IntelliJ IDEA보다는 위에 %SystemRoot%\syst..
ERROR 내용 mvn spring-boot:run -Dspring-boot.run.jvmArguments='-Dserver.port=9004'으로 터미널에서 9004 새로운 port로 기동하려 했으나, 오류가 떳다. 해결 1. mvn install 오류메시지를 따라서 홈페이지에 들어가 순서대로 mvn을 설치 해줬다. [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/LifecyclePhaseNotFoundException Invoke a lifecycle phase, e.g. mvn install This runs the lifecycle phase install and all its predecessor phases like comp..
ERROR 내용java 버전을 확인하려고 했는데 인식 안된다는 오류가 떳다.java : 'java' 용어가 cmdlet, 함수, 스크립트 파일 또는 실행할 수 있는 프로그램 이름으로 인식되지 않습니다. 이름이 정확한지 확인하고 경로가 포함된 경우 경로가 올바른지 검증한 다음 다시 시도하십시오.위치 줄:1 문자:1 + java -version + ~~~~ ..
프로젝트 및 공부를 하며 git push를 했지만 unknown로 commit이 되었다. 이전 커밋의 user, author을 바꿔보자.. 1. git user 설정 git user 다시 설정. 아래 명령어는 추후 사용자를 변경하고 싶을 때도 그대로 사용할 수 있다. git config --global user.name "git 이름" git config --global user.email "git 이메일" ✔ 만약에 특정 repository 에만 user을 다르게 설정하고 싶다면 --global 플래그를 빼고 수행하면 된다. git config user.name "git 이름" git config user.email "git 이메일" 2. git log 확인 3. author 을 바꿀 commit 을 ..