Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

assisted inject and GinAdapterModule cause UnsupportedOperationException #172

Open
GoogleCodeExporter opened this issue Mar 13, 2015 · 6 comments

Comments

@GoogleCodeExporter
Copy link

I'm trying to reuse a GinModule on the server side where Guice is used. For 
that I am using the install( new GinModuleAdapter( new MyGinModule());

This seems to have impact on other bindings that use Assisted Inject.

This breaks in GIN 1.5, but I have build GIN from trunk (a few weeks ago) and 
there it seems to work fine. I could not find an issue in the trackers that 
might explain... 

But anyway: this is an important issue for me since I am not allowed to use a 
self-build from trunk version of GIN due to company policy.

What is the expected output? What do you see instead?
INFO: An exception was caught and reported. Message: 
java.lang.UnsupportedOperationException
java.lang.UnsupportedOperationException
       at java.util.AbstractCollection.add(AbstractCollection.java:221)
       at com.google.gwt.inject.rebind.adapter.BinderAdapter.install(BinderAdapter.java:59)
       at com.google.gwt.inject.client.AbstractGinModule.install(AbstractGinModule.java:55)
       at com.swift.editor.shared.SharedEditorModule.configure(SharedEditorModule.java:73)
       at com.google.gwt.inject.client.AbstractGinModule.configure(AbstractGinModule.java:33)
       at com.google.gwt.inject.rebind.adapter.GinModuleAdapter.configure(GinModuleAdapter.java:49)
       at com.google.inject.spi.Elements$RecordingBinder.install(Elements.java:223)
       at com.google.inject.AbstractModule.install(AbstractModule.java:118)
       at com.swift.sawa.messenger.MessengerEJBModule.xml(MessengerEJBModule.java:224)
       at com.swift.sawa.messenger.MessengerEJBModule.configure(MessengerEJBModule.java:186)
       at com.google.inject.AbstractModule.configure(AbstractModule.java:59)
       at com.google.inject.spi.Elements$RecordingBinder.install(Elements.java:223)
       at com.google.inject.spi.Elements.getElements(Elements.java:101)
       at com.google.inject.internal.InjectorShell$Builder.build(InjectorShell.java:133)
       at com.google.inject.internal.InternalInjectorCreator.build(InternalInjectorCreator.java:103)
       at com.google.inject.Guice.createInjector(Guice.java:95)
       at com.google.inject.Guice.createInjector(Guice.java:72)
       at com.google.inject.Guice.createInjector(Guice.java:62)


What version of the product are you using? On what operating system?


Please provide any additional information below.


Original issue reported on code.google.com by david.nouls on 27 Feb 2012 at 2:45

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant