[GitHub] spark pull request #19961: [SPARK-22496][SQL] thrift server adds operation l...

2017-12-14 Thread ChenjunZou
Github user ChenjunZou commented on a diff in the pull request:

https://github.com/apache/spark/pull/19961#discussion_r157117909
  
--- Diff: 
sql/hive-thriftserver/src/main/java/org/apache/hive/service/cli/operation/ExecuteStatementOperation.java
 ---
@@ -67,4 +68,16 @@ protected void setConfOverlay(Map 
confOverlay) {
   this.confOverlay = confOverlay;
 }
   }
+
+  protected void registerCurrentOperationLog() {
+if (isOperationLogEnabled) {
+  if (operationLog == null) {
+LOG.warn("Failed to get current OperationLog object of Operation: 
" +
+getHandle().getHandleIdentifier());
--- End diff --

thanks @gatorsmile


---

-
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org



[GitHub] spark pull request #19961: [SPARK-22496][SQL] thrift server adds operation l...

2017-12-14 Thread HyukjinKwon
Github user HyukjinKwon commented on a diff in the pull request:

https://github.com/apache/spark/pull/19961#discussion_r157098963
  
--- Diff: 
sql/hive-thriftserver/src/main/java/org/apache/hive/service/cli/operation/ExecuteStatementOperation.java
 ---
@@ -67,4 +68,16 @@ protected void setConfOverlay(Map 
confOverlay) {
   this.confOverlay = confOverlay;
 }
   }
+
+  protected void registerCurrentOperationLog() {
+if (isOperationLogEnabled) {
+  if (operationLog == null) {
+LOG.warn("Failed to get current OperationLog object of Operation: 
" +
+getHandle().getHandleIdentifier());
--- End diff --

Thank you @gatorsmile.


---

-
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org



[GitHub] spark pull request #19961: [SPARK-22496][SQL] thrift server adds operation l...

2017-12-14 Thread asfgit
Github user asfgit closed the pull request at:

https://github.com/apache/spark/pull/19961


---

-
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org



[GitHub] spark pull request #19961: [SPARK-22496][SQL] thrift server adds operation l...

2017-12-14 Thread gatorsmile
Github user gatorsmile commented on a diff in the pull request:

https://github.com/apache/spark/pull/19961#discussion_r157091511
  
--- Diff: 
sql/hive-thriftserver/src/main/java/org/apache/hive/service/cli/operation/ExecuteStatementOperation.java
 ---
@@ -67,4 +68,16 @@ protected void setConfOverlay(Map 
confOverlay) {
   this.confOverlay = confOverlay;
 }
   }
+
+  protected void registerCurrentOperationLog() {
+if (isOperationLogEnabled) {
+  if (operationLog == null) {
+LOG.warn("Failed to get current OperationLog object of Operation: 
" +
+getHandle().getHandleIdentifier());
--- End diff --

This was resolved by me when I did the merge.


---

-
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org



[GitHub] spark pull request #19961: [SPARK-22496][SQL] thrift server adds operation l...

2017-12-12 Thread HyukjinKwon
Github user HyukjinKwon commented on a diff in the pull request:

https://github.com/apache/spark/pull/19961#discussion_r156555741
  
--- Diff: 
sql/hive-thriftserver/src/main/java/org/apache/hive/service/cli/operation/ExecuteStatementOperation.java
 ---
@@ -67,4 +68,16 @@ protected void setConfOverlay(Map 
confOverlay) {
   this.confOverlay = confOverlay;
 }
   }
+
+  protected void registerCurrentOperationLog() {
+if (isOperationLogEnabled) {
+  if (operationLog == null) {
+LOG.warn("Failed to get current OperationLog object of Operation: 
" +
+getHandle().getHandleIdentifier());
--- End diff --

I think the indentation should be double spaced.


---

-
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org



[GitHub] spark pull request #19961: [SPARK-22496][SQL] thrift server adds operation l...

2017-12-12 Thread ChenjunZou
GitHub user ChenjunZou opened a pull request:

https://github.com/apache/spark/pull/19961

[SPARK-22496][SQL] thrift server adds operation logs

## What changes were proposed in this pull request?
since hive 2.0+  upgrades log4j to log4j2,a lot of 
[changes](https://issues.apache.org/jira/browse/HIVE-11304) are made working on 
it.
as spark is not to ready to update its inner hive version(1.2.1) , so I 
manage to make little changes.
the function registerCurrentOperationLog  is moved from SQLOperstion to its 
parent class ExecuteStatementOperation so spark can use it.

## How was this patch tested?
manual test

Author: zouchenjun 

Closes #19721 from ChenjunZou/operation-log.

## What changes were proposed in this pull request?

(Please fill in changes proposed in this fix)

## How was this patch tested?

(Please explain how this patch was tested. E.g. unit tests, integration 
tests, manual tests)
(If this patch involves UI changes, please attach a screenshot; otherwise, 
remove this)

Please review http://spark.apache.org/contributing.html before opening a 
pull request.


You can merge this pull request into a Git repository by running:

$ git pull https://github.com/ChenjunZou/spark spark-22496

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/spark/pull/19961.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #19961


commit b39d36fba5ffbbcac6ba9c15b4062b7ade7b6f1e
Author: zouchenjun 
Date:   2017-12-11T04:36:14Z

[SPARK-22496][SQL] thrift server adds operation logs

## What changes were proposed in this pull request?
since hive 2.0+  upgrades log4j to log4j2,a lot of 
[changes](https://issues.apache.org/jira/browse/HIVE-11304) are made working on 
it.
as spark is not to ready to update its inner hive version(1.2.1) , so I 
manage to make little changes.
the function registerCurrentOperationLog  is moved from SQLOperstion to its 
parent class ExecuteStatementOperation so spark can use it.

## How was this patch tested?
manual test

Author: zouchenjun 

Closes #19721 from ChenjunZou/operation-log.




---

-
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org