SlideShare ist ein Scribd-Unternehmen logo
1 von 61
Downloaden Sie, um offline zu lesen
© Copyright 2018 Pivotal Software, Inc. All rights Reserved.
Cloud Native 서비스를 위한 도구들
김민석
2018/05/10
https://pf.kakao.com/_nixhxoxl
September 24–27, 2018
Washington DC
Gaylord, National Harbor
Discount Code
S1P200_MKim
Hear more of
cases & tactics
like these, plus
nerd stuff.
Register Today
& Save!
Spring Camp 2018 4
2018년 11월 12-13 Seoul
springonetour.io
소개
• 김민석 (myminseok@gmail.com)
• Platform Architect @ Pivotal
• Big-Data Monitoring System Developer
• Software Architect
• Software Quality Engineer
• Developer
https://www.facebook.com/groups/CloudfoundryKorea
“Pivotal is currently contributing as much software
to open source projects as IBM.”
Source: https://redmonk.com/jgovernor/2017/10/25/some-thoughts-on-the-top-contributors-to-github-2017/
전 세계의 2,500명이 넘는 Pivotal의 개발자들은 다양한 오픈소스 프로젝트에 깊게 기여하고
있음
Process &
Culture
Build for
change
DevOps Tools
Continuously
Improve
Platform
Any App, Every Cloud,
One Platform
Pivotal Cloud
Foundry
Tracker / Spring / Concourse
Pivotal Labs
Data / AI
Apps
Open Source Based
Data
Pivotal Big
Data Suites
Customer
Insight
Dojo
개발자 중심의 실리콘 밸리 기업인 Pivotal은 디지털 변혁을 위한 1) 문화/프로세스, 2) 기술 플랫
폼, 3) DevOps 툴 및 4) 데이터 분석에 걸쳐 다양한 Offering을 제공 하고 있음
Pivotal
Data Science
5조원 21 +2,500
시가총액 글로벌 오피스 개발자
1/3 이상의..
Pivotal Overview
Fortune 100 회사가 Pivotal과 함께 일하고 있습니다.
7 of the largest banks / payments
9 of the largest automakers
7 of the largest insurers
8 of the largest retailers
9 of the largest telcos
Pivotal Customers
Agenda
■  이번 밋업에서 다루는 도구들
■  마이크로서비스 기반서비스
■  모니터링 및 통합로그수집
■  장애 내성을 키워주는 도구
■  Q&A
이번 밋업에서 다루는 도구들
우리의 IT환경은 점점
•  마이크로 서비스팀이 점점 작아지고 많아짐
•  API contract 개선이 더 잦아짐(Agile)
•  다른 시간대(Timezone)의 팀간의 협업이 요구됨
Cloud Native 시스템 운영을 위한 도구들은
■  앱 자동배포
■  MSA를 위한 기반 서비스
■  On-demand backing service
■  실시간 모니터링
■  중앙집중형 통합로그
개발자의 속도
■  VM, 로드밸런서, IP관리 자동화
■  플랫폼 설치 자동화
■  App, VM,AZ까지의 고가용성
■  플랫폼/서비스 통합 모니터링
■  중앙집중형 통합로그
■  Autoscaling
■  플랫폼 무중단 업데이트
■  신속한 보안패치
■  컨테이너 보안
■  Credentials 관리및 rotate
운영자의 안정성
Cloud native 서비스를 도와주는 도구들.
Customer
Service
Loyalty
Service
Notifications
Service
Other…
Create Loyalty Bank
Send Email
Email
Service
Post
Service
Generate Mail
Other Actions
Backend for
Frontend
Backend for
Frontend
Backend for
Frontend
Backend for
Frontend
Service
Adaptor1
Adaptor2
Translator
Config Registry
CB
Dashboard
Compliance …..
Saboteur
Vizceral
Spring Boot Admin
Microservice Dashboard
MSA 기반 서비스
MSA를 위한 기반 서비스
Web
Frontend
Customer
Service
Loyalty
Service
Notifications
Service
Other…
Create Loyalty Bank
Send Email
Email
Service
Post
Service
Generate Mail
Other Actions
Mobile
Wearables
Echo
3rd Party
Backend for
Frontend
Backend for
Frontend
Backend for
Frontend
Backend for
Frontend
ESB
Payments
Other
Service
Adaptor1
Adaptor2
Translator
LegacyCore Business uServicesAPI Gateway uServices Anti Corruption uServices
Config Registry
CB
Dashboard
Compliance ….. ……
Foundational uServices
Spring boot기반 앱의 모니터링과 관리를 위한 라이브러리
Spring Boot Actuator 1.x Spring Boot Actuator 2.x
• Spring MVC • Spring MVC
• Spring WebFlux
• Jersey
<dependency>!
<groupId>org.springframework.boot</groupId>!
<artifactId>spring-boot-starter-actuator</artifactId>!
</dependency>!
Spring Boot Actuator
16
•  auditevents
•  beans
•  conditions
•  Configprops
•  env
•  health
•  httptrace
•  flyway
https://docs.spring.io/spring-boot/docs/current/reference/html/production-ready-endpoints.html
•  info
•  loggers
•  liquibase
•  metrics
•  mappings
•  scheduledtasks
•  sessions
•  shutdown
•  threaddump
•  heapdump
•  jolokia
•  logfile
•  prometheus
Spring Boot Actuator
management.endpoint.health.show-details=when_authorized!
when authorized
http://IP:PORT/actuator/health
With PCFWithout PCF
Config Server Service
Registry
(Eureka)
Circuit Breaker
(Hystrix)
개발자가 배포 및 보안 관리 플랫폼이 배포 및 보안 관리
Config Server Service Registry
(Eureka)
Circuit Breaker
(Hystrix)
MSA기반 서비스의 사용예
Config Server
application.yml
•  hello-server-dev.yml
•  hello-server-stage.yml
•  hello-server-prod.yml
hello-server-dev hello-server-stage hello-server-prod
refresh w/ curl
앱의 장애확산을 방지하며, 서비스 상태를 통합하여 대쉬보
드로 보여주는 Circuit Breaker, hystrix dashboard , turbine
Circuit Breaker 메트릭을 통합해주는 turbine
분산 추적용 ZipKin
분산 추적용 ZipKin
넷플릭스 오픈소스 도구 중 하나인 Vizceral 의 동작 영상을 살펴보면 이런 구조를 쉽게 살펴볼 수 있습니다.
왼쪽은 AWS 각 리전에 분포한 트래픽, 오른쪽은 각 리전 내부의 트래픽 흐름 입니다.
플릭스 오픈소스 도구 중 하나인 Vizceral
모니터링 및 통합로그수집
Spring Boot Admin
https://github.com/codecentric/spring-boot-admin
Microservice Dashbord- Why?
https://github.com/ordina-jworks/microservices-dashboard
Microservice Dashbord
https://github.com/ordina-jworks/microservices-dashboard
http://ordina-jworks.github.io/microservices-dashboard/1.0.1/
분산시스템을 위한 모니터링 도구 - Prometheus
•  SoundCloud에서 개발하여 오픈소스화
•  multi-dimensional data model 데이터가 host, service, endpoint, method단위로 조합이
되어서 multi-dimensional data model이 제공
•  Operational simplicity 설설치가 쉬운 모니터링 정관리가 쉬워서 박사학위가 없어도 될 정도로
•  Scalable and decentralized
•  powerful query language 시각화와 의미있는 알림을 줄 수 있는 데이터모델, Query.
https://ordina-jworks.github.io/monitoring/2016/09/23/Monitoring-with-Prometheus.html
https://prometheus.io/docs/introduction/comparison/
모니터링 도구 특징
Server polls Client pushes
Prometheus
Atlas, Datadog, Datadog StatsD,
Influx, SignalFx, Telegraf StatsD,
Wavefront, New Relic
Dimensional
Graphite, Ganglia, JMX, Etsy StatsD,
PCF Metrics 1.4
Hierarchical
Prometheus at a glance
Prometheus
Alerting: custom example
Alerting: Notifications
Prometheus at a glance
Prometheus 자동 설치 및 Cloud Foundry 플랫폼 모니터링 자동화
https://github.com/myminseok/pcf-prometheus-pipeline
https://github.com/bosh-prometheus/prometheus-
boshrelease
Cloud Foundry상의 모든 메트릭을 시각화/알림
•  VM메트릭 (node_exporter)
•  Process Metric (Bosh_exporter)
•  App metric (cf_exporter)
Prometheus Use Case
Prometheus best practices
•  대시보드 하나에 5개 미만 그래프유지
•  각 그래프에 5개 Plots(lines)이하 유지
•  유용하지 않은 데이터는 제거
•  용도별 대시보드 분리( 개발용, 운영용)
•  알림은 간단히, 엔드유져가 느끼는 현상 중심으로, 문제파악에 도움이 되는 요소를 링크로 포함.
•  Pushgateway는 SPOF이므로 필요한 곳에 사용
•  네트워크 분리의 경우 같은망에 Prometheus서버 구성
https://prometheus.io/docs/practices/consoles/
벤더 중립적인 애플리케이션 메트릭 수집
39
•  JVM based Application code
•  Dimensional Metrics
•  Integrated into Spring
•  Support for popular monitoring system (no vendor lock-in)
https://micrometer.io/
•  Prometheus
•  Netflix Atlas
•  CloudWatch
•  Datadog
•  Graphite
•  Ganglia
•  JMX
•  Influx/Telegraf
•  New Relic
•  StatsD
•  SignalFx
•  Wavefront
Prometheus by micrometer
<dependency>!
<groupId>io.micrometer</groupId>!
<artifactId>micrometer-registry-prometheus</artifactId>!
</dependency>!
/actuator/prometheus
system_cpu_count 4.0
system_load_average_1m 1.64
jvm_memory_max_bytes{area="heap",id="PS Eden Space",} 1.05906176E8
jvm_memory_max_bytes{area="heap",id="PS Survivor Space",} 2.1495808E7
jvm_memory_max_bytes{area="heap",id="PS Old Gen",} 3.00941312E8
http_server_requests_seconds_count{exception="None",method="GET",status=
"200",uri="/hello",} 4469.0
http_server_requests_seconds_sum{exception="None",method="GET",status="2
00",uri="/hello",} 297.942920787
http_server_requests_seconds_max{exception="None",method="GET",status="2
00",uri="/hello",} 0.401581731
https://docs.spring.io/spring-boot/docs/2.0.x/reference/html/production-ready-metrics.html#production-ready-metrics
Prometheus alert예
ELK Architecture
http://trustmeiamadeveloper.com/2014/12/20/elk-as-a-software-monitoring-tool/
통합로그 수집- ELK
장애 내성을 키워주는 도구
서비스 장애 주입 - Trouble maker
https://keyholelabs.com/trouble-maker/
https://github.com/in-the-keyhole/khs-trouble-maker
https://github.com/in-the-keyhole/khs-spring-boot-troublemaker-starter
Netflix Chaos Monkey는 EC2 API에 제한
Cloud에 독립적
Service registry연동
스케줄링 기능
랜덤 장애발생
-  KILL
-  LOAD
-  Memory
-  Exception
서비스 장애 주입 - Trouble maker
https://github.com/in-the-keyhole/khs-trouble-maker
https://github.com/in-the-keyhole/khs-spring-boot-troublemaker-starter
네트워크 장애주입 - Saboteur
Saboteur: https://github.com/tomakehurst/saboteur
Vagrant wiremock saboteur https://github.com/chbatey/vagrant-wiremock-saboteur
네트워크 장애 주입 도구로서 장애 내성 및 안정성 테스트를 간단하게 하여줌
•  Total network partition
•  Remote service dead (not listening on the expected port)
•  Delays
•  Packet loss
•  TCP connection timeout (as often happens when two systems are
separated by a stateful firewall)
•  Support Linux only
네트워크 장애주입 - Saboteur
Saboteur: https://github.com/tomakehurst/saboteur
Vagrant wiremock saboteur https://github.com/chbatey/vagrant-wiremock-saboteur
Vagrant 테스트 시뮬레이션 환경
Saboteur
Wiremock server
Iptables, tc
$ cd vagrant-wiremock-saboteur/vm
$ curl 192.168.2.2:8080/name
eth1
$ rpm -ivh https://github.com/tomakehurst/saboteur/releases/download/v0.7/saboteur-0.7-1.noarch.rpm
$ service saboteur-agent start
MSA 운영을 위한 최적의 플랫폼
Pivotal Cloud Foundry
애플리케이션이 컨테이너에 배포되고 관리되는 과정
코드 및 테스트 완료 후 해야하는 일
가용한 호스트 찾기
Docker image 설정
Docker 허브에 로그인
원하는 OS를 포함하는 Docker 이미지 받기
Docker 컨테이너 내부로 진입해서 OS 업데이트
필요한 런타임 수동 설치
Docker 이미지를 허브에 올리기
컨테이너를 호스트에 배포
환경 변수 설정
로드발란서 구성
SSL 생성
방화벽 구성
서비스 모니터링 도구 갱신
로그 수집기 구성
스케일링
애플리케이션이 컨테이너에 배포되고 관리되는 전과정을 플랫폼에 위임하
고 개발자는 코드개발에 집중합니다.
cf push
~ 45 seconds
Speed &
Consistency
코드 및 테스트 완료 후 해야하는 일
가용한 호스트 찾기
Docker image 설정
Docker 허브에 로그인
원하는 OS를 포함하는 Docker 이미지 받기
Docker 컨테이너 내부로 진입해서 OS 업데이트
필요한 런타임 수동 설치
Docker 이미지를 허브에 올리기
컨테이너를 호스트에 배포
환경 변수 설정
로드발란서 구성
SSL 생성
방화벽 구성
서비스 모니터링 도구 갱신
로그 수집기 구성
스케일링
Platform의 빌드팩(Build-Pack)
•  앱을 구동하기 위해 필요한 Dependency(JVM, Tomcat,
Apache 등)를 미리 구축해 놓는 것이 아닌, 앱을 배포하는 시점
에 앱에서 필요한 정확한 Dependency(라이브러리, JVM, 미들
웨어 등)를 Build-pack에서 찾아 설치하여 사용하게 함
•  빌드팩 역시 개발/스테이징/운영 환경을 별도로 관리하며, 이를
통해 환경의 일치를 구성할 수 있음
•  Self-Contained App형태로 운영 가능하도록 하여 즉시적으로
Deploy할 수 있는 형태
Platform의 Cloud Controller
•  플랫폼에서 컨테이너 생성, 환경변수 설정, 라우팅 설정, 방화벽
구성, 로그 수집등의 앱 구동을 위한 스텝 지원
•  이 후, 앱 운영(Operation)에 필요한 HA/Scaling 지원
Spring boot support
https://docs.spring.io/spring-boot/docs/2.0.x/reference/html/production-ready-cloudfoundry.html
PCF에서 기본으로 제공되는 MSA기반 서비스 PCF
앱 성능 분석 및 통합로그수집 - PCF metrics
분산 추적 및 통합로그수집 - PCF metrics
플랫폼 운영자를 위해 플랫폼의 현재상황/메트릭 추이를 한눈에 보여주는 대시보드를 제공하여 플랫폼 운영
의 통찰을 제공
§  End User Impact
- Http Request Throughput, Latency
- Router CPU
- 502 bad gateway
§  Developer Impact
- cf command line도구의 응답성능
- 어플리케이션 배포공간 잔여용량(메모리, 디스크)
- 총 container수
§  Platform Impact
- 플랫폼 컴포넌트 health 상태
- 플랫폼 구성요수의 리소스 사용량(메모리, 디스크)
플랫폼 운영자를 위해 플랫폼의 현재상황/메트릭 추이를 한눈에 보여주는 대시보드를 제공하여 플랫폼 운영
의 통찰을 제공
§  End User Impact
- Http Request Throughput, Latency
- Router CPU
- 502 bad gateway
§  Developer Impact
- cf command line도구의 응답성능
- 어플리케이션 배포공간 잔여용량(메모리, 디스크)
- 총 container수
§  Platform Impact
- 플랫폼 컴포넌트 health 상태
- 플랫폼 구성요수의 리소스 사용량(메모리, 디스크)
DIY Cloud Native Platform Reference Architecture
Same Reference Arch with Pivotal Cloud Foundry
60
Transforming How The World Builds Software
© Copyright 2017 Pivotal Software, Inc. All rights Reserved.

Weitere ähnliche Inhalte

Was ist angesagt?

Was ist angesagt? (20)

Cloud native application 입문
Cloud native application 입문Cloud native application 입문
Cloud native application 입문
 
Spring Project와 최신 Pivotal Cloud Foundry 업데이트
Spring Project와 최신 Pivotal Cloud Foundry 업데이트 Spring Project와 최신 Pivotal Cloud Foundry 업데이트
Spring Project와 최신 Pivotal Cloud Foundry 업데이트
 
Pcf 1page 201501
Pcf 1page 201501Pcf 1page 201501
Pcf 1page 201501
 
Sources와 Sinks를 Confluent Cloud에 원활하게 연결
Sources와 Sinks를 Confluent Cloud에 원활하게 연결Sources와 Sinks를 Confluent Cloud에 원활하게 연결
Sources와 Sinks를 Confluent Cloud에 원활하게 연결
 
클라우드 네이티브를 위한 필요사항과 Pivotal 제안 - 이우상
클라우드 네이티브를 위한 필요사항과 Pivotal 제안 - 이우상클라우드 네이티브를 위한 필요사항과 Pivotal 제안 - 이우상
클라우드 네이티브를 위한 필요사항과 Pivotal 제안 - 이우상
 
GitLab Premium 라이선스 기능소개 - 인포그랩
GitLab Premium 라이선스 기능소개 - 인포그랩GitLab Premium 라이선스 기능소개 - 인포그랩
GitLab Premium 라이선스 기능소개 - 인포그랩
 
애플리케이션 최적화를 위한 컨테이너 인프라 구축
애플리케이션 최적화를 위한 컨테이너 인프라 구축애플리케이션 최적화를 위한 컨테이너 인프라 구축
애플리케이션 최적화를 위한 컨테이너 인프라 구축
 
Pivotal 101세미나 발표자료 (PAS,PKS)
Pivotal 101세미나 발표자료 (PAS,PKS) Pivotal 101세미나 발표자료 (PAS,PKS)
Pivotal 101세미나 발표자료 (PAS,PKS)
 
클라우드 네이티브 IT를 위한 4가지 요소와 상관관계 - DevOps, CI/CD, Container, 그리고 MSA
클라우드 네이티브 IT를 위한 4가지 요소와 상관관계 - DevOps, CI/CD, Container, 그리고 MSA클라우드 네이티브 IT를 위한 4가지 요소와 상관관계 - DevOps, CI/CD, Container, 그리고 MSA
클라우드 네이티브 IT를 위한 4가지 요소와 상관관계 - DevOps, CI/CD, Container, 그리고 MSA
 
[열린기술공방] Container기반의 DevOps - 클라우드 네이티브
[열린기술공방] Container기반의 DevOps - 클라우드 네이티브[열린기술공방] Container기반의 DevOps - 클라우드 네이티브
[열린기술공방] Container기반의 DevOps - 클라우드 네이티브
 
[OpenInfra Days Korea 2018] (Track 4) - FreeIPA와 함께 SSO 구성
[OpenInfra Days Korea 2018] (Track 4) - FreeIPA와 함께 SSO 구성[OpenInfra Days Korea 2018] (Track 4) - FreeIPA와 함께 SSO 구성
[OpenInfra Days Korea 2018] (Track 4) - FreeIPA와 함께 SSO 구성
 
꿀밋업2탄_도메인 모델에 따른 데이터 분리 저장과 API 연결
꿀밋업2탄_도메인 모델에 따른 데이터 분리 저장과 API 연결꿀밋업2탄_도메인 모델에 따른 데이터 분리 저장과 API 연결
꿀밋업2탄_도메인 모델에 따른 데이터 분리 저장과 API 연결
 
[OpenInfra Days Korea 2018] Day 2 - E5: GPU on Kubernetes
[OpenInfra Days Korea 2018] Day 2 - E5: GPU on Kubernetes[OpenInfra Days Korea 2018] Day 2 - E5: GPU on Kubernetes
[OpenInfra Days Korea 2018] Day 2 - E5: GPU on Kubernetes
 
객체지향프로그래밍 특강
객체지향프로그래밍 특강객체지향프로그래밍 특강
객체지향프로그래밍 특강
 
GitLab Ultimate 라이선스 기능소개 - 인포그랩
GitLab Ultimate 라이선스 기능소개 - 인포그랩GitLab Ultimate 라이선스 기능소개 - 인포그랩
GitLab Ultimate 라이선스 기능소개 - 인포그랩
 
Atlassian cloud 제품을 이용한 DevOps 프로세스 구축
Atlassian cloud 제품을 이용한 DevOps 프로세스 구축Atlassian cloud 제품을 이용한 DevOps 프로세스 구축
Atlassian cloud 제품을 이용한 DevOps 프로세스 구축
 
Spring Camp 2017 - DevOps for everyone
Spring Camp 2017 - DevOps for everyoneSpring Camp 2017 - DevOps for everyone
Spring Camp 2017 - DevOps for everyone
 
Open infradays 2019_msa_k8s
Open infradays 2019_msa_k8sOpen infradays 2019_msa_k8s
Open infradays 2019_msa_k8s
 
[OpenInfra Days Korea 2018] (Track 1) From OpenStack to cloud native
[OpenInfra Days Korea 2018] (Track 1) From OpenStack to cloud native[OpenInfra Days Korea 2018] (Track 1) From OpenStack to cloud native
[OpenInfra Days Korea 2018] (Track 1) From OpenStack to cloud native
 
Private PaaS with Docker, spring cloud and mesos
Private PaaS with Docker, spring cloud and mesos Private PaaS with Docker, spring cloud and mesos
Private PaaS with Docker, spring cloud and mesos
 

Ähnlich wie Meetup tools for-cloud_native_apps_meetup20180510-vs

Open standard open cloud engine (3)
Open standard open cloud engine (3)Open standard open cloud engine (3)
Open standard open cloud engine (3)
uEngine Solutions
 
[Td 2015]구름 위로 올려 어느 곳에서든 연결되는 서비스 azure 앱 서비스(이종인)
[Td 2015]구름 위로 올려 어느 곳에서든 연결되는 서비스 azure 앱 서비스(이종인)[Td 2015]구름 위로 올려 어느 곳에서든 연결되는 서비스 azure 앱 서비스(이종인)
[Td 2015]구름 위로 올려 어느 곳에서든 연결되는 서비스 azure 앱 서비스(이종인)
Sang Don Kim
 
Open standard open cloud engine for digital business process
Open standard open cloud engine for digital business process Open standard open cloud engine for digital business process
Open standard open cloud engine for digital business process
uEngine Solutions
 
MSA(Service Mesh), MDA(Data Mesh), MIA(Inference Mesh) 기술동향 소개-박문기@메ᄀ...
MSA(Service Mesh), MDA(Data Mesh), MIA(Inference Mesh) 기술동향 소개-박문기@메ᄀ...MSA(Service Mesh), MDA(Data Mesh), MIA(Inference Mesh) 기술동향 소개-박문기@메ᄀ...
MSA(Service Mesh), MDA(Data Mesh), MIA(Inference Mesh) 기술동향 소개-박문기@메ᄀ...
문기 박
 
OCE - Cno 2014 private sector oriented open paas oce
OCE - Cno 2014 private sector oriented open paas   oceOCE - Cno 2014 private sector oriented open paas   oce
OCE - Cno 2014 private sector oriented open paas oce
uEngine Solutions
 
효과적인 데브옵스를 위한 AWS 개발 도구 활용하기 - AWS Summit Seoul 2017
효과적인 데브옵스를 위한 AWS 개발 도구 활용하기 - AWS Summit Seoul 2017효과적인 데브옵스를 위한 AWS 개발 도구 활용하기 - AWS Summit Seoul 2017
효과적인 데브옵스를 위한 AWS 개발 도구 활용하기 - AWS Summit Seoul 2017
Amazon Web Services Korea
 

Ähnlich wie Meetup tools for-cloud_native_apps_meetup20180510-vs (20)

락플레이스 OpenShift Q&A 토크쇼 발표자료
락플레이스 OpenShift Q&A 토크쇼 발표자료락플레이스 OpenShift Q&A 토크쇼 발표자료
락플레이스 OpenShift Q&A 토크쇼 발표자료
 
Openshift 활용을 위한 Application의 준비, Cloud Native
Openshift 활용을 위한 Application의 준비, Cloud NativeOpenshift 활용을 위한 Application의 준비, Cloud Native
Openshift 활용을 위한 Application의 준비, Cloud Native
 
Open standard open cloud engine (3)
Open standard open cloud engine (3)Open standard open cloud engine (3)
Open standard open cloud engine (3)
 
[Td 2015]구름 위로 올려 어느 곳에서든 연결되는 서비스 azure 앱 서비스(이종인)
[Td 2015]구름 위로 올려 어느 곳에서든 연결되는 서비스 azure 앱 서비스(이종인)[Td 2015]구름 위로 올려 어느 곳에서든 연결되는 서비스 azure 앱 서비스(이종인)
[Td 2015]구름 위로 올려 어느 곳에서든 연결되는 서비스 azure 앱 서비스(이종인)
 
Deployment techniques for cloud native
Deployment techniques for cloud nativeDeployment techniques for cloud native
Deployment techniques for cloud native
 
Open standard open cloud engine for digital business process
Open standard open cloud engine for digital business process Open standard open cloud engine for digital business process
Open standard open cloud engine for digital business process
 
designing, implementing and delivering microservices with event storming, spr...
designing, implementing and delivering microservices with event storming, spr...designing, implementing and delivering microservices with event storming, spr...
designing, implementing and delivering microservices with event storming, spr...
 
유엔진 오픈소스 클라우드 플랫폼 (uEngine Microservice architecture Platform)
유엔진 오픈소스 클라우드 플랫폼 (uEngine Microservice architecture Platform)유엔진 오픈소스 클라우드 플랫폼 (uEngine Microservice architecture Platform)
유엔진 오픈소스 클라우드 플랫폼 (uEngine Microservice architecture Platform)
 
[아이펀팩토리]2017 NDC 강연 자료_아이펀 엔진 개발 노트
[아이펀팩토리]2017 NDC 강연 자료_아이펀 엔진 개발 노트[아이펀팩토리]2017 NDC 강연 자료_아이펀 엔진 개발 노트
[아이펀팩토리]2017 NDC 강연 자료_아이펀 엔진 개발 노트
 
[2017 AWS Startup Day] 서버리스 마이크로서비스로 일당백 개발조직 만들기
[2017 AWS Startup Day] 서버리스 마이크로서비스로 일당백 개발조직 만들기[2017 AWS Startup Day] 서버리스 마이크로서비스로 일당백 개발조직 만들기
[2017 AWS Startup Day] 서버리스 마이크로서비스로 일당백 개발조직 만들기
 
Intro to hpe helion stackato_paa_s
Intro to hpe helion stackato_paa_sIntro to hpe helion stackato_paa_s
Intro to hpe helion stackato_paa_s
 
MSA(Service Mesh), MDA(Data Mesh), MIA(Inference Mesh) 기술동향 소개-박문기@메ᄀ...
MSA(Service Mesh), MDA(Data Mesh), MIA(Inference Mesh) 기술동향 소개-박문기@메ᄀ...MSA(Service Mesh), MDA(Data Mesh), MIA(Inference Mesh) 기술동향 소개-박문기@메ᄀ...
MSA(Service Mesh), MDA(Data Mesh), MIA(Inference Mesh) 기술동향 소개-박문기@메ᄀ...
 
모바일을 위한 (AWS) 클라우드 기술 동향
모바일을 위한 (AWS) 클라우드 기술 동향 모바일을 위한 (AWS) 클라우드 기술 동향
모바일을 위한 (AWS) 클라우드 기술 동향
 
[오픈테크넷서밋2022] 국내 PaaS(Kubernetes) Best Practice 및 DevOps 환경 구축 사례.pdf
[오픈테크넷서밋2022] 국내 PaaS(Kubernetes) Best Practice 및 DevOps 환경 구축 사례.pdf[오픈테크넷서밋2022] 국내 PaaS(Kubernetes) Best Practice 및 DevOps 환경 구축 사례.pdf
[오픈테크넷서밋2022] 국내 PaaS(Kubernetes) Best Practice 및 DevOps 환경 구축 사례.pdf
 
OCE - Cno 2014 private sector oriented open paas oce
OCE - Cno 2014 private sector oriented open paas   oceOCE - Cno 2014 private sector oriented open paas   oce
OCE - Cno 2014 private sector oriented open paas oce
 
제4회 한국IBM과 함께하는 난공불락 오픈소스 인프라 세미나- IBM Bluemix
제4회 한국IBM과 함께하는 난공불락 오픈소스 인프라 세미나- IBM Bluemix제4회 한국IBM과 함께하는 난공불락 오픈소스 인프라 세미나- IBM Bluemix
제4회 한국IBM과 함께하는 난공불락 오픈소스 인프라 세미나- IBM Bluemix
 
2015 oce garuda
2015 oce garuda2015 oce garuda
2015 oce garuda
 
개발자를 위한 네이버 클라우드 플랫폼ㅣNAVER CLOUD PLATFORM for Developers
개발자를 위한 네이버 클라우드 플랫폼ㅣNAVER CLOUD PLATFORM for Developers 개발자를 위한 네이버 클라우드 플랫폼ㅣNAVER CLOUD PLATFORM for Developers
개발자를 위한 네이버 클라우드 플랫폼ㅣNAVER CLOUD PLATFORM for Developers
 
효과적인 데브옵스를 위한 AWS 개발 도구 활용하기 - AWS Summit Seoul 2017
효과적인 데브옵스를 위한 AWS 개발 도구 활용하기 - AWS Summit Seoul 2017효과적인 데브옵스를 위한 AWS 개발 도구 활용하기 - AWS Summit Seoul 2017
효과적인 데브옵스를 위한 AWS 개발 도구 활용하기 - AWS Summit Seoul 2017
 
성공적인 하이브리드 클라우드를 위한 레드햇의 전략
성공적인 하이브리드 클라우드를 위한 레드햇의 전략성공적인 하이브리드 클라우드를 위한 레드햇의 전략
성공적인 하이브리드 클라우드를 위한 레드햇의 전략
 

Mehr von minseok kim

Mehr von minseok kim (7)

PCF2.2 update mkim_201807
PCF2.2 update mkim_201807PCF2.2 update mkim_201807
PCF2.2 update mkim_201807
 
consumer_driven_contract with spring cloud contract at spring camp 2018
consumer_driven_contract with spring cloud contract at spring camp 2018consumer_driven_contract with spring cloud contract at spring camp 2018
consumer_driven_contract with spring cloud contract at spring camp 2018
 
SpringOnePlatform2017 recap
SpringOnePlatform2017 recapSpringOnePlatform2017 recap
SpringOnePlatform2017 recap
 
Pivotal seminarq4 20161129_share
Pivotal seminarq4 20161129_sharePivotal seminarq4 20161129_share
Pivotal seminarq4 20161129_share
 
Pivotal korea transformation_strategy_seminar_enterprise_dev_ops_20160630_v1.0
Pivotal korea transformation_strategy_seminar_enterprise_dev_ops_20160630_v1.0Pivotal korea transformation_strategy_seminar_enterprise_dev_ops_20160630_v1.0
Pivotal korea transformation_strategy_seminar_enterprise_dev_ops_20160630_v1.0
 
Development on cloud_paa_s_sddc_mkim_20141216_final
Development on cloud_paa_s_sddc_mkim_20141216_finalDevelopment on cloud_paa_s_sddc_mkim_20141216_final
Development on cloud_paa_s_sddc_mkim_20141216_final
 
Pivotal cf for_devops_mkim_20141209
Pivotal cf for_devops_mkim_20141209Pivotal cf for_devops_mkim_20141209
Pivotal cf for_devops_mkim_20141209
 

Meetup tools for-cloud_native_apps_meetup20180510-vs

  • 1. © Copyright 2018 Pivotal Software, Inc. All rights Reserved. Cloud Native 서비스를 위한 도구들 김민석 2018/05/10
  • 3. September 24–27, 2018 Washington DC Gaylord, National Harbor Discount Code S1P200_MKim Hear more of cases & tactics like these, plus nerd stuff. Register Today & Save!
  • 4. Spring Camp 2018 4 2018년 11월 12-13 Seoul springonetour.io
  • 5. 소개 • 김민석 (myminseok@gmail.com) • Platform Architect @ Pivotal • Big-Data Monitoring System Developer • Software Architect • Software Quality Engineer • Developer https://www.facebook.com/groups/CloudfoundryKorea
  • 6. “Pivotal is currently contributing as much software to open source projects as IBM.” Source: https://redmonk.com/jgovernor/2017/10/25/some-thoughts-on-the-top-contributors-to-github-2017/ 전 세계의 2,500명이 넘는 Pivotal의 개발자들은 다양한 오픈소스 프로젝트에 깊게 기여하고 있음
  • 7. Process & Culture Build for change DevOps Tools Continuously Improve Platform Any App, Every Cloud, One Platform Pivotal Cloud Foundry Tracker / Spring / Concourse Pivotal Labs Data / AI Apps Open Source Based Data Pivotal Big Data Suites Customer Insight Dojo 개발자 중심의 실리콘 밸리 기업인 Pivotal은 디지털 변혁을 위한 1) 문화/프로세스, 2) 기술 플랫 폼, 3) DevOps 툴 및 4) 데이터 분석에 걸쳐 다양한 Offering을 제공 하고 있음 Pivotal Data Science 5조원 21 +2,500 시가총액 글로벌 오피스 개발자 1/3 이상의.. Pivotal Overview Fortune 100 회사가 Pivotal과 함께 일하고 있습니다. 7 of the largest banks / payments 9 of the largest automakers 7 of the largest insurers 8 of the largest retailers 9 of the largest telcos Pivotal Customers
  • 8. Agenda ■  이번 밋업에서 다루는 도구들 ■  마이크로서비스 기반서비스 ■  모니터링 및 통합로그수집 ■  장애 내성을 키워주는 도구 ■  Q&A
  • 10. 우리의 IT환경은 점점 •  마이크로 서비스팀이 점점 작아지고 많아짐 •  API contract 개선이 더 잦아짐(Agile) •  다른 시간대(Timezone)의 팀간의 협업이 요구됨
  • 11. Cloud Native 시스템 운영을 위한 도구들은 ■  앱 자동배포 ■  MSA를 위한 기반 서비스 ■  On-demand backing service ■  실시간 모니터링 ■  중앙집중형 통합로그 개발자의 속도 ■  VM, 로드밸런서, IP관리 자동화 ■  플랫폼 설치 자동화 ■  App, VM,AZ까지의 고가용성 ■  플랫폼/서비스 통합 모니터링 ■  중앙집중형 통합로그 ■  Autoscaling ■  플랫폼 무중단 업데이트 ■  신속한 보안패치 ■  컨테이너 보안 ■  Credentials 관리및 rotate 운영자의 안정성
  • 12. Cloud native 서비스를 도와주는 도구들. Customer Service Loyalty Service Notifications Service Other… Create Loyalty Bank Send Email Email Service Post Service Generate Mail Other Actions Backend for Frontend Backend for Frontend Backend for Frontend Backend for Frontend Service Adaptor1 Adaptor2 Translator Config Registry CB Dashboard Compliance ….. Saboteur Vizceral Spring Boot Admin Microservice Dashboard
  • 14. MSA를 위한 기반 서비스 Web Frontend Customer Service Loyalty Service Notifications Service Other… Create Loyalty Bank Send Email Email Service Post Service Generate Mail Other Actions Mobile Wearables Echo 3rd Party Backend for Frontend Backend for Frontend Backend for Frontend Backend for Frontend ESB Payments Other Service Adaptor1 Adaptor2 Translator LegacyCore Business uServicesAPI Gateway uServices Anti Corruption uServices Config Registry CB Dashboard Compliance ….. …… Foundational uServices
  • 15. Spring boot기반 앱의 모니터링과 관리를 위한 라이브러리 Spring Boot Actuator 1.x Spring Boot Actuator 2.x • Spring MVC • Spring MVC • Spring WebFlux • Jersey <dependency>! <groupId>org.springframework.boot</groupId>! <artifactId>spring-boot-starter-actuator</artifactId>! </dependency>!
  • 16. Spring Boot Actuator 16 •  auditevents •  beans •  conditions •  Configprops •  env •  health •  httptrace •  flyway https://docs.spring.io/spring-boot/docs/current/reference/html/production-ready-endpoints.html •  info •  loggers •  liquibase •  metrics •  mappings •  scheduledtasks •  sessions •  shutdown •  threaddump •  heapdump •  jolokia •  logfile •  prometheus
  • 18. With PCFWithout PCF Config Server Service Registry (Eureka) Circuit Breaker (Hystrix) 개발자가 배포 및 보안 관리 플랫폼이 배포 및 보안 관리 Config Server Service Registry (Eureka) Circuit Breaker (Hystrix) MSA기반 서비스의 사용예
  • 19. Config Server application.yml •  hello-server-dev.yml •  hello-server-stage.yml •  hello-server-prod.yml hello-server-dev hello-server-stage hello-server-prod refresh w/ curl
  • 20. 앱의 장애확산을 방지하며, 서비스 상태를 통합하여 대쉬보 드로 보여주는 Circuit Breaker, hystrix dashboard , turbine
  • 21. Circuit Breaker 메트릭을 통합해주는 turbine
  • 24. 넷플릭스 오픈소스 도구 중 하나인 Vizceral 의 동작 영상을 살펴보면 이런 구조를 쉽게 살펴볼 수 있습니다. 왼쪽은 AWS 각 리전에 분포한 트래픽, 오른쪽은 각 리전 내부의 트래픽 흐름 입니다. 플릭스 오픈소스 도구 중 하나인 Vizceral
  • 29. 분산시스템을 위한 모니터링 도구 - Prometheus •  SoundCloud에서 개발하여 오픈소스화 •  multi-dimensional data model 데이터가 host, service, endpoint, method단위로 조합이 되어서 multi-dimensional data model이 제공 •  Operational simplicity 설설치가 쉬운 모니터링 정관리가 쉬워서 박사학위가 없어도 될 정도로 •  Scalable and decentralized •  powerful query language 시각화와 의미있는 알림을 줄 수 있는 데이터모델, Query. https://ordina-jworks.github.io/monitoring/2016/09/23/Monitoring-with-Prometheus.html https://prometheus.io/docs/introduction/comparison/
  • 30. 모니터링 도구 특징 Server polls Client pushes Prometheus Atlas, Datadog, Datadog StatsD, Influx, SignalFx, Telegraf StatsD, Wavefront, New Relic Dimensional Graphite, Ganglia, JMX, Etsy StatsD, PCF Metrics 1.4 Hierarchical
  • 31. Prometheus at a glance
  • 35. Prometheus at a glance
  • 36. Prometheus 자동 설치 및 Cloud Foundry 플랫폼 모니터링 자동화 https://github.com/myminseok/pcf-prometheus-pipeline https://github.com/bosh-prometheus/prometheus- boshrelease Cloud Foundry상의 모든 메트릭을 시각화/알림 •  VM메트릭 (node_exporter) •  Process Metric (Bosh_exporter) •  App metric (cf_exporter)
  • 38. Prometheus best practices •  대시보드 하나에 5개 미만 그래프유지 •  각 그래프에 5개 Plots(lines)이하 유지 •  유용하지 않은 데이터는 제거 •  용도별 대시보드 분리( 개발용, 운영용) •  알림은 간단히, 엔드유져가 느끼는 현상 중심으로, 문제파악에 도움이 되는 요소를 링크로 포함. •  Pushgateway는 SPOF이므로 필요한 곳에 사용 •  네트워크 분리의 경우 같은망에 Prometheus서버 구성 https://prometheus.io/docs/practices/consoles/
  • 39. 벤더 중립적인 애플리케이션 메트릭 수집 39 •  JVM based Application code •  Dimensional Metrics •  Integrated into Spring •  Support for popular monitoring system (no vendor lock-in) https://micrometer.io/ •  Prometheus •  Netflix Atlas •  CloudWatch •  Datadog •  Graphite •  Ganglia •  JMX •  Influx/Telegraf •  New Relic •  StatsD •  SignalFx •  Wavefront
  • 41. /actuator/prometheus system_cpu_count 4.0 system_load_average_1m 1.64 jvm_memory_max_bytes{area="heap",id="PS Eden Space",} 1.05906176E8 jvm_memory_max_bytes{area="heap",id="PS Survivor Space",} 2.1495808E7 jvm_memory_max_bytes{area="heap",id="PS Old Gen",} 3.00941312E8 http_server_requests_seconds_count{exception="None",method="GET",status= "200",uri="/hello",} 4469.0 http_server_requests_seconds_sum{exception="None",method="GET",status="2 00",uri="/hello",} 297.942920787 http_server_requests_seconds_max{exception="None",method="GET",status="2 00",uri="/hello",} 0.401581731 https://docs.spring.io/spring-boot/docs/2.0.x/reference/html/production-ready-metrics.html#production-ready-metrics
  • 46. 서비스 장애 주입 - Trouble maker https://keyholelabs.com/trouble-maker/ https://github.com/in-the-keyhole/khs-trouble-maker https://github.com/in-the-keyhole/khs-spring-boot-troublemaker-starter Netflix Chaos Monkey는 EC2 API에 제한 Cloud에 독립적 Service registry연동 스케줄링 기능 랜덤 장애발생 -  KILL -  LOAD -  Memory -  Exception
  • 47. 서비스 장애 주입 - Trouble maker https://github.com/in-the-keyhole/khs-trouble-maker https://github.com/in-the-keyhole/khs-spring-boot-troublemaker-starter
  • 48. 네트워크 장애주입 - Saboteur Saboteur: https://github.com/tomakehurst/saboteur Vagrant wiremock saboteur https://github.com/chbatey/vagrant-wiremock-saboteur 네트워크 장애 주입 도구로서 장애 내성 및 안정성 테스트를 간단하게 하여줌 •  Total network partition •  Remote service dead (not listening on the expected port) •  Delays •  Packet loss •  TCP connection timeout (as often happens when two systems are separated by a stateful firewall) •  Support Linux only
  • 49. 네트워크 장애주입 - Saboteur Saboteur: https://github.com/tomakehurst/saboteur Vagrant wiremock saboteur https://github.com/chbatey/vagrant-wiremock-saboteur Vagrant 테스트 시뮬레이션 환경 Saboteur Wiremock server Iptables, tc $ cd vagrant-wiremock-saboteur/vm $ curl 192.168.2.2:8080/name eth1 $ rpm -ivh https://github.com/tomakehurst/saboteur/releases/download/v0.7/saboteur-0.7-1.noarch.rpm $ service saboteur-agent start
  • 50. MSA 운영을 위한 최적의 플랫폼 Pivotal Cloud Foundry
  • 51. 애플리케이션이 컨테이너에 배포되고 관리되는 과정 코드 및 테스트 완료 후 해야하는 일 가용한 호스트 찾기 Docker image 설정 Docker 허브에 로그인 원하는 OS를 포함하는 Docker 이미지 받기 Docker 컨테이너 내부로 진입해서 OS 업데이트 필요한 런타임 수동 설치 Docker 이미지를 허브에 올리기 컨테이너를 호스트에 배포 환경 변수 설정 로드발란서 구성 SSL 생성 방화벽 구성 서비스 모니터링 도구 갱신 로그 수집기 구성 스케일링
  • 52. 애플리케이션이 컨테이너에 배포되고 관리되는 전과정을 플랫폼에 위임하 고 개발자는 코드개발에 집중합니다. cf push ~ 45 seconds Speed & Consistency 코드 및 테스트 완료 후 해야하는 일 가용한 호스트 찾기 Docker image 설정 Docker 허브에 로그인 원하는 OS를 포함하는 Docker 이미지 받기 Docker 컨테이너 내부로 진입해서 OS 업데이트 필요한 런타임 수동 설치 Docker 이미지를 허브에 올리기 컨테이너를 호스트에 배포 환경 변수 설정 로드발란서 구성 SSL 생성 방화벽 구성 서비스 모니터링 도구 갱신 로그 수집기 구성 스케일링 Platform의 빌드팩(Build-Pack) •  앱을 구동하기 위해 필요한 Dependency(JVM, Tomcat, Apache 등)를 미리 구축해 놓는 것이 아닌, 앱을 배포하는 시점 에 앱에서 필요한 정확한 Dependency(라이브러리, JVM, 미들 웨어 등)를 Build-pack에서 찾아 설치하여 사용하게 함 •  빌드팩 역시 개발/스테이징/운영 환경을 별도로 관리하며, 이를 통해 환경의 일치를 구성할 수 있음 •  Self-Contained App형태로 운영 가능하도록 하여 즉시적으로 Deploy할 수 있는 형태 Platform의 Cloud Controller •  플랫폼에서 컨테이너 생성, 환경변수 설정, 라우팅 설정, 방화벽 구성, 로그 수집등의 앱 구동을 위한 스텝 지원 •  이 후, 앱 운영(Operation)에 필요한 HA/Scaling 지원
  • 54. PCF에서 기본으로 제공되는 MSA기반 서비스 PCF
  • 55. 앱 성능 분석 및 통합로그수집 - PCF metrics
  • 56. 분산 추적 및 통합로그수집 - PCF metrics
  • 57. 플랫폼 운영자를 위해 플랫폼의 현재상황/메트릭 추이를 한눈에 보여주는 대시보드를 제공하여 플랫폼 운영 의 통찰을 제공 §  End User Impact - Http Request Throughput, Latency - Router CPU - 502 bad gateway §  Developer Impact - cf command line도구의 응답성능 - 어플리케이션 배포공간 잔여용량(메모리, 디스크) - 총 container수 §  Platform Impact - 플랫폼 컴포넌트 health 상태 - 플랫폼 구성요수의 리소스 사용량(메모리, 디스크)
  • 58. 플랫폼 운영자를 위해 플랫폼의 현재상황/메트릭 추이를 한눈에 보여주는 대시보드를 제공하여 플랫폼 운영 의 통찰을 제공 §  End User Impact - Http Request Throughput, Latency - Router CPU - 502 bad gateway §  Developer Impact - cf command line도구의 응답성능 - 어플리케이션 배포공간 잔여용량(메모리, 디스크) - 총 container수 §  Platform Impact - 플랫폼 컴포넌트 health 상태 - 플랫폼 구성요수의 리소스 사용량(메모리, 디스크)
  • 59. DIY Cloud Native Platform Reference Architecture
  • 60. Same Reference Arch with Pivotal Cloud Foundry 60
  • 61. Transforming How The World Builds Software © Copyright 2017 Pivotal Software, Inc. All rights Reserved.