You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@geronimo.apache.org by David Blevins <da...@visi.com> on 2007/09/29 05:40:40 UTC

Jndi names, need input (Re: [DISCUSS] G 2.0.2 Release plan)

On Sep 25, 2007, at 3:40 PM, David Blevins wrote:

>
> On Sep 25, 2007, at 7:38 AM, Kevan Miller wrote:
>
>> One thing I've noticed -- the default JNDI name for EJB's has been  
>> changed in OpenEJB. So, there is a compatibility issue with 2.0.1.  
>> We might be able to configure how OpenEJB generates this default  
>> to maintain backward compatibility. Better, IMO, to go ahead and  
>> match OpenEJB's behavior.
>
> There are no compatibility issues as it was explicitly set in  
> Geronimo 2.0.1 to be essentially {moduleId}/{ejbName}/ 
> {interfaceClass}  (actually it's {deploymentId}/{interfaceClass}  
> and deploymentId will be {moduleId}/{ejbName}).  It'll still be the  
> same in Geronimo 2.0.2, just now it can be changed to something  
> shorter.
>
> I'd be fine with Geronimo using the OpenEJB default of essentially  
> {ejbName}{interfaceType.annotationName} (it's {deploymentId} 
> {interfaceType.annotation} where deploymentId defaults to  
> {ejbName}), but it's definitely a default that targets people with  
> just a couple apps.  People in bigger environments would have to  
> set the jndiname and deploymentId formats to something less likely  
> to conflict.

Does anyone have any thoughts or preferences on this one?  Need to  
get some input from the group.

-David




Re: Jndi names, need input (Re: [DISCUSS] G 2.0.2 Release plan)

Posted by David Blevins <da...@visi.com>.
On Oct 2, 2007, at 7:02 PM, David Blevins wrote:

> Ok, I made the following changes:
>
>  - Set the deployment id format to {appId}/{moduleId}/{ejbName}   
> (fixes GERONIMO-3199)
>  - Set jndiname format to {ejbName}{interfaceType.annotationName}   
> (this MUST go in the release notes as it will be a significant change)
>  - Setup jndi name binding of non-javaee clients to not fail a  
> deployment if a name is taken (just logs an ERROR as usual).
>
> I also slurped in the OpenEJB documentation on this subject to a  
> new page here:
>   http://cwiki.apache.org/GMOxSBOX/client-jndi-names.html

Moved the page to GMOxDEV per Hernan's request.

-David




Re: Jndi names, need input (Re: [DISCUSS] G 2.0.2 Release plan)

Posted by David Blevins <da...@visi.com>.
On Oct 1, 2007, at 4:24 PM, David Jencks wrote:

> I talked with david a bit on irc and he tells me there is a flag so  
> we can set it so if there is a non-javaee jndi name conflict we log  
> an error instead of throwing an exception.
>
> I'm happy with a simple default format for non-javaee jndi ejb  
> names if collisions result in loud logging rather than exceptions.   
> I'd like it to be possible for people only using javaee to deploy  
> lots of copies of the same app without exceptions from name  
> collisions, even if this means some random copy of the app wins in  
> the non-javaee jndi.  If someone wants to do this AND use non- 
> javaee jndi they should read the instructions and figure out a  
> sufficiently complicate name format so they avoid collisions.
>
> IIUC the proposed simple name format above that one would be just  
> fine.

Ok, I made the following changes:

  - Set the deployment id format to {appId}/{moduleId}/{ejbName}   
(fixes GERONIMO-3199)
  - Set jndiname format to {ejbName}{interfaceType.annotationName}   
(this MUST go in the release notes as it will be a significant change)
  - Setup jndi name binding of non-javaee clients to not fail a  
deployment if a name is taken (just logs an ERROR as usual).

I also slurped in the OpenEJB documentation on this subject to a new  
page here:
   http://cwiki.apache.org/GMOxSBOX/client-jndi-names.html

