frjaeger220 / google-guice

Automatically exported from code.google.com/p/google-guice
Apache License 2.0
0 stars 0 forks source link

CreationException not backwards compatible #315

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
In Guice 1.0, CreationException takes a Collection<Message> in it's
constructor. In Guice 2.0, this was changed to an Iterable<Message>. This
breaks backwards compability. E.g.:

java.lang.NoSuchMethodError:
com.google.inject.CreationException.<init>(Ljava/util/Collection;)V
        at
org.apache.shindig.common.PropertiesModule.readPropertyFile(PropertiesModule.jav
a:77)
        at
org.apache.shindig.common.PropertiesModule.<init>(PropertiesModule.java:50)
        at
piazza.web.servlet.PiazzaGuiceServletContextListener$1.<init>(PiazzaGuiceServlet
ContextListener.java:66)

Adding a constructor that agains accepts a Collection<Message> is trivial.

Original issue reported on code.google.com by mathias....@gmail.com on 21 Jan 2009 at 4:42

GoogleCodeExporter commented 9 years ago
Fixed.

Original comment by limpbizkit on 26 Jan 2009 at 1:20

GoogleCodeExporter commented 9 years ago
You fixed it by changing the method signature. A better fix would be to 
introduce a
second constructor taking the Collection (and leaving Iterable).

Original comment by mathias....@gmail.com on 27 Jan 2009 at 9:40