Re: Creating a JNDI entry

2000-08-13 Thread ishpal

You have to get hold of the Orion's context

For that you'll have to include orion.jar,jndi.ar,ejb.jar in ur command line
classpath when executing the client in a seperate JVM.

My Client code is:-

 Context ctx = new InitialContext();
 Object objref = ctx.lookup("Hello");  (Hello is the ejb-name of the
enterprise bean in the ejb-xml.jar file)
 HelloHome hellohome = (HelloHome)PortableRemoteObject.narrow(objref,
HelloHome.class);
Hello helloEx = hellohome.create();

My jndi.properties file is:--

java.naming.factory.initial=com.evermind.server.rmi.RMIInitialContextFactory
java.naming.provider.url=ormi://localhost/hello  ( Replace hello by the name
of ur applicatioin you have given in server.xml)

java.naming.security.principal=admin
java.naming.security.credentials=123 ( replace 123 by the password you have
given for the admin.)

Keep the jndi.properties file in the directory from where you are running ur
client, if it is in a seperate JVM...

Hope this helps..



- Original Message -
From: Ray [EMAIL PROTECTED]
To: Orion-Interest [EMAIL PROTECTED]
Sent: Sunday, August 13, 2000 5:30 AM
Subject: Creating a JNDI entry


 Hello 

 I'm trying to access an EJB through RMI.

 I can get hold of the context, but I'm not sure how to assign the bean a
 JNDI entry under Orion.

 Could someone tell me how this is done?

 Thanks








life mantra

2000-08-13 Thread PAPYRUS


- Original Message -
Sent: Saturday, August 12, 2000 3:16 Pm



   This is what The Dalai Lama has to say on the millennium, all it takes
is
   a few seconds to read and think about.
  
   Do not keep this message. The mantra must leave your hands within 96
   hours.
   You will get a very pleasant surprise. This is true even if you are not
   superstitious.
  
   Instructions for Life in the new millennium from the Dalai Lama:
  
   1. Take into account that great love and great achievements involve
great
   risk.
  
   2. When you lose, don't lose the lesson.
  
   3. Follow the three Rs:
  
   Respect for self
   Respect for others and
   Responsibility for all your actions.
  
   4. Remember that not getting what you want is sometimes a wonderful
 stroke
   of luck.
  
   5. Learn the rules so you know how to break them properly.
  
   6. Don't let a little dispute injure a great friendship.
  
   7. When you realize you've made a mistake, take immediate steps to
 correct
   it.
  
   8. Spend some time alone every day.
  
   9. Open your arms to change, but don't let go of your values.
  
   10. Remember that silence is sometimes the best answer.
  
   11. Live a good, honorable life. Then when you get older and think
back,
   you'll be able to enjoy it a second time.
  
   12. A loving atmosphere in your home is the foundation for your life.
  
   13. In disagreements with loved ones, deal only with the current
   situation.  Don't bring up the past.
  
   14. Share your knowledge. It's a way to achieve immortality.
  
   15. Be gentle with the earth.
  
   16. Once a year, go someplace you've never been before.
  
   17. Remember that the best relationship is one in which your love for
 each
   other exceeds your need for each other.
  
   18. Judge your success by what you had to give up in order to get it.
  
   19. Approach love and cooking with reckless abandon.
  
   Do not keep this message. The mantra must leave your hands within 96
   hours.
   You will get a very pleasant surprise (this is true even if you are
   not superstitious) if you send it to:
   0-4 people Your life will improve slightly.
   5-9 people Your life will improve to your liking.
   9-14 people You will have at least 5 surprises in the next 3 weeks.
   15 people and above Your life will improve drastically and
everything
   you ever dreamed of will begin to take shape
  
  
   __
  

 
 Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com







Tieing http session to db connection in orion?!?

2000-08-13 Thread keith kwiatek

  * some people say, it's best practice to put 1 connection
  into 1 user's http
  session and use it for all requests of that user
 This only works if you don't have a lot of users concurrently,
 say a small intranet application, that doesn't care scalibility.
 The reason is database connection can't be serialized for sure
 and connection in http session can't be replicated across your
 web server farm.  Hence each user in a session requires to use
 the same machine in your web farm.  This could be terrible if you
 intend to serve thousands of users concurrently.  Secondly
 database licensing is an issue.  Some database vendors charge you
 by concurrent opened connection.  If your site has a thousand
 users concurrently, you will need to purchase a thousand licenses
 (That is the thing scares me most).

