If the application invokes handler.nack() or allows handler to go out of scope, then the service will redeliver the message.
With exactly-once delivery subscriptions, the service will stop redelivering the message once the application invokes handler.ack() and the invocation succeeds. With best-efforts subscriptions, the service may redeliver the message, even after a successful handler.ack() invocation.
If handler is not an rvalue, you may need to use std::move(handler).ack() or std::move(handler).nack().
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-03-21 UTC."],[[["This webpage provides documentation for various versions of the `PullResponse` structure within the Google Cloud Pub/Sub C++ library, ranging from version 2.11.0 to the latest release candidate 2.37.0-rc."],["The `PullResponse` is utilized for handling the response of a blocking pull operation in the library."],["Message redelivery by the service is determined by whether the application invokes `handler.nack()` or if the `handler` goes out of scope."],["The service's behavior differs for exactly-once delivery subscriptions versus best-effort subscriptions, where the former will stop redelivering after a successful `handler.ack()` and the latter may redeliver even after a successful `handler.ack()`."],["If `handler` is not an rvalue, `std::move(handler).ack()` or `std::move(handler).nack()` may need to be used."]]],[]]