james.xu created LIVY-589:
-----------------------------
Summary: get operation log from interactive session
Key: LIVY-589
URL: https://issues.apache.org/jira/browse/LIVY-589
Project: Livy
Issue Type: New Feature
Components: REPL, RSC
Affects Versions: 0.6.0, 0.5.0
Reporter: james.xu
Attachments: operation_log.patch
in some case , i want get some log from InteractiveSession when the statement
has been submitted.
like that
{code:java}
//代码占位符
> curl -d '{"code" : "select * from tmp.ttt " ,"kind" : "sql"}' \
-H 'Content-Type: application/json' \
http://$livyhost:$port/sessions/0/statements
>response
{"id":1,"code":"select * from tmp.ttt
","state":"waiting","output":null,"progress":0.0}
// then i can get log like this
> curl http://namenode40:8998/sessions/0/statements/1/log?size=10
response
{
"statements": {
"id": 1,
"code": "select * from tmp.ttt ",
"state": "available",
"output": "19/04/13 12:40:01 DEBUG
org.apache.spark.sql.hive.HiveSessionStateBuilder$$anon$1: \n=== Result of
Batch Resolution ===\n!'Project [*] Project [name#5, age#6]\n!+-
'UnresolvedRelation `tmp`.`ttt` +- SubqueryAlias `tmp`.`ttt`\n! +-
HiveTableRelation `tmp`.`ttt`,
org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe, [name#5, age#6]\n
\n19/04/13 12:40:01 DEBUG
org.apache.spark.sql.internal.BaseSessionStateBuilder$$anon$2: \n=== Result of
Batch Finish Analysis ===\n GlobalLimit 1000 GlobalLimit 1000\n +- LocalLimit
1000 +- LocalLimit 1000 ",
"progress": 1
}
}{code}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)