Uploaded image for project: 'Java Driver'
  1. Java Driver
  2. JAVA-3382

Observables should filter null values

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor - P4 Minor - P4
    • 3.11.1
    • None
    • Async
    • None

    Description

      Unfortunately, throwing a NPE when seeing a null value in the AbstractSubscription class had some unintended consequences.

      Any async method that returns Void (eg Start transaction, abort transaction etc..) and find()#first() all would throw a NPE. A hotfix had to be implemented in SCALA-555 and JAVARS-209 to work around the limitation but there may be edge cases where NPE's can still be raised.

      Given that we are in control of providing the data to consumers, throwing a NPE is unhelpful and prevents the normal flow of Observables.

      Attachments

        Activity

          People

            john.stewart@mongodb.com John Stewart (Inactive)
            ross@mongodb.com Ross Lawley
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: