ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » IBM MQ Java / JMS » Initial Context Factory

Post new topic  Reply to topic
 Initial Context Factory « View previous topic :: View next topic » 
Author Message
beavis
PostPosted: Fri Oct 25, 2002 10:35 am    Post subject: Initial Context Factory Reply with quote

Newbie

Joined: 25 Oct 2002
Posts: 3

Hi,
I am a week old newbie and I am trying to connect to MQ Series running on an OS/390 from a windows desktop. We do not have LDAP running on the mainframe, so i can't use the com.sun.jndi.ldap.LdapCtxFactory. I would like to use iiop but the two factories com.ibm.ejs.ns.jndi.CNInitialContextFactory and com.ibm.websphere.naming.WsnInitialContextFactory are WebSphere classes that i do not have, nor really want. Is there another factory that i can use for iiop? If not, could you point me in the right direction to use the com.sun.jndi.fscontext.RefFSContextFactory class....i haven't the slightest clue about it.
Thanks a bunch!!!
Back to top
View user's profile Send private message
abmanesh
PostPosted: Mon Oct 28, 2002 5:27 am    Post subject: Reply with quote

Apprentice

Joined: 06 Nov 2001
Posts: 39

Refer chapter 8 in the redbook "Programming Patterns in MQSeries " . This chapter describes the use of different JNDI providers.
You could access the the redbook at
http://www.redbooks.ibm.com/pubs/pdfs/redbooks/sg246506.pdf
Back to top
View user's profile Send private message Send e-mail
kolban
PostPosted: Mon Oct 28, 2002 5:40 am    Post subject: Reply with quote

Grand Master

Joined: 22 May 2001
Posts: 1072
Location: Fort Worth, TX, USA

Pay particular attention to the File System store. This is by far the simplest JNDI system to use and does not require that you setup any LDAP or other naming and directory service.
Back to top
View user's profile Send private message
beavis
PostPosted: Mon Oct 28, 2002 8:43 am    Post subject: Reply with quote

Newbie

Joined: 25 Oct 2002
Posts: 3

I have changed the JMSAdmin.config file to the following:

INITIAL_CONTEXT_FACTORY=com.sun.jndi.fscontext.RefFSContextFactory
PROVIDER_URL=file:C:\Program Files\IBM\MQSeries\Java\jndi

(subdirectory that does exist)

and when i run the JMSAdmin tool as such:

JMSAdmin -cfg JMSAdmin.config

it gives the following error:

JNDI initialisation failed, please check your JNDI settings and service

(initialization spelled wrong from those IBMers)


Is there something more i need to specify? I thought the JMSAdmin tool was suppose to help me create the JMS objects that specify the IP Address of the MQ Series server to connect to...is this the correct assumption?
Back to top
View user's profile Send private message
bower5932
PostPosted: Mon Oct 28, 2002 12:14 pm    Post subject: Reply with quote

Jedi Knight

Joined: 27 Aug 2001
Posts: 3023
Location: Dallas, TX, USA

You are correct in what JMSAdmin is supposed to do. I'd suggest that you double-check your classpath and path. Most of the JMSAdmin errors that I've seen are related to classpath and path. You can also run with a trace to see if it sheds any more light (JMSAdmin -t). You'll some times get the actual error that is causing your problems.
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger
beavis
PostPosted: Tue Oct 29, 2002 3:22 pm    Post subject: Reply with quote

Newbie

Joined: 25 Oct 2002
Posts: 3

That was it...i didn't have fscontext.jar in the classpath. I got it all to work. THANKS for all the help everyone.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » IBM MQ Java / JMS » Initial Context Factory
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.