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

atmosphere-spring broken against Spring 3 #187

Open
morungos opened this issue Apr 28, 2015 · 2 comments
Open

atmosphere-spring broken against Spring 3 #187

morungos opened this issue Apr 28, 2015 · 2 comments

Comments

@morungos
Copy link

atmosphere-spring 2.2.1 used a different mechanism to set up the bean, but 2.3.0 is now broken against Spring 3. It uses a method that's not implemented in Spring 3 (in fact, the only getBean method that's not implemented in Spring 3), generating the backtrace:

Caused by:
java.lang.NoSuchMethodError: org.springframework.context.annotation.AnnotationConfigApplicationContext.getBean(Ljava/lang/Class;[Ljava/lang/Object;)Ljava/lang/Object;
    at org.atmosphere.spring.SpringWebObjectFactory.configure(SpringWebObjectFactory.java:90)
    at org.atmosphere.cpr.AtmosphereFramework.lookupDefaultObjectFactoryType(AtmosphereFramework.java:1673)
    at org.atmosphere.cpr.AtmosphereFramework.init(AtmosphereFramework.java:872)
    at org.atmosphere.cpr.AtmosphereFramework.init(AtmosphereFramework.java:830)
    at org.atmosphere.cpr.AtmosphereFrameworkInitializer.configureFramework(AtmosphereFrameworkInitializer.java:74)
    at org.atmosphere.cpr.AtmosphereServlet.configureFramework(AtmosphereServlet.java:83)
    at org.atmosphere.cpr.AtmosphereServlet.configureFramework(AtmosphereServlet.java:79)
    at org.atmosphere.cpr.AtmosphereServlet.init(AtmosphereServlet.java:74)
@jfarcand
Copy link
Member

@morungos OK I wasn't planning to support both Spring 2 and 3. Pull request welcomed ... and thanks for the report!

@morungos
Copy link
Author

Hmmm, well, okay. At first blush, this is very tight integration into Spring 4's use of classes to find prototypes, and there might not be an easy way to fit into Spring 3 without dropping some of the injection back to the 2.2.1 model. Which is sad, especially as getting Spring 4 to work with the rest of my code base was virtually impossible due to some CGLIB and JRE conflicts. At the least, it should probably be documented or expressed as Maven constraints. Or it might be easier for me to drop this dependency and retrofit with manual integration.

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

No branches or pull requests

2 participants