Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update tendermint to use Mutex instead RWMutex for query safety #657

Merged
merged 1 commit into from
Jan 11, 2022

Conversation

yun-yeo
Copy link
Contributor

@yun-yeo yun-yeo commented Jan 10, 2022

Summary of changes

We monitored #599 error when we use concurrent ABCI wasm query.
so to pervent this problem on main branch, we updated forked cosmos-sdk and tendermint to use Mutex instead of RWMutex on ABCI query.

Even we revert RWMutex updates, this branch still contains rocksdb updates #654 and configurable IAVL and inter-block cache updates #655 .
so node operators can configure these values in ~/.terra/config/app.toml

# InterBlockCacheSize set the size (the number of cache items) of interblock cache item
# Each item consumes 128 bytes, so the value should be dividend by 128
# Default cache size is 10mb.
# Ex) 100mb = 10,000,000 / 128 = 78,125
inter-block-cache-size = 78125

# IAVLCacheSize set the cache size (the number of cache items) of the iavl tree.
# Each item size consumes 128 bytes, so the value should be dividend by 128
# Default cache size is 100mb.
# Ex) 100mb = 100,000,000 / 128 = 781,250
iavl-cache-size = 781250

or can use rocksdb by building terrad with

COSMOS_BUILD_OPTIONS=rocksdb make install

Report of required housekeeping

  • Github issue OR spec proposal link
  • Wrote tests
  • Updated API documentation (client/lcd/swagger-ui/swagger.yaml)
  • Added a relevant changelog entry: clog add [section] [stanza] [message]

(FOR ADMIN) Before merging

  • Added appropriate labels to PR
  • Squashed all commits, uses message "Merge pull request #XYZ: [title]" (coding standards)
  • Confirm added tests are consistent with the intended behavior of changes
  • Ensure all tests pass

@yun-yeo yun-yeo requested a review from hanjukim January 10, 2022 10:05
@yun-yeo yun-yeo self-assigned this Jan 10, 2022
@codecov
Copy link

codecov bot commented Jan 10, 2022

Codecov Report

Merging #657 (ab1ced0) into main (0c293aa) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##             main     #657   +/-   ##
=======================================
  Coverage   44.63%   44.63%           
=======================================
  Files         120      120           
  Lines        6999     6999           
=======================================
  Hits         3124     3124           
  Misses       3630     3630           
  Partials      245      245           

@yun-yeo yun-yeo requested a review from Vritra4 January 11, 2022 02:39
Copy link

@Vritra4 Vritra4 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@yun-yeo yun-yeo merged commit 0b3a306 into main Jan 11, 2022
@yun-yeo yun-yeo deleted the mutex-tendermint branch January 11, 2022 08:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants