Skip to content

Commit 9eced92

Browse files
authored
Introduce internals.tidb.io in README (#319)
* update readme.md Signed-off-by: ekexium <ekexium@gmail.com> * fix clippy Signed-off-by: ekexium <ekexium@gmail.com> * ci: update commands for tiup 1.6 Signed-off-by: ekexium <ekexium@gmail.com> * fix fmt Signed-off-by: ekexium <ekexium@gmail.com> * remove SIG-related stuff in README Signed-off-by: ekexium <ekexium@gmail.com>
1 parent eb1d2da commit 9eced92

File tree

8 files changed

+34
-18
lines changed

8 files changed

+34
-18
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,6 @@ jobs:
105105
- name: install tiup
106106
run: curl --proto '=https' --tlsv1.2 -sSf https://tiup-mirrors.pingcap.com/install.sh | sh
107107
- name: start tiup playground
108-
run: /home/runner/.tiup/bin/tiup playground nightly --mode tikv-slim --kv 3 --monitor false --kv.config /home/runner/work/client-rust/client-rust/config/tikv.toml --pd.config /home/runner/work/client-rust/client-rust/config/pd.toml &
108+
run: /home/runner/.tiup/bin/tiup playground nightly --mode tikv-slim --kv 3 --without-monitor --kv.config /home/runner/work/client-rust/client-rust/config/tikv.toml --pd.config /home/runner/work/client-rust/client-rust/config/pd.toml &
109109
- name: integration test
110110
run: make integration-test

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,6 @@ doc:
3131
# docker: docker-pd docker-kv
3232

3333
tiup:
34-
tiup playground nightly --mode tikv-slim --kv 3 --monitor false --kv.config $(shell pwd)/config/tikv.toml --pd.config $(shell pwd)/config/pd.toml &
34+
tiup playground nightly --mode tikv-slim --kv 3 --without-monitor --kv.config $(shell pwd)/config/tikv.toml --pd.config $(shell pwd)/config/pd.toml &
3535

3636
all: check doc test

README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,8 @@ Please follow PingCAP's [Rust style guide](https://pingcap.github.io/style-guid
137137

138138
## Getting help
139139

140-
If you need help, either to find something to work on, or with any technical problem, the easiest way to get it is via Slack. We monitor the client-rust (better for general client questions) and sig-transaction (better for technical questions about TiKV's transaction protocol) channels on the [tikv-wg slack](https://tikv.org/chat).
140+
If you need help, either to find something to work on, or with any technical problem, the easiest way to get it is via internals.tidb.io, the forum for TiDB developers.
141141

142-
You can also get help on GitHub issues or PRs directly. You can just ask a question; if you don't get a response, you should ping @nrc or @ekexium.
142+
You can also ask in Slack. We monitor the #client-rust channel on the [tikv-wg slack](https://tikv.org/chat).
143+
144+
You can just ask a question on GitHub issues or PRs directly; if you don't get a response, you should ping @ekexium or @andylokandy.

mock-tikv/src/pd.rs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,11 @@ use tikv_client_proto::pdpb::*;
99
pub const MOCK_PD_PORT: u16 = 50021;
1010
/// This is mock pd server, used with mock tikv server.
1111
#[derive(Debug, Clone)]
12-
pub struct MockPd {
13-
ts: i64,
14-
}
12+
pub struct MockPd {}
1513

1614
impl MockPd {
1715
fn new() -> MockPd {
18-
MockPd { ts: 0 }
16+
MockPd {}
1917
}
2018

2119
fn region() -> tikv_client_proto::metapb::Region {

src/pd/client.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -195,8 +195,8 @@ pub trait PdClient: Send + Sync + 'static {
195195

196196
fn decode_region(mut region: RegionWithLeader, enable_codec: bool) -> Result<RegionWithLeader> {
197197
if enable_codec {
198-
codec::decode_bytes_in_place(&mut region.region.mut_start_key(), false)?;
199-
codec::decode_bytes_in_place(&mut region.region.mut_end_key(), false)?;
198+
codec::decode_bytes_in_place(region.region.mut_start_key(), false)?;
199+
codec::decode_bytes_in_place(region.region.mut_end_key(), false)?;
200200
}
201201
Ok(region)
202202
}

src/raw/client.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,9 @@ impl Client<PdRpcClient> {
7474
/// vec!["192.168.0.100"],
7575
/// Config::default().with_timeout(Duration::from_secs(60)),
7676
/// None,
77-
/// ).await.unwrap();
77+
/// )
78+
/// .await
79+
/// .unwrap();
7880
/// # });
7981
/// ```
8082
pub async fn new_with_config<S: Into<String>>(

src/transaction/client.rs

Lines changed: 18 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,9 @@ impl Client {
5151
/// # use tikv_client::{Config, TransactionClient};
5252
/// # use futures::prelude::*;
5353
/// # futures::executor::block_on(async {
54-
/// let client = TransactionClient::new(vec!["192.168.0.100"], None).await.unwrap();
54+
/// let client = TransactionClient::new(vec!["192.168.0.100"], None)
55+
/// .await
56+
/// .unwrap();
5557
/// # });
5658
/// ```
5759
pub async fn new<S: Into<String>>(
@@ -79,7 +81,9 @@ impl Client {
7981
/// vec!["192.168.0.100"],
8082
/// Config::default().with_timeout(Duration::from_secs(60)),
8183
/// None,
82-
/// ).await.unwrap();
84+
/// )
85+
/// .await
86+
/// .unwrap();
8387
/// # });
8488
/// ```
8589
pub async fn new_with_config<S: Into<String>>(
@@ -117,7 +121,9 @@ impl Client {
117121
/// # use tikv_client::{Config, TransactionClient};
118122
/// # use futures::prelude::*;
119123
/// # futures::executor::block_on(async {
120-
/// let client = TransactionClient::new(vec!["192.168.0.100"], None).await.unwrap();
124+
/// let client = TransactionClient::new(vec!["192.168.0.100"], None)
125+
/// .await
126+
/// .unwrap();
121127
/// let mut transaction = client.begin_optimistic().await.unwrap();
122128
/// // ... Issue some commands.
123129
/// transaction.commit().await.unwrap();
@@ -140,7 +146,9 @@ impl Client {
140146
/// # use tikv_client::{Config, TransactionClient};
141147
/// # use futures::prelude::*;
142148
/// # futures::executor::block_on(async {
143-
/// let client = TransactionClient::new(vec!["192.168.0.100"], None).await.unwrap();
149+
/// let client = TransactionClient::new(vec!["192.168.0.100"], None)
150+
/// .await
151+
/// .unwrap();
144152
/// let mut transaction = client.begin_pessimistic().await.unwrap();
145153
/// // ... Issue some commands.
146154
/// transaction.commit().await.unwrap();
@@ -160,7 +168,9 @@ impl Client {
160168
/// # use tikv_client::{Config, TransactionClient, TransactionOptions};
161169
/// # use futures::prelude::*;
162170
/// # futures::executor::block_on(async {
163-
/// let client = TransactionClient::new(vec!["192.168.0.100"], None).await.unwrap();
171+
/// let client = TransactionClient::new(vec!["192.168.0.100"], None)
172+
/// .await
173+
/// .unwrap();
164174
/// let mut transaction = client
165175
/// .begin_with_options(TransactionOptions::default().use_async_commit())
166176
/// .await
@@ -190,7 +200,9 @@ impl Client {
190200
/// # use tikv_client::{Config, TransactionClient};
191201
/// # use futures::prelude::*;
192202
/// # futures::executor::block_on(async {
193-
/// let client = TransactionClient::new(vec!["192.168.0.100"], None).await.unwrap();
203+
/// let client = TransactionClient::new(vec!["192.168.0.100"], None)
204+
/// .await
205+
/// .unwrap();
194206
/// let timestamp = client.current_timestamp().await.unwrap();
195207
/// # });
196208
/// ```

src/transaction/transaction.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,9 @@ use tokio::{sync::RwLock, time::Duration};
4949
/// # use tikv_client::{Config, TransactionClient};
5050
/// # use futures::prelude::*;
5151
/// # futures::executor::block_on(async {
52-
/// let client = TransactionClient::new(vec!["192.168.0.100"], None).await.unwrap();
52+
/// let client = TransactionClient::new(vec!["192.168.0.100"], None)
53+
/// .await
54+
/// .unwrap();
5355
/// let mut txn = client.begin_optimistic().await.unwrap();
5456
/// let foo = txn.get("foo".to_owned()).await.unwrap().unwrap();
5557
/// txn.put("bar".to_owned(), foo).await.unwrap();

0 commit comments

Comments
 (0)