.. primarily because it didn't seem possible to include part of it  
and have the updated Geronimo specific info that:
   1.  we won't fail the deployment on conflict and that this can be  
changed.
   2.  the default openejb.jndiname.format is actually {ejbName} 
{interfaceType.annotationName} rather than {deploymentId} 
{interfaceType.annotationName}.  The openejb.deploymentId.format in  
Geronimo is intentionally complex as to not have any conflicts.
   3.  the re recommended way to set a system property is likely via  
the config.xml which we should show in this document.  Unless of  
course we add a gbean property to OpenEjbSystemGBean, in which case  
it's still via the config.xml but in a different way.

Anyway, this doc needs #3 to get updated and we also need to find a  
place for it in one the main docco spaces for 2.0.2.

	
-David


Re: Jndi names, need input (Re: [DISCUSS] G 2.0.2 Release plan)

Posted by David Jencks <da...@yahoo.com>.
On Sep 29, 2007, at 3:06 PM, David Blevins wrote:

>
> On Sep 29, 2007, at 12:31 AM, David Jencks wrote:
>
>>
>> On Sep 28, 2007, at 8:40 PM, David Blevins wrote:
>>
>>>
>>> On Sep 25, 2007, at 3:40 PM, David Blevins wrote:
>>>
>>>>
>>>> On Sep 25, 2007, at 7:38 AM, Kevan Miller wrote:
>>>>
>>>>> One thing I've noticed -- the default JNDI name for EJB's has  
>>>>> been changed in OpenEJB. So, there is a compatibility issue  
>>>>> with 2.0.1. We might be able to configure how OpenEJB generates  
>>>>> this default to maintain backward compatibility. Better, IMO,  
>>>>> to go ahead and match OpenEJB's behavior.
>>>>
>>>> There are no compatibility issues as it was explicitly set in  
>>>> Geronimo 2.0.1 to be essentially {moduleId}/{ejbName}/ 
>>>> {interfaceClass}  (actually it's {deploymentId}/{interfaceClass}  
>>>> and deploymentId will be {moduleId}/{ejbName}).  It'll still be  
>>>> the same in Geronimo 2.0.2, just now it can be changed to  
>>>> something shorter.
>>>>
>>>> I'd be fine with Geronimo using the OpenEJB default of  
>>>> essentially {ejbName}{interfaceType.annotationName} (it's  
>>>> {deploymentId}{interfaceType.annotation} where deploymentId  
>>>> defaults to {ejbName}), but it's definitely a default that  
>>>> targets people with just a couple apps.  People in bigger  
>>>> environments would have to set the jndiname and deploymentId  
>>>> formats to something less likely to conflict.
>>>
>>> Does anyone have any thoughts or preferences on this one?  Need  
>>> to get some input from the group.
>>
>> My opinion on what to do depends a bit on whether this name format  
>> can result in name collisions for javaee clients as well as non- 
>> javaee clients.
>
> Javaee client names and the non-javaee client now use different  
> trees, so the jndiformat has no impact on javaee client functionality.

I talked with david a bit on irc and he tells me there is a flag so  
we can set it so if there is a non-javaee jndi name conflict we log  
an error instead of throwing an exception.

I'm happy with a simple default format for non-javaee jndi ejb names  
if collisions result in loud logging rather than exceptions.  I'd  
like it to be possible for people only using javaee to deploy lots of  
copies of the same app without exceptions from name collisions, even  
if this means some random copy of the app wins in the non-javaee  
jndi.  If someone wants to do this AND use non-javaee jndi they  
should read the instructions and figure out a sufficiently complicate  
name format so they avoid collisions.

IIUC the proposed simple name format above that one would be just fine.

thanks
david jencks

>
> -David
>


Re: Jndi names, need input (Re: [DISCUSS] G 2.0.2 Release plan)

Posted by David Blevins <da...@visi.com>.
On Sep 29, 2007, at 12:31 AM, David Jencks wrote:

>
> On Sep 28, 2007, at 8:40 PM, David Blevins wrote:
>
>>
>> On Sep 25, 2007, at 3:40 PM, David Blevins wrote:
>>
>>>
>>> On Sep 25, 2007, at 7:38 AM, Kevan Miller wrote:
>>>
>>>> One thing I've noticed -- the default JNDI name for EJB's has  
>>>> been changed in OpenEJB. So, there is a compatibility issue with  
>>>> 2.0.1. We might be able to configure how OpenEJB generates this  
>>>> default to maintain backward compatibility. Better, IMO, to go  
>>>> ahead and match OpenEJB's behavior.
>>>
>>> There are no compatibility issues as it was explicitly set in  
>>> Geronimo 2.0.1 to be essentially {moduleId}/{ejbName}/ 
>>> {interfaceClass}  (actually it's {deploymentId}/{interfaceClass}  
>>> and deploymentId will be {moduleId}/{ejbName}).  It'll still be  
>>> the same in Geronimo 2.0.2, just now it can be changed to  
>>> something shorter.
>>>
>>> I'd be fine with Geronimo using the OpenEJB default of  
>>> essentially {ejbName}{interfaceType.annotationName} (it's  
>>> {deploymentId}{interfaceType.annotation} where deploymentId  
>>> defaults to {ejbName}), but it's definitely a default that  
>>> targets people with just a couple apps.  People in bigger  
>>> environments would have to set the jndiname and deploymentId  
>>> formats to something less likely to conflict.
>>
>> Does anyone have any thoughts or preferences on this one?  Need to  
>> get some input from the group.
>
> My opinion on what to do depends a bit on whether this name format  
> can result in name collisions for javaee clients as well as non- 
> javaee clients.

Javaee client names and the non-javaee client now use different  
trees, so the jndiformat has no impact on javaee client functionality.

-David


Re: Jndi names, need input (Re: [DISCUSS] G 2.0.2 Release plan)

Posted by David Jencks <da...@yahoo.com>.
On Sep 28, 2007, at 8:40 PM, David Blevins wrote:

>
> On Sep 25, 2007, at 3:40 PM, David Blevins wrote:
>
>>
>> On Sep 25, 2007, at 7:38 AM, Kevan Miller wrote:
>>
>>> One thing I've noticed -- the default JNDI name for EJB's has  
>>> been changed in OpenEJB. So, there is a compatibility issue with  
>>> 2.0.1. We might be able to configure how OpenEJB generates this  
>>> default to maintain backward compatibility. Better, IMO, to go  
>>> ahead and match OpenEJB's behavior.
>>
>> There are no compatibility issues as it was explicitly set in  
>> Geronimo 2.0.1 to be essentially {moduleId}/{ejbName}/ 
>> {interfaceClass}  (actually it's {deploymentId}/{interfaceClass}  
>> and deploymentId will be {moduleId}/{ejbName}).  It'll still be  
>> the same in Geronimo 2.0.2, just now it can be changed to  
>> something shorter.
>>
>> I'd be fine with Geronimo using the OpenEJB default of essentially  
>> {ejbName}{interfaceType.annotationName} (it's {deploymentId} 
>> {interfaceType.annotation} where deploymentId defaults to  
>> {ejbName}), but it's definitely a default that targets people with  
>> just a couple apps.  People in bigger environments would have to  
>> set the jndiname and deploymentId formats to something less likely  
>> to conflict.
>
> Does anyone have any thoughts or preferences on this one?  Need to  
> get some input from the group.

My opinion on what to do depends a bit on whether this name format  
can result in name collisions for javaee clients as well as non- 
javaee clients.  My impression is that it can result in name  
collisions for both if you pick a name format that is not  
sufficiently unique.  Assuming this is true I would prefer to have a  
default name format that minimizes the chance of name collisions  
together with easy-to-follow instructions for those with only one app  
or who can modify all their apps to avoid name collisions as needed.

thanks
david jencks


>
> -David
>
>
>