You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@geronimo.apache.org by "Alan D. Cabrera" <li...@toolazydogs.com> on 2006/10/02 16:10:49 UTC

Re: Fixing java.endorsed.dirs

On Sep 28, 2006, at 12:25 PM, Dain Sundstrom wrote:

>
> Anyway, this sucks, since it requires users to use a shell script  
> to launch Geronimo.  Is there anyway to detect the corba api  
> version and not load the Yoko classes that have the problems?


When it comes to futzing w/ the endorsed dirs I would rather have it  
in the up front and in my face via a script than have some cute code  
forking and setting things behind the scenes.

We can add some startup code that looks for the "bad" versions of  
classes and throw an exception w/ a useful message stating that the  
endorsed dirs list was probably not setup correctly.

Let's keep it simple.


Regards,
Alan



Re: Fixing java.endorsed.dirs

Posted by Heinz Drews <he...@gmail.com>.
You can only replace the bootstrap classes with the endorsed mechanism
or by changing the bootstrap class path.

I don't think that there is anything else available.

Heinz


On 10/4/06, Alan D. Cabrera <li...@toolazydogs.com> wrote:
>
> On Oct 4, 2006, at 1:53 AM, Rick McGuire wrote:
>
> > Alan D. Cabrera wrote:
> >>> On Sep 28, 2006, at 12:25 PM, Dain Sundstrom wrote:
> >>>
> >>>
> >>>> Anyway, this sucks, since it requires users to use a shell
> >>>> script to launch Geronimo.  Is there anyway to detect the corba
> >>>> api version and not load the Yoko classes that have the problems?
> >>
> >>
> >> OT: in the future, if we used OSGi as a base, we would have a
> >> clean workaround for this problem, no?
> > I'm not sure how OSGi would help with this.  The functioning of
> > java.endorsed.dirs is a base function of how the JVM works.
> > There's not much other option to get around this.
>
> IIUC, you can eclipse JVM classes with your own.  Do I have it wrong?
>
>
> Regards,
> Alan
>
>
>

Re: Fixing java.endorsed.dirs

Posted by Jason Dillon <ja...@planet57.com>.
I think this would only work if the JVM was based on OSGI...

--jason


On Oct 4, 2006, at 12:39 PM, Alan D. Cabrera wrote:

>
> On Oct 4, 2006, at 1:53 AM, Rick McGuire wrote:
>
>> Alan D. Cabrera wrote:
>>>> On Sep 28, 2006, at 12:25 PM, Dain Sundstrom wrote:
>>>>
>>>>
>>>>> Anyway, this sucks, since it requires users to use a shell  
>>>>> script to launch Geronimo.  Is there anyway to detect the corba  
>>>>> api version and not load the Yoko classes that have the problems?
>>>
>>>
>>> OT: in the future, if we used OSGi as a base, we would have a  
>>> clean workaround for this problem, no?
>> I'm not sure how OSGi would help with this.  The functioning of  
>> java.endorsed.dirs is a base function of how the JVM works.   
>> There's not much other option to get around this.
>
> IIUC, you can eclipse JVM classes with your own.  Do I have it wrong?
>
>
> Regards,
> Alan
>
>


Re: Fixing java.endorsed.dirs

Posted by Rick McGuire <ri...@gmail.com>.
Alan D. Cabrera wrote:
>
> On Oct 4, 2006, at 1:53 AM, Rick McGuire wrote:
>
>> Alan D. Cabrera wrote:
>>>> On Sep 28, 2006, at 12:25 PM, Dain Sundstrom wrote:
>>>>
>>>>
>>>>> Anyway, this sucks, since it requires users to use a shell script 
>>>>> to launch Geronimo.  Is there anyway to detect the corba api 
>>>>> version and not load the Yoko classes that have the problems?
>>>
>>>
>>> OT: in the future, if we used OSGi as a base, we would have a clean 
>>> workaround for this problem, no?
>> I'm not sure how OSGi would help with this.  The functioning of 
>> java.endorsed.dirs is a base function of how the JVM works.  There's 
>> not much other option to get around this.
>
> IIUC, you can eclipse JVM classes with your own.  Do I have it wrong?
Yes, but there are certain fundamental classes where this become 
problematic because other portions of the JVM also contain references to 
these classes.  This is why java.endorsed.dirs got created in the first 
place. 

>
>
> Regards,
> Alan
>
>
>


Re: Fixing java.endorsed.dirs

Posted by "Alan D. Cabrera" <li...@toolazydogs.com>.
On Oct 4, 2006, at 1:53 AM, Rick McGuire wrote:

