SlideShare une entreprise Scribd logo
1  sur  18
© 2013 Gruter. All rights reserved.
실시간 분석 플랫폼
구축 사례
2013.08.28
김형준 수석 연구원
© 2013 Gruter. All rights reserved.
요구사항
• 실시간 데이터 수집
• 수집 단계에서 실시간 데이터 분석
• 실시간 분석 결과 실시간 데이터 제공
• 수집된 데이터 안정적 저장
• 저장소 데이터 배치 분석
• 저장소 데이터 검색
• 전체 클러스터 관리 및 모니터링
2
© 2013 Gruter. All rights reserved.
전체 아키텍처
3
웹 로그 수집 서버
WAS
log Agent
로그 Collector
Flume
Collector
분석 결과 저장소
검색 저장소
TCP
UDP
FTP
HDFS
Search
Real
Time
원본 파일 저장소
로그 Collector
Flume
Collector
TCP
UDP
FTP
HDFS
Search
Real
Time
실시간 분석
Application Server
사용자 행동
분석 로직
실시간 분석 클러스터
실시간 분석
Application Server
실시간 분석 로직
HBase
(NoSQL)
Table Table Table
ElasticSearch
Latest
Index
Backup
Index
Hadoop File System
Hive
Table A
Hive
Table B
배치분석
Hadoop MapReduce
Map
Reduce
클러스터 관리
ZooKeeper
Cloumon
Hive
질의
MySQL
© 2013 Gruter. All rights reserved.
실시간 분석 예 #1
• 구글 애널리틱스
4
© 2013 Gruter. All rights reserved.
실시간 분석 예 #2
• 페이스북 Social-Plugin
5
수집
실시간분석
실시간
Feedback
배치분석
process over 20 billion events per
day (200,000 events per second)
with a lag of less than 30 seconds.
Analytic
Transactional
© 2013 Gruter. All rights reserved.
실시간 분석 예 #3
• SNS 전파 경로 분석
6
© 2013 Gruter. All rights reserved.
현실은?
• 가장 기본적인 로그 조차도 일 단위 분석
– HTTP LOG 등
• 비즈니스에 중요한 데이터는 로그도 없음
• 일부 로그는 외부 업체로 전달
7
© 2013 Gruter. All rights reserved.
실시간 분석의 어려움 #1
• 중복, 유실, 성능 모두를 만족시키기 어려움
– 이중화된 큐와 체크 포인팅 기능이 핵심
– 체크 포인팅을 많이 사용하면 성능 저하 적게 사용하면 유실율
이 높아짐
• 성능
– 대량의 데이터
– 분석의 복잡성(다양한 메타 데이터와 연계 등)
• 운영 관리
– 무정지로 운영 되어야 함
– 비즈니스 로직 변경에 따른 배포
• 분석 결과 저장
– 체크 포인트
– 최종 결과
– 시각화
8
© 2013 Gruter. All rights reserved.
실시간 분석의 어려움 #2
• 시간 관리
– 분산된 환경의 시간 동기화
– Time window 동기화
– Data time vs. System time
• 분석 로직 구현
– SQL 기반
– 프로그램 기반
• 플랫폼들의 조합
– Flume, Storm, Kafka 등
– 각 솔루션은 HA 등에 대한 기능 제공
– But, 조합 시 불협화음
– 서버 사이징
• Agent/Collelctor 댓수 비율, CPU/Network 등
9
© 2013 Gruter. All rights reserved.
참조 아키텍처 #1
• Facebook Social Plugin
10
/category1/collect_1.dat
/category1/collect_2.dat
/category1/collect_3.dat
데이터 수집기
(scribe)
데이터 수집기
(scribe)
데이터 수집기
(scribe)
Hadoop
Write, sync
Key1: value
Key2: value
Key3: value
HBase
ptail
Driver
Aggregation
Store
Checkpoint
Handler
Storage
Thrift
Server
클라이언트
© 2013 Gruter. All rights reserved.
참조 아키텍처 #2
11
http://highlyscalable.wordpress.com/2013/08/20/in-stream-big-data-processing/
© 2013 Gruter. All rights reserved.
개발 시스템 아키텍처
12
ZooKeeper
분석 결과 저장소
(HBase)
Realtime Server
Partition
Proxy
Partitioner
Processor
Engine
User
Processor
ReplicatorQueue
Time Window
Manager
(Master Role)
Flume Collector
Realtime
Client
Partition #2
Partition #1
Partition #3
Flume Collector
Realtime
Client
Dimension
Data
memory
© 2013 Gruter. All rights reserved.
구성 요소
• Realtime Server
– 외부로부터 데이터를 수신하여 사용자가 개발한 분석 프로그램을 실행해주는 데몬 프로세스
– 여러 대의 물리적인 서버에 분산 배치
– 서버 자체는 분석 기능을 가지고 있지 않음
– 서버 장애를 대비하여 서버 별로 Slave 서버를 구성할 수 있음
• Cluster Master
– 클러스터 중 한대가 마스터 역할 수행, 자동으로 Master가 선정
– 서버 장애 시 Partition Master/Slave failover 수행
– 작업 그룹의 Flush 주기에 따라 Flush Scheduler 수행
– 서버 사이의 타임 동기화 작업
– 파티션 추가 및 제거 등 클러스터 관리 작업
• Realtime Client
– 실시간 분석 클러스터로 분석 대상 데이터를 전송하는 프로그램에서 사용하는 모듈
• ZooKeeper(시스템 외부)
– 클러스터의 전체 서버 상태 정보, Workgroup 정보 등 클러스터를 운영하는데 필요한 메타 정보 관
리
– Flush 이벤트 등 이벤트 전송
• 분석 결과 저장소(시스템 외부)
– 분석 결과를 저장하는 저장소
– 동시 저장 데이터가 많고 분석 서버가 많은 경우 HBase와 같은 분산 데이터 저장소 사용
– 결과 데이터가 작고 결과를 다양한 질의로 통해 조회하는 경우 MySQL과 같은 RDBMS 사용
13
© 2013 Gruter. All rights reserved.
특징
• 고정된 크기의 클러스터 파티션
– 각 서버는 시작 시 지정된 파티션 ID를 가짐
– 데이터 파티션 처리 쉬운 장점
– 서버 추가/제거는 Shell 명령을 가능
• 파티션 이중화
– 하나의 파티션은 두 개의 서버가 담당(Master/Slave)
• 분산 실시간 분석에 필요한 다양한 모듈 기본 제공
– 분산된 서버들 사이에 동기화된 Flush 기능
– Time 동기화 기능
– SQL-Like 질의 기반 분석 도구인 Esper와 연계 모듈
• WorkGroup
– 하나의 분석을 수행하기 위해서는 여러 개의 분석 모듈이 연결 되어야 함.
– 하나의 클러스터로 여러 개의 분석 업무를 동시에 수행
• 자체 개발
– 공개된 실시간 분석 솔루션은 다음 기능 제공
• 데몬 서버, 데이터 송수신 RPC, 프로그램 모델, 데이터 파티셔닝, Queue와 연동
– 활용 가능한 조각 모음은 대부분 오픈 소스로 나와 있음
• RPC: Thrift, Avro, Protobuf, Netty
• Event, Cluster Membership, Synchronization : ZooKeeper
• Query Processing: Esper
• Queue: Kafka, RabbitMQ, ZeroMQ
14
© 2013 Gruter. All rights reserved.
데이터 처리 흐름
15
Log Parsing
Log Parsing
Log Parsing
log
data
URL, Count(1)
Group by URL
URL, Count(1)
Group by URL
Count
(Distinct User)
Count
(Distinct User)
HBase Table
TOP 100
Order by count
Desc
hash(url) time batch 60 sec.
hash(user_id)
time batch 20 sec.WorkGroup #2
(LogType=User)
WorkGroup #1
(LogType=URL)
IP-City
DataLoad in memory
© 2013 Gruter. All rights reserved.
분석 프로그램 예시
16
public class WordCountProcessor extends AnalysisProcessor {
private Map<String, Integer> wordCountMap = new HashMap<String, Integer>();
public String getWorkGroupName() {
return "wordcountGroup";
}
public String getEventType() {
return "wordcount";
}
public int getPartitionId(EventParsedRecord eventParsedRecord, int numPartition, int serverId) {
return getHashPartitionId(eventParsedRecord.getKey(), numPartition);
}
public EventParsedRecord parseEvent(String event) throws IOException {
EventParsedRecord eventParsedRecord = new EventParsedRecord();
eventParsedRecord.setKey(event);
return eventParsedRecord;
}
public void process(String type, EventParsedRecord eventParsedRecord, boolean serverPairMaster) {
Integer count = wordCountMap.get(eventParsedRecord.getKey());
if(count == null) wordCountMap.put(eventParsedRecord.getKey(), 1);
else wordCountMap.put(eventParsedRecord.getKey(), count + 1);
}
public void flush(long flushTime, boolean serverPartitionMaster) throws IOException {
if(serverPartitionMaster) {
for(Map.Entry<String, Integer> entry: wordCountMap.entrySet()) {
HBaseStore.store(“T_WORD_COUNT”, entry.getKey() + ”,“ + entry.getValue());
}
}
}
© 2013 Gruter. All rights reserved.
결론
• 실시간 분석은 대세이지만 많은 난관이 존재
– 고객의 요구(정합성, 안정성 모두 만족 등)
– 메타 정보(JOIN) 처리 성능
– 운영의 어려움(항상 데이터가 흘러 다님)
• 분석 대상 데이터의 속성, 분석 로직 등에 따라
적절한 플랫폼 선택
– 플랫폼은 기본만 제공
– 많은 것을 그 위에 만들어야 함
– 적절한 플랫폼이 없으면 만드는 것도 방법
17
GRUTER: YOUR PARTNER
IN THE BIG DATA REVOLUTION
Phone +82-70-8129-2950
Fax +82-70-8129-2952
E-mail contact@gruter.com
Web www.gruter.com
© 2013 Gruter. All rights reserved.
Gruter, Inc.
5F Sehwa Office Building 889-70 Daechi-dong, Gangnam-gu, Seoul, South Korea 135-839

Contenu connexe

Tendances

Io t에서 big data를 통합하는 통합 빅데이터 플랫폼 flamingo_클라우다인_김병곤 대표이사
Io t에서 big data를 통합하는 통합 빅데이터 플랫폼 flamingo_클라우다인_김병곤 대표이사Io t에서 big data를 통합하는 통합 빅데이터 플랫폼 flamingo_클라우다인_김병곤 대표이사
Io t에서 big data를 통합하는 통합 빅데이터 플랫폼 flamingo_클라우다인_김병곤 대표이사uEngine Solutions
 
234 deview2013 김형준
234 deview2013 김형준234 deview2013 김형준
234 deview2013 김형준NAVER D2
 
Realtime Big data Anaytics and Exampes of Daum (2013)
Realtime Big data Anaytics and Exampes of Daum (2013)Realtime Big data Anaytics and Exampes of Daum (2013)
Realtime Big data Anaytics and Exampes of Daum (2013)Channy Yun
 
Tajo TPC-H Benchmark Test on AWS
Tajo TPC-H Benchmark Test on AWSTajo TPC-H Benchmark Test on AWS
Tajo TPC-H Benchmark Test on AWSGruter
 
201210 그루터 빅데이터_플랫폼_아키텍쳐_및_솔루션_소개
201210 그루터 빅데이터_플랫폼_아키텍쳐_및_솔루션_소개201210 그루터 빅데이터_플랫폼_아키텍쳐_및_솔루션_소개
201210 그루터 빅데이터_플랫폼_아키텍쳐_및_솔루션_소개Gruter
 
하둡 알아보기(Learn about Hadoop basic), NetApp FAS NFS Connector for Hadoop
하둡 알아보기(Learn about Hadoop basic), NetApp FAS NFS Connector for Hadoop하둡 알아보기(Learn about Hadoop basic), NetApp FAS NFS Connector for Hadoop
하둡 알아보기(Learn about Hadoop basic), NetApp FAS NFS Connector for HadoopSeungYong Baek
 
[Open Technet Summit 2014] 쓰기 쉬운 Hadoop 기반 빅데이터 플랫폼 아키텍처 및 활용 방안
[Open Technet Summit 2014] 쓰기 쉬운 Hadoop 기반 빅데이터 플랫폼 아키텍처 및 활용 방안[Open Technet Summit 2014] 쓰기 쉬운 Hadoop 기반 빅데이터 플랫폼 아키텍처 및 활용 방안
[Open Technet Summit 2014] 쓰기 쉬운 Hadoop 기반 빅데이터 플랫폼 아키텍처 및 활용 방안치완 박
 
서울 하둡 사용자 모임 발표자료
서울 하둡 사용자 모임 발표자료서울 하둡 사용자 모임 발표자료
서울 하둡 사용자 모임 발표자료Teddy Choi
 
SQL-on-Hadoop with Apache Tajo, and application case of SK Telecom
SQL-on-Hadoop with Apache Tajo,  and application case of SK TelecomSQL-on-Hadoop with Apache Tajo,  and application case of SK Telecom
SQL-on-Hadoop with Apache Tajo, and application case of SK TelecomGruter
 
Hadoop 제주대
Hadoop 제주대Hadoop 제주대
Hadoop 제주대DaeHeon Oh
 
DeView2013 Big Data Platform Architecture with Hadoop - Hyeong-jun Kim
DeView2013 Big Data Platform Architecture with Hadoop - Hyeong-jun KimDeView2013 Big Data Platform Architecture with Hadoop - Hyeong-jun Kim
DeView2013 Big Data Platform Architecture with Hadoop - Hyeong-jun KimGruter
 
Expanding Your Data Warehouse with Tajo
Expanding Your Data Warehouse with TajoExpanding Your Data Warehouse with Tajo
Expanding Your Data Warehouse with TajoMatthew (정재화)
 
Introduction to Apache Tajo
Introduction to Apache TajoIntroduction to Apache Tajo
Introduction to Apache TajoGruter
 
Gpdb best practices v a01 20150313
Gpdb best practices v a01 20150313Gpdb best practices v a01 20150313
Gpdb best practices v a01 20150313Sanghee Lee
 
스타트업사례로 본 로그 데이터분석 : Tajo on AWS
스타트업사례로 본 로그 데이터분석 : Tajo on AWS스타트업사례로 본 로그 데이터분석 : Tajo on AWS
스타트업사례로 본 로그 데이터분석 : Tajo on AWSGruter
 
Hadoop과 SQL-on-Hadoop (A short intro to Hadoop and SQL-on-Hadoop)
Hadoop과 SQL-on-Hadoop (A short intro to Hadoop and SQL-on-Hadoop)Hadoop과 SQL-on-Hadoop (A short intro to Hadoop and SQL-on-Hadoop)
Hadoop과 SQL-on-Hadoop (A short intro to Hadoop and SQL-on-Hadoop)Matthew (정재화)
 
Big data analysis with R and Apache Tajo (in Korean)
Big data analysis with R and Apache Tajo (in Korean)Big data analysis with R and Apache Tajo (in Korean)
Big data analysis with R and Apache Tajo (in Korean)Gruter
 
about hadoop yes
about hadoop yesabout hadoop yes
about hadoop yesEunsil Yoon
 
Tajo and SQL-on-Hadoop in Tech Planet 2013
Tajo and SQL-on-Hadoop in Tech Planet 2013Tajo and SQL-on-Hadoop in Tech Planet 2013
Tajo and SQL-on-Hadoop in Tech Planet 2013Gruter
 
빅데이터, big data
빅데이터, big data빅데이터, big data
빅데이터, big dataH K Yoon
 

Tendances (20)

Io t에서 big data를 통합하는 통합 빅데이터 플랫폼 flamingo_클라우다인_김병곤 대표이사
Io t에서 big data를 통합하는 통합 빅데이터 플랫폼 flamingo_클라우다인_김병곤 대표이사Io t에서 big data를 통합하는 통합 빅데이터 플랫폼 flamingo_클라우다인_김병곤 대표이사
Io t에서 big data를 통합하는 통합 빅데이터 플랫폼 flamingo_클라우다인_김병곤 대표이사
 
234 deview2013 김형준
234 deview2013 김형준234 deview2013 김형준
234 deview2013 김형준
 
Realtime Big data Anaytics and Exampes of Daum (2013)
Realtime Big data Anaytics and Exampes of Daum (2013)Realtime Big data Anaytics and Exampes of Daum (2013)
Realtime Big data Anaytics and Exampes of Daum (2013)
 
Tajo TPC-H Benchmark Test on AWS
Tajo TPC-H Benchmark Test on AWSTajo TPC-H Benchmark Test on AWS
Tajo TPC-H Benchmark Test on AWS
 
201210 그루터 빅데이터_플랫폼_아키텍쳐_및_솔루션_소개
201210 그루터 빅데이터_플랫폼_아키텍쳐_및_솔루션_소개201210 그루터 빅데이터_플랫폼_아키텍쳐_및_솔루션_소개
201210 그루터 빅데이터_플랫폼_아키텍쳐_및_솔루션_소개
 
하둡 알아보기(Learn about Hadoop basic), NetApp FAS NFS Connector for Hadoop
하둡 알아보기(Learn about Hadoop basic), NetApp FAS NFS Connector for Hadoop하둡 알아보기(Learn about Hadoop basic), NetApp FAS NFS Connector for Hadoop
하둡 알아보기(Learn about Hadoop basic), NetApp FAS NFS Connector for Hadoop
 
[Open Technet Summit 2014] 쓰기 쉬운 Hadoop 기반 빅데이터 플랫폼 아키텍처 및 활용 방안
[Open Technet Summit 2014] 쓰기 쉬운 Hadoop 기반 빅데이터 플랫폼 아키텍처 및 활용 방안[Open Technet Summit 2014] 쓰기 쉬운 Hadoop 기반 빅데이터 플랫폼 아키텍처 및 활용 방안
[Open Technet Summit 2014] 쓰기 쉬운 Hadoop 기반 빅데이터 플랫폼 아키텍처 및 활용 방안
 
서울 하둡 사용자 모임 발표자료
서울 하둡 사용자 모임 발표자료서울 하둡 사용자 모임 발표자료
서울 하둡 사용자 모임 발표자료
 
SQL-on-Hadoop with Apache Tajo, and application case of SK Telecom
SQL-on-Hadoop with Apache Tajo,  and application case of SK TelecomSQL-on-Hadoop with Apache Tajo,  and application case of SK Telecom
SQL-on-Hadoop with Apache Tajo, and application case of SK Telecom
 
Hadoop 제주대
Hadoop 제주대Hadoop 제주대
Hadoop 제주대
 
DeView2013 Big Data Platform Architecture with Hadoop - Hyeong-jun Kim
DeView2013 Big Data Platform Architecture with Hadoop - Hyeong-jun KimDeView2013 Big Data Platform Architecture with Hadoop - Hyeong-jun Kim
DeView2013 Big Data Platform Architecture with Hadoop - Hyeong-jun Kim
 
Expanding Your Data Warehouse with Tajo
Expanding Your Data Warehouse with TajoExpanding Your Data Warehouse with Tajo
Expanding Your Data Warehouse with Tajo
 
Introduction to Apache Tajo
Introduction to Apache TajoIntroduction to Apache Tajo
Introduction to Apache Tajo
 
Gpdb best practices v a01 20150313
Gpdb best practices v a01 20150313Gpdb best practices v a01 20150313
Gpdb best practices v a01 20150313
 
스타트업사례로 본 로그 데이터분석 : Tajo on AWS
스타트업사례로 본 로그 데이터분석 : Tajo on AWS스타트업사례로 본 로그 데이터분석 : Tajo on AWS
스타트업사례로 본 로그 데이터분석 : Tajo on AWS
 
Hadoop과 SQL-on-Hadoop (A short intro to Hadoop and SQL-on-Hadoop)
Hadoop과 SQL-on-Hadoop (A short intro to Hadoop and SQL-on-Hadoop)Hadoop과 SQL-on-Hadoop (A short intro to Hadoop and SQL-on-Hadoop)
Hadoop과 SQL-on-Hadoop (A short intro to Hadoop and SQL-on-Hadoop)
 
Big data analysis with R and Apache Tajo (in Korean)
Big data analysis with R and Apache Tajo (in Korean)Big data analysis with R and Apache Tajo (in Korean)
Big data analysis with R and Apache Tajo (in Korean)
 
about hadoop yes
about hadoop yesabout hadoop yes
about hadoop yes
 
Tajo and SQL-on-Hadoop in Tech Planet 2013
Tajo and SQL-on-Hadoop in Tech Planet 2013Tajo and SQL-on-Hadoop in Tech Planet 2013
Tajo and SQL-on-Hadoop in Tech Planet 2013
 
빅데이터, big data
빅데이터, big data빅데이터, big data
빅데이터, big data
 

Similaire à GRUTER가 들려주는 Big Data Platform 구축 전략과 적용 사례: 인터넷 쇼핑몰의 실시간 분석 플랫폼 구축 사례

Flamingo 1.2 릴리즈의 지원 기능 정리
Flamingo 1.2 릴리즈의 지원 기능 정리Flamingo 1.2 릴리즈의 지원 기능 정리
Flamingo 1.2 릴리즈의 지원 기능 정리BYOUNG GON KIM
 
Jco 소셜 빅데이터_20120218
Jco 소셜 빅데이터_20120218Jco 소셜 빅데이터_20120218
Jco 소셜 빅데이터_20120218Hyoungjun Kim
 
[경북] I'mcloud information
[경북] I'mcloud information[경북] I'mcloud information
[경북] I'mcloud informationstartupkorea
 
빅데이터 기술 현황과 시장 전망(2014)
빅데이터 기술 현황과 시장 전망(2014)빅데이터 기술 현황과 시장 전망(2014)
빅데이터 기술 현황과 시장 전망(2014)Channy Yun
 
JMI Techtalk : Backend.AI
JMI Techtalk : Backend.AIJMI Techtalk : Backend.AI
JMI Techtalk : Backend.AILablup Inc.
 
[pgday.Seoul 2022] PostgreSQL구조 - 윤성재
[pgday.Seoul 2022] PostgreSQL구조 - 윤성재[pgday.Seoul 2022] PostgreSQL구조 - 윤성재
[pgday.Seoul 2022] PostgreSQL구조 - 윤성재PgDay.Seoul
 
Apache Htrace overview (20160520)
Apache Htrace overview (20160520)Apache Htrace overview (20160520)
Apache Htrace overview (20160520)Steve Min
 
Fluentd with MySQL
Fluentd with MySQLFluentd with MySQL
Fluentd with MySQLI Goo Lee
 
DB Monitoring 개념 및 활용 (박명규)
DB Monitoring 개념 및 활용 (박명규)DB Monitoring 개념 및 활용 (박명규)
DB Monitoring 개념 및 활용 (박명규)WhaTap Labs
 
Spark streaming tutorial
Spark streaming tutorialSpark streaming tutorial
Spark streaming tutorialMinho Kim
 
Scalable system design patterns
Scalable system design patternsScalable system design patterns
Scalable system design patternsSteve Min
 
클라우드 환경에서 알아야할 성능 이야기
클라우드 환경에서 알아야할 성능 이야기클라우드 환경에서 알아야할 성능 이야기
클라우드 환경에서 알아야할 성능 이야기YoungSu Son
 
Hadoop Introduction (1.0)
Hadoop Introduction (1.0)Hadoop Introduction (1.0)
Hadoop Introduction (1.0)Keeyong Han
 
OLAP for Big Data (Druid vs Apache Kylin vs Apache Lens)
OLAP for Big Data (Druid vs Apache Kylin vs Apache Lens)OLAP for Big Data (Druid vs Apache Kylin vs Apache Lens)
OLAP for Big Data (Druid vs Apache Kylin vs Apache Lens)SANG WON PARK
 
서비스 모니터링 구현 사례 공유 - Realtime log monitoring platform-PMon을 ...
서비스 모니터링 구현 사례 공유 - Realtime log monitoring platform-PMon을 ...서비스 모니터링 구현 사례 공유 - Realtime log monitoring platform-PMon을 ...
서비스 모니터링 구현 사례 공유 - Realtime log monitoring platform-PMon을 ...Jemin Huh
 
Windows 성능모니터를 이용한 SQL Server 성능 분석
Windows 성능모니터를 이용한 SQL Server 성능 분석Windows 성능모니터를 이용한 SQL Server 성능 분석
Windows 성능모니터를 이용한 SQL Server 성능 분석Sung wook Kang
 
Cloud-Barista 제1차 오픈세미나 : CB-Dragonfly-멀티 클라우드 통합 모니터링 프레임워크(1st Open Seminar...
Cloud-Barista 제1차 오픈세미나 : CB-Dragonfly-멀티 클라우드 통합 모니터링 프레임워크(1st Open Seminar...Cloud-Barista 제1차 오픈세미나 : CB-Dragonfly-멀티 클라우드 통합 모니터링 프레임워크(1st Open Seminar...
Cloud-Barista 제1차 오픈세미나 : CB-Dragonfly-멀티 클라우드 통합 모니터링 프레임워크(1st Open Seminar...Cloud-Barista Community
 
스타트업 사례로 본 로그 데이터 분석 : Tajo on AWS
스타트업 사례로 본 로그 데이터 분석 : Tajo on AWS스타트업 사례로 본 로그 데이터 분석 : Tajo on AWS
스타트업 사례로 본 로그 데이터 분석 : Tajo on AWSMatthew (정재화)
 

Similaire à GRUTER가 들려주는 Big Data Platform 구축 전략과 적용 사례: 인터넷 쇼핑몰의 실시간 분석 플랫폼 구축 사례 (20)

Flamingo 1.2 릴리즈의 지원 기능 정리
Flamingo 1.2 릴리즈의 지원 기능 정리Flamingo 1.2 릴리즈의 지원 기능 정리
Flamingo 1.2 릴리즈의 지원 기능 정리
 
Jco 소셜 빅데이터_20120218
Jco 소셜 빅데이터_20120218Jco 소셜 빅데이터_20120218
Jco 소셜 빅데이터_20120218
 
[경북] I'mcloud information
[경북] I'mcloud information[경북] I'mcloud information
[경북] I'mcloud information
 
빅데이터 기술 현황과 시장 전망(2014)
빅데이터 기술 현황과 시장 전망(2014)빅데이터 기술 현황과 시장 전망(2014)
빅데이터 기술 현황과 시장 전망(2014)
 
JMI Techtalk : Backend.AI
JMI Techtalk : Backend.AIJMI Techtalk : Backend.AI
JMI Techtalk : Backend.AI
 
[pgday.Seoul 2022] PostgreSQL구조 - 윤성재
[pgday.Seoul 2022] PostgreSQL구조 - 윤성재[pgday.Seoul 2022] PostgreSQL구조 - 윤성재
[pgday.Seoul 2022] PostgreSQL구조 - 윤성재
 
Apache Htrace overview (20160520)
Apache Htrace overview (20160520)Apache Htrace overview (20160520)
Apache Htrace overview (20160520)
 
Hadoop overview
Hadoop overviewHadoop overview
Hadoop overview
 
Fluentd with MySQL
Fluentd with MySQLFluentd with MySQL
Fluentd with MySQL
 
DB Monitoring 개념 및 활용 (박명규)
DB Monitoring 개념 및 활용 (박명규)DB Monitoring 개념 및 활용 (박명규)
DB Monitoring 개념 및 활용 (박명규)
 
Spark streaming tutorial
Spark streaming tutorialSpark streaming tutorial
Spark streaming tutorial
 
Scalable system design patterns
Scalable system design patternsScalable system design patterns
Scalable system design patterns
 
Hadoop administration
Hadoop administrationHadoop administration
Hadoop administration
 
클라우드 환경에서 알아야할 성능 이야기
클라우드 환경에서 알아야할 성능 이야기클라우드 환경에서 알아야할 성능 이야기
클라우드 환경에서 알아야할 성능 이야기
 
Hadoop Introduction (1.0)
Hadoop Introduction (1.0)Hadoop Introduction (1.0)
Hadoop Introduction (1.0)
 
OLAP for Big Data (Druid vs Apache Kylin vs Apache Lens)
OLAP for Big Data (Druid vs Apache Kylin vs Apache Lens)OLAP for Big Data (Druid vs Apache Kylin vs Apache Lens)
OLAP for Big Data (Druid vs Apache Kylin vs Apache Lens)
 
서비스 모니터링 구현 사례 공유 - Realtime log monitoring platform-PMon을 ...
서비스 모니터링 구현 사례 공유 - Realtime log monitoring platform-PMon을 ...서비스 모니터링 구현 사례 공유 - Realtime log monitoring platform-PMon을 ...
서비스 모니터링 구현 사례 공유 - Realtime log monitoring platform-PMon을 ...
 
Windows 성능모니터를 이용한 SQL Server 성능 분석
Windows 성능모니터를 이용한 SQL Server 성능 분석Windows 성능모니터를 이용한 SQL Server 성능 분석
Windows 성능모니터를 이용한 SQL Server 성능 분석
 
Cloud-Barista 제1차 오픈세미나 : CB-Dragonfly-멀티 클라우드 통합 모니터링 프레임워크(1st Open Seminar...
Cloud-Barista 제1차 오픈세미나 : CB-Dragonfly-멀티 클라우드 통합 모니터링 프레임워크(1st Open Seminar...Cloud-Barista 제1차 오픈세미나 : CB-Dragonfly-멀티 클라우드 통합 모니터링 프레임워크(1st Open Seminar...
Cloud-Barista 제1차 오픈세미나 : CB-Dragonfly-멀티 클라우드 통합 모니터링 프레임워크(1st Open Seminar...
 
스타트업 사례로 본 로그 데이터 분석 : Tajo on AWS
스타트업 사례로 본 로그 데이터 분석 : Tajo on AWS스타트업 사례로 본 로그 데이터 분석 : Tajo on AWS
스타트업 사례로 본 로그 데이터 분석 : Tajo on AWS
 

Plus de Gruter

MelOn 빅데이터 플랫폼과 Tajo 이야기
MelOn 빅데이터 플랫폼과 Tajo 이야기MelOn 빅데이터 플랫폼과 Tajo 이야기
MelOn 빅데이터 플랫폼과 Tajo 이야기Gruter
 
Introduction to Apache Tajo: Future of Data Warehouse
Introduction to Apache Tajo: Future of Data WarehouseIntroduction to Apache Tajo: Future of Data Warehouse
Introduction to Apache Tajo: Future of Data WarehouseGruter
 
Expanding Your Data Warehouse with Tajo
Expanding Your Data Warehouse with TajoExpanding Your Data Warehouse with Tajo
Expanding Your Data Warehouse with TajoGruter
 
Introduction to Apache Tajo: Data Warehouse for Big Data
Introduction to Apache Tajo: Data Warehouse for Big DataIntroduction to Apache Tajo: Data Warehouse for Big Data
Introduction to Apache Tajo: Data Warehouse for Big DataGruter
 
What's New Tajo 0.10 and Its Beyond
What's New Tajo 0.10 and Its BeyondWhat's New Tajo 0.10 and Its Beyond
What's New Tajo 0.10 and Its BeyondGruter
 
Efficient In­‐situ Processing of Various Storage Types on Apache Tajo
Efficient In­‐situ Processing of Various Storage Types on Apache TajoEfficient In­‐situ Processing of Various Storage Types on Apache Tajo
Efficient In­‐situ Processing of Various Storage Types on Apache TajoGruter
 
Data analysis with Tajo
Data analysis with TajoData analysis with Tajo
Data analysis with TajoGruter
 
Gruter TECHDAY 2014 Realtime Processing in Telco
Gruter TECHDAY 2014 Realtime Processing in TelcoGruter TECHDAY 2014 Realtime Processing in Telco
Gruter TECHDAY 2014 Realtime Processing in TelcoGruter
 
Gruter TECHDAY 2014 MelOn BigData
Gruter TECHDAY 2014 MelOn BigDataGruter TECHDAY 2014 MelOn BigData
Gruter TECHDAY 2014 MelOn BigDataGruter
 
Gruter_TECHDAY_2014_04_TajoCloudHandsOn (in Korean)
Gruter_TECHDAY_2014_04_TajoCloudHandsOn (in Korean)Gruter_TECHDAY_2014_04_TajoCloudHandsOn (in Korean)
Gruter_TECHDAY_2014_04_TajoCloudHandsOn (in Korean)Gruter
 
Gruter_TECHDAY_2014_03_ApacheTajo (in Korean)
Gruter_TECHDAY_2014_03_ApacheTajo (in Korean)Gruter_TECHDAY_2014_03_ApacheTajo (in Korean)
Gruter_TECHDAY_2014_03_ApacheTajo (in Korean)Gruter
 
Gruter_TECHDAY_2014_01_SearchEngine (in Korean)
Gruter_TECHDAY_2014_01_SearchEngine (in Korean)Gruter_TECHDAY_2014_01_SearchEngine (in Korean)
Gruter_TECHDAY_2014_01_SearchEngine (in Korean)Gruter
 
Apache Tajo - BWC 2014
Apache Tajo - BWC 2014Apache Tajo - BWC 2014
Apache Tajo - BWC 2014Gruter
 
Elastic Search Performance Optimization - Deview 2014
Elastic Search Performance Optimization - Deview 2014Elastic Search Performance Optimization - Deview 2014
Elastic Search Performance Optimization - Deview 2014Gruter
 
Hadoop security DeView 2014
Hadoop security DeView 2014Hadoop security DeView 2014
Hadoop security DeView 2014Gruter
 
Vectorized processing in_a_nutshell_DeView2014
Vectorized processing in_a_nutshell_DeView2014Vectorized processing in_a_nutshell_DeView2014
Vectorized processing in_a_nutshell_DeView2014Gruter
 
Big Data Camp LA 2014 - Apache Tajo: A Big Data Warehouse System on Hadoop
Big Data Camp LA 2014 - Apache Tajo: A Big Data Warehouse System on HadoopBig Data Camp LA 2014 - Apache Tajo: A Big Data Warehouse System on Hadoop
Big Data Camp LA 2014 - Apache Tajo: A Big Data Warehouse System on HadoopGruter
 
Hadoop Summit 2014: Query Optimization and JIT-based Vectorized Execution in ...
Hadoop Summit 2014: Query Optimization and JIT-based Vectorized Execution in ...Hadoop Summit 2014: Query Optimization and JIT-based Vectorized Execution in ...
Hadoop Summit 2014: Query Optimization and JIT-based Vectorized Execution in ...Gruter
 
Cloumon sw제품설명회 발표자료
Cloumon sw제품설명회 발표자료Cloumon sw제품설명회 발표자료
Cloumon sw제품설명회 발표자료Gruter
 
Tajo case study bay area hug 20131105
Tajo case study bay area hug 20131105Tajo case study bay area hug 20131105
Tajo case study bay area hug 20131105Gruter
 

Plus de Gruter (20)

MelOn 빅데이터 플랫폼과 Tajo 이야기
MelOn 빅데이터 플랫폼과 Tajo 이야기MelOn 빅데이터 플랫폼과 Tajo 이야기
MelOn 빅데이터 플랫폼과 Tajo 이야기
 
Introduction to Apache Tajo: Future of Data Warehouse
Introduction to Apache Tajo: Future of Data WarehouseIntroduction to Apache Tajo: Future of Data Warehouse
Introduction to Apache Tajo: Future of Data Warehouse
 
Expanding Your Data Warehouse with Tajo
Expanding Your Data Warehouse with TajoExpanding Your Data Warehouse with Tajo
Expanding Your Data Warehouse with Tajo
 
Introduction to Apache Tajo: Data Warehouse for Big Data
Introduction to Apache Tajo: Data Warehouse for Big DataIntroduction to Apache Tajo: Data Warehouse for Big Data
Introduction to Apache Tajo: Data Warehouse for Big Data
 
What's New Tajo 0.10 and Its Beyond
What's New Tajo 0.10 and Its BeyondWhat's New Tajo 0.10 and Its Beyond
What's New Tajo 0.10 and Its Beyond
 
Efficient In­‐situ Processing of Various Storage Types on Apache Tajo
Efficient In­‐situ Processing of Various Storage Types on Apache TajoEfficient In­‐situ Processing of Various Storage Types on Apache Tajo
Efficient In­‐situ Processing of Various Storage Types on Apache Tajo
 
Data analysis with Tajo
Data analysis with TajoData analysis with Tajo
Data analysis with Tajo
 
Gruter TECHDAY 2014 Realtime Processing in Telco
Gruter TECHDAY 2014 Realtime Processing in TelcoGruter TECHDAY 2014 Realtime Processing in Telco
Gruter TECHDAY 2014 Realtime Processing in Telco
 
Gruter TECHDAY 2014 MelOn BigData
Gruter TECHDAY 2014 MelOn BigDataGruter TECHDAY 2014 MelOn BigData
Gruter TECHDAY 2014 MelOn BigData
 
Gruter_TECHDAY_2014_04_TajoCloudHandsOn (in Korean)
Gruter_TECHDAY_2014_04_TajoCloudHandsOn (in Korean)Gruter_TECHDAY_2014_04_TajoCloudHandsOn (in Korean)
Gruter_TECHDAY_2014_04_TajoCloudHandsOn (in Korean)
 
Gruter_TECHDAY_2014_03_ApacheTajo (in Korean)
Gruter_TECHDAY_2014_03_ApacheTajo (in Korean)Gruter_TECHDAY_2014_03_ApacheTajo (in Korean)
Gruter_TECHDAY_2014_03_ApacheTajo (in Korean)
 
Gruter_TECHDAY_2014_01_SearchEngine (in Korean)
Gruter_TECHDAY_2014_01_SearchEngine (in Korean)Gruter_TECHDAY_2014_01_SearchEngine (in Korean)
Gruter_TECHDAY_2014_01_SearchEngine (in Korean)
 
Apache Tajo - BWC 2014
Apache Tajo - BWC 2014Apache Tajo - BWC 2014
Apache Tajo - BWC 2014
 
Elastic Search Performance Optimization - Deview 2014
Elastic Search Performance Optimization - Deview 2014Elastic Search Performance Optimization - Deview 2014
Elastic Search Performance Optimization - Deview 2014
 
Hadoop security DeView 2014
Hadoop security DeView 2014Hadoop security DeView 2014
Hadoop security DeView 2014
 
Vectorized processing in_a_nutshell_DeView2014
Vectorized processing in_a_nutshell_DeView2014Vectorized processing in_a_nutshell_DeView2014
Vectorized processing in_a_nutshell_DeView2014
 
Big Data Camp LA 2014 - Apache Tajo: A Big Data Warehouse System on Hadoop
Big Data Camp LA 2014 - Apache Tajo: A Big Data Warehouse System on HadoopBig Data Camp LA 2014 - Apache Tajo: A Big Data Warehouse System on Hadoop
Big Data Camp LA 2014 - Apache Tajo: A Big Data Warehouse System on Hadoop
 
Hadoop Summit 2014: Query Optimization and JIT-based Vectorized Execution in ...
Hadoop Summit 2014: Query Optimization and JIT-based Vectorized Execution in ...Hadoop Summit 2014: Query Optimization and JIT-based Vectorized Execution in ...
Hadoop Summit 2014: Query Optimization and JIT-based Vectorized Execution in ...
 
Cloumon sw제품설명회 발표자료
Cloumon sw제품설명회 발표자료Cloumon sw제품설명회 발표자료
Cloumon sw제품설명회 발표자료
 
Tajo case study bay area hug 20131105
Tajo case study bay area hug 20131105Tajo case study bay area hug 20131105
Tajo case study bay area hug 20131105
 

GRUTER가 들려주는 Big Data Platform 구축 전략과 적용 사례: 인터넷 쇼핑몰의 실시간 분석 플랫폼 구축 사례

  • 1. © 2013 Gruter. All rights reserved. 실시간 분석 플랫폼 구축 사례 2013.08.28 김형준 수석 연구원
  • 2. © 2013 Gruter. All rights reserved. 요구사항 • 실시간 데이터 수집 • 수집 단계에서 실시간 데이터 분석 • 실시간 분석 결과 실시간 데이터 제공 • 수집된 데이터 안정적 저장 • 저장소 데이터 배치 분석 • 저장소 데이터 검색 • 전체 클러스터 관리 및 모니터링 2
  • 3. © 2013 Gruter. All rights reserved. 전체 아키텍처 3 웹 로그 수집 서버 WAS log Agent 로그 Collector Flume Collector 분석 결과 저장소 검색 저장소 TCP UDP FTP HDFS Search Real Time 원본 파일 저장소 로그 Collector Flume Collector TCP UDP FTP HDFS Search Real Time 실시간 분석 Application Server 사용자 행동 분석 로직 실시간 분석 클러스터 실시간 분석 Application Server 실시간 분석 로직 HBase (NoSQL) Table Table Table ElasticSearch Latest Index Backup Index Hadoop File System Hive Table A Hive Table B 배치분석 Hadoop MapReduce Map Reduce 클러스터 관리 ZooKeeper Cloumon Hive 질의 MySQL
  • 4. © 2013 Gruter. All rights reserved. 실시간 분석 예 #1 • 구글 애널리틱스 4
  • 5. © 2013 Gruter. All rights reserved. 실시간 분석 예 #2 • 페이스북 Social-Plugin 5 수집 실시간분석 실시간 Feedback 배치분석 process over 20 billion events per day (200,000 events per second) with a lag of less than 30 seconds. Analytic Transactional
  • 6. © 2013 Gruter. All rights reserved. 실시간 분석 예 #3 • SNS 전파 경로 분석 6
  • 7. © 2013 Gruter. All rights reserved. 현실은? • 가장 기본적인 로그 조차도 일 단위 분석 – HTTP LOG 등 • 비즈니스에 중요한 데이터는 로그도 없음 • 일부 로그는 외부 업체로 전달 7
  • 8. © 2013 Gruter. All rights reserved. 실시간 분석의 어려움 #1 • 중복, 유실, 성능 모두를 만족시키기 어려움 – 이중화된 큐와 체크 포인팅 기능이 핵심 – 체크 포인팅을 많이 사용하면 성능 저하 적게 사용하면 유실율 이 높아짐 • 성능 – 대량의 데이터 – 분석의 복잡성(다양한 메타 데이터와 연계 등) • 운영 관리 – 무정지로 운영 되어야 함 – 비즈니스 로직 변경에 따른 배포 • 분석 결과 저장 – 체크 포인트 – 최종 결과 – 시각화 8
  • 9. © 2013 Gruter. All rights reserved. 실시간 분석의 어려움 #2 • 시간 관리 – 분산된 환경의 시간 동기화 – Time window 동기화 – Data time vs. System time • 분석 로직 구현 – SQL 기반 – 프로그램 기반 • 플랫폼들의 조합 – Flume, Storm, Kafka 등 – 각 솔루션은 HA 등에 대한 기능 제공 – But, 조합 시 불협화음 – 서버 사이징 • Agent/Collelctor 댓수 비율, CPU/Network 등 9
  • 10. © 2013 Gruter. All rights reserved. 참조 아키텍처 #1 • Facebook Social Plugin 10 /category1/collect_1.dat /category1/collect_2.dat /category1/collect_3.dat 데이터 수집기 (scribe) 데이터 수집기 (scribe) 데이터 수집기 (scribe) Hadoop Write, sync Key1: value Key2: value Key3: value HBase ptail Driver Aggregation Store Checkpoint Handler Storage Thrift Server 클라이언트
  • 11. © 2013 Gruter. All rights reserved. 참조 아키텍처 #2 11 http://highlyscalable.wordpress.com/2013/08/20/in-stream-big-data-processing/
  • 12. © 2013 Gruter. All rights reserved. 개발 시스템 아키텍처 12 ZooKeeper 분석 결과 저장소 (HBase) Realtime Server Partition Proxy Partitioner Processor Engine User Processor ReplicatorQueue Time Window Manager (Master Role) Flume Collector Realtime Client Partition #2 Partition #1 Partition #3 Flume Collector Realtime Client Dimension Data memory
  • 13. © 2013 Gruter. All rights reserved. 구성 요소 • Realtime Server – 외부로부터 데이터를 수신하여 사용자가 개발한 분석 프로그램을 실행해주는 데몬 프로세스 – 여러 대의 물리적인 서버에 분산 배치 – 서버 자체는 분석 기능을 가지고 있지 않음 – 서버 장애를 대비하여 서버 별로 Slave 서버를 구성할 수 있음 • Cluster Master – 클러스터 중 한대가 마스터 역할 수행, 자동으로 Master가 선정 – 서버 장애 시 Partition Master/Slave failover 수행 – 작업 그룹의 Flush 주기에 따라 Flush Scheduler 수행 – 서버 사이의 타임 동기화 작업 – 파티션 추가 및 제거 등 클러스터 관리 작업 • Realtime Client – 실시간 분석 클러스터로 분석 대상 데이터를 전송하는 프로그램에서 사용하는 모듈 • ZooKeeper(시스템 외부) – 클러스터의 전체 서버 상태 정보, Workgroup 정보 등 클러스터를 운영하는데 필요한 메타 정보 관 리 – Flush 이벤트 등 이벤트 전송 • 분석 결과 저장소(시스템 외부) – 분석 결과를 저장하는 저장소 – 동시 저장 데이터가 많고 분석 서버가 많은 경우 HBase와 같은 분산 데이터 저장소 사용 – 결과 데이터가 작고 결과를 다양한 질의로 통해 조회하는 경우 MySQL과 같은 RDBMS 사용 13
  • 14. © 2013 Gruter. All rights reserved. 특징 • 고정된 크기의 클러스터 파티션 – 각 서버는 시작 시 지정된 파티션 ID를 가짐 – 데이터 파티션 처리 쉬운 장점 – 서버 추가/제거는 Shell 명령을 가능 • 파티션 이중화 – 하나의 파티션은 두 개의 서버가 담당(Master/Slave) • 분산 실시간 분석에 필요한 다양한 모듈 기본 제공 – 분산된 서버들 사이에 동기화된 Flush 기능 – Time 동기화 기능 – SQL-Like 질의 기반 분석 도구인 Esper와 연계 모듈 • WorkGroup – 하나의 분석을 수행하기 위해서는 여러 개의 분석 모듈이 연결 되어야 함. – 하나의 클러스터로 여러 개의 분석 업무를 동시에 수행 • 자체 개발 – 공개된 실시간 분석 솔루션은 다음 기능 제공 • 데몬 서버, 데이터 송수신 RPC, 프로그램 모델, 데이터 파티셔닝, Queue와 연동 – 활용 가능한 조각 모음은 대부분 오픈 소스로 나와 있음 • RPC: Thrift, Avro, Protobuf, Netty • Event, Cluster Membership, Synchronization : ZooKeeper • Query Processing: Esper • Queue: Kafka, RabbitMQ, ZeroMQ 14
  • 15. © 2013 Gruter. All rights reserved. 데이터 처리 흐름 15 Log Parsing Log Parsing Log Parsing log data URL, Count(1) Group by URL URL, Count(1) Group by URL Count (Distinct User) Count (Distinct User) HBase Table TOP 100 Order by count Desc hash(url) time batch 60 sec. hash(user_id) time batch 20 sec.WorkGroup #2 (LogType=User) WorkGroup #1 (LogType=URL) IP-City DataLoad in memory
  • 16. © 2013 Gruter. All rights reserved. 분석 프로그램 예시 16 public class WordCountProcessor extends AnalysisProcessor { private Map<String, Integer> wordCountMap = new HashMap<String, Integer>(); public String getWorkGroupName() { return "wordcountGroup"; } public String getEventType() { return "wordcount"; } public int getPartitionId(EventParsedRecord eventParsedRecord, int numPartition, int serverId) { return getHashPartitionId(eventParsedRecord.getKey(), numPartition); } public EventParsedRecord parseEvent(String event) throws IOException { EventParsedRecord eventParsedRecord = new EventParsedRecord(); eventParsedRecord.setKey(event); return eventParsedRecord; } public void process(String type, EventParsedRecord eventParsedRecord, boolean serverPairMaster) { Integer count = wordCountMap.get(eventParsedRecord.getKey()); if(count == null) wordCountMap.put(eventParsedRecord.getKey(), 1); else wordCountMap.put(eventParsedRecord.getKey(), count + 1); } public void flush(long flushTime, boolean serverPartitionMaster) throws IOException { if(serverPartitionMaster) { for(Map.Entry<String, Integer> entry: wordCountMap.entrySet()) { HBaseStore.store(“T_WORD_COUNT”, entry.getKey() + ”,“ + entry.getValue()); } } }
  • 17. © 2013 Gruter. All rights reserved. 결론 • 실시간 분석은 대세이지만 많은 난관이 존재 – 고객의 요구(정합성, 안정성 모두 만족 등) – 메타 정보(JOIN) 처리 성능 – 운영의 어려움(항상 데이터가 흘러 다님) • 분석 대상 데이터의 속성, 분석 로직 등에 따라 적절한 플랫폼 선택 – 플랫폼은 기본만 제공 – 많은 것을 그 위에 만들어야 함 – 적절한 플랫폼이 없으면 만드는 것도 방법 17
  • 18. GRUTER: YOUR PARTNER IN THE BIG DATA REVOLUTION Phone +82-70-8129-2950 Fax +82-70-8129-2952 E-mail contact@gruter.com Web www.gruter.com © 2013 Gruter. All rights reserved. Gruter, Inc. 5F Sehwa Office Building 889-70 Daechi-dong, Gangnam-gu, Seoul, South Korea 135-839