admin@glassfish.java.net

Re: Unix Style path names

From: Vince Kraemer <vince.kraemer_at_oracle.com>
Date: Tue, 31 Aug 2010 16:54:15 -0700

Folks may want to be on the look-out for space-in-path problems, too.

vbk

Carla Mott wrote:
>
> Hi all,
>
> I wanted to provide some information from my investigation of issue
> 12961. We were seeing failures in create-instance and start-instance
> when running on Windows platforms. The error only shows up when the
> DAS is running on Windows because the tokens for install root or
> instance root are resolved and they are platform specific and on
> Windows the strings returned contain backslashes. This caused
> problems when the strings returned were used to create a command to
> run on MKS and we suspect cgwin because the backslashes are
> interpreted as an escape character by that shell. I have added APIs
> to the Node config bean to return Unix style path names to help avoid
> these problems. For example, if you are going to use the node install
> dir attribute to create a command to run over SSH you will want to use
> the API getInstallDirUnixStyle which returns the path with forward
> slashes.
>
> One other place I saw an error in using the platform specific path
> separator is in creating a URI. Again the backslash caused an error.
> I have updated code that affected creating and staring an instance but
> have not looked to see if there are other cases where this can cause a
> failure on Windows. I'm hoping folks will use this email as a trigger
> to think about any cases where they are grabbing a token that will
> have platform dependent separators and try to use that string either
> over SSH or to create a URI.
> Thanks,
> Carla
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: admin-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: admin-help_at_glassfish.dev.java.net
>