mirror of
https://github.com/apache/zeppelin
synced 2026-05-24 09:38:26 +00:00
ZEPPELIN-773 livy to have conf for configuring yarn master
This commit is contained in:
parent
134923ddfc
commit
23b78117cd
2 changed files with 7 additions and 2 deletions
|
|
@ -62,8 +62,11 @@ public class LivyHelper {
|
|||
try {
|
||||
String json = executeHTTP(property.getProperty("zeppelin.livy.url") + "/sessions",
|
||||
"POST",
|
||||
"{\"kind\": \"" + kind + "\", \"proxyUser\": \""
|
||||
+ context.getAuthenticationInfo().getUser() + "\"}",
|
||||
"{" +
|
||||
"\"kind\": \"" + kind + "\", " +
|
||||
"\"master\": \"" + property.getProperty("zeppelin.livy.master") + "\", " +
|
||||
"\"proxyUser\": \"" + context.getAuthenticationInfo().getUser() + "\"" +
|
||||
"}",
|
||||
context.getParagraphId()
|
||||
);
|
||||
Map jsonMap = (Map<Object, Object>) gson.fromJson(json,
|
||||
|
|
|
|||
|
|
@ -34,6 +34,7 @@ import java.util.Properties;
|
|||
public class LivySparkInterpreter extends Interpreter {
|
||||
|
||||
static String DEFAULT_URL = "http://localhost:8998";
|
||||
static String LOCAL = "local";
|
||||
Logger LOGGER = LoggerFactory.getLogger(LivySparkInterpreter.class);
|
||||
private LivyOutputStream out;
|
||||
|
||||
|
|
@ -44,6 +45,7 @@ public class LivySparkInterpreter extends Interpreter {
|
|||
LivySparkInterpreter.class.getName(),
|
||||
new InterpreterPropertyBuilder()
|
||||
.add("zeppelin.livy.url", DEFAULT_URL, "The URL for Livy Server.")
|
||||
.add("zeppelin.livy.master", LOCAL, "Spark master uri. ex) spark://masterhost:7077")
|
||||
.build()
|
||||
);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue