Uploaded image for project: 'JGroups'
  1. JGroups
  2. JGRP-445

Digest not set on FlushHeader on suspect member during a flush

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • 2.5
    • 2.5
    • None

      NullPointerException can occur in findVirtualSynchronyGaps() because the Digest is not always set on the FlushHeader.

      The below fix works, but not sure of it's implications.

      private void onSuspect(Address address)
      {
      ...

      if (flushOkCompleted)

      { Digest digest = (Digest)down_prot.down(new Event(Event.GET_DIGEST)); // ************* Patch ************ FlushHeader fh = new FlushHeader(FlushHeader.FLUSH_COMPLETED, viewID); fh.addDigest(digest); m.putHeader(getName(),fh); // ************* Patch ************ // original // m.putHeader(getName(), new FlushHeader(FlushHeader.FLUSH_COMPLETED, viewID)); down_prot.down(new Event(Event.MSG, m)); if (log.isDebugEnabled()) log.debug(localAddress + " sent FLUSH_COMPLETED message to " + flushCoordinator); }

      ...
      }

              vblagoje Vladimir Blagojevic (Inactive)
              mnewcomb_jira Michael Newcomb (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: