You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kyuubi.apache.org by GitBox <gi...@apache.org> on 2021/07/20 08:23:53 UTC

[GitHub] [incubator-kyuubi] hddong opened a new pull request #840: [KYUUBI#839]Fix load user specific defaults from properties file

hddong opened a new pull request #840:
URL: https://github.com/apache/incubator-kyuubi/pull/840


   <!--
   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/contributions.html
     2. If the PR is related to an issue in https://github.com/apache/incubator-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.
   -->
   loadFromMap ignored user specific defaults that start with '___'.
   
   ### _How was this patch tested?_
   - [X] 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.readthedocs.io/en/latest/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: commits-unsubscribe@kyuubi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-kyuubi] codecov-commenter edited a comment on pull request #840: [KYUUBI #839]Fix load user specific defaults from properties file

Posted by GitBox <gi...@apache.org>.
codecov-commenter edited a comment on pull request #840:
URL: https://github.com/apache/incubator-kyuubi/pull/840#issuecomment-883824641


   # [Codecov](https://codecov.io/gh/apache/incubator-kyuubi/pull/840?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) Report
   > Merging [#840](https://codecov.io/gh/apache/incubator-kyuubi/pull/840?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (ba3683e) into [master](https://codecov.io/gh/apache/incubator-kyuubi/commit/7ee92ce5c1831fa20e62c1a703fd0564416f75cd?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (7ee92ce) will **increase** coverage by `0.00%`.
   > The diff coverage is `50.00%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-kyuubi/pull/840/graphs/tree.svg?width=650&height=150&src=pr&token=925D4tb9AH&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/incubator-kyuubi/pull/840?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@            Coverage Diff            @@
   ##             master     #840   +/-   ##
   =========================================
     Coverage     78.60%   78.60%           
     Complexity       10       10           
   =========================================
     Files           135      135           
     Lines          5122     5123    +1     
     Branches        641      642    +1     
   =========================================
   + Hits           4026     4027    +1     
     Misses          745      745           
     Partials        351      351           
   ```
   
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-kyuubi/pull/840?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | Coverage Δ | |
   |---|---|---|
   | [...in/scala/org/apache/kyuubi/config/KyuubiConf.scala](https://codecov.io/gh/apache/incubator-kyuubi/pull/840/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-a3l1dWJpLWNvbW1vbi9zcmMvbWFpbi9zY2FsYS9vcmcvYXBhY2hlL2t5dXViaS9jb25maWcvS3l1dWJpQ29uZi5zY2FsYQ==) | `94.06% <50.00%> (+0.01%)` | :arrow_up: |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-kyuubi/pull/840?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-kyuubi/pull/840?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Last update [7ee92ce...ba3683e](https://codecov.io/gh/apache/incubator-kyuubi/pull/840?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   


-- 
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: commits-unsubscribe@kyuubi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-kyuubi] yaooqinn commented on a change in pull request #840: [KYUUBI #839]Fix load user specific defaults from properties file

Posted by GitBox <gi...@apache.org>.
yaooqinn commented on a change in pull request #840:
URL: https://github.com/apache/incubator-kyuubi/pull/840#discussion_r673020501



##########
File path: kyuubi-common/src/test/scala/org/apache/kyuubi/config/KyuubiConfSuite.scala
##########
@@ -97,17 +97,13 @@ class KyuubiConfSuite extends KyuubiFunSuite {
 
 
   test("get user specific defaults") {
-    val conf = KyuubiConf(false)
-      .set("spark.user.test", "a")
-      .set("___userb___.spark.user.test", "b")
-      .set("___userc___.spark.user.test", "c")
-
-    val all1 = conf.getUserDefaults("kyuubi").getAll
-    assert(all1.size === 1)
-    assert(all1("spark.user.test") === "a")
-    val all2 = conf.getUserDefaults("userb").getAll
-    assert(all2.size === 1)
-    assert(all2("spark.user.test") === "b")
+    sys.props.put("spark.user.test", "a")

Review comment:
       can we add a file in test resource?




-- 
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: commits-unsubscribe@kyuubi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-kyuubi] ulysses-you commented on pull request #840: [KYUUBI #839]Fix load user specific defaults from properties file

Posted by GitBox <gi...@apache.org>.
ulysses-you commented on pull request #840:
URL: https://github.com/apache/incubator-kyuubi/pull/840#issuecomment-883872525


   thanks, merging to master/v1.2.0


-- 
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: commits-unsubscribe@kyuubi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-kyuubi] ulysses-you closed pull request #840: [KYUUBI #839]Fix load user specific defaults from properties file

Posted by GitBox <gi...@apache.org>.
ulysses-you closed pull request #840:
URL: https://github.com/apache/incubator-kyuubi/pull/840


   


-- 
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: commits-unsubscribe@kyuubi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-kyuubi] yaooqinn commented on a change in pull request #840: [KYUUBI #839]Fix load user specific defaults from properties file

