티스토리 뷰
이클립스에서 메이븐을 이용하여 spark 에서 사용할 수 있는 scala 프로젝트를 빌드하는 방법은 다음과 같다.
- 메이븐 pom.xml 설정의 디펜던시 추가
<dependencies>
<dependency>
<groupId>org.scala-lang</groupId>
<artifactId>scala-library</artifactId>
<version>${ver.scala}</version>
</dependency>
<dependency>
<groupId>org.apache.spark</groupId>
<artifactId>spark-core_${ver.scala.main}</artifactId>
<version>${ver.spark}</version>
</dependency>
<dependency>
<groupId>org.apache.spark</groupId>
<artifactId>spark-sql_${ver.scala.main}</artifactId>
<version>${ver.spark}</version>
</dependency>
<dependency>
<groupId>org.apache.spark</groupId>
<artifactId>spark-hive_${ver.scala.main}</artifactId>
<version>${ver.spark}</version>
</dependency>
</dependencies>
- 메이븐 pom.xml 의 빌드 설정 추가
<plugin>
<groupId>net.alchim31.maven</groupId>
<artifactId>scala-maven-plugin</artifactId>
<version>3.2.1</version>
<executions>
<execution>
<phase>process-resources</phase>
<goals>
<goal>compile</goal>
</goals>
</execution>
</executions>
<configuration>
<scalaVersion>2.11.8</scalaVersion>
</configuration>
</plugin>
위와 같이 설정하고 메이븐 빌드의 골을 package 로 설정하면 된다.
'Tools' 카테고리의 다른 글
[vscode] vscode에서 파이썬 인터프리터의 버전 선택 (2) | 2019.05.02 |
---|---|
[eclipse] 맥용 이클립스 git에서 No password provided 오류 해결방법 (1) | 2019.02.21 |
[eclipse] 기본클래스를 찾거나 로드할 수 없습니다. (0) | 2018.05.30 |
[sublime] 서브라임에서 파이썬 버전별 빌드 설정 (0) | 2018.05.23 |
[git] git 저장소의 리파지토리 이름 변경 및 프로젝트의 이름 변경 (0) | 2018.05.10 |
- Total
- Today
- Yesterday
- ubuntu
- nodejs
- Hadoop
- oozie
- 하둡
- hbase
- build
- 정올
- yarn
- SPARK
- 하이브
- AWS
- HIVE
- Linux
- SQL
- 알고리즘
- S3
- 파이썬
- mysql
- 다이나믹
- HDFS
- airflow
- bash
- 백준
- java
- Tez
- error
- 오류
- Python
- emr
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 | 29 | 30 | 31 |