공부하고 기록하는, 경제학과 출신 개발자의 노트

학습일지 198

Deview 2021 - istio/Envoy로 Multi-IDC L7 로드밸런서 만들기

Deview 2021: https://deview.kr/2021/sessions/502 당신의 대문을 책임집니다. Istio/Envoy로 Multi-IDC L7 로드밸런서 만들기 발표자 : 김동경 deview.kr 영상: https://tv.naver.com/v/23651554 Google에서 Multi-Cluster Application을 제공하는 플랫폼의 형태 여러 Region에 배포된 클러스터를 향해 트래픽이 전달됨 Fleet이라는 product - 물리적으로 나뉘어 있는 클러스터를 하나의 logical cluster처럼 만드는 기능 cluster API - 하나의 API로 여러 region에 클러스터를 배포할 수 있음. 멀티 클러스터로 트래픽을 분산하는 Load balancer에는 앞단에서 사용될..

KubeCon 2019 - The story of Why we migrate to gRPC and How we go about it (Spoti

https://youtu.be/fMq3IpPE3TUThe story of Why we migrate to gRPC and How we go about itMatthias Grüter. Engineering Manager in the infrastructure group. gRPC based infrastructure로 전환한 이유gRPC based infrastructure로 전환한 방법2500여 개의 내부 serviceingress로 들어오는 request 가 초당 8백만 (Query for Second서비스 간 통신에는 자체 개발한 protocol을 사용하고 있었음. (이름은 Hermes) RPC 프레임워크가 아니라 통신 프로토콜이었음. gRPC보다는 http와 비교대상.동작에는 문제 없음그런데 왜 ..

istio 개념 정리 (2) - VirtualService / DestinationRule / Gateway

Canaries 애플리케이션의 사용량이 많을수록 유용한 기능. 사용자가 많은 애플리케이션에서 새로운 버전을 100% 바로 배포할 경우 발생할 수 있는 리스크를 줄일 수 있음. istio 없이 Kubernetes component로 Canary 적용하기 Single Service에 multiple pod를 연결하는 것이 가능함. deployment에 Label 붙이고, service에서 matchLabel로 pod 선택하는 게 가능하기 때문 k8s의 load balancing은 기본적으로 round robin. 따라서 위 그림과 같은 상황이라면, new version (staff-service:6)은 전체 트래픽의 33%를 점유하게 됨 대신, 이 방법은 traffic의 %를 변경하려면 그만큼 pod 비율을..

istio 개념 정리 (1) - Service Mesh와 istio

Istio Istio : Service Mesh의 한 종류. Service Meshcluster-based MicroService 프로젝트가 많아지면서, k8s와 같은 Orchestration tool만으로는 기능 요구사항을 맞추기 어려워지며 대두된 서비스.일종의 Extra Layer of Software that you deploy alongside k8s.Multiple Software Components가 서로 통신하고 연결되어 있는 Distributed Architecture라면 사용할 수 있음. 반드시 K8s 환경에서만 쓰이는 게 아님. 예시를 위한 도식. 각 Microservice에는 pod가 있고, 보통 하나의 pod에는 하나의 Container가 있다. 각각의 microservice는 Se..

KubeCon 2018 - Using gRPC for long-lived and Streaming RPCs

Using gPRC for long-lived and Streaming RPCs 발표자: Eric Anderson - gRPC Java 팀 tech lead. Google에서 근무 발표자료: https://kccna18.sched.com/event/GrWo 발표영상: https://youtu.be/Naonb2XD_2Q Long-Lived gRPC란? RPCs that last minutes / hours/ days. Long polling (Hanging Get). 예컨대 서버에서 특정 이벤트가 발생할 때까지 대기하는 로직. 강연에서는 Notification / Watches를 예시로 들었음. Hanging Get : 서버에서 요청에 응답할 데이터가 없는 경우, 해당 데이터를 사용할 수 있게 될 때까지 ..

if kakao 2021 - PostgreSQL ecosystem

https://if.kakao.com/session/59 if(kakao)2021 함께 나아가는 더 나은 세상 if.kakao.com PostgreSQL EcoSystem 1996년 오픈소스 프로젝트로 오픈됨. 현재까지도 1년에 한 번은 메이저 버전이 오픈됨. Extension: 다양하고 실험적인 기능을 패키지 형태로 제공하는 기능. 예시: 데이터 암호화 기능 (pg), pivot table 쿼리를 쉽게 구현할 수 있는 tablefunc. FDW : Foreign Data Wrapper 원격지의 데이터를 로컬 table처럼 사용할 수 있게 해주는 extension. 원격 데이터 + 로컬 데이터 join이나 DML 실행이 가능함. 데이터 처리 로직을 보다 간단히 구현할 수 있음. Orafce : 오라클과 ..

Fluentd 정리: Open Source Log Data Collector

https://www.youtube.com/watch?v=5ofsNyHZwWE Why we Need Logs? k8s에 여러 MicroService 앱이 배포되어 있다고 가정하자. nodejs / python postgres DB RabbitMQ 각각의 앱은 "어떤 동작을 하고 있는지" 로그를 생성한다. 로그는 보통 아래 세 가지 목적으로 쓰임. Compliance Security Debugging How Application Logs data? Write to files. 일반적인 방식. 단, 로그데이터 분석에는 제약이 따름. UI나 visualization tool 없이는 cross application log 확인도 어려운 편 로그마다 format도 다름 (timestamps, log level 등..

학습일지 2022.08.03

Token-based Authentication - JWT의 단점과 PASETO

아래 글과 유튜브 영상 내용을 학습하면서 기록한 포스트 https://dev.to/techschoolguru/why-paseto-is-better-than-jwt-for-token-based-authentication-1b0c Why PASETO is better than JWT for token-based authentication? JWT vs PASETO Nowadays, token-based authentication has become more and more popular in the... dev.to https://youtu.be/nBGx-q52KAY Why Paseto is better than JWT? Token-based Authentication 방식에서 많이 사용되는 게 JWT. 그..

KubeCon 2022 Europe - Create your first CNCF Serverless Workflow Project with Kogito and Knative

Create your first CNCF Serverless Workflow Project with Kogito and Knative선요약Kogito: Redhat에서 진행중인 knative serving / eventing 컴포넌트의 조합을 묶어 workflow를 구성해 주는 프로덕트사용자에게서 json / yaml 형태의 선언형으로 input을 받고, 주어진 값을 토대로 quarkus을 활용해서 knative object를 만들어준다추후에는 low code 형태로도 개발해서 소스코드를 입력하지 않고도, 비개발자도 사용할 수 있는 방향을 구상하고 있다고 함. CNCF Serverless Workflow project - KogitoCNCF Sandbox incubating project로, DSL to..

Transaction Isolation - MySQL과 Postgresql 비교

Transaction Isolation Level / read phenomena ACID 4요소 중 하나가 isolation. 가장 높은 수준의 isolation -> all concurrent txn will not affect each other. 반대로 말하면, txn이 다른 txn에게 영향을 줄 수 있는 정도가 구분된다는 뜻. 이걸 Read Phenomenon이라 부른다. Dirty Read : uncommitted txn값을 읽어들이는 것. txn이 commit일지 rollback일지 알 수 없기 때문에 incorrect data를 사용하게 될 가능성이 높음 Non-Repeatable Read : 동일한 쿼리 요청을 했는데 응답값이 달라지는 경우 Phantom Read : 2와 비슷하지만, 하나..