Uploaded image for project: 'Couchbase Java Client'
  1. Couchbase Java Client
  2. JCBC-874

Provide N1QL utility method to deal with finalSucess -> rows or errors flow

    XMLWordPrintable

Details

    • New Feature
    • Resolution: Won't Do
    • Major
    • .backlog
    • 2.2.1
    • None
    • Security Level: Public
    • None

    Description

      When dealing with asynchronous N1QL results, it is often needed to branch from the finalSuccess and then do something with either rows or errors.

      Sometimes it would be less tedious to have a utility method abstract that away, and to let errors surface as an Exception in the onError of the Observable (eg. expose rows if finalSuccess is true but raise an exception if finalSuccess is false).

      It could be interesting to provide quality-of-life utility methods that do that by flatMapping on the finalSuccess and then either process rows or emit onError with the content of the errors() observable.

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              daschl Michael Nitschinger
              simonbasle Simon Baslé (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes

                  PagerDuty