본문 바로가기

2018/12

힘든 어떤 일을 한 후, 나의 가장 가까운 사람에게 해줘야하고 들었으면 하는 말. 가끔 이 말이 너무 듣고 싶을때가 있다. 조이양에게..ㅎㅎ 더보기
Local Docker Elasticsearch 운영 - Spring + High Level Client 이전에 설치했던 elasticsearch 가 잘 운영되고 있다면.. http://127.0.0.1:9200/_cat/health1545724265 07:51:05 docker-cluster green 2 2 10 5 0 0 0 0 - 100.0% 스프링부트로 새로운 프로젝트를 생상한다.IDEA 도움을 받아 프로젝트 설치 후, build.gradle 파일을 열어보자 buildscript { ext { springBootVersion = '2.1.1.RELEASE' } repositories { mavenCentral() } dependencies { classpath("org.springframework.boot:spring-boot-gradle-plugin:${springBootVersion}") } }.. 더보기
Local Docker Elasticsearch 설치 제공괴는 Image에 추가로 몇몇 플러그인등을 적용해야하니 별도의 Dockerfile을 작성한다.$> vi Dockerfile # Elasticsearch 6.5.4 FROM docker.elastic.co/elasticsearch/elasticsearch:6.5.4WORKDIR /usr/share/elasticsearchRUN /usr/share/elasticsearch/bin/elasticsearch-plugin install --batch discovery-ec2RUN /usr/share/elasticsearch/bin/elasticsearch-plugin install --batch analysis-nori$> docker build -t elasticsearch-my6_5_4 . EC2 용 플러.. 더보기
QueryDSL 이용시 datetime column type에 대한 group by 아래와 같이 세개의 컬럼이 존재한다. 상품번호 판매수량 일자 100003 2 2018-12-19 12:23:11 100003 1 2018-12-18 11:13:09 100003 1 2018-12-18 09:13:09 요구사항은 일자별 판매수량 sum이라고 치자. 즉, 아래와 같이 시간은 제거되고 일자 만으로 groupby와 판매수량에 대한 sum 처리를 해야 한다. 100003 | 2 | 2018-12-19100003 | 2 | 2018-12-18 QueryDSL으로 이용하려니 날짜에 대한 시간 제거를 모르겠다..흠.해서 MySQL의 자체 function을 이용하는 방법으로 우선 해결. 코드는 다음과 같다. StringTemplate datePathOrderDate = Expressions.stringT.. 더보기
Annotation 정리 문서 - 추가중 이렇게 정리해두니 좋네~ https://dzone.com/articles/all-java-built-in-annotation-examples https://dzone.com/articles/spring-web-mvc-annotation-examples https://dzone.com/articles/all-hibernate-annotations-mapping-annotations https://dzone.com/articles/all-jpa-annotations-mapping-annotations 더보기