> Alan D. Cabrera wrote:
>>> On Sep 28, 2006, at 12:25 PM, Dain Sundstrom wrote:
>>>
>>>
>>>> Anyway, this sucks, since it requires users to use a shell  
>>>> script to launch Geronimo.  Is there anyway to detect the corba  
>>>> api version and not load the Yoko classes that have the problems?
>>
>>
>> OT: in the future, if we used OSGi as a base, we would have a  
>> clean workaround for this problem, no?
> I'm not sure how OSGi would help with this.  The functioning of  
> java.endorsed.dirs is a base function of how the JVM works.   
> There's not much other option to get around this.

IIUC, you can eclipse JVM classes with your own.  Do I have it wrong?


Regards,
Alan



Re: Fixing java.endorsed.dirs

Posted by Rick McGuire <ri...@gmail.com>.
Alan D. Cabrera wrote:
>> On Sep 28, 2006, at 12:25 PM, Dain Sundstrom wrote:
>>
>>
>>> Anyway, this sucks, since it requires users to use a shell script to 
>>> launch Geronimo.  Is there anyway to detect the corba api version 
>>> and not load the Yoko classes that have the problems?
>
>
> OT: in the future, if we used OSGi as a base, we would have a clean 
> workaround for this problem, no?
I'm not sure how OSGi would help with this.  The functioning of 
java.endorsed.dirs is a base function of how the JVM works.  There's not 
much other option to get around this.

>
>
> Regards,
> Alan
>
>
>


Re: Fixing java.endorsed.dirs

Posted by "Alan D. Cabrera" <li...@toolazydogs.com>.
> On Sep 28, 2006, at 12:25 PM, Dain Sundstrom wrote:
>
>
>> Anyway, this sucks, since it requires users to use a shell script  
>> to launch Geronimo.  Is there anyway to detect the corba api  
>> version and not load the Yoko classes that have the problems?


OT: in the future, if we used OSGi as a base, we would have a clean  
workaround for this problem, no?


Regards,
Alan



Re: Fixing java.endorsed.dirs

Posted by Rick McGuire <ri...@gmail.com>.
Aaron Mulder wrote:
> On 10/2/06, Dain Sundstrom <da...@iq80.com> wrote:
>> > When it comes to futzing w/ the endorsed dirs I would rather have
>> > it in the up front and in my face via a script than have some cute
>> > code forking and setting things behind the scenes.
>>
>> I couldn't agree more.  I dislike Java forking Java more than I
>> dislike using shell scripts to start Java.
>
> My biggest potential problem with forking is that the way I usually
> set up a server process is to launch it into the background and record
> the process ID to a file.  If the original process immediately
> launches a new process and quits, then I may not know what the actual
> server process ID is and I may not be able to effectively kill it
> later.  It's less problematic since you can shut down with the console
> or shutdown JAR, but still annoying.
Forking also poses some interesting issues, such as making sure the same 
set of JVM options (e.g., memory options) get used for the forked 
JVM....or making sure the new JVM gets launched in a cross 
vendor/release fashion.

Rick


>
> Thanks,
>      Aaron
>


Re: Fixing java.endorsed.dirs

Posted by Aaron Mulder <am...@alumni.princeton.edu>.
On 10/2/06, Dain Sundstrom <da...@iq80.com> wrote:
> > When it comes to futzing w/ the endorsed dirs I would rather have
> > it in the up front and in my face via a script than have some cute
> > code forking and setting things behind the scenes.
>
> I couldn't agree more.  I dislike Java forking Java more than I
> dislike using shell scripts to start Java.

My biggest potential problem with forking is that the way I usually
set up a server process is to launch it into the background and record
the process ID to a file.  If the original process immediately
launches a new process and quits, then I may not know what the actual
server process ID is and I may not be able to effectively kill it
later.  It's less problematic since you can shut down with the console
or shutdown JAR, but still annoying.

Thanks,
      Aaron

Re: Fixing java.endorsed.dirs

Posted by Dain Sundstrom <da...@iq80.com>.
On Oct 2, 2006, at 7:10 AM, Alan D. Cabrera wrote:

> On Sep 28, 2006, at 12:25 PM, Dain Sundstrom wrote:
>
>> Anyway, this sucks, since it requires users to use a shell script  
>> to launch Geronimo.  Is there anyway to detect the corba api  
>> version and not load the Yoko classes that have the problems?
>
> When it comes to futzing w/ the endorsed dirs I would rather have  
> it in the up front and in my face via a script than have some cute  
> code forking and setting things behind the scenes.

I couldn't agree more.  I dislike Java forking Java more than I  
dislike using shell scripts to start Java.

> We can add some startup code that looks for the "bad" versions of  
> classes and throw an exception w/ a useful message stating that the  
> endorsed dirs list was probably not setup correctly.

I'd prefer we keep such a check to the Corba startup code.  In the  
normally our users will not be starting the corba module so there is  
no need to force everyone to use the shell scripts.

-dain