java.lang.RuntimeException: java.lang.IllegalStateException: No value for key [org.hibernate.internal.SessionFactoryImpl@28af7fd7] bound to thread [http-bio-8080-exec-1]] with root cause java.lang.IllegalStateException: No value for key [org.hibernate.internal.SessionFactoryImpl@28af7fd7] bound to thread [http-bio-8080-exec-1]

Spring JIRA | Stig Runar Vangen | 4 years ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    In a controller I return a DeferredResult in order to set up an async request. From an another thread I set the result of DeferredResult, and thus return the result back to the user. The problem lies in that I also use a OpenSessionInViewFilter for Hibernate session management. This filter gives an error now and then indicating that a session is not bound to the current thread. Stack trace is as follows: {code} 29.aug.2013 11:15:57 [http-bio-8080-exec-1] ERROR org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/].[appServlet] - Servlet.service() for servlet appServlet threw exception java.lang.IllegalStateException: No value for key [org.hibernate.internal.SessionFactoryImpl@28af7fd7] bound to thread [http-bio-8080-exec-1] at org.springframework.transaction.support.TransactionSynchronizationManager.unbindResource(TransactionSynchronizationManager.java:209) at org.springframework.orm.hibernate4.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:157) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:749) at org.apache.catalina.core.ApplicationDispatcher.doDispatch(ApplicationDispatcher.java:660) at org.apache.catalina.core.ApplicationDispatcher.dispatch(ApplicationDispatcher.java:626) at org.apache.catalina.core.AsyncContextImpl$1.run(AsyncContextImpl.java:225) at org.apache.catalina.core.AsyncContextImpl.doInternalDispatch(AsyncContextImpl.java:367) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:217) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:123) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:171) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:99) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:953) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118) at org.apache.catalina.connector.CoyoteAdapter.asyncDispatch(CoyoteAdapter.java:299) at org.apache.coyote.http11.AbstractHttp11Processor.asyncDispatch(AbstractHttp11Processor.java:1587) at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:583) at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:312) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) at java.lang.Thread.run(Thread.java:722) 29.aug.2013 11:15:57 [http-bio-8080-exec-1] ERROR org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/].[appServlet] - Servlet.service() for servlet [appServlet] in context with path [] threw exception [java.lang.RuntimeException: java.lang.IllegalStateException: No value for key [org.hibernate.internal.SessionFactoryImpl@28af7fd7] bound to thread [http-bio-8080-exec-1]] with root cause java.lang.IllegalStateException: No value for key [org.hibernate.internal.SessionFactoryImpl@28af7fd7] bound to thread [http-bio-8080-exec-1] at org.springframework.transaction.support.TransactionSynchronizationManager.unbindResource(TransactionSynchronizationManager.java:209) at org.springframework.orm.hibernate4.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:157) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:749) at org.apache.catalina.core.ApplicationDispatcher.doDispatch(ApplicationDispatcher.java:660) at org.apache.catalina.core.ApplicationDispatcher.dispatch(ApplicationDispatcher.java:626) at org.apache.catalina.core.AsyncContextImpl$1.run(AsyncContextImpl.java:225) at org.apache.catalina.core.AsyncContextImpl.doInternalDispatch(AsyncContextImpl.java:367) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:217) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:123) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:171) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:99) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:953) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118) at org.apache.catalina.connector.CoyoteAdapter.asyncDispatch(CoyoteAdapter.java:299) at org.apache.coyote.http11.AbstractHttp11Processor.asyncDispatch(AbstractHttp11Processor.java:1587) at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:583) at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:312) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) at java.lang.Thread.run(Thread.java:722) {code}

    Spring JIRA | 4 years ago | Stig Runar Vangen
    java.lang.RuntimeException: java.lang.IllegalStateException: No value for key [org.hibernate.internal.SessionFactoryImpl@28af7fd7] bound to thread [http-bio-8080-exec-1]] with root cause java.lang.IllegalStateException: No value for key [org.hibernate.internal.SessionFactoryImpl@28af7fd7] bound to thread [http-bio-8080-exec-1]
  2. 0

    In a controller I return a DeferredResult in order to set up an async request. From an another thread I set the result of DeferredResult, and thus return the result back to the user. The problem lies in that I also use a OpenSessionInViewFilter for Hibernate session management. This filter gives an error now and then indicating that a session is not bound to the current thread. Stack trace is as follows: {code} 29.aug.2013 11:15:57 [http-bio-8080-exec-1] ERROR org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/].[appServlet] - Servlet.service() for servlet appServlet threw exception java.lang.IllegalStateException: No value for key [org.hibernate.internal.SessionFactoryImpl@28af7fd7] bound to thread [http-bio-8080-exec-1] at org.springframework.transaction.support.TransactionSynchronizationManager.unbindResource(TransactionSynchronizationManager.java:209) at org.springframework.orm.hibernate4.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:157) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:749) at org.apache.catalina.core.ApplicationDispatcher.doDispatch(ApplicationDispatcher.java:660) at org.apache.catalina.core.ApplicationDispatcher.dispatch(ApplicationDispatcher.java:626) at org.apache.catalina.core.AsyncContextImpl$1.run(AsyncContextImpl.java:225) at org.apache.catalina.core.AsyncContextImpl.doInternalDispatch(AsyncContextImpl.java:367) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:217) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:123) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:171) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:99) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:953) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118) at org.apache.catalina.connector.CoyoteAdapter.asyncDispatch(CoyoteAdapter.java:299) at org.apache.coyote.http11.AbstractHttp11Processor.asyncDispatch(AbstractHttp11Processor.java:1587) at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:583) at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:312) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) at java.lang.Thread.run(Thread.java:722) 29.aug.2013 11:15:57 [http-bio-8080-exec-1] ERROR org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/].[appServlet] - Servlet.service() for servlet [appServlet] in context with path [] threw exception [java.lang.RuntimeException: java.lang.IllegalStateException: No value for key [org.hibernate.internal.SessionFactoryImpl@28af7fd7] bound to thread [http-bio-8080-exec-1]] with root cause java.lang.IllegalStateException: No value for key [org.hibernate.internal.SessionFactoryImpl@28af7fd7] bound to thread [http-bio-8080-exec-1] at org.springframework.transaction.support.TransactionSynchronizationManager.unbindResource(TransactionSynchronizationManager.java:209) at org.springframework.orm.hibernate4.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:157) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:749) at org.apache.catalina.core.ApplicationDispatcher.doDispatch(ApplicationDispatcher.java:660) at org.apache.catalina.core.ApplicationDispatcher.dispatch(ApplicationDispatcher.java:626) at org.apache.catalina.core.AsyncContextImpl$1.run(AsyncContextImpl.java:225) at org.apache.catalina.core.AsyncContextImpl.doInternalDispatch(AsyncContextImpl.java:367) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:217) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:123) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:171) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:99) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:953) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118) at org.apache.catalina.connector.CoyoteAdapter.asyncDispatch(CoyoteAdapter.java:299) at org.apache.coyote.http11.AbstractHttp11Processor.asyncDispatch(AbstractHttp11Processor.java:1587) at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:583) at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:312) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) at java.lang.Thread.run(Thread.java:722) {code}

    Spring JIRA | 4 years ago | Stig Runar Vangen
    java.lang.RuntimeException: java.lang.IllegalStateException: No value for key [org.hibernate.internal.SessionFactoryImpl@28af7fd7] bound to thread [http-bio-8080-exec-1]] with root cause java.lang.IllegalStateException: No value for key [org.hibernate.internal.SessionFactoryImpl@28af7fd7] bound to thread [http-bio-8080-exec-1]
  3. 0

    Porting project JBoss AS 6 to JBoss AS 7

    Stack Overflow | 5 years ago | Rounak
    java.lang.RuntimeException: com.sun.faces.config.ConfigurationException : CONFIGURATION FAILED! Class org.jboss.as.web.deployment.jsf.JandexAnnotationPr ovider is not an instance of com.sun.faces.spi.AnnotationProvider at com.sun.faces.config.ConfigureListener.contextInitialized(ConfigureLi stener.java:292) [jsf-impl.jar:] at org.apache.catalina.core.StandardContext.contextListenerStart(Standar dContext.java:3368) [jbossweb-7.0.1.Final.jar:7.0.2.Final] at org.apache.catalina.core.StandardContext.start(StandardContext.java:3 821) [jbossweb-7.0.1.Final.jar:7.0.2.Final] at org.jboss.as.web.deployment.WebDeploymentService.start(WebDeploymentS ervice.java:70) [jboss-as-web-7.0.2.Final.jar:7.0.2.Final] at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(Se rviceControllerImpl.java:1824) at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceCont rollerImpl.java:1759) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor. java:1110) [:1.7.0] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor .java:603) [:1.7.0]
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Error initializing GroovyPageView

    Stack Overflow | 3 years ago | mrquad
    org.codehaus.groovy.grails.web.mapping.exceptions.UrlMappingException: Error map ping onto view [/index]: Error initializing GroovyPageView
  6. 0

    Android Asynctask method does not display the data

    Stack Overflow | 3 years ago | user3316775
    java.lang.RuntimeException: An error occured while executing doInBackground() android.os.AsyncTask$3.done(AsyncTask.java:278) java.util.concurrent.FutureTask$Sync.innerSetException(FutureTask.java:273) java.util.concurrent.FutureTask.setException(FutureTask.java:124) java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:307) java.util.concurrent.FutureTask.run(FutureTask.java:137) android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:208) java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1076) java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:569)

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.lang.RuntimeException

      java.lang.IllegalStateException: No value for key [org.hibernate.internal.SessionFactoryImpl@28af7fd7] bound to thread [http-bio-8080-exec-1]] with root cause java.lang.IllegalStateException: No value for key [org.hibernate.internal.SessionFactoryImpl@28af7fd7] bound to thread [http-bio-8080-exec-1]

      at org.springframework.transaction.support.TransactionSynchronizationManager.unbindResource()
    2. Spring Tx
      TransactionSynchronizationManager.unbindResource
      1. org.springframework.transaction.support.TransactionSynchronizationManager.unbindResource(TransactionSynchronizationManager.java:209)
      1 frame
    3. Spring ORM
      OpenSessionInViewFilter.doFilterInternal
      1. org.springframework.orm.hibernate4.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:157)
      1 frame
    4. Spring
      OncePerRequestFilter.doFilter
      1. org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
      1 frame
    5. Glassfish Core
      CoyoteAdapter.asyncDispatch
      1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
      2. org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
      3. org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:749)
      4. org.apache.catalina.core.ApplicationDispatcher.doDispatch(ApplicationDispatcher.java:660)
      5. org.apache.catalina.core.ApplicationDispatcher.dispatch(ApplicationDispatcher.java:626)
      6. org.apache.catalina.core.AsyncContextImpl$1.run(AsyncContextImpl.java:225)
      7. org.apache.catalina.core.AsyncContextImpl.doInternalDispatch(AsyncContextImpl.java:367)
      8. org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:217)
      9. org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:123)
      10. org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:171)
      11. org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:99)
      12. org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:953)
      13. org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
      14. org.apache.catalina.connector.CoyoteAdapter.asyncDispatch(CoyoteAdapter.java:299)
      14 frames
    6. Grizzly HTTP
      JIoEndpoint$SocketProcessor.run
      1. org.apache.coyote.http11.AbstractHttp11Processor.asyncDispatch(AbstractHttp11Processor.java:1587)
      2. org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:583)
      3. org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:312)
      3 frames
    7. Java RT
      Thread.run
      1. java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
      2. java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
      3. java.lang.Thread.run(Thread.java:722)
      3 frames