Skip to content
Permalink
Browse files

Copy of

commit dcd9379eb5707bc7514a2ff4d9127790356505cb
Author: Manuel Ung <mung@fb.com>
Date:   Fri Jun 14 10:38:17 2019 -0700

    Skip valgrind for rocksdb.force_shutdown

    Summary:
    This test does unclean shutdown, and leaks memory.

    Squash with: D15749084

    Reviewed By: hermanlee

    Differential Revision: D15828957

    fbshipit-source-id: 30541455d74
  • Loading branch information...
spetrunia committed Jun 15, 2019
1 parent faa4d8f commit 5173e396ffce706954f7302e9854126aadab4c54
Showing with 18,235 additions and 5,212 deletions.
  1. +70 −26 storage/rocksdb/.clang-format
  2. +23 −1 storage/rocksdb/CMakeLists.txt
  3. +5 −4 storage/rocksdb/event_listener.cc
  4. +3 −3 storage/rocksdb/event_listener.h
  5. +2,132 −1,859 storage/rocksdb/ha_rocksdb.cc
  6. +122 −522 storage/rocksdb/ha_rocksdb.h
  7. +2 −2 storage/rocksdb/ha_rocksdb_proto.h
  8. +3 −3 storage/rocksdb/logger.h
  9. +16 −4 storage/rocksdb/myrocks_hotbackup
  10. +0 −1 storage/rocksdb/mysql-test/rocksdb/combinations
  11. +14 −2 storage/rocksdb/mysql-test/rocksdb/include/bulk_load.inc
  12. +3 −2 storage/rocksdb/mysql-test/rocksdb/include/bulk_load_unsorted.inc
  13. +298 −0 storage/rocksdb/mysql-test/rocksdb/include/bypass_create_table.inc
  14. +3 −2 storage/rocksdb/mysql-test/rocksdb/include/locking_issues_case3.inc
  15. +3 −2 storage/rocksdb/mysql-test/rocksdb/include/locking_issues_case4.inc
  16. +3 −2 storage/rocksdb/mysql-test/rocksdb/include/locking_issues_case5.inc
  17. +3 −2 storage/rocksdb/mysql-test/rocksdb/include/locking_issues_case6.inc
  18. +0 −53 storage/rocksdb/mysql-test/rocksdb/include/rocksdb_concurrent_delete.inc
  19. +23 −0 storage/rocksdb/mysql-test/rocksdb/include/use_direct_io_option.inc
  20. +1 −1 storage/rocksdb/mysql-test/rocksdb/r/add_index_inplace_sstfilewriter.result
  21. +21 −0 storage/rocksdb/mysql-test/rocksdb/r/autoinc_vars.result
  22. +5 −3 storage/rocksdb/mysql-test/rocksdb/r/{blind_delete_without_tx_api.result → blind_delete_rc.result}
  23. +87 −0 storage/rocksdb/mysql-test/rocksdb/r/blind_delete_rr.result
  24. +4 −1 storage/rocksdb/mysql-test/rocksdb/r/bloomfilter3.result
  25. +24 −1 storage/rocksdb/mysql-test/rocksdb/r/bloomfilter5.result
  26. +8 −6 storage/rocksdb/mysql-test/rocksdb/r/bulk_load.result
  27. +8 −6 storage/rocksdb/mysql-test/rocksdb/r/bulk_load_rev_cf.result
  28. +8 −6 storage/rocksdb/mysql-test/rocksdb/r/bulk_load_rev_cf_and_data.result
  29. +8 −6 storage/rocksdb/mysql-test/rocksdb/r/bulk_load_rev_data.result
  30. +3 −6 storage/rocksdb/mysql-test/rocksdb/r/bulk_load_unsorted.result
  31. +3 −6 storage/rocksdb/mysql-test/rocksdb/r/bulk_load_unsorted_rev.result
  32. +693 −0 storage/rocksdb/mysql-test/rocksdb/r/bypass_select_basic.result
  33. +693 −0 storage/rocksdb/mysql-test/rocksdb/r/bypass_select_basic_bloom.result
  34. +47 −0 storage/rocksdb/mysql-test/rocksdb/r/check_flags.result
  35. +6 −6 storage/rocksdb/mysql-test/rocksdb/r/cons_snapshot_read_committed.result
  36. +1 −1 storage/rocksdb/mysql-test/rocksdb/r/cons_snapshot_repeatable_read.result
  37. +5 −5 storage/rocksdb/mysql-test/rocksdb/r/corrupted_data_reads_debug.result
  38. +15 −1 storage/rocksdb/mysql-test/rocksdb/r/create_no_primary_key_table.result
  39. +77 −77 storage/rocksdb/mysql-test/rocksdb/r/ddl_high_priority.result
  40. +2 −1 storage/rocksdb/mysql-test/rocksdb/r/deadlock_stats.result
  41. +0 −15 storage/rocksdb/mysql-test/rocksdb/r/delete_before_lock.result
  42. +38 −0 storage/rocksdb/mysql-test/rocksdb/r/force_shutdown.result
  43. +3,503 −0 storage/rocksdb/mysql-test/rocksdb/r/group_min_max.result
  44. +10 −0 storage/rocksdb/mysql-test/rocksdb/r/ha_extra_keyread.result
  45. +196 −3 storage/rocksdb/mysql-test/rocksdb/r/insert_with_keys.result
  46. +7 −7 storage/rocksdb/mysql-test/rocksdb/r/issue255.result
  47. +79 −0 storage/rocksdb/mysql-test/rocksdb/r/issue884.result
  48. +17 −0 storage/rocksdb/mysql-test/rocksdb/r/issue896.result
  49. +11 −0 storage/rocksdb/mysql-test/rocksdb/r/issue900.result
  50. +15 −0 storage/rocksdb/mysql-test/rocksdb/r/iterator_bounds.result
  51. +128 −0 storage/rocksdb/mysql-test/rocksdb/r/mysqlbinlog_blind_replace.result
  52. +73 −9 storage/rocksdb/mysql-test/rocksdb/r/mysqldump.result
  53. +98 −0 storage/rocksdb/mysql-test/rocksdb/r/optimize_myrocks_replace_into_base.result
  54. +46 −0 storage/rocksdb/mysql-test/rocksdb/r/optimize_myrocks_replace_into_lock.result
  55. +7 −0 storage/rocksdb/mysql-test/rocksdb/r/prefix_extractor_override.result
  56. +15 −6 storage/rocksdb/mysql-test/rocksdb/r/rocksdb.result
  57. +1 −1 storage/rocksdb/mysql-test/rocksdb/r/rocksdb_checksums.result
  58. +469 −8 storage/rocksdb/mysql-test/rocksdb/r/rocksdb_concurrent_delete.result
  59. +335 −0 storage/rocksdb/mysql-test/rocksdb/r/rocksdb_read_free_rpl.result
  60. +35 −0 storage/rocksdb/mysql-test/rocksdb/r/rocksdb_read_free_rpl_stress.result
  61. +72 −0 storage/rocksdb/mysql-test/rocksdb/r/rocksdb_timeout_rollback.result
  62. +0 −321 storage/rocksdb/mysql-test/rocksdb/r/rpl_read_free.result
  63. +56 −0 storage/rocksdb/mysql-test/rocksdb/r/rpl_row_not_found_rc.result
  64. +16 −0 storage/rocksdb/mysql-test/rocksdb/r/show_engine.result
  65. +3 −3 storage/rocksdb/mysql-test/rocksdb/r/show_table_status.result
  66. +31 −0 storage/rocksdb/mysql-test/rocksdb/r/skip_core_dump_on_error.result
  67. +9 −9 storage/rocksdb/mysql-test/rocksdb/r/statistics.result
  68. +4 −4 storage/rocksdb/mysql-test/rocksdb/r/tbl_opt_data_index_dir.result
  69. +620 −0 storage/rocksdb/mysql-test/rocksdb/r/truncate_partition.result
  70. +45 −0 storage/rocksdb/mysql-test/rocksdb/r/ttl_rows_examined.result
  71. +3 −3 storage/rocksdb/mysql-test/rocksdb/r/type_decimal.result
  72. +18 −0 storage/rocksdb/mysql-test/rocksdb/r/use_direct_io_for_flush_and_compaction.result
  73. +20 −0 storage/rocksdb/mysql-test/rocksdb/t/autoinc_vars.test
  74. 0 storage/rocksdb/mysql-test/rocksdb/t/{blind_delete_without_tx_api.cnf → blind_delete_rc.cnf}
  75. +3 −0 storage/rocksdb/mysql-test/rocksdb/t/blind_delete_rc.test
  76. +11 −0 storage/rocksdb/mysql-test/rocksdb/t/blind_delete_rr.cnf
  77. +3 −0 storage/rocksdb/mysql-test/rocksdb/t/blind_delete_rr.test
  78. +5 −3 ...rocksdb/mysql-test/rocksdb/t/{blind_delete_without_tx_api.test → blind_delete_without_tx_api.inc}
  79. +1 −0 storage/rocksdb/mysql-test/rocksdb/t/bloomfilter3-master.opt
  80. +4 −0 storage/rocksdb/mysql-test/rocksdb/t/bloomfilter3.test
  81. +1 −1 storage/rocksdb/mysql-test/rocksdb/t/bloomfilter5-master.opt
  82. +26 −1 storage/rocksdb/mysql-test/rocksdb/t/bloomfilter5.test
  83. +1 −0 storage/rocksdb/mysql-test/rocksdb/t/bulk_load.test
  84. +19 −4 storage/rocksdb/mysql-test/rocksdb/t/bulk_load_errors.test
  85. +1 −0 storage/rocksdb/mysql-test/rocksdb/t/bulk_load_rev_cf.test
  86. +1 −0 storage/rocksdb/mysql-test/rocksdb/t/bulk_load_rev_cf_and_data.test
  87. +1 −0 storage/rocksdb/mysql-test/rocksdb/t/bulk_load_rev_data.test
  88. +213 −0 storage/rocksdb/mysql-test/rocksdb/t/bypass_select_basic.inc
  89. +3 −0 storage/rocksdb/mysql-test/rocksdb/t/bypass_select_basic.test
  90. +3 −0 storage/rocksdb/mysql-test/rocksdb/t/bypass_select_basic_bloom-master.opt
  91. +3 −0 storage/rocksdb/mysql-test/rocksdb/t/bypass_select_basic_bloom.test
  92. +117 −0 storage/rocksdb/mysql-test/rocksdb/t/check_flags.test
  93. +3 −0 storage/rocksdb/mysql-test/rocksdb/t/com_rpc_tx.test
  94. +1 −0 storage/rocksdb/mysql-test/rocksdb/t/cons_snapshot_read_committed.opt
  95. +1 −0 storage/rocksdb/mysql-test/rocksdb/t/cons_snapshot_repeatable_read.opt
  96. +1 −0 storage/rocksdb/mysql-test/rocksdb/t/cons_snapshot_serializable.opt
  97. +20 −1 storage/rocksdb/mysql-test/rocksdb/t/create_no_primary_key_table.test
  98. +0 −36 storage/rocksdb/mysql-test/rocksdb/t/delete_before_lock.test
  99. +97 −0 storage/rocksdb/mysql-test/rocksdb/t/force_shutdown.test
  100. +1 −0 storage/rocksdb/mysql-test/rocksdb/t/group_min_max-master.opt
  101. +8 −0 storage/rocksdb/mysql-test/rocksdb/t/group_min_max.test
  102. +15 −0 storage/rocksdb/mysql-test/rocksdb/t/ha_extra_keyread.test
  103. +90 −14 storage/rocksdb/mysql-test/rocksdb/t/insert_with_keys.test
  104. +8 −8 storage/rocksdb/mysql-test/rocksdb/t/issue255.test
  105. +43 −0 storage/rocksdb/mysql-test/rocksdb/t/issue884.test
  106. +17 −0 storage/rocksdb/mysql-test/rocksdb/t/issue896.test
  107. +13 −0 storage/rocksdb/mysql-test/rocksdb/t/issue900.test
  108. +2 −0 storage/rocksdb/mysql-test/rocksdb/t/iterator_bounds-master.opt
  109. +29 −0 storage/rocksdb/mysql-test/rocksdb/t/iterator_bounds.test
  110. +1 −0 storage/rocksdb/mysql-test/rocksdb/t/level_read_uncommitted.opt
  111. +62 −0 storage/rocksdb/mysql-test/rocksdb/t/mysqlbinlog_blind_replace.test
  112. +7 −1 storage/rocksdb/mysql-test/rocksdb/t/mysqldump.test
  113. +96 −0 storage/rocksdb/mysql-test/rocksdb/t/optimize_myrocks_replace_into_base.test
  114. +88 −0 storage/rocksdb/mysql-test/rocksdb/t/optimize_myrocks_replace_into_lock.test
  115. +4 −0 storage/rocksdb/mysql-test/rocksdb/t/prefix_extractor_override.test
  116. +5 −4 storage/rocksdb/mysql-test/rocksdb/t/rocksdb.test
  117. +106 −0 storage/rocksdb/mysql-test/rocksdb/t/rocksdb_concurrent_delete.inc
  118. +33 −19 storage/rocksdb/mysql-test/rocksdb/t/rocksdb_concurrent_delete.test
  119. +30 −0 storage/rocksdb/mysql-test/rocksdb/t/rocksdb_concurrent_delete_main.inc
  120. +85 −0 storage/rocksdb/mysql-test/rocksdb/t/rocksdb_concurrent_delete_range.inc
  121. +82 −0 storage/rocksdb/mysql-test/rocksdb/t/rocksdb_concurrent_delete_sk.inc
  122. +3 −2 storage/rocksdb/mysql-test/rocksdb/t/rocksdb_locks.test
  123. +4 −2 storage/rocksdb/mysql-test/rocksdb/t/{rpl_read_free.cnf → rocksdb_read_free_rpl.cnf}
  124. +414 −0 storage/rocksdb/mysql-test/rocksdb/t/rocksdb_read_free_rpl.test
  125. +17 −0 storage/rocksdb/mysql-test/rocksdb/t/rocksdb_read_free_rpl_stress.cnf
  126. +69 −0 storage/rocksdb/mysql-test/rocksdb/t/rocksdb_read_free_rpl_stress.inc
  127. +22 −0 storage/rocksdb/mysql-test/rocksdb/t/rocksdb_read_free_rpl_stress.test
  128. +1 −0 storage/rocksdb/mysql-test/rocksdb/t/rocksdb_timeout_rollback-master.opt
  129. +78 −0 storage/rocksdb/mysql-test/rocksdb/t/rocksdb_timeout_rollback.test
  130. +0 −302 storage/rocksdb/mysql-test/rocksdb/t/rpl_read_free.test
  131. +11 −0 storage/rocksdb/mysql-test/rocksdb/t/rpl_row_not_found_rc.cnf
  132. +4 −0 storage/rocksdb/mysql-test/rocksdb/t/rpl_row_not_found_rc.test
  133. +2 −2 storage/rocksdb/mysql-test/rocksdb/t/rpl_row_triggers.cnf
  134. +4 −0 storage/rocksdb/mysql-test/rocksdb/t/rqg_examples.test
  135. +4 −0 storage/rocksdb/mysql-test/rocksdb/t/rqg_runtime.test
  136. +4 −0 storage/rocksdb/mysql-test/rocksdb/t/rqg_transactions.test
  137. +1 −0 storage/rocksdb/mysql-test/rocksdb/t/skip_core_dump_on_error-master.opt
  138. +53 −0 storage/rocksdb/mysql-test/rocksdb/t/skip_core_dump_on_error.test
  139. +102 −0 storage/rocksdb/mysql-test/rocksdb/t/truncate_partition.inc
  140. +82 −0 storage/rocksdb/mysql-test/rocksdb/t/truncate_partition.test
  141. +56 −0 storage/rocksdb/mysql-test/rocksdb/t/ttl_rows_examined.test
  142. +2 −1 storage/rocksdb/mysql-test/rocksdb/t/unique_check.test
  143. +5 −0 storage/rocksdb/mysql-test/rocksdb/t/use_direct_io_for_flush_and_compaction.test
  144. +2 −34 storage/rocksdb/mysql-test/rocksdb/t/use_direct_reads.test
  145. +1 −0 storage/rocksdb/mysql-test/rocksdb/t/use_direct_reads_writes.test
  146. +8 −0 storage/rocksdb/mysql-test/rocksdb_hotbackup/include/clean_tmpfiles.sh
  147. +14 −16 storage/rocksdb/mysql-test/rocksdb_hotbackup/include/stream_run.sh
  148. +21 −0 storage/rocksdb/mysql-test/rocksdb_hotbackup/r/xbstream_direct.result
  149. +25 −0 storage/rocksdb/mysql-test/rocksdb_hotbackup/t/xbstream.inc
  150. +6 −24 storage/rocksdb/mysql-test/rocksdb_hotbackup/t/xbstream.test
  151. +1 −0 storage/rocksdb/mysql-test/rocksdb_hotbackup/t/xbstream_direct-master.opt
  152. +7 −0 storage/rocksdb/mysql-test/rocksdb_hotbackup/t/xbstream_direct.test
  153. +5 −1 storage/rocksdb/mysql-test/rocksdb_rpl/combinations
  154. +37 −0 storage/rocksdb/mysql-test/rocksdb_rpl/include/rpl_gtid_crash_safe.inc
  155. +282 −0 storage/rocksdb/mysql-test/rocksdb_rpl/r/optimize_myrocks_replace_into.result
  156. +165 −0 storage/rocksdb/mysql-test/rocksdb_rpl/r/rocksdb_slave_check_before_image_consistency.result
  157. +361 −0 storage/rocksdb/mysql-test/rocksdb_rpl/r/rpl_gtid_crash_safe_optimized.result
  158. +43 −0 storage/rocksdb/mysql-test/rocksdb_rpl/r/rpl_rocksdb_slave_gtid_info_optimized.result
  159. +0 −2 storage/rocksdb/mysql-test/rocksdb_rpl/t/combinations
  160. +149 −0 storage/rocksdb/mysql-test/rocksdb_rpl/t/optimize_myrocks_replace_into.test
  161. +1 −0 storage/rocksdb/mysql-test/rocksdb_rpl/t/rocksdb_slave_check_before_image_consistency-slave.opt
  162. +22 −0 storage/rocksdb/mysql-test/rocksdb_rpl/t/rocksdb_slave_check_before_image_consistency.test
  163. +4 −35 storage/rocksdb/mysql-test/rocksdb_rpl/t/rpl_gtid_crash_safe.test
  164. +1 −0 storage/rocksdb/mysql-test/rocksdb_rpl/t/rpl_gtid_crash_safe_optimized-master.opt
  165. +2 −0 storage/rocksdb/mysql-test/rocksdb_rpl/t/rpl_gtid_crash_safe_optimized-slave.opt
  166. +11 −0 storage/rocksdb/mysql-test/rocksdb_rpl/t/rpl_gtid_crash_safe_optimized.test
  167. +1 −0 storage/rocksdb/mysql-test/rocksdb_rpl/t/rpl_rocksdb_slave_gtid_info_optimized-master.opt
  168. +1 −0 storage/rocksdb/mysql-test/rocksdb_rpl/t/rpl_rocksdb_slave_gtid_info_optimized-slave.opt
  169. +51 −0 storage/rocksdb/mysql-test/rocksdb_rpl/t/rpl_rocksdb_slave_gtid_info_optimized.test
  170. +19 −0 storage/rocksdb/mysql-test/rocksdb_sys_vars/r/rocksdb_cache_dump_basic.result
  171. +22 −0 storage/rocksdb/mysql-test/rocksdb_sys_vars/r/rocksdb_cache_high_pri_pool_ratio_basic.result
  172. +19 −0 ...ksdb/mysql-test/rocksdb_sys_vars/r/rocksdb_cache_index_and_filter_with_high_priority_basic.result
  173. +14 −14 storage/rocksdb/mysql-test/rocksdb_sys_vars/r/rocksdb_commit_time_batch_for_recovery_basic.result
  174. +6 −0 storage/rocksdb/mysql-test/rocksdb_sys_vars/r/rocksdb_delete_cf_basic.result
  175. +75 −0 storage/rocksdb/mysql-test/rocksdb_sys_vars/r/rocksdb_enable_insert_with_update_caching_basic.result
  176. +58 −0 storage/rocksdb/mysql-test/rocksdb_sys_vars/r/rocksdb_read_free_rpl_basic.result
  177. +17 −33 storage/rocksdb/mysql-test/rocksdb_sys_vars/r/rocksdb_read_free_rpl_tables_basic.result
  178. +97 −0 storage/rocksdb/mysql-test/rocksdb_sys_vars/r/rocksdb_rollback_on_timeout_basic.result
  179. +2 −0 storage/rocksdb/mysql-test/rocksdb_sys_vars/r/rocksdb_skip_unique_check_tables_basic.result
  180. +85 −0 storage/rocksdb/mysql-test/rocksdb_sys_vars/r/rocksdb_stats_level_basic.result
  181. +4 −0 storage/rocksdb/mysql-test/rocksdb_sys_vars/r/rocksdb_update_cf_options_basic.result
  182. +21 −0 storage/rocksdb/mysql-test/rocksdb_sys_vars/t/rocksdb_cache_dump_basic.test
  183. +24 −0 storage/rocksdb/mysql-test/rocksdb_sys_vars/t/rocksdb_cache_high_pri_pool_ratio_basic.test
  184. +21 −0 ...ocksdb/mysql-test/rocksdb_sys_vars/t/rocksdb_cache_index_and_filter_with_high_priority_basic.test
  185. +1 −0 storage/rocksdb/mysql-test/rocksdb_sys_vars/t/rocksdb_delete_cf_basic-master.opt
  186. +75 −0 storage/rocksdb/mysql-test/rocksdb_sys_vars/t/rocksdb_delete_cf_basic.test
  187. +21 −0 storage/rocksdb/mysql-test/rocksdb_sys_vars/t/rocksdb_enable_insert_with_update_caching_basic.test
  188. +19 −0 storage/rocksdb/mysql-test/rocksdb_sys_vars/t/rocksdb_read_free_rpl_basic.test
  189. +6 −1 storage/rocksdb/mysql-test/rocksdb_sys_vars/t/rocksdb_read_free_rpl_tables_basic.test
  190. +21 −0 storage/rocksdb/mysql-test/rocksdb_sys_vars/t/rocksdb_rollback_on_timeout_basic.test
  191. +3 −0 storage/rocksdb/mysql-test/rocksdb_sys_vars/t/rocksdb_skip_unique_check_tables_basic.test
  192. +21 −0 storage/rocksdb/mysql-test/rocksdb_sys_vars/t/rocksdb_stats_level_basic.test
  193. +11 −0 storage/rocksdb/mysql-test/rocksdb_sys_vars/t/rocksdb_update_cf_options_basic.test
  194. +52 −0 storage/rocksdb/nosql_access.cc
  195. +35 −0 storage/rocksdb/nosql_access.h
  196. +52 −44 storage/rocksdb/properties_collector.cc
  197. +29 −24 storage/rocksdb/properties_collector.h
  198. +106 −32 storage/rocksdb/rdb_buff.h
  199. +96 −16 storage/rocksdb/rdb_cf_manager.cc
  200. +7 −5 storage/rocksdb/rdb_cf_manager.h
  201. +33 −37 storage/rocksdb/rdb_cf_options.cc
  202. +9 −9 storage/rocksdb/rdb_cf_options.h
  203. +17 −15 storage/rocksdb/rdb_compact_filter.h
  204. +3 −3 storage/rocksdb/rdb_comparator.h
  205. +829 −0 storage/rocksdb/rdb_converter.cc
  206. +247 −0 storage/rocksdb/rdb_converter.h
  207. +982 −907 storage/rocksdb/rdb_datadic.cc
  208. +311 −207 storage/rocksdb/rdb_datadic.h
  209. +392 −0 storage/rocksdb/rdb_global.h
  210. +73 −44 storage/rocksdb/rdb_i_s.cc
  211. +1 −1 storage/rocksdb/rdb_i_s.h
  212. +12 −8 storage/rocksdb/rdb_index_merge.cc
  213. +9 −6 storage/rocksdb/rdb_index_merge.h
  214. +6 −5 storage/rocksdb/rdb_io_watchdog.cc
  215. +8 −6 storage/rocksdb/rdb_io_watchdog.h
  216. +10 −10 storage/rocksdb/rdb_mutex_wrapper.cc
  217. +20 −20 storage/rocksdb/rdb_mutex_wrapper.h
  218. +13 −11 storage/rocksdb/rdb_perf_context.cc
  219. +8 −5 storage/rocksdb/rdb_perf_context.h
  220. +5 −11 storage/rocksdb/rdb_psi.cc
  221. +2 −1 storage/rocksdb/rdb_psi.h
  222. +87 −146 storage/rocksdb/rdb_sst_info.cc
  223. +99 −20 storage/rocksdb/rdb_sst_info.h
  224. +5 −5 storage/rocksdb/rdb_threads.cc
  225. +10 −10 storage/rocksdb/rdb_threads.h
  226. +15 −11 storage/rocksdb/rdb_utils.cc
  227. +42 −20 storage/rocksdb/rdb_utils.h
