Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix Chinese translation for chat server #78

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion posts/translations/zh-hans/chat-server.md
Original file line number Diff line number Diff line change
Expand Up @@ -548,7 +548,7 @@ $ just telnet # concurrent client 2

译注:`poll` 取得一些进展是指状态机发生变化即 `Pending` 状态,而状态机完成是指 `Ready` 状态。

一方面,这个功能很棒,因为我们开始 `poll` 一个 `Future` 随后可以决定不再需要等待其最终结果,我们可以停止`poll`从而不会浪费CPU做无效的工作。另外一方面,如果我们在一个 `Future` 的重要操作中间取消,没有有用没有完成可能导致丢失重要的数据或可能使数据处于损坏状态,这可能不太妙
一方面,这个功能很棒,因为我们开始 `poll` 一个 `Future` 随后可以决定不再需要等待其最终结果,我们可以停止`poll`从而不会浪费CPU做无效的工作。另一方面,这个功能在某些场景下会有危险,比如我们在一个 `Future` 正在执行重要操作的中途取消它,这时候如果执行没有完成,会造成数据的丢失;或者让数据处于损坏状态

让我们看一个取消`Future`的例子。取消并不是一个显式的操作,它只是意味着我们开始轮询一个`Future`,但是在完成之前就停止了轮询。

Expand Down