GeezerVison is showing github.com — example: update python scripts, more config options · coder-java-caicai/codis@069d7a2
File tree
Expand file treeCollapse file tree
Open diff view settings
Expand file treeCollapse file tree
Open diff view settings
Collapse file
Copy file name to clipboardExpand all lines: example/dashboard.py +6Lines changed: 6 additions & 0 deletions | Original file line number | Diff line number | Diff line change |
|---|
@@ -32,6 +32,12 @@ def _open_config(admin_port, product_name, product_auth=None): |
32 | 32 | if product_auth is not None: |
33 | 33 | f.write('product_auth = "{}"\n'.format(product_auth)) |
34 | 34 | f.write('admin_addr = ":{}"\n'.format(admin_port)) |
| 35 | + f.write('forward_method = "semi-async"\n') |
| 36 | + f.write('migrate_async_maxbulks = 1000\n') |
| 37 | + f.write('migrate_async_maxbytes = "256k"\n') |
| 38 | + f.write('migrate_async_numkeys = 128\n') |
| 39 | + f.write('sentinel_quorum = 2\n') |
| 40 | + f.write('sentinel_parallel_syncs = 1\n') |
35 | 41 | f.write('sentinel_down_after = "5s"\n') |
36 | 42 | f.write('sentinel_failover_timeout = "10m"\n') |
37 | 43 | path = os.getcwd() |
|
Collapse file
Copy file name to clipboardExpand all lines: example/proxy.py +14Lines changed: 14 additions & 0 deletions | Original file line number | Diff line number | Diff line change |
|---|
@@ -36,6 +36,20 @@ def _open_config(admin_port, proxy_port, product_name, product_auth=None): |
36 | 36 | f.write('proxy_datacenter = "localhost"\n') |
37 | 37 | f.write('proxy_heap_placeholder = "0"\n') |
38 | 38 | f.write('proxy_max_offheap_size = "0"\n') |
| 39 | + f.write('backend_ping_period = "5s"\n') |
| 40 | + f.write('backend_recv_bufsize = "128kb"\n') |
| 41 | + f.write('backend_recv_timeout = "30s"\n') |
| 42 | + f.write('backend_send_bufsize = "128kb"\n') |
| 43 | + f.write('backend_send_timeout = "30s"\n') |
| 44 | + f.write('backend_max_pipeline = 1024\n') |
| 45 | + f.write('backend_primary_only = false\n') |
| 46 | + f.write('backend_keepalive_period = "75s"\n') |
| 47 | + f.write('session_recv_bufsize = "128kb"\n') |
| 48 | + f.write('session_recv_timeout = "30m"\n') |
| 49 | + f.write('session_send_bufsize = "64kb"\n') |
| 50 | + f.write('session_send_timeout = "30s"\n') |
| 51 | + f.write('session_max_pipeline = 1024\n') |
| 52 | + f.write('session_keepalive_period = "75s"\n') |
39 | 53 | f.write('session_break_on_failure = false\n') |
40 | 54 | return config |
41 | 55 |
|
|