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

Fix the ClusterListener, ServerListener, ServerMonitorListener API docs relevant to thread-safety

    • Type: Icon: Improvement Improvement
    • Resolution: Done
    • Priority: Icon: Unknown Unknown
    • 4.11.0
    • Affects Version/s: None
    • Component/s: Documentation
    • Labels:
      None
    • Fully Compatible
    • Needed
    • Hide

      Let's mention in What's new that we fixed the documentation of ClusterListener, ServerListener, ServerMonitorListener. Users should not take the guarantee provided by these listeners as something that automatically spares them from synchronizing memory accesses.

      Show
      Let's mention in What's new that we fixed the documentation of ClusterListener , ServerListener , ServerMonitorListener . Users should not take the guarantee provided by these listeners as something that automatically spares them from synchronizing memory accesses.

      While the events are delivered to ClusterListener/ServerListener/ServerMonitorListener in a total order consistent with HB, these listeners still have to synchronize writes to shared memory with reads from it if the listeners write to shared memory. For a listener to be of any use, it has to write to shared memory, unless the only activity it does is logging or terminating the process.

            Assignee:
            valentin.kovalenko@mongodb.com Valentin Kavalenka
            Reporter:
            valentin.kovalenko@mongodb.com Valentin Kavalenka
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: