본문 바로가기

728x90
반응형

분류 전체보기

(135)
jar build 해서 동작 확인 지금 하고 있는 프로젝트에서 gradlew clean build 한다. 깔끔하게 지우고 다시 build를 해주는거란다. 근데 안된다...  BUILD FAILED ㅎㅎㅎ 아놔... Publishing a build scan to scans.gradle.com requires aceepting the Gradle Terms of Use defined at https://gradle.com/help/legal-terms-of-use. Do you accept these terms? [yes, no]에 대답을 yes로 하니 Gradle Terms of Use accepted 하면서 끝나더라...된건지 찝찝...
MVCC=TRUE application.yml에 url: jdbc:h2:tcp://localhost/~/jpashop;MVCC=TRUE 이렇게 넣고 rerun을 하면 error 가 났다. 구글링해보니   주의: H2 데이터베이스의 MVCC 옵션은 H2 1.4.198 버전부터 제거되었습니다. *1.4.200 버전에서는 MVCC 옵션을 사용하면 오류가 발생*합니다.  그래서 url에url: jdbc:h2:tcp://localhost/~/jpashop; 넣으니 잘 굴러간다... 아침부터 시간 낭비, 전력 낭비한듯...
Intellij 단축키 만들기 Setting 에 들어가서 4번에는 아래와 같이 입력해줬다@Testpublic void $NAME$() throws Exception{ //given $END$ //when //then} 이렇게 하면 tdd  입력하고 탭 클릭하면 자동완성 된다. 근데 하려고하니까 안되더라... 왜인지 모르겠더라... 근데... 이렇게 되어 있어서 그랬던거였다... 그래서 ㅎㅎ 일단 이렇게 설정해줬다. 잘될거 같다 ㅎㅎ 잘 뜬다 ㅎㅎㅎ 별거 아닌데 기분 좋음
JPA와 DB 설정, 동작확인 application.properties를 삭제하고  application.yml 파일을 만들어준다.spring: datasource: url: jdbc:h2:tcp://localhost/~/jpashop;MVCC=TRUE username: sa password: driver-class-name: org.h2.Driver jpa: hibernate: ddl-auto: create properties: hibernate:# show_sql: true format_sql: truelogging: level: org.hibernate.SQL: debug
H2 Database 개발이나 테스트 용도로 가볍고 편리한 DB, 웹 화면 제공 https://www.h2database.com H2 Database Engine (redirect)H2 Database Engine Welcome to H2, the free SQL database. The main feature of H2 are: It is free to use for everybody, source code is included Written in Java, but also available as native executable JDBC and (partial) ODBC API Embedded and client/server mowww.h2database.com - DB 파일 생성 방법  http://localhost:80..
org.springframework.boot:spring-boot-devtools org.springframework.boot:spring-boot-devtools를 추가해주면 sync 해주고 서버 재시작 해주고 파일 변경을 하고 Recompile 'hello.html'을 해주면 웹에서 F5를 해주면 반영이 되는 것을 알 수 있다. 서버를 계속 재시작 할 필요없다.
thymeleaf viewName 매핑 스프링 부트 thymeleaf viewName 매핑- 'resource:templates/'+ {ViewName} + '.html' 로 해버림  이렇게 작성하면resources/templates/hello.html로 보내버림!!!
lombok 설치 및 확인 Intellij에서 Settings로 들어가서 Plugins로 들어가서 Lombok을 설치 및 확인해본다.  설치하면이렇게 바뀐다 restart 를 해준뒤  Settings 에 Annotation Processors에 들어가서 Enable annotaion processing을 설정해준다. 제대로 적용이 되었는지 확인하기 위해  Hello 클래스를 하나 생성한뒤 이렇게 만들어주고 단축키를 이용해 ( soutv ) 아래와 같이 만들어준다. 콘솔에 이렇게 찍힌다
public static void main(String[] args) 실행 시 무한 로딩 이런 상황임...위에 거를 아래와 같이 바꾸라고 하는데... 내가 뭘 잘못한줄 알았는데... 잘되고 있는거였음... ㅎㅎㅎ 잘 나옴 ㅎㅎ
AbstractProperty$PropertyQueryException: Failed to calculate the value of task ':compileJava' property 'javaCompiler' start.spring.io 에서 java 버전을 너무 옛날거로 해서 설정하니... 저런 에러가 남...  이렇게 설정을 하고 나면잘된다...

728x90
반응형