Skip to content

Commit 516c31f

Browse files
committed
Add sample annotations
1 parent 9b88753 commit 516c31f

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

sample/CanalSharp.SimpleClient/Program.cs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,9 @@ static void Main(string[] args)
2121
connector.Subscribe(".*\\\\..*");
2222
while (true)
2323
{
24-
//获取消息数据
25-
var message = connector.Get(5000);
24+
//获取数据 1024表示数据大小 单位为字节
25+
var message = connector.Get(1024);
26+
//批次id 可用于回滚
2627
var batchId = message.Id;
2728
if (batchId == -1 || message.Entries.Count <= 0)
2829
{

0 commit comments

Comments
 (0)