[jboss-user] [Messaging, JMS & JBossMQ] - application suddenly starts to fail with 'Invalid authentica

pkorros do-not-reply at jboss.com
Thu May 17 08:59:47 EDT 2007


Our J2EE application suddenly starts to fail with the following exception:

java.lang.SecurityException: Invalid authentication attempt, principal=null
	at org.jboss.resource.connectionmanager.BaseConnectionManager2.getSubject(BaseConnectionManager2.java:589)
	at org.jboss.resource.connectionmanager.BaseConnectionManager2.allocateConnection(BaseConnectionManager2.java:395)
	at org.jboss.resource.connectionmanager.BaseConnectionManager2$ConnectionManagerProxy.allocateConnection(BaseConnectionManager2.java:842)
	at org.jboss.resource.adapter.jms.JmsSessionFactoryImpl.allocateConnection(JmsSessionFactoryImpl.java:389)
	at org.jboss.resource.adapter.jms.JmsSessionFactoryImpl.createQueueSession(JmsSessionFactoryImpl.java:144)
	at com.oakgrovesystems.reactor.services.policyExecution.MDBMessageSender.init(MDBMessageSender.java:158)
	at com.oakgrovesystems.reactor.services.policyExecution.MDBMessageSender.sendEvent(MDBMessageSender.java:35)
	at com.oakgrovesystems.reactor.services.policyExecution.PolicyExecutor.fireEvent(PolicyExecutor.java:343)
	at com.oakgrovesystems.reactor.services.policyExecution.PolicyExecutor.execute(PolicyExecutor.java:315)
	at com.oakgrovesystems.reactor.services.policyExecution.PolicyExecutionMessageBean.execute(PolicyExecutionMessageBean.java:213)
	at com.oakgrovesystems.reactor.services.policyExecution.PolicyExecutionMessageBean.handleExecuteMessage(PolicyExecutionMessageBean.java:203)
	at com.oakgrovesystems.reactor.services.policyExecution.PolicyExecutionMessageBean.onMessage(PolicyExecutionMessageBean.java:117)
	at sun.reflect.GeneratedMethodAccessor365.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:585)
	at org.jboss.invocation.Invocation.performCall(Invocation.java:359)
	at org.jboss.ejb.MessageDrivenContainer$ContainerInterceptor.invoke(MessageDrivenContainer.java:495)
	at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:158)
	at org.jboss.ejb.plugins.MessageDrivenInstanceInterceptor.invoke(MessageDrivenInstanceInterceptor.java:116)
	at org.jboss.ejb.plugins.CallValidationInterceptor.invoke(CallValidationInterceptor.java:63)
	at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:121)
	at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:350)
	at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:181)
	at org.jboss.ejb.plugins.RunAsSecurityInterceptor.invoke(RunAsSecurityInterceptor.java:109)
	at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:205)
	at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:136)
	at org.jboss.ejb.MessageDrivenContainer.internalInvoke(MessageDrivenContainer.java:402)
	at org.jboss.ejb.Container.invoke(Container.java:954)
	at org.jboss.ejb.plugins.jms.JMSContainerInvoker.invoke(JMSContainerInvoker.java:987)
	at org.jboss.ejb.plugins.jms.JMSContainerInvoker$MessageListenerImpl.onMessage(JMSContainerInvoker.java:1287)
	at org.jboss.jms.asf.StdServerSession.onMessage(StdServerSession.java:266)
	at org.jboss.mq.SpyMessageConsumer.sessionConsumerProcessMessage(SpyMessageConsumer.java:905)
	at org.jboss.mq.SpyMessageConsumer.addMessage(SpyMessageConsumer.java:170)
	at org.jboss.mq.SpySession.run(SpySession.java:323)
	at org.jboss.jms.asf.StdServerSession.run(StdServerSession.java:194)
	at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExecutor.java:748)
	at java.lang.Thread.run(Thread.java:595)

The application tries to obtain a connection to the message queue with the following code:

  | Context context = new InitialContext();
  | QueueConnectionFactory queueFactory = (QueueConnectionFactory) context.lookup(factoryName);
  | queueConnection = queueFactory.createQueueConnection();
  | queueSession = queueConnection.createQueueSession(false,Session.AUTO_ACKNOWLEDGE);
  | queue = (Queue) context.lookup(queueName);
  | queueSender = queueSession.createSender(queue);
  | 

This block of code is called all the time, as our application is heavily based on jms queues, and works correctly under heavy ussage for many days in our production environment.
The problem is that suddenly it starts to fail to open a connection to the message queue. When this happens only a restart of the application server can solve the problem.

Any ideas on what may be wrong? How could we trace the problem? Is there a way to solve the problem without restarting the server?

environment:

AS: JBoss 4.0.5
JDK: SUN 1.5.0_10
OS: MS Windows 2003
Database: MS SQLServer 2005


View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4046473#4046473

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4046473



More information about the jboss-user mailing list