일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 |
- 하둡에코시스템
- recommendation system
- BigData
- pyspark
- DataEngineering
- kafka
- redis bloom filter
- 개발자혜성
- kubernetes
- cloudera
- dataengineer
- Data engineering
- 블로그
- hadoop
- eks
- spark
- Python
- Terraform
- 데이터엔지니어링
- 개발자
- 하둡
- 빅데이터플랫폼
- Spark structured streaming
- 클라우데라
- AWS SageMaker
- apache spark
- mlops
- 데이터엔지니어
- 추천시스템
- 빅데이터
- Today
- Total
목록apache spark (6)
Hyesung Oh
개요 Spark에서는 JDBC api를 통해 접근할 수 있는 datasource(dbms)를 지원합니다. jdbc datasource를 사용하기 위해선 JDBC interface를 구현한 Driver class가 필요합니다. *현재 사용 중인 mysql-connector-java-8.0.23을 기준으로 작성했습니다. spark.read.jdbc option으로 driver class path를 아래와 같이 설정해주면 됩니다. driver class path: com.mysql.cj.jdbc.Driver # Read from MySQL Table df = spark.read \ .format("jdbc") \ .option("url", "jdbc:mysql://localhost:3306/emp") \ .o..
EMRFS EMR의 S3 파일 읽기 쓰기와 관련된 프로토콜 집합이며, Amazon S3로 직접 일반 파일을 읽고 쓰는 데 사용하는 HDFS 구현체이다. 그리고 여기엔 다양한 기능들이 포함되는데, 그 중에서도 대표적으로 실무에서 가장 많이 이슈를 겪었던 consistent view와 s3-optimized commiter에 대해 다뤄보려 한다. EMRFS consistent view EMR에서는 file consistency를 강화하기 위해 자체적인 consistent view 메커니즘을 지원한다. EMR이 S3 또는 file system에 파일에 대한 메타정보를 DynamoDB에 관리한다. EMR 단에서 file을 create, delete를 하게 되면, 정상적으로 DynamoDB 메타정보와 sync가 ..
EMR Core node의 hdfs (disk)의 점유율이 90% (default threshold 90%) 이상이 되어 해당 node가 unhealthy 상태인 것을 확인할 수 있습니다. If the node remains unhealthy for 45 minutes, Amazon EMR marks the associated Amazon EC2 instance for termination as FAILED_BY_MASTER.When all Amazon EC2 instances associated with core nodes are marked for termination, the cluster terminates with the status NO_SLAVE_LEFT because there are no..
조금만 검색해보면 spark Performance tuning과 관련된 좋은 참고자료들이 많이 있습니다. 그 중에서 실제 팀에서 적용하여 효과를 보고있는 내용만 선별하여 공유하고자 합니다. 크게 코드 레벨에서의 최적화와 configuration 레벨에서의 최적화 두 가지가 있을 것 같습니다. 1. Code Level Opimization point 1. filter -> aggregation. aggregation을 하게 되면 driver 노드에 많은 부하가 있을 수 있습니다. 따라서 이럴 경우 reduceByKey를 이용하여 driver로 전송되는 데이터 사이즈를 최대한 줄이는게 포인트입니다. point 2. Iterator 최대한 활용하기 driver node로 데이터를 불러와서 작업을 해야하는 경우..
Spark가 JVM 위에서 동작하는 사실은 Spark 개발자라면 누구나 아는 사실입니다. Pyspark 구동의 핵심 부분인 Python process와 JVM process간의 객체 레벨 통신에 대해서 궁금증이 생겼습니다. 아래 본문은 Pyspark 소스코드를 파헤치며 파악한 내용들이며 잘못된 내용에 대한 피드백 주시면 책임감을 가지고 수정하겠습니다. Overview PySpark is built on top of Spark's Java API. Data is processed in Python and cached / shuffled in the JVM The In the Python driver program, SparkContext uses Py4J to launch a JVM and create a..
apache spark official github repo: github.com/apache/spark 1. 이해의 출발 지점은 바로, 우리가 spark-shell REPL를 사용하기 위해 실행하는 bin/spark-shell 스크립트 # Shell script for starting the Spark Shell REPL cygwin=false case "$(uname)" in CYGWIN*) cygwin=true;; esac * cygwin: window에서 linux터미널을 사용할 수 있게 해주는 오픈소스 현재 터미널이 linux이면 true, window이면 false정도로 이해했다. function main() { if $cygwin; then # Workaround for issue invol..