Showing results for 
Search instead for 
Did you mean: 

Problems in accessing Connection Factories in JMS

Former Member
0 Kudos


We are porting A J2ee application from weblogic to SAP Web AS.

Primarily in weblogic we always get a Connection Factory Instance from

the Connection Factory and then typecast it to either

QueueConnectionFactory or TopicConnectionFactory.(Pl. see the code



ConnectionFactory factory = null;

QueueConnectionFactory queueFactory = null;

Hashtable env = new Hashtable();



env.put(Context.PROVIDER_URL, this.providerUrl);

context = new InitialContext(env);

factory = (ConnectionFactory)context.lookup


queueFactory = (QueueConnectionFactory)factory;

this.connection = queueFactory.createQueueConnection();

this.session = this.connection.createQueueSession

(false, Session.AUTO_ACKNOWLEDGE);

this.queue = (Queue)context.lookup(this.queueName);



But in SAP WEB As there is not such facility provided.Is it that always

we need to lookup to the jmsfactory/default/QueueConnectionFactory for

a Queue and jmsfactory/default/TopicConnectionFactory or

jmsfactory/default/QueueConnectionFactory for Topic . Is it poosibel to

get a Connection factory Instance from where on I Could further

Typecast it to TopicConnectionFactory or QueueConnectionFactory

Instance , because this the way we normally do in Weblogic or JMS.

Also this is how the java JMS API accepts . Could you please let me

know as to are there any more configuration to be Done apart from the

JMS provider and JMS Connector in the Visual Admin for Accessing the

Topmost ConnectionFactory JNDI Instance . If no ,are there any other

workarounds , as approach for changing the code for accessing the

individual Connection Factories JNDI is not feasible for us


rajesh kr

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Rajesh,

Please see the discussion about that in

Best Regards


Answers (0)