apache zeppelin additional repository import

蓝咒 提交于 2019-12-10 20:15:51

问题


How to import an additional dependency in zeppelin?

I am trying to import a library (saddle) in apache zeppelin, however ...

import org.saddle._

<console>:21: error: object saddle is not a member of package org
   import org.saddle._
              ^

I've tried using the %dep interpreter (dependency loader) like this:

%dep
z.reset()
z.addRepo("Saddle Repo").url("http://mvnrepository.com/artifact/org.scala-saddle/saddle_2.10/1.0.1")
z.load("org.scala-saddle:saddle_2.10:1.3.0")

I've also tried in the GUI by 1. including the maven repository under interpreter dependencies, or 2. including the saddle website under zeppelin.dep.additionalRemoteRepository.

I've also tried downloading the jar file and including it in conf/zeppelin-env.sh as SPARK_SUBMIT_OPTIONS.

I've then copied the jar to zeppelin-zengine/target/lib/, when I saw jars from there where used and imported.

So far, I haven't made it work. Help appreciated.


回答1:


I am sure that you must solved the problem by now. Posting it if somebody else facing the issue. I tried the following and it worked. There is no need to add maven as it is already added to Zeppelin.

z.load("org.scala-saddle:saddle-core_2.11:1.3.4")



回答2:


Interpreter Repository config GUI in Zeppelin. com.typesafe.config.ConfigFactory or Saddle Core » 1.3.4

error: object typesafe is not a member of package com

1 - Open site https://mvnrepository.com/ and find "saddle" repository.

SCALA Version, then click on Buildr

https://mvnrepository.com/artifact/org.scala-saddle/saddle-core

'org.scala-saddle:saddle-core_2.11:jar:1.3.4'

2 - Click on “Anonymous” at the top right, a drop down menu will pop up, click on “Interpreters”, then at the new page search or scroll down to “Spark”. In the top right of the Spark interpreter tile there are three buttons, “Edit”, “Restart”, “Remove”. Click “Edit” then You will see Dependencies and Values. Scroll down and find the property and click ADD and complete properties:

And click Save.

3- Test



来源:https://stackoverflow.com/questions/36750057/apache-zeppelin-additional-repository-import

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!