Agreed with replier..you would NEVER want to do this. If you are not careful
you can lose the connections which will ultimately crash the database and/or
the web server. VERY bad design.

Hello,

With regards to the discussion above, and the "tieing of an http session to a single 
(or multiple) database connections", a lot of people downed this idea, BUT... 

I actually consider the "one http/db connection" to be a good way for small/medium 
intranet type applications to use the "transaction managment" of the database (ie 
oracle's "select for update", two phase commit).

OTHERWISE, HOW would you handle the transaction management ?! If you use database 
connection pooling in an http sessionless environment, how do you handle the dirty 
read/write situation? What do you do if an http request fetches data for "update", but 
by the time the update is accomplished, the data has already changed (please don't 
tell me you you've coded a "check timestamp" for database rows!)? Or does everyone use 
optimistic locking?

OR is this where the powers of EJB state + transaction managment comes in? 

Thanks,

Keith






RE: posting fourth time but did not got any answer

2000-08-13 Thread J.T. Wenting

For server shutdown, a quick hack is to create a servlet that loads on
server startup, has an empty init method, no service methods, and a finalize
that does something. finalize will get called when the class instance (of
which there is only one, of course) is garbage collected, which happens to
be right before the JVM terminates ;)

 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]]On Behalf Of Christian Sell
 Sent: Sunday, August 13, 2000 14:32
 To: Orion-Interest
 Cc: Orion-Interest
 Subject: Re: posting fourth time but did not got any answer


 for server startup, the following should do:

 1. specify load-on-startup for your servlet in web.xml
 2. specify load-on-startup for your web application in web-site.xml

 for server shutdown, I have no idea

  Khan Kamran schrieb:
 
  Hi all,
 
  I want to know how i can run my servlet at orion server startup and
  shutdown.
 
  Ples
 
  help
 
  Thanks
  Kamran






Re: Netscape 4.7: Connection reset by peer

2000-08-13 Thread Dale Bronk

I have received this error also.  I have not narrowed it down to Netscape
4.7.  I simply see about every couple of days this exception popping up on
my server console.  I have sent this to support and this mailing list before
and have not received an answer.  I have received replies stating they see
the same thing.




- Original Message -
From: Thomas Kwan [EMAIL PROTECTED]
To: Orion-Interest [EMAIL PROTECTED]
Sent: Sunday, August 13, 2000 12:01 AM
Subject: Netscape 4.7: Connection reset by peer


 Have anyone seen Connection reset by peer doing a POST operation
 using Netscape 4.7?

 I got the error randomly.







Setting system properties

2000-08-13 Thread Ray

Hi there again 

I have a question setting system properties under Orion.

I have the following lines of code in my client app:

System.setProperty("java.naming.factory.initial", 
"com.evermind.server.rmi.RMIInitialContextFactory");

System.setProperty("java.naming.provider.url", "ormi://localhost/store");

System.setProperty("java.naming.security.principal", "user");

System.setProperty("java.naming.security.credentials", "456");

.. which throws a security exception saying that I don't have the correct 
username/password.

But when I put the settings in a jndi.properties file, they all work 
correctly. Is there any way to put the settings in the code?

Thanks





Re: Netscape 4.7: Connection reset by peer

2000-08-13 Thread pminearo



Have you tried to duplicate the error on other platforms?

I have received this error numerous times.  It seems to be machine specific.   I
get it all the time with my laptop; but with mine and other desktops, I do not
get it.  I have consulted others on this issue and they are inclined to believe
that it has to do something my mahcine's IP stack.






Anders Bengtsson [EMAIL PROTECTED] on 08/13/2000 08:05:14 AM

To:   Orion-Interest [EMAIL PROTECTED]
cc:

Subject:  Re: Netscape 4.7: Connection reset by peer



Thomas Kwan wrote:

 Have anyone seen Connection reset by peer doing a POST operation
 using Netscape 4.7?

 I got the error randomly.

We've been having the same problem when POSTing from an applet in
Netscape. It seems to appear only when the posted data is above some
size (don't remember what size exactly).
We reported it recently, but I don't think we have received any response
yet.

/Anders
_
A n d e r s  B e n g t s s o n  [EMAIL PROTECTED]
http://www.natakademin.se/