FW: Bean to remote bean communication... (2nd try)

2002-04-16 Thread Chris Francis



I originally posted this at elephantwalker but have had little response,
hopefully someone here has some ideas...

I'm trying to lookup a bean on a remote machine. I set up initial context in
usual way using properties taken from the jndi.properties on the remote oc4j
server. 
In fact I want to lookup the bean from within a web-app (or ejb) installed
on a local oc4j server. When I attempt it all I get is 
NullPointerException: domain was null. 

Does anyone know what this means?

Some more info:
I do the lookup programmatically. If I run it as a standalone client (not
what I want to do) I get an error telling me the Factory can't find
application-client.xml - this is not surprising as it's not on my classpath.
Running from local container gives the error above. I have added an entry to
orion-application.xml: 
ejb-module remote=true path=myremoteapp-ejb /
and entries for the beans deployed there into my local oc4j servers'
application-client.xml

Here's the code I'm using to do the lookup:
Hashtable env = new Hashtable();
env.put(java.naming.provider.url,
ormi://remotemachineIP:rmiport/myremoteapp);
env.put (java.naming.factory.initial,
com.evermind.server.ApplicationClientInitialContextFactory);
env.put(java.naming.security.principal, myremoteapp);
env.put(java.naming.security.credentials, password);

targetEJB_URI = java:comp/env/ + targetEJB_URI;
EJBHome ejbRef = null;
Context ic = new InitialContext(env);

//ejbRef  = (EJBHome)PortableRemoteObject.narrow(ic.lookupLink
(targetEJB_URI), EJBHome.class);
ejbRef = (EJBHome) ic.lookupLink (targetEJB_URI);

One other thing is if I use the RMIInitialContextFactory instead then the
context lookup works if I'm running as a standalone client. I then only get
a naming exception since it can't see application-client.xml

Any help appreciated.

Thanks, 

Chris.




When to use java.util.Collection or java.util.Set

2002-04-16 Thread Randahl Fink Isaksen








Hi everybody





I noticed in the EJB 2.0
specification that most of the examples use java.util.Collection
when defining a relationship between two entities, even though java.util.Set is also allowed.



Why is that so?



I would expect java.util.Set
to be the most frequently used type, since in general you would not want
duplicates in a relationship. Think of a Person-owns-Car relationship for
instance  you are not interested in any duplicates here, since a Person
cannot own the same car twice so to speak (if one relationship says that person
P is the owner of car C, it does not provide you with any usefull
information to create yet another relationship between P and C).



Which cmr-field-types
do you use and why?





Randahl










how do I setup a datasource for mssql ?

2002-04-16 Thread @Basebeans.com

Subject: how do I setup a datasource for mssql 1 2 3 4 5 6 7 8 9
From: alt.cybercafes [EMAIL PROTECTED]
 ===
I have tried setting up my the datasource like the following

data-source
  class=com.evermind.sql.DriverManagerDataSource
  name=Billing
  schema=database-schemas/ms-sql.xml
  location=jdbc/Billing
  xa-location=jdbc/Billing
  ejb-location=jdbc/Billing
  url=com.microsoft.jdbc.sqlserver.SQLServerDriver

connection-driver=jdbc:microsoft:sqlserver://myserver:1433;DatabaseName=Bil
ling
  username=applesauce
  password=1234
  inactivity-timeout=30
 /

 and I get the following errors
Error initializing data-source 'jdbc/Billing': DriverManagerDataSource
driver 'jdbc:microsoft:sqlser
ver://Appserver1:1433;DatabaseName=Billing' not found

What am I doing wrong?

thanks








Unknown Source

2002-04-16 Thread Adam Cassar

Hi Guys,

I am having a problem with v1.5.4 of Orion. In stack traces it displays
the line number everywhere except for the EJB's!

I know it used to work, any ideas on what to look for? 





RE: When to use java.util.Collection or java.util.Set

2002-04-16 Thread Greg Davis