@@ -1,23 +1,49 @@
---
# Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License, version 2.0,
# as published by the Free Software Foundation.
#
# This program is also distributed with certain software (including
# but not limited to OpenSSL) that is licensed under separate terms,
# as designated in a particular file or component or in included license
# documentation. The authors of MySQL hereby grant you an additional
# permission to link the program and your derivative works with the
# separately licensed software that they have included with MySQL.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License, version 2.0, for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA

# This is the output of clang-format-5.0 --style=google --dump-config,
# except for changes mentioned below. We lock the style so that any newer
# version of clang-format will give the same result; as time goes, we may
# update this list, requiring newer versions of clang-format.

Language: Cpp
# BasedOnStyle: LLVM
AccessModifierOffset: -2
# BasedOnStyle: Google
AccessModifierOffset: -1
AlignAfterOpenBracket: Align
AlignConsecutiveAssignments: false
AlignConsecutiveDeclarations: false
AlignEscapedNewlinesLeft: false
AlignEscapedNewlines: Left
AlignOperands: true
AlignTrailingComments: true
AllowAllParametersOfDeclarationOnNextLine: true
AllowShortBlocksOnASingleLine: false
AllowShortCaseLabelsOnASingleLine: false
AllowShortFunctionsOnASingleLine: All
AllowShortIfStatementsOnASingleLine: false
AllowShortLoopsOnASingleLine: false
AllowShortIfStatementsOnASingleLine: true
AllowShortLoopsOnASingleLine: true
AlwaysBreakAfterDefinitionReturnType: None
AlwaysBreakAfterReturnType: None
AlwaysBreakBeforeMultilineStrings: false
AlwaysBreakTemplateDeclarations: false
AlwaysBreakBeforeMultilineStrings: true
AlwaysBreakTemplateDeclarations: true
BinPackArguments: true
BinPackParameters: true
BraceWrapping:
@@ -32,62 +58,80 @@ BraceWrapping:
BeforeCatch: false
BeforeElse: false
IndentBraces: false
SplitEmptyFunction: true
SplitEmptyRecord: true
SplitEmptyNamespace: true
BreakBeforeBinaryOperators: None
BreakBeforeBraces: Attach
BreakBeforeInheritanceComma: false
BreakBeforeTernaryOperators: true
BreakConstructorInitializersBeforeComma: false
BreakConstructorInitializers: BeforeColon
BreakAfterJavaFieldAnnotations: false
BreakStringLiterals: true
ColumnLimit: 80
CommentPragmas: '^ IWYU pragma:'
ConstructorInitializerAllOnOneLineOrOnePerLine: false
CompactNamespaces: false
ConstructorInitializerAllOnOneLineOrOnePerLine: true
ConstructorInitializerIndentWidth: 4
ContinuationIndentWidth: 4
Cpp11BracedListStyle: true
DerivePointerAlignment: false
DisableFormat: false
ExperimentalAutoDetectBinPacking: false
ForEachMacros: [ foreach, Q_FOREACH, BOOST_FOREACH ]
FixNamespaceComments: true
ForEachMacros:
- foreach
- Q_FOREACH
- BOOST_FOREACH
IncludeCategories:
- Regex: '^"(llvm|llvm-c|clang|clang-c)/'
- Regex: '^<.*\.h>'
Priority: 1
- Regex: '^<.*'
Priority: 2
- Regex: '^(<|"(gtest|isl|json)/)'
Priority: 3
- Regex: '.*'
Priority: 1
IncludeIsMainRegex: '$'
IndentCaseLabels: false
Priority: 3
IncludeIsMainRegex: '([-_](test|unittest))?$'
IndentCaseLabels: true
IndentWidth: 2
IndentWrappedFunctionNames: false
KeepEmptyLinesAtTheStartOfBlocks: true
JavaScriptQuotes: Leave
JavaScriptWrapImports: true
KeepEmptyLinesAtTheStartOfBlocks: false
MacroBlockBegin: ''
MacroBlockEnd: ''
MaxEmptyLinesToKeep: 1
NamespaceIndentation: None
ObjCBlockIndentWidth: 2
ObjCSpaceAfterProperty: false
ObjCSpaceBeforeProtocolList: true
PenaltyBreakBeforeFirstCallParameter: 19
ObjCSpaceBeforeProtocolList: false
PenaltyBreakAssignment: 2
PenaltyBreakBeforeFirstCallParameter: 1
PenaltyBreakComment: 300
PenaltyBreakFirstLessLess: 120
PenaltyBreakString: 1000
PenaltyExcessCharacter: 1000000
PenaltyReturnTypeOnItsOwnLine: 60
PointerAlignment: Right
PenaltyReturnTypeOnItsOwnLine: 200
ReflowComments: true
SortIncludes: true
SortUsingDeclarations: true
SpaceAfterCStyleCast: false
SpaceAfterTemplateKeyword: true
SpaceBeforeAssignmentOperators: true
SpaceBeforeParens: ControlStatements
SpaceInEmptyParentheses: false
SpacesBeforeTrailingComments: 1
SpacesBeforeTrailingComments: 2
SpacesInAngles: false
SpacesInContainerLiterals: true
SpacesInCStyleCastParentheses: false
SpacesInParentheses: false
SpacesInSquareBrackets: false
Standard: Cpp11
TabWidth: 8
UseTab: Never
JavaScriptQuotes: Leave
...

# We declare one specific pointer style since right alignment is dominant in
# the MySQL code base (default --style=google has DerivePointerAlignment true).
DerivePointerAlignment: false
PointerAlignment: Right

# MySQL source code is allowed to use C++11 features.
Standard: Cpp11
@@ -60,6 +60,7 @@ SET(ROCKSDB_SOURCES
rdb_datadic.cc rdb_datadic.h
rdb_cf_options.cc rdb_cf_options.h
rdb_cf_manager.cc rdb_cf_manager.h
rdb_converter.cc rdb_converter.h
properties_collector.cc properties_collector.h
event_listener.cc event_listener.h
rdb_i_s.cc rdb_i_s.h
@@ -71,6 +72,7 @@ SET(ROCKSDB_SOURCES
rdb_sst_info.cc rdb_sst_info.h
rdb_utils.cc rdb_utils.h rdb_buff.h
rdb_threads.cc rdb_threads.h
nosql_access.cc nosql_access.h
${ROCKSDB_LIB_SOURCES}
)

@@ -81,6 +83,25 @@ ELSE()
ENDIF()

SET(rocksdb_static_libs )

IF (WITH_JEMALLOC)
FIND_LIBRARY(JEMALLOC_LIBRARY
NAMES libjemalloc${PIC_EXT}.a jemalloc
HINTS ${WITH_JEMALLOC}/lib)
SET(rocksdb_static_libs ${rocksdb_static_libs}
${JEMALLOC_LIBRARY})
ADD_DEFINITIONS(-DROCKSDB_JEMALLOC)
ADD_DEFINITIONS(-DROCKSDB_MALLOC_USABLE_SIZE)
ENDIF()

IF (WITH_UNWIND)
FIND_LIBRARY(UNWIND_LIBRARY
NAMES libunwind${PIC_EXT}.a unwind
HINTS ${WITH_UNWIND}/lib)
SET(rocksdb_static_libs ${rocksdb_static_libs}
${UNWIND_LIBRARY})
ENDIF()

IF (WITH_SNAPPY)
FIND_LIBRARY(SNAPPY_LIBRARY
NAMES libsnappy${PIC_EXT}.a snappy
@@ -111,6 +132,7 @@ ENDIF()
IF (WITH_ZSTD)
SET(rocksdb_static_libs ${rocksdb_static_libs} ${ZSTD_LIBRARY})
ADD_DEFINITIONS(-DZSTD)
ADD_DEFINITIONS(-DZSTD_STATIC_LINKING_ONLY)
ENDIF()

IF (WITH_TBB)
@@ -129,7 +151,7 @@ IF (HAVE_ZLIB_H)
SET(rocksdb_static_libs ${rocksdb_static_libs} ${ZLIB_LIBRARY})
ENDIF()

SET(rocksdb_static_libs ${rocksdb_static_libs} "-lrt")
SET(rocksdb_static_libs ${rocksdb_static_libs} "-lrt" "-ldl" "-lpthread")

MYSQL_ADD_PLUGIN(rocksdb_se ${ROCKSDB_SOURCES} STORAGE_ENGINE DEFAULT STATIC_ONLY
LINK_LIBRARIES ${rocksdb_static_libs}
@@ -32,9 +32,9 @@

namespace myrocks {

static std::vector<Rdb_index_stats>
extract_index_stats(const std::vector<std::string> &files,
const rocksdb::TablePropertiesCollection &props) {
static std::vector<Rdb_index_stats> extract_index_stats(
const std::vector<std::string> &files,
const rocksdb::TablePropertiesCollection &props) {
std::vector<Rdb_index_stats> ret;
for (auto fn : files) {
const auto it = props.find(fn);
@@ -85,10 +85,11 @@ void Rdb_event_listener::OnExternalFileIngested(
void Rdb_event_listener::OnBackgroundError(
rocksdb::BackgroundErrorReason reason, rocksdb::Status *status) {
rdb_log_status_error(*status, "Error detected in background");
// NO_LINT_DEBUG
sql_print_error("RocksDB: BackgroundErrorReason: %d", (int)reason);
if (status->IsCorruption()) {
rdb_persist_corruption_marker();
abort();
}
}
} // namespace myrocks
} // namespace myrocks
@@ -22,7 +22,7 @@ namespace myrocks {
class Rdb_ddl_manager;

class Rdb_event_listener : public rocksdb::EventListener {
public:
public:
Rdb_event_listener(const Rdb_event_listener &) = delete;
Rdb_event_listener &operator=(const Rdb_event_listener &) = delete;

@@ -40,10 +40,10 @@ class Rdb_event_listener : public rocksdb::EventListener {
void OnBackgroundError(rocksdb::BackgroundErrorReason reason,
rocksdb::Status *status) override;

private:
private:
Rdb_ddl_manager *m_ddl_manager;

void update_index_stats(const rocksdb::TableProperties &props);
};

} // namespace myrocks
} // namespace myrocks

0 comments on commit 5173e39

Please sign in to comment.
You can’t perform that action at this time.