You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@servicemix.apache.org by "Ivan Pryvalov (JIRA)" <ji...@apache.org> on 2009/11/10 12:37:52 UTC

[jira] Commented: (SM-1909) Timeout Exception under heavy load

    [ https://issues.apache.org/activemq/browse/SM-1909?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=55263#action_55263 ] 

Ivan Pryvalov commented on SM-1909:
-----------------------------------

Exception occured only at once in total ~ 50. 000 requests.


Any suggestions how to check/detect cause of Exception?


Thanks, Ivan Pryvalov.

> Timeout Exception under heavy load
> ----------------------------------
>
>                 Key: SM-1909
>                 URL: https://issues.apache.org/activemq/browse/SM-1909
>             Project: ServiceMix
>          Issue Type: Bug
>    Affects Versions: 3.3.1
>         Environment: SM 3.3.1,
> Windown XP SP3
>            Reporter: Ivan Pryvalov
>
> There are 2 service-units  involved to message exchange.
> Here is a SNIPPET of code of first service-unit:
> /////////////// 1st service-unit, lw-container
> public class ServiceFirst extends ComponentSupport  implements org.apache.servicemix.jbi.listener.MessageExchangeListener{
> 	protected synchronized ServiceMixClient getServicemixClient(){
> 		if (smClient==null)
> 			smClient = new ServiceMixClientFacade( getContext() );
> 		return smClient;
> 	}
>           public void onMessageExchange(MessageExchange exchange) throws MessagingException {
>                        QName destService = ...;  // qname of destination service (2nd service) is used here.
> 			EndpointResolver endpointResolver = getServicemixClient().createResolverForService(destService);
> 			InOnly inOnly = smClient.createInOnlyExchange(endpointResolver);
>                        
>                         ... // fill content of message
> 			boolean result = smClient.sendSync(inOnly);
>                         // result was FALSE here (!)	
>          }	
> }	
> /////////////// 2nd service-unit, servicemix-bean  ///////////////////////////////
> public class ServiceTwo implements MessageExchangeListener{
>         @Resource
> 	private DeliveryChannel channel;
>   
>         public void onMessageExchange(MessageExchange exchange) throws MessagingException {
>                  if (if (exchange.getStatus() == ExchangeStatus.ACTIVE) {
>                       ...
>                       exchange.setStatus(ExchangeStatus.DONE);   // also cath Exception uses ERROR status
> 		 }
>                       
>                  channel.send();                  // Excpetion occured here (!)
>         }
> }
> ///////////////////////////////////////   stackTrace ///////////////////////////////////////
> 2009-11-09 09:44:52,946 | ERROR | AsyncBaseLifeCycle | pool-flow.seda.servicemix-bean-thread-13591 | | Error processing exchange InOnly[
>   id: ID:127.0.0.1-124c547e987-26:79012
>   status: Error
>   role: provider
>   service: {http://example.com}some_router_service
>   endpoint: jbi
>   in: ...
>   error: java.lang.RuntimeException: sendSync timeout for ID:127.0.0.1-124c547e987-26:79012
> ]
> org.apache.servicemix.jbi.ExchangeTimeoutException: Exchange has timed out: InOnly[
>   id: ID:127.0.0.1-124c547e987-26:79012
>   status: Error
>   role: provider
>   service: {http://example.com}some_router_service
>   endpoint: jbi
>   in: ...
>   error: java.lang.RuntimeException: sendSync timeout for ID:127.0.0.1-124c547e987-26:79012
> ]
>         at org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.doSend(DeliveryChannelImpl.java:362)
>         at org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.send(DeliveryChannelImpl.java:432)
>         at org.apache.servicemix.common.EndpointDeliveryChannel.send(EndpointDeliveryChannel.java:88)
>         at org.apache.servicemix.bean.BeanEndpoint$PojoChannel.send(BeanEndpoint.java:628)
>         at com.example.MessageExchangeListenerImpl.onMessageExchange(MessageExchangeListenerImpl.java:182)
>         at org.apache.servicemix.bean.BeanEndpoint.onProviderExchange(BeanEndpoint.java:230)
>         at org.apache.servicemix.bean.BeanEndpoint.process(BeanEndpoint.java:217)
>         at org.apache.servicemix.common.AsyncBaseLifeCycle.doProcess(AsyncBaseLifeCycle.java:627)
>         at org.apache.servicemix.common.AsyncBaseLifeCycle.processExchange(AsyncBaseLifeCycle.java:581)
>         at org.apache.servicemix.common.AsyncBaseLifeCycle.onMessageExchange(AsyncBaseLifeCycle.java:535)
>         at org.apache.servicemix.common.SyncLifeCycleWrapper.onMessageExchange(SyncLifeCycleWrapper.java:60)
>         at org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.processInBound(DeliveryChannelImpl.java:623)
>         at org.apache.servicemix.jbi.nmr.flow.AbstractFlow.doRouting(AbstractFlow.java:172)
>         at org.apache.servicemix.jbi.nmr.flow.seda.SedaFlow.doRouting(SedaFlow.java:168)
>         at org.apache.servicemix.jbi.nmr.flow.seda.SedaQueue$1.run(SedaQueue.java:134)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
>         at java.lang.Thread.run(Unknown Source)
> 2009-11-09 09:44:53,069 | ERROR | AsyncBaseLifeCycle | pool-flow.seda.servicemix-bean-thread-13591 | | Error setting exchange status to ERROR
> org.apache.servicemix.jbi.ExchangeTimeoutException: Exchange has timed out: InOnly[
>   id: ID:127.0.0.1-124c547e987-26:79012
>   status: Error
>   role: provider
>   service: {http://example.com}some_router_service
>   endpoint: jbi
>   in:  ...
>   error: org.apache.servicemix.jbi.ExchangeTimeoutException: Exchange has timed out: InOnly[
>   id: ID:127.0.0.1-124c547e987-26:79012
>   status: Error
>   role: provider
>   service: {http://example.com}some_router_service
>   endpoint: jbi
>   in:  ...
>   error: java.lang.RuntimeException: sendSync timeout for ID:127.0.0.1-124c547e987-26:79012
> ]
> ]
>         at org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.doSend(DeliveryChannelImpl.java:362)
>         at org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.send(DeliveryChannelImpl.java:432)
>         at org.apache.servicemix.common.AsyncBaseLifeCycle.onMessageExchange(AsyncBaseLifeCycle.java:551)
>         at org.apache.servicemix.common.SyncLifeCycleWrapper.onMessageExchange(SyncLifeCycleWrapper.java:60)
>         at org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.processInBound(DeliveryChannelImpl.java:623)
>         at org.apache.servicemix.jbi.nmr.flow.AbstractFlow.doRouting(AbstractFlow.java:172)
>         at org.apache.servicemix.jbi.nmr.flow.seda.SedaFlow.doRouting(SedaFlow.java:168)
>         at org.apache.servicemix.jbi.nmr.flow.seda.SedaQueue$1.run(SedaQueue.java:134)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
>         at java.lang.Thread.run(Unknown Source)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.