Posted by GitBox <gi...@apache.org>.
yaooqinn commented on a change in pull request #840:
URL: https://github.com/apache/incubator-kyuubi/pull/840#discussion_r673020501



##########
File path: kyuubi-common/src/test/scala/org/apache/kyuubi/config/KyuubiConfSuite.scala
##########
@@ -97,17 +97,13 @@ class KyuubiConfSuite extends KyuubiFunSuite {
 
 
   test("get user specific defaults") {
-    val conf = KyuubiConf(false)
-      .set("spark.user.test", "a")
-      .set("___userb___.spark.user.test", "b")
-      .set("___userc___.spark.user.test", "c")
-
-    val all1 = conf.getUserDefaults("kyuubi").getAll
-    assert(all1.size === 1)
-    assert(all1("spark.user.test") === "a")
-    val all2 = conf.getUserDefaults("userb").getAll
-    assert(all2.size === 1)
-    assert(all2("spark.user.test") === "b")
+    sys.props.put("spark.user.test", "a")

Review comment:
       can we add a file in test resource?




-- 
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: commits-unsubscribe@kyuubi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [incubator-kyuubi] codecov-commenter commented on pull request #840: [KYUUBI #839]Fix load user specific defaults from properties file

Posted by GitBox <gi...@apache.org>.
codecov-commenter commented on pull request #840:
URL: https://github.com/apache/incubator-kyuubi/pull/840#issuecomment-883824641


   # [Codecov](https://codecov.io/gh/apache/incubator-kyuubi/pull/840?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) Report
   > Merging [#840](https://codecov.io/gh/apache/incubator-kyuubi/pull/840?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (398c569) into [master](https://codecov.io/gh/apache/incubator-kyuubi/commit/7ee92ce5c1831fa20e62c1a703fd0564416f75cd?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (7ee92ce) will **increase** coverage by `0.00%`.
   > The diff coverage is `50.00%`.
   
   > :exclamation: Current head 398c569 differs from pull request most recent head ba3683e. Consider uploading reports for the commit ba3683e to get more accurate results
   [![Impacted file tree graph](https://codecov.io/gh/apache/incubator-kyuubi/pull/840/graphs/tree.svg?width=650&height=150&src=pr&token=925D4tb9AH&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/incubator-kyuubi/pull/840?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@            Coverage Diff            @@
   ##             master     #840   +/-   ##
   =========================================
     Coverage     78.60%   78.60%           
     Complexity       10       10           
   =========================================
     Files           135      135           
     Lines          5122     5123    +1     
     Branches        641      642    +1     
   =========================================
   + Hits           4026     4027    +1     
     Misses          745      745           
     Partials        351      351           
   ```
   
   
   | [Impacted Files](https://codecov.io/gh/apache/incubator-kyuubi/pull/840?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | Coverage Δ | |
   |---|---|---|
   | [...in/scala/org/apache/kyuubi/config/KyuubiConf.scala](https://codecov.io/gh/apache/incubator-kyuubi/pull/840/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-a3l1dWJpLWNvbW1vbi9zcmMvbWFpbi9zY2FsYS9vcmcvYXBhY2hlL2t5dXViaS9jb25maWcvS3l1dWJpQ29uZi5zY2FsYQ==) | `94.06% <50.00%> (+0.01%)` | :arrow_up: |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/incubator-kyuubi/pull/840?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/incubator-kyuubi/pull/840?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Last update [7ee92ce...ba3683e](https://codecov.io/gh/apache/incubator-kyuubi/pull/840?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   


-- 
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: commits-unsubscribe@kyuubi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org