<html><head><meta http-equiv="Content-Type" content="text/html charset=windows-1252"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;">I think this is satisfactory.<div><br></div><div>+1</div><div><br></div><div>Brian</div><div><br><div style=""><div>On May 20, 2016, at 2:03 PM, Phil Race <<a href="mailto:philip.race@oracle.com">philip.race@oracle.com</a>> wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite">
  
    <meta content="text/html; charset=windows-1252" http-equiv="Content-Type">
  
  <div text="#000000" bgcolor="#FFFFFF">
    <div class="moz-cite-prefix">The jai_imageio code parses the version
      string before<br>
      it does anything with the result. And the only thing<br>
      it intends to do is tweak the registruy ordering or<br>
      remove itself if it thinks the JDK version is high enough.<br>
      So I don't see the harm in this versus not adding it to<br>
      the registry at all.<br>
      <br>
      Theoretically a different plugin that had a fatal error<br>
      as a result of this probably should not be registered<br>
      but there can't be existing examples of that on JDK 1.8<br>
      and even if there were a problem on 9 they'll get<br>
      the exception printed ..<br>
      <br>
      -phil.<br>
      <br>
      On 05/20/2016 01:55 PM, Brian Burkhalter wrote:<br>
    </div>
    <blockquote cite="mid:FA59BEB0-EC34-46FE-8CB0-8C35CCA5398D@oracle.com" type="cite">
      <meta http-equiv="Content-Type" content="text/html;
        charset=windows-1252">
      These statements
      <div><br>
      </div>
      <div>
        <div style="margin: 0px; font-size: 11px; font-family: Courier;"> 
                map.put(provider.getClass(), provider);</div>
        <div style="margin: 0px; font-size: 11px; font-family: Courier;"> 
                poset.add(provider);</div>
      </div>
      <div><br>
      </div>
      <div>occur before the  if (provider instanceof
        RegisterableService) block. Do we really want the provider
        added to that map and set if the Throwable occurs?</div>
      <div><br>
      </div>
      <div>Brian</div>
      <div><br>
      </div>
      <div>
        <div>
          <div>On May 20, 2016, at 1:07 PM, Phil Race <<a moz-do-not-send="true" href="mailto:philip.race@oracle.com">philip.race@oracle.com</a>>
            wrote:</div>
          <br class="Apple-interchange-newline">
          <blockquote type="cite">Please review the following workaround
            for :-<br>
            <a moz-do-not-send="true" href="https://bugs.openjdk.java.net/browse/JDK-8154860">https://bugs.openjdk.java.net/browse/JDK-8154860</a><br>
            <br>
            -phil.<br>
            <br>
            ---
            a/src/java.desktop/share/classes/javax/imageio/spi/ServiceRegistry.java<br>
            +++
            b/src/java.desktop/share/classes/javax/imageio/spi/ServiceRegistry.java<br>
            @@ -770,7 +770,12 @@<br>
                    poset.add(provider);<br>
                    if (provider instanceof RegisterableService) {<br>
                        RegisterableService rs =
            (RegisterableService)provider;<br>
            +            try {<br>
                        rs.onRegistration(registry, category);<br>
            +            } catch (Throwable t) {<br>
            +                System.err.println("Caught and handled this
            exception :");<br>
            +                t.printStackTrace();<br>
            +            }<br>
                    }<br>
            <br>
                    return !present;<br>
            <br>
          </blockquote>
        </div>
        <br>
      </div>
    </blockquote>
    <br>
  </div>

</blockquote></div><br></div></body></html>