What 
if Person P steals car C? If I were the police I would want to know he 
stole it three times. :-) Although in most cases I would tend toward a Set 
before collections, Logging is one of the areas where P C being the key 
could exist multiple times and I would want the information. I would hope 
that you datasource would not have duplicate records in it anyway. 
:-)

  -Original Message-From: Randahl Fink Isaksen 
  [mailto:[EMAIL PROTECTED]]Sent: Tuesday, April 16, 2002 9:12 
  AMTo: Orion-InterestSubject: When to use 
  java.util.Collection or java.util.Set
  
  Hi 
  everybody
  
  
  I 
  noticed in the EJB 2.0 specification that most of the examples use java.util.Collection when defining a relationship between 
  two entities, even though java.util.Set is also 
  allowed.
  
  Why is 
  that so?
  
  I would 
  expect java.util.Set to be the most frequently used 
  type, since in general you would not want duplicates in a relationship. Think 
  of a Person-owns-Car relationship for instance - you are not interested in any 
  duplicates here, since a Person cannot own the same car twice so to speak (if 
  one relationship says that person P is the owner of car C, it does not provide 
  you with any usefull information to create yet 
  another relationship between P and C).
  
  Which 
  cmr-field-types do you use and 
  why?
  
  
  Randahl
  


could somebody help me pls

2002-04-16 Thread Cristina Perma




 Hi,
 I have a database on firebird interbase and respectively a jsp file with a 
bean file . The bean must be the connection to the database, but I receive an 
error like in attached file:

   Know somebody why ??


__
Do you want a free e-mail for life ? Get it at http://www.clujnapoca.ro/




eroare.zip
Description: Zip compressed data


JNDI Reference to home of EJB failing?

2002-04-16 Thread Ken Cooper

Attempting to get a reference to the home of a bean.

Context is setup as follows:

  Hashtable env = new Hashtable();
  env.put(Context.INITIAL_CONTEXT_FACTORY,
  com.evermind.server.rmi.RMIInitialContextFactory);
  env.put(Context.SECURITY_PRINCIPAL, admin);
  env.put(Context.SECURITY_CREDENTIALS, admin);
  env.put(Context.PROVIDER_URL,  
ormi://kecooper-lap:23792/Stateless1);
  Context ctx = new InitialContext(env);

Doing a lookup as per the following:

  Stateless1Home stateless1Home = 
(Stateless1Home)ctx.lookup(Stateless1);

All works well - no issues.
Problem is converting above lookup to a lookup of the following type:

 Object homeObject = ctx.lookup(java:comp/env/Stateless1);

The subsequent step would be to narrow the homeObject reference. However I 
cannot get the reference. Using Oracles JDeveloper9i I get the following 
error message:

 javax.naming.NameNotFoundException: java:comp/env/Stateless1 not found

Need some help in determining hyow to fix this problem. I have modified 
several xml files, in particular ejb-jar.xml and orion-ejb-jar.xml to no 
avail.

PLEASE let me know a possible solution as soon as possible.

THANKS - Ken Cooper

--
Kenneth Cooper, Jr.[EMAIL PROTECTED]
--


_
MSN Photos is the easiest way to share and print your photos: 
http://photos.msn.com/support/worldwide.aspx





You Can Reverse the Aging Process 10-20 years with HGH.

2002-04-16 Thread ultimatehgh








 



 
Hello, [EMAIL PROTECTED],As seen on NBC, CBS, CNN, and even Oprah! 
The health discovery that actually reverses aging while burning 
fat, without dieting or exercise! This proven discovery has 
even been reported on by the New England Journal of Medicine. 
Forget aging and dieting forever! And it's Guaranteed!


Click here 


Would you like to lose weight while you sleep!
No dieting!
No hunger pains!
No Cravings!
No strenuous exercise!
Change your life forever! 





 
1.Body 
Fat Loss 
82% 
improvement.

 
2.Wrinkle 
Reduction 
61% 
improvement.

 
3.Energy 
Level 
84% 
improvement.

 
4.Muscle 
Strength 
88% 
improvement.

 
5.Sexual 
Potency 
75% 
improvement.

 
6.Emotional 
Stability 
67% 
improvement.

 
7.Memory 

62% 
improvement.


 

100% 
GUARANTEED!






 





 
 



















 

You 
are receiving this email as a subscriber
to the Opt-In America Mailing List. 
To remove yourself from all related maillists,
just  
Click Here