Skip to content

Handling Salesforce paginated apis with Quarkus #36681

Answered by manofthepeace
IvanPuntev asked this question in Q&A
Discussion options

You must be logged in to vote

Something like this

     Multi<SalesforceRecord> multi = Multi.createBy().repeating()
                .uni(() -> new AtomicReference<String>("firstPage"),
                        url -> sfClient.getRecord(url.get()).onItem()
                                .invoke(sfRecord -> url.set(sfRecord.getNextRecordsUrl())))
                .until(SalesforceRecord::isDone);

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@IvanPuntev
Comment options

@IvanPuntev
Comment options

@IvanPuntev
Comment options

Answer selected by IvanPuntev
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants