Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Сomments are considered incorrect

Павел Суров January 29, 2021

Hi!
I develop plugin for Bitbucket Server version 7.6.0.
I want to get all comments on pull request. I use method commentService.search

commentService.search(new CommentSearchRequest.Builder(pullRequest).build(), new PageRequestImpl(0, 100));

This method don't return all comments but only file's comment.
What do i do wrong and how i can fix this? 

1 answer

1 accepted

0 votes
Answer accepted
Павел Суров February 1, 2021

nessesary to use 

CommentSearchRequest.Builder builder = new CommentSearchRequest.Builder(pullRequest);
builder.anchorState(CommentThreadDiffAnchorState.ALL);
commentService.search(builder.build(), new PageRequestImpl(0, 100)).getSize();

 

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events