You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by "LuciferYang (via GitHub)" <gi...@apache.org> on 2023/05/10 16:09:34 UTC

[GitHub] [spark] LuciferYang opened a new pull request, #41122: [SPARK-43436][BUILD] Upgrade rocksdbjni to 8.1.1.1

LuciferYang opened a new pull request, #41122:
URL: https://github.com/apache/spark/pull/41122

   <!--
   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://spark.apache.org/contributing.html
     2. Ensure you have added or run the appropriate tests for your PR: https://spark.apache.org/developer-tools.html
     3. If the PR is unfinished, add '[WIP]' in your PR title, e.g., '[WIP][SPARK-XXXX] Your PR title ...'.
     4. Be sure to keep the PR description updated to reflect all changes.
     5. Please write your PR title to summarize what this PR proposes.
     6. If possible, provide a concise example to reproduce the issue for a faster review.
     7. If you want to add a new configuration, please read the guideline first for naming configurations in
        'core/src/main/scala/org/apache/spark/internal/config/ConfigEntry.scala'.
     8. If you want to add or modify an error type or message, please read the guideline first in
        'core/src/main/resources/error/README.md'.
   -->
   
   ### What changes were proposed in this pull request?
   <!--
   Please clarify what changes you are proposing. The purpose of this section is to outline the changes and how this PR fixes the issue. 
   If possible, please consider writing useful notes for better and faster reviews in your PR. See the examples below.
     1. If you refactor some codes with changing classes, showing the class hierarchy will help reviewers.
     2. If you fix some SQL features, you can provide some references of other DBMSes.
     3. If there is design documentation, please add the link.
     4. If there is a discussion in the mailing list, please add the link.
   -->
   
   
   ### Why are the changes needed?
   <!--
   Please clarify why the changes are needed. For instance,
     1. If you propose a new API, clarify the use case for a new API.
     2. If you fix a bug, you can clarify why it is a bug.
   -->
   
   
   ### Does this PR introduce _any_ user-facing change?
   <!--
   Note that it means *any* user-facing change including all aspects such as the documentation fix.
   If yes, please clarify the previous behavior and the change this PR proposes - provide the console output, description and/or an example to show the behavior difference if possible.
   If possible, please also clarify if this is a user-facing change compared to the released Spark versions or within the unreleased branches such as master.
   If no, write 'No'.
   -->
   
   
   ### How was this patch tested?
   <!--
   If tests were added, say they were added here. Please make sure to add some test cases that check the changes thoroughly including negative and positive cases if possible.
   If it was tested in a way different from regular unit tests, please clarify how you tested step by step, ideally copy and paste-able, so that other reviewers can test and check, and descendants can verify in the future.
   If tests were not added, please describe why they were not added and/or why it was difficult to add.
   If benchmark tests were added, please run the benchmarks in GitHub Actions for the consistent environment, and the instructions could accord to: https://spark.apache.org/developer-tools.html#github-workflow-benchmarks.
   -->
   


-- 
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: reviews-unsubscribe@spark.apache.org

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


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


[GitHub] [spark] LuciferYang commented on pull request #41122: [SPARK-43436][BUILD] Upgrade rocksdbjni to 8.1.1.1

Posted by "LuciferYang (via GitHub)" <gi...@apache.org>.
LuciferYang commented on PR #41122:
URL: https://github.com/apache/spark/pull/41122#issuecomment-1545207874

   If this is expected, optimizing benchmark testing should be more reasonable, as current benchmark testing will fail due to GA timeout
   
   


-- 
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: reviews-unsubscribe@spark.apache.org

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


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


[GitHub] [spark] dongjoon-hyun commented on pull request #41122: [SPARK-43436][BUILD] Upgrade rocksdbjni to 8.1.1.1

Posted by "dongjoon-hyun (via GitHub)" <gi...@apache.org>.
dongjoon-hyun commented on PR #41122:
URL: https://github.com/apache/spark/pull/41122#issuecomment-1552036061

   Merged to master for Apache Spark 3.5.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: reviews-unsubscribe@spark.apache.org

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


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


[GitHub] [spark] dongjoon-hyun closed pull request #41122: [SPARK-43436][BUILD] Upgrade rocksdbjni to 8.1.1.1

Posted by "dongjoon-hyun (via GitHub)" <gi...@apache.org>.
dongjoon-hyun closed pull request #41122: [SPARK-43436][BUILD] Upgrade rocksdbjni to 8.1.1.1
URL: https://github.com/apache/spark/pull/41122


-- 
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: reviews-unsubscribe@spark.apache.org

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


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


[GitHub] [spark] LuciferYang commented on pull request #41122: [SPARK-43436][BUILD] Upgrade rocksdbjni to 8.1.1.1

Posted by "LuciferYang (via GitHub)" <gi...@apache.org>.
LuciferYang commented on PR #41122:
URL: https://github.com/apache/spark/pull/41122#issuecomment-1547242903

   Thanks @anishshri-db 


-- 
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: reviews-unsubscribe@spark.apache.org

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


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


[GitHub] [spark] LuciferYang commented on pull request #41122: [SPARK-43436][BUILD] Upgrade rocksdbjni to 8.1.1.1

Posted by "LuciferYang (via GitHub)" <gi...@apache.org>.
LuciferYang commented on PR #41122:
URL: https://github.com/apache/spark/pull/41122#issuecomment-1545057975

   When I tried this upgrade, I found that the result of 'StateStoreBasicOperationsBenchmark' was unexpected. For check if it was a new version(8.1.1.1) issue, I also ran the 'StateStoreBasicOperationsBenchmark' on the master branch(with 8.0.0), and there were significant differences between the test data and the previous records and 'StateStoreBasicOperationsBenchmark' also run timeout(more than 6hours, It should have been completed in 3 hours before):
   
   https://github.com/LuciferYang/spark/actions/runs/4949396450/jobs/8856766625
   
   ``
   [success] Total time: 791 s (13:11), completed May 11, 2023 7:33:07 PM
   23/05/11 19:33:12 WARN NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
   Running org.apache.spark.sql.execution.benchmark.StateStoreBasicOperationsBenchmark:
   23/05/11 19:33:15 WARN SparkContext: The JAR file:/home/runner/work/spark/spark/core/target/scala-2.12/spark-core_2.12-3.5.0-SNAPSHOT-tests.jar at spark://localhost:44659/jars/spark-core_2.12-3.5.0-SNAPSHOT-tests.jar has been added already. Overwriting of added jar is not supported in the current version.
   Running benchmark: putting 10000 rows (10000 rows to overwrite - rate 100)
     Running case: In-memory
     Stopped after 10000 iterations, 82351 ms
     Running case: RocksDB (trackTotalNumberOfRows: true)
     Stopped after 10000 iterations, 599839 ms
     Running case: RocksDB (trackTotalNumberOfRows: false)
     Stopped after 10000 iterations, 210482 ms
   
   OpenJDK 64-Bit Server VM 1.8.0_362-b09 on Linux 5.15.0-1037-azure
   Intel(R) Xeon(R) Platinum 8370C CPU @ 2.80GHz
   putting 10000 rows (10000 rows to overwrite - rate 100):  Best Time(ms)   Avg Time(ms)   Stdev(ms)    Rate(M/s)   Per Row(ns)   Relative
   ---------------------------------------------------------------------------------------------------------------------------------------
   In-memory                                                            7              8           1          1.4         739.9       1.0X
   RocksDB (trackTotalNumberOfRows: true)                              58             60           1          0.2        5828.2       0.1X
   RocksDB (trackTotalNumberOfRows: false)                             20             21           0          0.5        2033.4       0.4X
   
   OpenJDK 64-Bit Server VM 1.8.0_362-b09 on Linux 5.15.0-1037-azure
   Intel(R) Xeon(R) Platinum 8370C CPU @ 2.80GHz
   putting 10000 rows (7500 rows to overwrite - rate 75):  Best Time(ms)   Avg Time(ms)   Stdev(ms)    Rate(M/s)   Per Row(ns)   Relative
   -------------------------------------------------------------------------------------------------------------------------------------
   In-memory                                                          8              9           1          1.3         772.9       1.0X
   RocksDB (trackTotalNumberOfRows: true)                            56             58           1          0.2        5567.7       0.1X
   RocksDB (trackTotalNumberOfRows: false)                           21             23           4          0.5        2126.2       0.4X
   
   OpenJDK 64-Bit Server VM 1.8.0_362-b09 on Linux 5.15.0-1037-azure
   Intel(R) Xeon(R) Platinum 8370C CPU @ 2.80GHz
   putting 10000 rows (5000 rows to overwrite - rate 50):  Best Time(ms)   Avg Time(ms)   Stdev(ms)    Rate(M/s)   Per Row(ns)   Relative
   -------------------------------------------------------------------------------------------------------------------------------------
   In-memory                                                          8              9           1          1.3         760.7       1.0X
   RocksDB (trackTotalNumberOfRows: true)                            51             53           1          0.2        5089.3       0.1X
   RocksDB (trackTotalNumberOfRows: false)                           21             22           1          0.5        2133.7       0.4X
   
   
   OpenJDK 64-Bit Server VM 1.8.0_362-b09 on Linux 5.15.0-1037-azure
   Intel(R) Xeon(R) Platinum 8370C CPU @ 2.80GHz
   putting 10000 rows (2500 rows to overwrite - rate 25):  Best Time(ms)   Avg Time(ms)   Stdev(ms)    Rate(M/s)   Per Row(ns)   Relative
   -------------------------------------------------------------------------------------------------------------------------------------
   In-memory                                                          7              8           1          1.3         747.6       1.0X
   RocksDB (trackTotalNumberOfRows: true)                            46             47           1          0.2        4603.3       0.2X
   RocksDB (trackTotalNumberOfRows: false)                           21             22           1          0.5        2141.8       0.3X
   
   
   OpenJDK 64-Bit Server VM 1.8.0_362-b09 on Linux 5.15.0-1037-azure
   Intel(R) Xeon(R) Platinum 8370C CPU @ 2.80GHz
   putting 10000 rows (1000 rows to overwrite - rate 10):  Best Time(ms)   Avg Time(ms)   Stdev(ms)    Rate(M/s)   Per Row(ns)   Relative
   -------------------------------------------------------------------------------------------------------------------------------------
   In-memory                                                          7              8           1          1.4         732.3       1.0X
   RocksDB (trackTotalNumberOfRows: true)                            43             44           1          0.2        4283.7       0.2X
   RocksDB (trackTotalNumberOfRows: false)                           21             22           1          0.5        2132.0       0.3X
   
   
   OpenJDK 64-Bit Server VM 1.8.0_362-b09 on Linux 5.15.0-1037-azure
   Intel(R) Xeon(R) Platinum 8370C CPU @ 2.80GHz
   putting 10000 rows (500 rows to overwrite - rate 5):  Best Time(ms)   Avg Time(ms)   Stdev(ms)    Rate(M/s)   Per Row(ns)   Relative
   -----------------------------------------------------------------------------------------------------------------------------------
   In-memory                                                        7              8           1          1.4         732.3       1.0X
   RocksDB (trackTotalNumberOfRows: true)                          42             43           1          0.2        4169.4       0.2X
   RocksDB (trackTotalNumberOfRows: false)                         21             22           1          0.5        2124.4       0.3X
   
   
   OpenJDK 64-Bit Server VM 1.8.0_362-b09 on Linux 5.15.0-1037-azure
   Intel(R) Xeon(R) Platinum 8370C CPU @ 2.80GHz
   putting 10000 rows (0 rows to overwrite - rate 0):  Best Time(ms)   Avg Time(ms)   Stdev(ms)    Rate(M/s)   Per Row(ns)   Relative
   ---------------------------------------------------------------------------------------------------------------------------------
   In-memory                                                      7              8           1          1.4         727.9       1.0X
   RocksDB (trackTotalNumberOfRows: true)                        40             42           1          0.2        4038.6       0.2X
   RocksDB (trackTotalNumberOfRows: false)                       21             22           1          0.5        2129.9       0.3X
   
   .......
   
   OpenJDK 64-Bit Server VM 1.8.0_362-b09 on Linux 5.15.0-1037-azure
   Intel(R) Xeon(R) Platinum 8370C CPU @ 2.80GHz
   evicting 1000 rows (maxTimestampToEvictInMillis: 999) from 10000 rows:  Best Time(ms)   Avg Time(ms)   Stdev(ms)    Rate(M/s)   Per Row(ns)   Relative
   -----------------------------------------------------------------------------------------------------------------------------------------------------
   In-memory                                                                          5              5           0          2.2         458.3       1.0X
   RocksDB (trackTotalNumberOfRows: true)                                             9              9           0          1.1         871.2       0.5X
   RocksDB (trackTotalNumberOfRows: false)                                            5              6           0          1.9         518.3       0.9X
   
   Running benchmark: evicting 500 rows (maxTimestampToEvictInMillis: 499) from 10000 rows
     Running case: In-memory
     Stopped after 10000 iterations, 50617 ms
     Running case: RocksDB (trackTotalNumberOfRows: true)
   Error: The operation was canceled.
   ```
   
   I will try to investigate this issue, cc @dongjoon-hyun @HeartSaVioR FYI
   


-- 
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: reviews-unsubscribe@spark.apache.org

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


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


[GitHub] [spark] LuciferYang commented on pull request #41122: [SPARK-43436][BUILD] Upgrade rocksdbjni to 8.1.1.1

Posted by "LuciferYang (via GitHub)" <gi...@apache.org>.
LuciferYang commented on PR #41122:
URL: https://github.com/apache/spark/pull/41122#issuecomment-1542472612

   will update result of `StateStoreBasicOperationsBenchmark` later


-- 
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: reviews-unsubscribe@spark.apache.org

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


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


[GitHub] [spark] HeartSaVioR commented on pull request #41122: [SPARK-43436][BUILD] Upgrade rocksdbjni to 8.1.1.1

Posted by "HeartSaVioR (via GitHub)" <gi...@apache.org>.
HeartSaVioR commented on PR #41122:
URL: https://github.com/apache/spark/pull/41122#issuecomment-1545192031

   That's because we no longer use writebatch which has been problematic on memory usage. We should have probably run the benchmark and updated the result...
   
   The overall performance won't be significantly reduced as we pay the cost in each operation without writebatch which we are going to pay the cost at once in commit phase when we use writebatch & flush in commit phase. (We benchmarked by ourselves.)
   
   cc. @anishshri-db Would you mind adding more context here? We probably need to update the benchmark, with reduce of the number of operations.


-- 
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: reviews-unsubscribe@spark.apache.org

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


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


[GitHub] [spark] dongjoon-hyun commented on pull request #41122: [SPARK-43436][BUILD] Upgrade rocksdbjni to 8.1.1.1

Posted by "dongjoon-hyun (via GitHub)" <gi...@apache.org>.
dongjoon-hyun commented on PR #41122:
URL: https://github.com/apache/spark/pull/41122#issuecomment-1545091809

   Thank you for your investigation, @LuciferYang !


-- 
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: reviews-unsubscribe@spark.apache.org

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


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


[GitHub] [spark] anishshri-db commented on pull request #41122: [SPARK-43436][BUILD] Upgrade rocksdbjni to 8.1.1.1

Posted by "anishshri-db (via GitHub)" <gi...@apache.org>.
anishshri-db commented on PR #41122:
URL: https://github.com/apache/spark/pull/41122#issuecomment-1547231543

   @LuciferYang - As @HeartSaVioR mentioned, this is part of our broader effort to reduce memory usage for rocksdb. As part of that change, we don't use writeBatch any more and have also moved to disable the write ahead log. As part of this, puts/deletes will be written to memtables and gets will also be served from memtables/block cache which might lead to some difference in perf for those options. We can cover up for most of that since the db write during commit is now eliminated and we can also do periodic flushing with a related upcoming change.
   
   Could you let me know which b/mark test will fail and how we run that ?
   
   @HeartSaVioR - do you proposing changing the b/mark itself ? or rerunning and updating the results page ?


-- 
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: reviews-unsubscribe@spark.apache.org

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


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


[GitHub] [spark] LuciferYang commented on pull request #41122: [SPARK-43436][BUILD] Upgrade rocksdbjni to 8.1.1.1

Posted by "LuciferYang (via GitHub)" <gi...@apache.org>.
LuciferYang commented on PR #41122:
URL: https://github.com/apache/spark/pull/41122#issuecomment-1547239087

   @anishshri-db I need to update the results of `StateStoreBasicOperationsBenchmark` when upgrade rocksdbjni, we can run `StateStoreBasicOperationsBenchmark` with GA as following:
   
   <img width="355" alt="image" src="https://github.com/apache/spark/assets/1475305/b5ce0ad4-b3e8-48a1-bc52-3db3b0dfa5ad">
    
   It did not fail and was killed by GA due to timeout. Previously, 'StateStoreBasicOperationsBenchmark' was executed for 3 hours, but now it has been executed for more than 6 hours and has not been completed yet.
   


-- 
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: reviews-unsubscribe@spark.apache.org

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


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


[GitHub] [spark] anishshri-db commented on pull request #41122: [SPARK-43436][BUILD] Upgrade rocksdbjni to 8.1.1.1

Posted by "anishshri-db (via GitHub)" <gi...@apache.org>.
anishshri-db commented on PR #41122:
URL: https://github.com/apache/spark/pull/41122#issuecomment-1547242180

   @LuciferYang - ok cool thanks. I'll update the b/mark and try running this workflow.


-- 
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: reviews-unsubscribe@spark.apache.org

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


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