RE: Placing resources in to Orion/JNDI...

2000-03-29 Thread Alex Paransky

Worked great, with one exception.  The resource I am trying to register, is
being referenced  from one of the ejb-jar.xml files.  However,
the ejb-jar.xml gets processed BEFORE my .  So, I get an
error from Orion.

E:\work\orion>java -jar d:\java\orion\orion.jar
Auto-deploying citysearch...
Error initializing home of type ejb/ClassType in package
E:\work\citysearch\com\
citysearch\ejb\ClassType: Error creating context: toplink/SessionFactory not
found
Auto-starting com/citysearch/ejb/TopLink...
DefaultSessionFactory.DefaultSessionFactory creating initial context
DefaultSessionFactory.DefaultSessionFactory retrieving resource location
DefaultSessionFactory.DefaultSessionFactory binding to
toplink/SessionFactory
Orion/0.9.4 initialized

As you can see, the "toplink/SessionFactory" gets bound to the registry
AFTER the bean starts up.  Is there away to force my client-module to load
BEFORE anything else?  

Thanks.
-AP_

-Original Message-
From: Magnus Stenman [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, March 29, 2000 1:37 AM
To: Orion-Interest
Subject: Re: Placing resources in to Orion/JNDI...


The recommended procedure for this in Orion is to create an
application-client (j2ee, with META-INF/application-client.xml etc) that
performs the task. You then set auto-start="true" on the  tag
in orion-application.xml and specify a valid user="" attribute value to run
it as in order to invoke it at server startup. We feel this procedure is the
best since it uses minimum "proprietary" technologies and is the most
portable. You will have a problem if using / when
using the values you bind to the context though since the values need to be
present before the app-client is run, but for global vars/bindings it will
work fine.

/Magnus Stenman, the Orion team

- Original Message -
From: "Alex Paransky" <[EMAIL PROTECTED]>
To: "Orion-Interest" <[EMAIL PROTECTED]>
Sent: Wednesday, March 29, 2000 1:42 AM
Subject: Placing resources in to Orion/JNDI...


> I have a resource which needs to be available for all the EJB objects to
> use.  I would like to create this resource and bind it in to JNDI context.
> This is a singleton resource.  I am not sure of how to accomplish this
with
> Orion.  In other servers, there is a way to execute some "startup" code
> which could do this initialization for me, however, with Orion I am at
loss.
>
>
> Section 5.4 of the J2EE 1.2 Spec talks about Resource Factory References,
> which should be used to reference "factory" type of resources from the
> beans.  The problem is that the Reference, is just that, a reference to
> something else.  How do I put that "something else" in to the JNDI
registry
> at server startup, so the reference is then valid.
>
> Thanks.
> -AP_





Re: Placing resources in to Orion/JNDI...

2000-03-29 Thread Magnus Stenman

The recommended procedure for this in Orion is to create an
application-client (j2ee, with META-INF/application-client.xml etc) that
performs the task. You then set auto-start="true" on the  tag
in orion-application.xml and specify a valid user="" attribute value to run
it as in order to invoke it at server startup. We feel this procedure is the
best since it uses minimum "proprietary" technologies and is the most
portable. You will have a problem if using / when
using the values you bind to the context though since the values need to be
present before the app-client is run, but for global vars/bindings it will
work fine.

/Magnus Stenman, the Orion team

- Original Message -
From: "Alex Paransky" <[EMAIL PROTECTED]>
To: "Orion-Interest" <[EMAIL PROTECTED]>
Sent: Wednesday, March 29, 2000 1:42 AM
Subject: Placing resources in to Orion/JNDI...


> I have a resource which needs to be available for all the EJB objects to
> use.  I would like to create this resource and bind it in to JNDI context.
> This is a singleton resource.  I am not sure of how to accomplish this
with
> Orion.  In other servers, there is a way to execute some "startup" code
> which could do this initialization for me, however, with Orion I am at
loss.
>
>
> Section 5.4 of the J2EE 1.2 Spec talks about Resource Factory References,
> which should be used to reference "factory" type of resources from the
> beans.  The problem is that the Reference, is just that, a reference to
> something else.  How do I put that "something else" in to the JNDI
registry
> at server startup, so the reference is then valid.
>
> Thanks.
> -AP_






Placing resources in to Orion/JNDI...

2000-03-28 Thread Alex Paransky

I have a resource which needs to be available for all the EJB objects to
use.  I would like to create this resource and bind it in to JNDI context.
This is a singleton resource.  I am not sure of how to accomplish this with
Orion.  In other servers, there is a way to execute some "startup" code
which could do this initialization for me, however, with Orion I am at loss.


Section 5.4 of the J2EE 1.2 Spec talks about Resource Factory References,
which should be used to reference "factory" type of resources from the
beans.  The problem is that the Reference, is just that, a reference to
something else.  How do I put that "something else" in to the JNDI registry
at server startup, so the reference is then valid.

Thanks.
-AP_