David Daney wrote: > Jeroen Frijters wrote: > > David Daney wrote: > > > >> Jeroen Frijters wrote: > >> > >>> throw new RuntimeException("error > instantiating default > >>> socket factory: " > >>> - + ex.toString()); > >>> > >>> > >> That sounds more like an InternalError than the super-generic > >> RuntimeException. > >> > > > > Possibly. I don't know enough about this stuff to tell. I > have, however, > > since discovered that the current code is wrong. When the > factory is not > > properly configured it is supposed to return a factory that throws > > exceptions upon invocation of the factory methods, not at > this stage. > > > > I've got a patch (attached), but I'm going on vacation tomorrow and > > don't have time to properly test it and check it in, but if someone > > would like to do so, that would be great. > > > > Regards, > > Jeroen > > > > + > > + public String[] getDefaultCipherSuites() > > + { > > + throw new RuntimeException(x); > > + } > > + > > + public String[] getSupportedCipherSuites() > > + { > > + throw new RuntimeException(x); > > + } > > + > > > I'm sorry if I sound like I am preaching, but what type of exception > does the RI throw here? Should this really be > RuntimeException? There > are different exception types for a reason, would something like > UnsupportedOperationException be more appropriate?
I fully agree with you here, I'm just operating under "I'm not making it worse" defense here ;-) I think Casey wrote most of this stuff, he should have a better idea of what is the proper thing to do. Regards, Jeroen