본문 바로가기 메뉴 바로가기

기본을 알면 개발이 쉬워진다

프로필사진
  • 글쓰기
  • 관리
  • 태그
  • 방명록
  • RSS

기본을 알면 개발이 쉬워진다

검색하기 폼
  • 분류 전체보기 (105)
    • 개발작업중해결방안 (2)
    • 프로그램이야기 (18)
    • Spring (13)
    • Java (0)
      • 기본 (36)
      • IO (2)
      • Pattern (2)
      • Stream (1)
    • JavaScript (7)
      • 기본 (6)
      • JavaScript 이야기 (1)
    • 개발TOOL (3)
    • 책요약 (13)
    • 설치 (1)
    • 멘토 (1)
      • 에어콘 3조 (1)
    • ElasticSearch (6)
  • 방명록

Spring (13)
Springboot JPA Pagination

실제 운영 환경에서는 Pageable 속성을 지정하여 메모리 아웃을 피해야 합니다. 1. 도메인 클래스 생성 @Setter @Getter @Table(name = "TB_DEMO") @AllArgsConstructor @NoArgsConstructor @Entity @Builder public class DemoEntity { @Id @GeneratedValue(strategy = GenerationType.SEQUENCE) private int id; private String title; private String content; } 2. Repository 생성 페이징 및 정렬을 하기 위해서는 ListPagingAndSortingRepository 또는 PagingAndSortingRepositor..

Spring 2023. 8. 23. 02:33
SpringBoot 로그 출력

스프링 부트에서 로그는 log4j2, logbak을 사용하여 출력 할 수 있습니다. spring-boot-starter-log4j2 로깅을 위해 Log4j2를 사용하기 위한 스타터. spring-boot-starter-logging Logback을 사용하여 로깅하기 위한 스타터입니다. 기본 로깅 스타터 참고 : https://docs.spring.io/spring-boot/docs/3.1.2/reference/html/features.html#features.logging Core Features Spring Boot uses Commons Logging for all internal logging but leaves the underlying log implementation open. Default ..

Spring 2023. 8. 15. 17:36
SpringBoot - ES 개발

1. RestClient 개발 참고 :https://www.elastic.co/guide/en/elasticsearch/client/java-api-client/current/connecting.html Connecting | Elasticsearch Java API Client [8.9] | Elastic The Java API Client is structured around three main components: API client classes. These provide strongly typed data structures and methods for Elasticsearch APIs. Since the Elasticsearch API is large, it is structured in fe..

Spring 2023. 8. 15. 13:19
SpringBoot Mybatis 구성

Mybatis는 SQL, 저장 프로시저를 자바 오브젝트에 매핑하는 것을 지원하는 SQL 매퍼 프레임워크 입니다. 참고 : MyBatis – 마이바티스 3 | 소개 MyBatis – 마이바티스 3 | 소개 마이바티스는 무엇인가? 마이바티스는 개발자가 지정한 SQL, 저장프로시저 그리고 몇가지 고급 매핑을 지원하는 퍼시스턴스 프레임워크이다. 마이바티스는 JDBC로 처리하는 상당부분의 코드와 mybatis.org 스프링 부트에서 MyBatis를 적용 1. 의존성 설정 mybatis-spring-boot-starter는 mybatis-spring-boot-autoconfigure, spring-boot-starter, spring-boot-starter-jdbc, mybatis-spring 의존성을 포함하고 있..

Spring 2023. 8. 13. 14:02
Spring Boot H2 사용하기

1. 종속성 1.1 gradle 종속성 runtimeOnly 'com.h2database:h2' implementation 'org.springframework.boot:spring-boot-starter-data-jpa' 1.2 Maven 종속성 org.springframework.boot spring-boot-starter-data-jpa com.h2database h2 runtime 2. 데이터베이스 구성 SpringBoot에서 DB를 연결하기 위해서는 Application.yml 또는 application.properties에 속성을 추가 해야 합니다. spring: datasource: url: jdbc:h2:file:./data/demodb # 파일 저장소 username: sa passwor..

Spring 2023. 8. 12. 04:02
이전 1 2 다음
이전 다음

Blog is powered by Tistory / Designed by Tistory

티스토리툴바