dev@glassfish.java.net

Re: directory deployment and global jndi names appear to not play well together...

From: Hong Zhang <Hong.Zhang_at_Sun.COM>
Date: Fri, 02 Oct 2009 21:01:51 -0400

Hi, Bill

>>> The spec may be overstating things here, or you may be misinterpreting
>>> them. The intent was not to prevent deployment tools from being to
>>> specify the name at deployment time, overriding the default or
>>> app-specified
>>> name. I would expect the --name argument to specify the application
>>> name.
>>>
>>> Let me reword the spec to make it clear that deployment tools are
>>> allowed
>>> to do this.
>>
>
> Rereading the spec, I think this is pretty clear in the application case,
> but maybe not quite as clear in the standalone module case. Were you
> treating the two cases differently?
>
No, they were treated the same. I implemented this part quite early when
there was no formal write up in the spec yet. At the time, when I
discussed with Ken about the pieces we know, we felt it's probably best
to separate the portable EE 6 spec name from the impl specific
application registration name. I talked to Ken again about this
clarification, and he is fine with making them the same. I am in the
process of making the changes now.

Thanks,

- Hong

>> Thanks for the clarification. I will make the changes to not
>> differentiate application registration name and EE 6 application name.
>>
>> For a related part of the spec:
>> =====================
>> The deployment tool must ensure that the application name is unique
>> in the application server instance. If the name is not unique, the
>> deployment tool may automatically choose a unique name or allow the
>> Deployer to choose a unique name, but must not fail the deployment.
>> This ensures that existing applications continue to be deployable.
>> ====================
>>
>> For the cases where the user does not specify --name, we will
>> reassign another (unique) name to the application.
>> But for the case where user explicitly specifies a --name option and
>> the name is in conflict with another name, what should be the
>> expected behavior?
>
>
> Since the ability to specify a name in the deployment tool is a product
> specific feature not defined by the spec, we can do whatever we want.
>
>> I think we should still fail the deployment. If user specifies a name
>> explicitly, most likely they will depend on this name and it's not
>> good to just reassign a different name behind the scene. The error
>> message of the failed deployment would say something like
>> "Application with name XXX is already registered. Please pick a
>> different name if this is a new deployment. And please specify the
>> force option if this is a redeployment of the same application". I
>> think this behavior is spec compatible as this "allow the Deployer to
>> choose a unique name". And this behavior is more compatible with the
>> behavior we currently have (fail the deployment and ask user to use
>> force option to redeploy application). Please let me know what you
>> think.
>
>
> I agree.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: dev-help_at_glassfish.dev.java.net
>