[JBoss JIRA] Created: (WELD-531) Weld swallowing stacktrace when multiple container errors
by Dan Allen (JIRA)
Weld swallowing stacktrace when multiple container errors
---------------------------------------------------------
Key: WELD-531
URL: https://jira.jboss.org/browse/WELD-531
Project: Weld
Issue Type: Bug
Affects Versions: 1.0.1.Final
Reporter: Dan Allen
When there are multiple container errors (for instance, definition errors at startup), Weld cycles through the errors and builds a localized message. However, it drops the cause of the exception. If the message is further up the chain (i.e., in the exception cause), this leads to exceptions such as:
Exception #0: null
The user is lost as to what the real problem is. Typically root causes are:
- NoClassDefFoundError
- NullPointerException
The problem is not that the message is null. The problem is that the underlying cause is dropped.
This came up recently when using Arquillian as reported in this forum post: https://community.jboss.org/message/544395#544395
When placed in a debugger, it turned out that a NoClassDefFoundError was being thrown. There was no way for the user to trace that to the source.
I think that what Weld needs to do is follow the cause until it finds a non-null message.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 10 months
[JBoss JIRA] Created: (WELD-448) invoking sendRedirect() in a JSP causes WELD-001303
by Dan Allen (JIRA)
invoking sendRedirect() in a JSP causes WELD-001303
---------------------------------------------------
Key: WELD-448
URL: https://jira.jboss.org/jira/browse/WELD-448
Project: Weld
Issue Type: Bug
Components: Conversations
Affects Versions: 1.0.1.CR2
Reporter: Dan Allen
Fix For: 1.0.1.GA
When sendRedirect() is used inside of a JSP page, it results in the exception WELD-001303: No active contexts for scope type @ConversationScoped
A source of this error is a typical /index.jsp redirector page:
<% response.sendRedirect("home.jsf"); %>
The ConversationPropagationFilter is wrapping all requests (not just JSF requests). The conversation scope is only active during JSF requests. The problem comes when ConversationPropagationFilter traps calls to sendRedirect(). It first checks whether the conversation is transient. But this check mandates that the conversation scope be active.
ConverationPropagationFilter.java:
...
@Override
public void sendRedirect(String path) throws IOException
{
ConversationImpl conversation = conversation(ctx);
if (!conversation.isTransient())
{
...
}
super.sendRedirect(path);
}
...
ConversationImpl.java
...
public boolean isTransient()
{
checkConversationActive();
return _transient;
}
...
I don't understand why isTransient() is enforcing that a conversation be active. If it's not active, then that should be considered transient (or there needs to be a portable way of checking if it's active.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 10 months
[JBoss JIRA] Created: (WELDINT-61) Message Driven Beans fail to run if an item is on the queue before the application server is started up
by Ian (JIRA)
Message Driven Beans fail to run if an item is on the queue before the application server is started up
-------------------------------------------------------------------------------------------------------
Key: WELDINT-61
URL: https://jira.jboss.org/jira/browse/WELDINT-61
Project: Weld Integration
Issue Type: Bug
Components: Weld Bootstrapper
Environment: JBoss 6.0.0-M3 with Weld 1.0.1-Final
Reporter: Ian
The scenario occurs when I start up an application with an MDB and there is a message on the queue before the application starts. If a message appears on the queue after application startup, there are no issues and everything processes correctly. During application startup, I get "StackTrace #1" - the error is to do with being unable to locate the BeanManager. After the application starts up, I continually get "StackTrace #2" - which means no further messages ever get delivered to the MDB.
StackTrace #1
11:08:53,949 ERROR [org.jboss.aspects.tx.TxPolicy] javax.ejb.EJBTransactionRolledbackException: Unable to inject jndi dependency: env/org.jboss.weld.integration.ejb.SessionBeanInterceptor/beanManager into property org.jboss.weld.integration.ejb.SessionBeanInterceptor.beanManager: WELD-001300 Unable to locate BeanManager
11:08:53,949 ERROR [org.hornetq.ra.inflow.HornetQMessageHandler] Failed to deliver message: javax.ejb.EJBTransactionRolledbackException: Unable to inject jndi dependency: env/org.jboss.weld.integration.ejb.SessionBeanInterceptor/beanManager into property org.jboss.weld.integration.ejb.SessionBeanInterceptor.beanManager: WELD-001300 Unable to locate BeanManager
at org.jboss.ejb3.tx.Ejb3TxPolicy.handleInCallerTx(Ejb3TxPolicy.java:115) [:1.0.2]
at org.jboss.aspects.tx.TxPolicy.invokeInCallerTx(TxPolicy.java:130) [:1.0.0.GA]
at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:194) [:1.0.0.GA]
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102) [jboss-aop.jar:2.2.0.Final]
at org.jboss.ejb3.tx.NullInterceptor.invoke(NullInterceptor.java:42) [:1.0.2]
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102) [jboss-aop.jar:2.2.0.Final]
at org.jboss.ejb3.security.Ejb3AuthenticationInterceptorv2.invoke(Ejb3AuthenticationInterceptorv2.java:80) [:1.3.1]
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102) [jboss-aop.jar:2.2.0.Final]
at org.jboss.ejb3.BlockContainerShutdownInterceptor.invoke(BlockContainerShutdownInterceptor.java:67) [:1.3.1]
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102) [jboss-aop.jar:2.2.0.Final]
at org.jboss.ejb3.core.context.CurrentInvocationContextInterceptor.invoke(CurrentInvocationContextInterceptor.java:47) [:1.3.1]
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102) [jboss-aop.jar:2.2.0.Final]
at org.jboss.aspects.currentinvocation.CurrentInvocationInterceptor.invoke(CurrentInvocationInterceptor.java:67) [:1.0.1]
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102) [jboss-aop.jar:2.2.0.Final]
at org.jboss.ejb3.interceptor.EJB3TCCLInterceptor.invoke(EJB3TCCLInterceptor.java:86) [:1.3.1]
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102) [jboss-aop.jar:2.2.0.Final]
at org.jboss.ejb3.mdb.MessagingContainer.localInvoke(MessagingContainer.java:277) [:1.3.1]
at org.jboss.ejb3.mdb.inflow.MessageInflowLocalProxy.delivery(MessageInflowLocalProxy.java:299) [:1.3.1]
at org.jboss.ejb3.mdb.inflow.MessageInflowLocalProxy.invoke(MessageInflowLocalProxy.java:152) [:1.3.1]
at $Proxy171.onMessage(Unknown Source) at org.hornetq.ra.inflow.HornetQMessageHandler.onMessage(HornetQMessageHandler.java:259) [:6.0.0.20100429-M3]
at org.hornetq.core.client.impl.ClientConsumerImpl.callOnMessage(ClientConsumerImpl.java:809) [:6.0.0.20100429-M3]
at org.hornetq.core.client.impl.ClientConsumerImpl.access$100(ClientConsumerImpl.java:46) [:6.0.0.20100429-M3]
at org.hornetq.core.client.impl.ClientConsumerImpl$Runner.run(ClientConsumerImpl.java:927) [:6.0.0.20100429-M3]
at org.hornetq.utils.OrderedExecutorFactory$OrderedExecutor$1.run(OrderedExecutorFactory.java:96) [:6.0.0.20100429-M3]
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) [:1.6.0_11]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) [:1.6.0_11]
at java.lang.Thread.run(Thread.java:619) [:1.6.0_11]
Caused by: java.lang.RuntimeException: Unable to inject jndi dependency: env/org.jboss.weld.integration.ejb.SessionBeanInterceptor/beanManager into property org.jboss.weld.integration.ejb.SessionBeanInterceptor.beanManager: WELD-001300 Unable to locate BeanManager
at org.jboss.injection.JndiPropertyInjector.lookup(JndiPropertyInjector.java:82) [:1.3.1]
at org.jboss.injection.JndiPropertyInjector.inject(JndiPropertyInjector.java:99) [:1.3.1]
at org.jboss.injection.JndiPropertyInjector.inject(JndiPropertyInjector.java:89) [:1.3.1]
at org.jboss.ejb3.interceptor.InterceptorInjector.inject(InterceptorInjector.java:49) [:1.3.1]
at org.jboss.ejb3.EJBContainer.createInterceptor(EJBContainer.java:359) [:1.3.1]
at org.jboss.ejb3.BaseContext.initialiseInterceptorInstances(BaseContext.java:112) [:1.3.1]
at org.jboss.ejb3.injection.InjectionHelper.inject(InjectionHelper.java:55) [:1.3.1]
at org.jboss.ejb3.injection.InjectionHelper.inject(InjectionHelper.java:43) [:1.3.1]
at org.jboss.ejb3.mdb.MDBInjectionInvocation.proceed(MDBInjectionInvocation.java:45) [:1.3.1]
at org.jboss.ejb3.injection.InjectionInvocation.invokeTarget(InjectionInvocation.java:97) [:1.3.1]
at org.jboss.ejb3.injection.InjectionInvocation.invokeNext(InjectionInvocation.java:91) [:1.3.1]
at org.jboss.ejb3.core.context.CurrentInvocationContextInterceptor.invoke(CurrentInvocationContextInterceptor.java:47) [:1.3.1]
at org.jboss.ejb3.injection.InjectionInvocation.invokeNext(InjectionInvocation.java:82) [:1.3.1]
at org.jboss.aspects.currentinvocation.CurrentInvocationInterceptor.invoke(CurrentInvocationInterceptor.java:67) [:1.0.1]
at org.jboss.ejb3.injection.InjectionInvocation.invokeNext(InjectionInvocation.java:82) [:1.3.1]
at org.jboss.ejb3.EJBContainer.injectBeanContext(EJBContainer.java:1197) [:1.3.1]
at org.jboss.ejb3.pool.AbstractPool.create(AbstractPool.java:83) [:1.3.1]
at org.jboss.ejb3.pool.AbstractPool.create(AbstractPool.java:73) [:1.3.1]
at org.jboss.ejb3.pool.StrictMaxPool.get(StrictMaxPool.java:146) [:1.3.1]
at org.jboss.ejb3.stateless.StatelessInstanceInterceptor.invoke(StatelessInstanceInterceptor.java:58) [:1.3.1]
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102) [jboss-aop.jar:2.2.0.Final]
at org.jboss.aspects.tx.TxPolicy.invokeInCallerTx(TxPolicy.java:126) [:1.0.0.GA]
... 26 more
Caused by: javax.naming.NamingException: Could not dereference object [Root exception is javax.naming.NamingException: WELD-001300 Unable to locate BeanManager]
at org.jnp.interfaces.NamingContext.resolveLink(NamingContext.java:1356) [:5.0.5.Final]
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:819) [:5.0.5.Final]
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:688) [:5.0.5.Final]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [:1.6.0_11]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) [:1.6.0_11]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) [:1.6.0_11]
at java.lang.reflect.Method.invoke(Method.java:597) [:1.6.0_11]
at org.jboss.ejb3.EJBContainer$1.invoke(EJBContainer.java:828) [:1.3.1]
at $Proxy163.lookup(Unknown Source) at org.jboss.ejb3.JndiUtil.lookup(JndiUtil.java:44) [:1.3.1]
at org.jboss.injection.JndiPropertyInjector.lookup(JndiPropertyInjector.java:75) [:1.3.1]
... 47 more
Caused by: javax.naming.NamingException: WELD-001300 Unable to locate BeanManager
at org.jboss.weld.resources.ManagerObjectFactory.getObjectInstance(ManagerObjectFactory.java:50) [:1.0.1.Final]
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:304) [:1.6.0_11]
at org.jnp.interfaces.NamingContext.getObjectInstance(NamingContext.java:1483) [:5.0.5.Final]
at org.jnp.interfaces.NamingContext.getObjectInstanceWrapFailure(NamingContext.java:1500) [:5.0.5.Final]
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:824) [:5.0.5.Final]
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:835) [:5.0.5.Final]
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:688) [:5.0.5.Final]
at javax.naming.InitialContext.lookup(InitialContext.java:392) [:1.6.0_11]
at org.jnp.interfaces.NamingContext.resolveLink(NamingContext.java:1350) [:5.0.5.Final]
... 57 more
StackTrace #2
11:09:14,777 ERROR [org.jboss.aspects.tx.TxPolicy] javax.ejb.EJBException: Failed to acquire the pool semaphore, strictTimeout=10000
11:09:14,777 ERROR [org.hornetq.ra.inflow.HornetQMessageHandler] Failed to deliver message: javax.ejb.EJBException: Failed to acquire the pool semaphore, strictTimeout=10000
at org.jboss.ejb3.pool.StrictMaxPool.get(StrictMaxPool.java:127) [:1.3.1]
at org.jboss.ejb3.stateless.StatelessInstanceInterceptor.invoke(StatelessInstanceInterceptor.java:58) [:1.3.1]
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102) [jboss-aop.jar:2.2.0.Final]
at org.jboss.aspects.tx.TxPolicy.invokeInCallerTx(TxPolicy.java:126) [:1.0.0.GA]
at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:194) [:1.0.0.GA]
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102) [jboss-aop.jar:2.2.0.Final]
at org.jboss.ejb3.tx.NullInterceptor.invoke(NullInterceptor.java:42) [:1.0.2]
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102) [jboss-aop.jar:2.2.0.Final]
at org.jboss.ejb3.security.Ejb3AuthenticationInterceptorv2.invoke(Ejb3AuthenticationInterceptorv2.java:80) [:1.3.1]
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102) [jboss-aop.jar:2.2.0.Final]
at org.jboss.ejb3.BlockContainerShutdownInterceptor.invoke(BlockContainerShutdownInterceptor.java:67) [:1.3.1]
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102) [jboss-aop.jar:2.2.0.Final]
at org.jboss.ejb3.core.context.CurrentInvocationContextInterceptor.invoke(CurrentInvocationContextInterceptor.java:47) [:1.3.1]
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102) [jboss-aop.jar:2.2.0.Final]
at org.jboss.aspects.currentinvocation.CurrentInvocationInterceptor.invoke(CurrentInvocationInterceptor.java:67) [:1.0.1]
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102) [jboss-aop.jar:2.2.0.Final]
at org.jboss.ejb3.interceptor.EJB3TCCLInterceptor.invoke(EJB3TCCLInterceptor.java:86) [:1.3.1]
at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102) [jboss-aop.jar:2.2.0.Final]
at org.jboss.ejb3.mdb.MessagingContainer.localInvoke(MessagingContainer.java:277) [:1.3.1]
at org.jboss.ejb3.mdb.inflow.MessageInflowLocalProxy.delivery(MessageInflowLocalProxy.java:299) [:1.3.1]
at org.jboss.ejb3.mdb.inflow.MessageInflowLocalProxy.invoke(MessageInflowLocalProxy.java:152) [:1.3.1]
at $Proxy171.onMessage(Unknown Source) at org.hornetq.ra.inflow.HornetQMessageHandler.onMessage(HornetQMessageHandler.java:259) [:6.0.0.20100429-M3]
at org.hornetq.core.client.impl.ClientConsumerImpl.callOnMessage(ClientConsumerImpl.java:809) [:6.0.0.20100429-M3]
at org.hornetq.core.client.impl.ClientConsumerImpl.access$100(ClientConsumerImpl.java:46) [:6.0.0.20100429-M3]
at org.hornetq.core.client.impl.ClientConsumerImpl$Runner.run(ClientConsumerImpl.java:927) [:6.0.0.20100429-M3]
at org.hornetq.utils.OrderedExecutorFactory$OrderedExecutor$1.run(OrderedExecutorFactory.java:96) [:6.0.0.20100429-M3]
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) [:1.6.0_11]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) [:1.6.0_11]
at java.lang.Thread.run(Thread.java:619) [:1.6.0_11]
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 10 months
[JBoss JIRA] Created: (WELD-553) Weld should visibly log when /WEB-INF/beans.xml is not found.
by Lincoln Baxter III (JIRA)
Weld should visibly log when /WEB-INF/beans.xml is not found.
-------------------------------------------------------------
Key: WELD-553
URL: https://jira.jboss.org/browse/WELD-553
Project: Weld
Issue Type: Feature Request
Components: Bootstrap and Metamodel API
Affects Versions: 1.0.1.Final
Reporter: Lincoln Baxter III
An INFO or WARNING level log message must be displayed when loading a web-application where /WEB-INF/beans.xml is missing.
"/WEB-INF/beans.xml is not present - Beans in WAR " +warName+ " will not be loaded."
The user needs to know this because weld is making an important decision. Also, a common pitfall, defining EJBs with @Injected dependencies will break because the EJB's are discovered, @Injection is attempted, but fails because no other beans were loaded.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 10 months