[JBossCache] - Problem with ShutdownHook
by lembrand
Hi.
I found possible problem in class org.jboss.cache.CacheImpl.java in method internalStart() at line ~820: "Runtime.getRuntime().addShutdownHook(shutdownHook);"
It works perfectly in stand-alone environment, but in MBeanServer it may cause problems.
MBean server has internal life-cycle definition for mbeans, and defines "stop" method for mbeans. When ShutdownHookMBean is processed in MBeanServer, the server stops mbeans in order reversed to their start. When MBeans depending on "CacheMBean" in stop method need to do some finalization work with cache (e.g. remove/update nodes), exception "java.lang.IllegalStateException" throwns, because Cache had already switched to stop state (due to hardcoded shutdown hook). Solution is to check runtime environment and in depend on this check to rely on shutdownhook (as it is now) or to stop method.
PS: Sorry for my english.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4089709#4089709
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4089709
18 years, 6 months
[JBoss Portal] - Re: Is this a JBP 2.6.1 bug? (403 Error From Dashboard Link)
by NM-156
That is exactly what I am researching now. If I use form based authentication to the portal, everything works fine because IdentityLoginModule AND my custom JAAS LoginModule are activated.
But now, I am trying to implement a Tomcat valve so that I will be able to bypass the portal login form altogether (my valve class extends org.apache.catalina.authenticator.SingleSignOn). When I add the roles and user principal to the request (inside of the valve), I am sent to the portal, and everything works fine except the dashboard link again (403 error ;). That is because, as you said, the login module call sequence in the context of form based login, appears to be providing something that my valve code is not. In the context of the execution of my valve, whatever the IdentityLoginModule (apparently) appears to be providing to enable the Dashboard is now missing again.
If any of the JBoss developers could provide some insight about what is required to enable the Dashboard link (programmatically or via configuration), that would be a great. I know that Sohil talked about the exact valve scenario that I am referring to here:
http://jboss.org/index.html?module=bb&op=viewtopic&t=115399&postdays=0&po...
Thanks.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4089702#4089702
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4089702
18 years, 6 months