You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@kyuubi.apache.org by GitBox <gi...@apache.org> on 2023/01/12 09:10:31 UTC
[GitHub] [kyuubi] turboFei opened a new pull request, #4155: Reduce the application info call for batch
turboFei opened a new pull request, #4155:
URL: https://github.com/apache/kyuubi/pull/4155
<!--
Thanks for sending a pull request!
Here are some tips for you:
1. If this is your first time, please read our contributor guidelines: https://kyuubi.readthedocs.io/en/latest/community/CONTRIBUTING.html
2. If the PR is related to an issue in https://github.com/apache/kyuubi/issues, add '[KYUUBI #XXXX]' in your PR title, e.g., '[KYUUBI #XXXX] Your PR title ...'.
3. If the PR is unfinished, add '[WIP]' in your PR title, e.g., '[WIP][KYUUBI #XXXX] Your PR title ...'.
-->
### _Why are the changes needed?_
<!--
Please clarify why the changes are needed. For instance,
1. If you add a feature, you can talk about the use case of it.
2. If you fix a bug, you can clarify why it is a bug.
-->
### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible
- [ ] Add screenshots for manual tests if appropriate
- [ ] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@kyuubi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@kyuubi.apache.org
For additional commands, e-mail: notifications-help@kyuubi.apache.org
[GitHub] [kyuubi] ulysses-you commented on a diff in pull request #4155: Reduce the application info call for batch
Posted by GitBox <gi...@apache.org>.
ulysses-you commented on code in PR #4155:
URL: https://github.com/apache/kyuubi/pull/4155#discussion_r1068839823
##########
kyuubi-server/src/main/scala/org/apache/kyuubi/server/api/v1/BatchesResource.scala:
##########
@@ -68,7 +68,7 @@ private[v1] class BatchesResource extends ApiRequestContext with Logging {
private def buildBatch(session: KyuubiBatchSessionImpl): Batch = {
val batchOp = session.batchJobSubmissionOp
val batchOpStatus = batchOp.getStatus
- val batchAppStatus = batchOp.currentApplicationInfo
+ val batchAppStatus = batchOp.getApplicationInfo
Review Comment:
I'm not sure it can alway return a correct info, shall we make this method as `getOrFetchCurrentApplicationInfo` ? Then we in that method, we can call `currentApplicationInfo` if applicationInfo is empty.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@kyuubi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@kyuubi.apache.org
For additional commands, e-mail: notifications-help@kyuubi.apache.org
[GitHub] [kyuubi] ulysses-you commented on a diff in pull request #4155: Reduce the application info call for batch
Posted by GitBox <gi...@apache.org>.
ulysses-you commented on code in PR #4155:
URL: https://github.com/apache/kyuubi/pull/4155#discussion_r1068839823
##########
kyuubi-server/src/main/scala/org/apache/kyuubi/server/api/v1/BatchesResource.scala:
##########
@@ -68,7 +68,7 @@ private[v1] class BatchesResource extends ApiRequestContext with Logging {
private def buildBatch(session: KyuubiBatchSessionImpl): Batch = {
val batchOp = session.batchJobSubmissionOp
val batchOpStatus = batchOp.getStatus
- val batchAppStatus = batchOp.currentApplicationInfo
+ val batchAppStatus = batchOp.getApplicationInfo
Review Comment:
I'm not sure it can alway return a correct info, shall we make this method as `getOrFetchCurrentApplicationInfo` ? Then in that method, we can call `currentApplicationInfo` if applicationInfo is empty.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@kyuubi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@kyuubi.apache.org
For additional commands, e-mail: notifications-help@kyuubi.apache.org
[GitHub] [kyuubi] bowenliang123 commented on a diff in pull request #4155: Reduce the application info call for batch
Posted by GitBox <gi...@apache.org>.
bowenliang123 commented on code in PR #4155:
URL: https://github.com/apache/kyuubi/pull/4155#discussion_r1068947067
##########
kyuubi-server/src/main/scala/org/apache/kyuubi/operation/BatchJobSubmission.scala:
##########
@@ -69,7 +69,13 @@ class BatchJobSubmission(
private[kyuubi] val batchId: String = session.handle.identifier.toString
- private var applicationInfo: Option[ApplicationInfo] = None
+ @volatile private var _applicationInfo: Option[ApplicationInfo] = None
+ def getOrFetchCurrentApplicationInfo: Option[ApplicationInfo] = {
Review Comment:
minor: the empty brace can be removed.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@kyuubi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@kyuubi.apache.org
For additional commands, e-mail: notifications-help@kyuubi.apache.org
[GitHub] [kyuubi] turboFei commented on a diff in pull request #4155: Reduce the application info call for batch
Posted by GitBox <gi...@apache.org>.
turboFei commented on code in PR #4155:
URL: https://github.com/apache/kyuubi/pull/4155#discussion_r1068966999
##########
kyuubi-server/src/main/scala/org/apache/kyuubi/operation/BatchJobSubmission.scala:
##########
@@ -69,7 +69,13 @@ class BatchJobSubmission(
private[kyuubi] val batchId: String = session.handle.identifier.toString
- private var applicationInfo: Option[ApplicationInfo] = None
+ @volatile private var _applicationInfo: Option[ApplicationInfo] = None
+ def getOrFetchCurrentApplicationInfo: Option[ApplicationInfo] = {
Review Comment:
done
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@kyuubi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@kyuubi.apache.org
For additional commands, e-mail: notifications-help@kyuubi.apache.org
[GitHub] [kyuubi] turboFei commented on a diff in pull request #4155: Reduce the application info call for batch
Posted by GitBox <gi...@apache.org>.
turboFei commented on code in PR #4155:
URL: https://github.com/apache/kyuubi/pull/4155#discussion_r1068916897
##########
kyuubi-server/src/main/scala/org/apache/kyuubi/server/api/v1/BatchesResource.scala:
##########
@@ -68,7 +68,7 @@ private[v1] class BatchesResource extends ApiRequestContext with Logging {
private def buildBatch(session: KyuubiBatchSessionImpl): Batch = {
val batchOp = session.batchJobSubmissionOp
val batchOpStatus = batchOp.getStatus
- val batchAppStatus = batchOp.currentApplicationInfo
+ val batchAppStatus = batchOp.getApplicationInfo
Review Comment:
thanks, done
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@kyuubi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@kyuubi.apache.org
For additional commands, e-mail: notifications-help@kyuubi.apache.org
[GitHub] [kyuubi] turboFei closed pull request #4155: Reduce the application info call for batch
Posted by GitBox <gi...@apache.org>.
turboFei closed pull request #4155: Reduce the application info call for batch
URL: https://github.com/apache/kyuubi/pull/4155
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@kyuubi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@kyuubi.apache.org
For additional commands, e-mail: notifications-help@kyuubi.apache.org