• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Can't run a ejb client, please help

 
Ranch Hand
Posts: 40
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I am new to weblogic5.1. I encountered a problem when I run:
java examples.ejb.basic.beanManaged.Client
the I got:
Beginning beanManaged.Client...
We were unable to get a connection to the WebLogic server at t3://localhost:7001
Please make sure that the server is running.
Unable to look up the beans home: Cannot instantiate class: weblogic.jndi.WLInit
ialContextFactory
I am using Weblogic5.1 , Actually, I follow BEA document step by step. Can't figure out why. Please tell me what's wrong and how to invoke its servlet (this example use two approaches).
Many thanks and have a nice weekend.
Yongping
[This message has been edited by Yongping Wang (edited June 15, 2001).]
 
Ranch Hand
Posts: 111
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
As per the error message it seems the server is not running..
But.. make sure the bean is deployed properly.
Try to use build script in the example..
 
Yongping Wang
Ranch Hand
Posts: 40
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Saran Vel:
As per the error message it seems the server is not running..
But.. make sure the bean is deployed properly.
Try to use build script in the example..


I did use build script and checked everything is created correct. I think the real problem is t3://localhost:7001 and weblogic.jndi.WLInitialContextFactory because the example works fine in servlet mode but didn't work at all by using java client.
Can anyone explain it to me why?
I appreciate it very much.
Yongping
 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Wang,
Your problem is not on the server side but is on the client side. From the exception it looks like WLInitialConnection is not their in your classpath. The reason of why it works in the servlet is that in case of the servlet you use the default initial context, new InitialContext(); whereas in the client side you can't use the default context but you need to create a context which takes weblogic.jndi.WLInitialContextFactory as a parameter among the other things. Check your classpath settings to see whether this class is there.
Hope this helps.
Vikram.
 
Yongping Wang
Ranch Hand
Posts: 40
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Vikram Das:
Hi Wang,
Your problem is not on the server side but is on the client side. From the exception it looks like WLInitialConnection is not their in your classpath. The reason of why it works in the servlet is that in case of the servlet you use the default initial context, new InitialContext(); whereas in the client side you can't use the default context but you need to create a context which takes weblogic.jndi.WLInitialContextFactory as a parameter among the other things. Check your classpath settings to see whether this class is there.
Hope this helps.
Vikram.


Hi, Vikram:
Thanks for your reply.
I checked my classpath settings and they look fine. Here is my classpath setting:
CLASSPATH=C:\weblogic\lib\weblogicaux.jar;c:\visualcafeee\java2\lib\tools.jar;C:\weblogic\license;C:\weblogic\classes;C:\weblogic\myserver\clientclasses;C:\weblogic\myserver\server classes
Please tell me if some more classes need. Thanks again.
Yongping
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic