Nivi Kundem

+ Follow
since Dec 28, 2014
Merit badge: grant badges
For More
Cows and Likes
Total received
In last 30 days
Total given
Total received
Received in last 30 days
Total given
Given in last 30 days
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Nivi Kundem

Could anyone suggest me how to configure connectionfactory in mule using connectionFactory-ref

I am trying to configure connectionfactory in mule using connectionFactory-ref[this is the url I am following :::].

In the above mentioned documentation - mentioned - Configuring the ConnectionFactory

One of the most important attributes is connectionFactory-ref. This is a reference to the ConnectionFactory object which creates new connections for your JMS provider. The object must implement the interface javax.jms.ConnectionFactory.


So to implement the above, below is my mule configuraion xml

<?xml version="1.0" encoding="UTF-8"?>

<mule xmlns:smtps=""
xmlns:scripting="" xmlns:https=""
xmlns:http="" xmlns:jms="" xmlns="" xmlns:doc=""
xmlns:spring="" version="EE-3.5.1"

<spring:bean name="connectionFactory" class="com.ers.connections.ConnectionFactoryImpl"/>
<jms:activemq-connector name="Active_MQForApex" connectionFactory-ref="connectionFactory" validateConnections="true" doc:name="Active MQ"/>
<flow name="apexwritequeueFlow1" doc:name="apexwritequeueFlow1">
<http:inbound-endpoint exchange-pattern="request-response" host="localhost" port="8081" path="niviTest" doc:name="HTTP"/>
<logger message="Payload ::: #[payload]" level="INFO" doc:name="Logger"/>
<jms:outbound-endpoint queue="ANS.RecOps.Incoming" connector-ref="Active_MQForApex" doc:name="JMS"/>

Below java class

import javax.jms.Connection;
import javax.jms.ConnectionFactory;
import javax.jms.JMSException;

import org.apache.activemq.ActiveMQConnectionFactory;

public class ConnectionFactoryImpl implements javax.jms.ConnectionFactory {

public Connection createConnection() throws JMSException {
// Create a ConnectionFactory
ConnectionFactory connectionFactory = new ActiveMQConnectionFactory("21233", "123", "ssl://");
return connectionFactory.createConnection();

public Connection createConnection(String arg0, String arg1)
throws JMSException {
// TODO Auto-generated method stub
return null;



However I am getting this error

. Root Exception was: Unsupported ConnectionFactory type: com.ers.connections.ConnectionFactoryImpl. Type: class java.lang.IllegalArgumentException ERROR 2014-12-28 11:53:26,141 [main] org.mule.module.launcher.application.DefaultMuleApplication: null java.lang.IllegalArgumentException: Unsupported ConnectionFactory type: com.ers.connections.ConnectionFactoryImpl

Thank you in advance. Any suggestions most appreciated. Thank you and regards Nivi
9 years ago