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

ProductList 的请求参数为什么会有ProductId #31

Open
yesgs opened this issue Jul 4, 2022 · 1 comment
Open

ProductList 的请求参数为什么会有ProductId #31

yesgs opened this issue Jul 4, 2022 · 1 comment

Comments

@yesgs
Copy link

yesgs commented Jul 4, 2022

go-zero微服务实战系列(五、缓存代码怎么写)里面的 ProductListRequest 结构为什么会有 ProductId

message ProductListRequest {
  int32 category_id = 1;
  int64 cursor = 2;
  int32 ps = 3;
  int64 product_id = 4;
}

请问这个 ProductId 的作用是什么?

@zhoushuguang
Copy link
Owner

防止cursor重复,去重用

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants