-
Notifications
You must be signed in to change notification settings - Fork 1.1k
NotSerializableException: DefaultListableBeanFactory has no serialization id #1202
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
Comments
Thanks for the report @BenDol. A minimal sample app that we could use to reproduce this issue would be really helpful, would you be able to provide one? |
Once I know how to actually reproduce this issue I will put a sample app together. Right now it seems somewhat sporadic and I haven't had the issue in a while. |
We're running into something that looks to be related, if not the same, issue. Here's a sample app Steps to reproduce:
We're seeing the following symptoms:
@vpavic ^ thanks! |
Any progress on this issue? It has been occurring for me again. |
Upon further research I think my issue is actually related to this: #395 However I am using Spring 5.x with Spring Boot 2, so either this bug still exists in another form or I have done something wrong. Any hints? The attribute that is failing is |
@BenDol Without a way to reproduce this, it's hard for us to make any progress. @vreynolds I've taken a look at your sample, but that doesn't actually involve Spring Session. Even the stacktrace you've posted shows |
So I resolved this issue by changing the |
Are you having two different apps share the same session store? |
They don't share the same session, but they are authenticating off the same OAuth2 client-id |
Closing due to lack of feedback. Please comment back if you can provide more details and we can re-open the issue. |
Hello, We have here exactly the same exception that @BenDol described in his first entry. We are running a web application in a JBoss-Cluster using a shared JDBC-Session-Store. As long as we use "sticky" connections in the load balancer everything works fine. As soon as we disable it the error occurs. Before the application redirects the user to the OAuth provider, a DefaultOAuth2ClientContext is saved to the database succesfully. After returning from the OAuth provider Spring Session tries to save the DefaultOAuth2ClientContext again and the the exception is thrown. Seems like a proxy is generated which holds a reference to the BeanFactory. We use:
By the way: For internal users we use normal ActiveDirectory/LDAP authentication, which works fine in all cases. |
I had this same problem but found it was just because one of the classes did not implement Serializable |
@Johannes-Rost Could you open a new issue and provide a sample that can be used to reproduce the problem? It isn't obvious that this is the problem with Spring Session itself. |
We have the same issue for local development:
Is this expected? I would not expect that controller classes affect serialization of DefaultOAuth2ClientContext. If it is not an expected behavior, I can provide a sample repository. We use Spring Boot 2.0.6 with the spring-cloud-starter-oauth2 (Finchley.SR2). |
I noticed that this issue has come up already and has been closed as "fixed". I'm running into this issue still:
I tried some of the suggestions from this thread, but it didn't resolve it.
Any help is greatly appreciated.
The text was updated successfully, but these errors were encountered: