account for the overhead of tags on a message when batching transactions into a version
increased the default location cache size
This commit is contained in:
parent
3cb7fb3f0f
commit
18509ac4dd
|
@ -51,6 +51,7 @@ ClientKnobs::ClientKnobs(bool randomize) {
|
|||
init( DEFAULT_MAX_BACKOFF, 1.0 );
|
||||
init( BACKOFF_GROWTH_RATE, 2.0 );
|
||||
init( RESOURCE_CONSTRAINED_MAX_BACKOFF, 30.0 );
|
||||
init( PROXY_COMMIT_OVERHEAD_BYTES, 23 ); //The size of serializing 7 tags (3 primary, 3 remote, 1 log router) + 2 for the tag length
|
||||
|
||||
init( TRANSACTION_SIZE_LIMIT, 1e7 );
|
||||
init( KEY_SIZE_LIMIT, 1e4 );
|
||||
|
@ -61,7 +62,7 @@ ClientKnobs::ClientKnobs(bool randomize) {
|
|||
init( MAX_BATCH_SIZE, 20 ); if( randomize && BUGGIFY ) MAX_BATCH_SIZE = 1; // Note that SERVER_KNOBS->START_TRANSACTION_MAX_BUDGET_SIZE is set to match this value
|
||||
init( GRV_BATCH_TIMEOUT, 0.005 ); if( randomize && BUGGIFY ) GRV_BATCH_TIMEOUT = 0.1;
|
||||
|
||||
init( LOCATION_CACHE_EVICTION_SIZE, 100000 );
|
||||
init( LOCATION_CACHE_EVICTION_SIZE, 300000 );
|
||||
init( LOCATION_CACHE_EVICTION_SIZE_SIM, 10 ); if( randomize && BUGGIFY ) LOCATION_CACHE_EVICTION_SIZE_SIM = 3;
|
||||
|
||||
init( GET_RANGE_SHARD_LIMIT, 2 );
|
||||
|
|
|
@ -49,6 +49,7 @@ public:
|
|||
double DEFAULT_MAX_BACKOFF;
|
||||
double BACKOFF_GROWTH_RATE;
|
||||
double RESOURCE_CONSTRAINED_MAX_BACKOFF;
|
||||
int PROXY_COMMIT_OVERHEAD_BYTES;
|
||||
|
||||
int64_t TRANSACTION_SIZE_LIMIT;
|
||||
int64_t KEY_SIZE_LIMIT;
|
||||
|
|
|
@ -101,7 +101,7 @@ static inline int getBytes( CommitTransactionRequest const& r ) {
|
|||
//return r.arena.getSize(); // NOT correct because arena can be shared!
|
||||
int total = sizeof(r);
|
||||
for(auto m = r.transaction.mutations.begin(); m != r.transaction.mutations.end(); ++m)
|
||||
total += m->expectedSize();
|
||||
total += m->expectedSize() + CLIENT_KNOBS->PROXY_COMMIT_OVERHEAD_BYTES;
|
||||
for(auto i = r.transaction.read_conflict_ranges.begin(); i != r.transaction.read_conflict_ranges.end(); ++i)
|
||||
total += i->expectedSize();
|
||||
for(auto i = r.transaction.write_conflict_ranges.begin(); i != r.transaction.write_conflict_ranges.end(); ++i)
|
||||
|
|
Loading…
Reference in New Issue