Whenever you have a JNDI lookup question, you should first check out "JNDIView"
from the "JMX Agent view"  page on your server: < http://localhost:8082 > follow
the "service=JNDIView" link under "DefaultDomain" and select the "list" button.

It will give you a tree listing of the fully qualified names from each namespace
to everything registered.  Most of the time, that will answer your questions.

- Tim

Message: 11
Message-ID: <[EMAIL PROTECTED]>
From: "Sternagel Annegret (PN-SYS/DAS)" <[EMAIL PROTECTED]>
To: "'[EMAIL PROTECTED]'"
<[EMAIL PROTECTED]>
Subject: RE: [JBoss-user] JMS: Simple question!
Date: Mon, 25 Jun 2001 14:37:42 +0200
MIME-Version: 1.0
Content-Type: text/plain
Sender: [EMAIL PROTECTED]
Precedence: bulk
Reply-To: [EMAIL PROTECTED]
List-Help: <mailto:[EMAIL PROTECTED]?subject=help>
List-Post: <mailto:[EMAIL PROTECTED]>
List-Subscribe: <http://lists.sourceforge.net/lists/listinfo/jboss-user>,   <
mailto:[EMAIL PROTECTED]?subject=subscribe>
List-Id: The JBoss User main mailing list <jboss-user.lists.sourceforge.net>
List-Unsubscribe: <http://lists.sourceforge.net/lists/listinfo/jboss-user>, <
mailto:[EMAIL PROTECTED]?subject=unsubscribe>
List-Archive: <http://lists.sourceforge.net/archives//jboss-user/>


You must lookup "queue/userQueue"

> -----Original Message-----
> From:   Keerthi P [SMTP:[EMAIL PROTECTED]]
> Sent:   Montag, 25. Juni 2001 14:14
> To:     [EMAIL PROTECTED]
> Subject:     [JBoss-user] JMS: Simple question!
>
> Hi all,
> Could someone tell me how to look up a queue in
> Jboss... I have a created a queue by name "userQueue",
> by specifying it in jbossmq.xml.. and i am trying to
> look up the same in a sample application.. but it
> throws NameNotFoundException: the code is here...
>
> Properties env = new Properties();
>         env.setProperty(Context.INITIAL_CONTEXT_FACTORY,
> "org.jnp.interfaces.NamingContextFactory");
>         env.setProperty(Context.PROVIDER_URL,
> "localhost:1099");
>         env.setProperty(Context.URL_PKG_PREFIXES,
> "org.jboss.naming");
>
>         InitialContext ic=new InitialContext(env);
>
>         Queue q=(Queue)ic.lookup("userQueue");
>
> Thanks in advance..
> Keerthi
>
> __________________________________________________
> Do You Yahoo!?
> Get personalized email addresses from Yahoo! Mail - only $35
> a year!  http://personal.mail.yahoo.com/
>
> _______________________________________________
> JBoss-user mailing list
> [EMAIL PROTECTED]
> http://lists.sourceforge.net/lists/listinfo/jboss-user



_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to