Hi,
The problem was that the MDB was deployed as multiple instances and second instance did not define the resource-ref to the JMS Connction Factory and jboss mixed the class loader and first MDB was also not able to find the resource. Once the resources are added in the deployment descriptor everything works OK.
Hope this will help someone