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

Expose a way to paginate details of GetPostInfoById method in APIService #23

Open
canaldocelo opened this issue Jan 16, 2023 · 1 comment

Comments

@canaldocelo
Copy link

I am trying to fetch all voters list for a specific Article so sending the postId I am not able to get all information if the voters are higher than 100 because of the checkLimit which has some constants set by maximum of 100

Method
**func (as *APIService) GetPostInfoById (ctx context.Context, req grpcpb.GetPostInfoByIdRequest) (grpcpb.GetPostInfoByIdResponse, error)

One way to solve would be removing the check

if uint32(len(voterList)) >= voterLimit {
return false
}

or exposing a sort of pagination in voteWrap.ForEachByOrder method. I would appreciate this feature to create dapps / services on top of contentos blockchain

@canaldocelo
Copy link
Author

@SeavantUUz I am aware you are busy but could please help on that or if I can help would be great as well

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

1 participant