분류 전체보기
-
1. Kafka 도입 사례Kafka 2024. 1. 19. 20:52
Event-Driven System의 핵심 - Inbound Data와 Outbound Data가 일치해야 함 Event-Driven System을 구축하는 프레임워크 중 하나인 Kafka를 사용하는 목적은 받은 데이터를 잘 전달하는 데에 있다. 그러므로 데이터 전달 시 추가적인 변형이나 손실이 없게끔 Data가 잘 전달되어야만 한다. Event-Driven System의 초기 도입 사례는 Kafka가 아닌 API와 PostgreSQL로 연결하는 CRUD 타입으로 구성하고, DB 업데이트 이후 아웃바운드 이벤트가 생성되도록 구성된 것이다. 이 같은 경우 다양한 문제가 발생한다. 더보기 - 여러 네트워크를 이용하는 환경에서 모든 데이터 변경에 대한 올바른 전달 보장 문제 - 동일 데이터를 동시에 수정하면서..
-
CBD 방법론Data Engineer 2024. 1. 11. 07:20
재사용성, 대체성 재사용성 : 컴포넌트가 독립적인 기능 혹은 서비스를 제공하는 독립적인 모듈이므로 이를 필요로 하는 여러 애플리케이션에서 반복적으로 재사용되도록 하는 것을 의미 개발하고자 하는 시스템에서 필요로 하는 기능 및 서비스를 제공하는 컴포넌트를 식별하고 이를 정의하는 것이 핵심 기존 개발 방식과는 달리 특정 프레임워크 상에서 실행되는 부품화된 컴포넌트를 바탕으로 이를 조립하여 더 큰 컴포넌트를 만들거나 애플리케이션을 개발하는 새로운 기법 분석 - 설계 - 구현 - 테스트 및 인도 컴포넌트 자체를 생산하거나 테스트 완료된 컴포넌트를 조립하여 사용자 요구에 맞는 소프트웨어를 만드는 방법 1. 복잡한 개발 문제를 적당한 구현 단위로 분해하고, 조립 방식으로 애플리케이션을 개발할 수 있어 개발 생산성을..
-
[Django] 로그 설정하는 법Django 2024. 1. 10. 09:13
대략적인 방법은 이렇다. 로그 관련 파일을 만든다. 로그를 만들고 싶은 파일로 들어가 해당 파일을 임포트한다 Logging.{출력하고 싶은 로그 레벨}(들어가고자하는 내용)을 집어넣는다 # log_setter.py Import os Import time Import logging Import logging.handlers From logging.handlers import TimedRotatingFileHandler Class RetimedRotatingFileHandler(TimedRotatingFileHandler) def __init__(self, filename, when=‘h’, interval = 1, backUpCount=0 , encoding=None, delay=False, utc=Fal..
-
[Django] CHAR 적용하기Django 2024. 1. 2. 16:14
# models.py class rCharField(models.Field): description = "CHAR field in mysql" def __init__(self, *args, **kwargs): super().__init__(*args, **kwargs) self.max_length = kwargs["max_length"] def db_type(self, connection): return f"CHAR({self.max_length})" Django의 MTV 중 하나인 model에서는 varchar 형식만 지원해준다. Char 형식을 지정해주기 위해서는 따로 클래스를 지정하여 사용해야 한다. 적용 방식은 models.py에 rCharField 클래스를 지정해준뒤 다음과 같이 CHAR 형식을..
-
Apache JMeter(Thread Group, Sampler, Listener)Network 2023. 12. 29. 11:28
성능 테스트를 위해, Apache JMeter를 이용한다. 자바 오픈 소스 소프트웨어 퍼포먼스 테스팅은 무거운 로드와 다양하고 동시의 유저 트래픽에 대한 웹 애플리케이션을 테스트하는 것을 의미 기능 테스트, 데이터베이스 서버 테스트 및 API 테스팅에 활용 오픈 소스 라이센스 유저 친화적인 GUI 독립된 플랫폼 > Mac, unix, windows에서 모두 사용가능 자바 based 애플리케이션 멀티 스레딩 프레임워크 테스트 결과를 시각화 쉬운 설치 Highly extensible Unlimited testing capabilities 이용 : Java 설치(8 이상) > homebrew 이용 jmeter 설치 > 실행 명령어 : open /opt/homebrew/bin/Jmeter 혹은 open /usr..
-
Azure VMSSNetwork 2023. 12. 29. 11:22
Virtual Machine Scale Sets 유지 관리를 수행하거나 애플리케이션 인스턴스를 업데이트하는 경우, 고객은 사용 가능한 다른 애플리케이션 인스턴스에 배포되어야 한다. 추가 고객 요구에 맞추려면 애플리케이션을 실행하는 애플리케이션 인스턴스의 수를 늘려야 할 수도 있다. 이런 경우에 VM에서 실행되는 애플리케이션, 리소스의 자동 크기 조정 및 트래픽 부하 분산에 대한 관리 기능을 제공 확장 집합 > 애플리케이션의 여러 인스턴스를 실행하는 데 사용된다. 동일한 기본 OS 이미지 및 구성에 모든 VM 인스턴스가 만들어진다. 이 방식을 사용하면 추가 구성 작업 또는 네트워크 관리 없이 수백 개의 VM을 쉽게 관리할 수 있다. 기본 4계층 트래픽 분산에는 Azure load balancer를 사용하고..
-
[Internship] 개발자 도구 - Network TabNetwork 2023. 12. 22. 20:42
오늘 여태껏 개발한 웹 화면을 토대로 회사 사람들과 사용자 UI/UX 테스트를 진행했는데, 여지껏 내가 개발자 도구를 잘 쓰지 못했던 것 같아 많은 게 생각나던 하루였다. 그래서 한 번 정리해보았다. 개발자 도구_ Network Tab 서버와 데이터를 주고 받을 때 편리하게 디버깅을 할 수 있도록 도와주는 도구 각 소스들을 불러올 때 속도, 응답 등 네트워크 측면에서 확인 가능하며, 문제 시 비교 및 분석 가능 빨간점 : 기록되고 있다는 뜻 기록되는 동안 주고받는 모든 네트워크 요소를 보여준다. 클릭 시 기록을 멈출 수 있으며, 오른쪽 정지표를 클릭하면 기록된 모든 요소를 지운다 Filter / search : 이름과 같이 필터링하고, 검색하는 기능 Preserve log : 페이지가 이동되어도 로그가 ..
-
Git add / commit / push 취소Data Engineer 2023. 12. 15. 09:06
git add 취소 $ git reset HEAD [file] 입력 시 특정 파일만 취소 가능 git commit 취소 $ git reset HEAD^ git push 취소 $ Git reset HEAD^ $ Git reblog or git log -g : 브랜치와 HEAD가 지난 몇 달 동안에 가리켰었던 커밋 $ Git reset HEAD@{number} 또는 git reset [commit id] : 원하는 시점으로 워킹 디렉토리 되돌림 Git commit -m “Write commit messages” : 되돌려진 상태에서 다시 커밋 Git push origin [branch name] -f 또는 git push origin +[branch name] : 원격 저장소에 강제로 push Git cle..