Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
MB-48562 Use macros instead of hard-coded bucket values
Rather than hard-code values which could be present in more than one file we'll use macros. Change-Id: Ifdb13375db4b6819f9f9c810741878bf010e76d9 Reviewed-on: http://review.couchbase.org/c/ns_server/+/163503 Well-Formed: Build Bot <build@couchbase.com> Tested-by: Steve Watanabe <steve.watanabe@couchbase.com> Reviewed-by: Meni Hillel <meni.hillel@couchbase.com>
- Loading branch information
1 parent
4348680
commit 55f7b92
Showing
4 changed files
with
85 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
%% @author Couchbase <info@couchbase.com> | ||
%% @copyright 2021-Present Couchbase, Inc. | ||
%% | ||
%% Use of this software is governed by the Business Source License included | ||
%% in the file licenses/BSL-Couchbase.txt. As of the Change Date specified | ||
%% in that file, in accordance with the Business Source License, use of this | ||
%% software will be governed by the Apache License, Version 2.0, included in | ||
%% the file licenses/APL2.txt. | ||
%% | ||
%% @doc Bucket related macros | ||
%% | ||
|
||
-define(MAGMA_FRAG_PERCENTAGE, 50). | ||
-define(MIN_MAGMA_FRAG_PERCENTAGE, 10). | ||
-define(MAX_MAGMA_FRAG_PERCENTAGE, 100). | ||
|
||
-define(MAGMA_STORAGE_QUOTA_PERCENTAGE, 10). | ||
-define(MIN_MAGMA_STORAGE_QUOTA_PERCENTAGE, 1). | ||
-define(MAX_MAGMA_STORAGE_QUOTA_PERCENTAGE, 85). | ||
|
||
-define(NUM_WORKER_THREADS, 3). | ||
-define(MIN_NUM_WORKER_THREADS, 2). | ||
-define(MAX_NUM_WORKER_THREADS, 8). | ||
|
||
-define(MEMBASE_HT_LOCKS, 47). | ||
-define(MAX_NUM_REPLICAS, 3). | ||
-define(MIN_DRIFT_BEHIND_THRESHOLD, 100). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters