[ grinder-Feature Requests-2908989 ] grinder.jvm.arguments with spaces

"SourceForge.net" <[email protected]>
Newsgroups gmane.comp.java.grinder.devel
Message-ID <[email protected]>
Feature Requests item #2908989, was opened at 2009-12-04 19:01
Message generated for change (Comment added) made by sf-robot
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=368598&aid=2908989&group_id=18598

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: Core engine
Group: None
>Status: Closed
Priority: 5
Private: No
Submitted By: Chris Cooper (coopstah13)
Assigned to: Nobody/Anonymous (nobody)
Summary: grinder.jvm.arguments with spaces

Initial Comment:
It would be nice if you could specify through a -Dgrinder.jvm.arguments more than one thing, probably quoted would be the easiest (currently the only way is through grinder.properties which i'm avoiding using at all costs).
The code is already in place to support a space separated string of arguments, but it doesn't have code to handle the quotes. It would be an easy addition. Could be as simple as

if (jvmArguments.startsWith("\"") && jvmArguments.endsWith("\"") && jvmArguments.length() >= 4) {
  jvmArguments = jvmArguments.substring(1, jvmArguments.length() - 2);
}

----------------------------------------------------------------------

>Comment By: SourceForge Robot (sf-robot)
Date: 2009-12-23 02:20

Message:
This Tracker item was closed automatically by the system. It was
previously set to a Pending status, and the original submitter
did not respond within 14 days (the time period specified by
the administrator of this Tracker).

----------------------------------------------------------------------

Comment By: Philip Aston (philipa)
Date: 2009-12-08 14:19

Message:
np.

Report back if it's still not working for you.

----------------------------------------------------------------------

Comment By: Chris Cooper (coopstah13)
Date: 2009-12-07 14:53

Message:
Hmm, actually my comment about using the \ isn't quite true, when I
manually execute it on the command line it works, but using something else
it doesn't. Most likely this is all on me now, sorry for the bother.

----------------------------------------------------------------------

Comment By: Chris Cooper (coopstah13)
Date: 2009-12-07 14:44

Message:
I retried the second one, and tried the first one. Neither of them worked.
The first one tried to use what was in the quotes as the classname
apparently, since it threw an error that it couldn't find the class
"-Dgrinder.jvm.arguments=-Dpython.home=/path/to/python/home
-Dpython.cachedir=/path/to/python/cachedir". The second one almost works,
but the first argument had a \ at the end of it, making it not work.

'-Dpython.home=/opt/svsagent/grinder/jython\'
'-Dpython.cachedir=/opt/svsagent/grinder/jython/cache'

----------------------------------------------------------------------

Comment By: Chris Cooper (coopstah13)
Date: 2009-12-05 20:16

Message:
I've tried the 2nd one there you recommended and it didn't work, at least I
didn't think so. I'll try it again monday along with the first one. The
only problem is I need it to work on windows too, but i don't really have a
problem putting conditionals in to manage that.

----------------------------------------------------------------------

Comment By: Philip Aston (philipa)
Date: 2009-12-05 15:37

Message:
s/your're/your/

----------------------------------------------------------------------

Comment By: Philip Aston (philipa)
Date: 2009-12-05 15:34

Message:
You're shell should be your friend here. Please try:

"-Dgrinder.jvm.arguments=-Dpython.home=/path/to/python/home
-Dpython.cachedir=/path/to/python/cachedir"

or even

-Dgrinder.jvm.arguments=-Dpython.home=/path/to/python/home\
-Dpython.cachedir=/path/to/python/cachedir

----------------------------------------------------------------------

Comment By: Chris Cooper (coopstah13)
Date: 2009-12-05 13:47

Message:
I need to set the python home/cachedir variables in the grinder process
jvm.
-Dgrinder.jvm.arguments="-Dpython.home=/path/to/python/home
-Dpython.cachedir=/path/to/python/cachedir" works with the code below on
linux.

----------------------------------------------------------------------

Comment By: Philip Aston (philipa)
Date: 2009-12-05 09:08

Message:
Can you provide an example please?

I want to be careful before rushing into an implementation here. There's a
world of quoting pain to get right due to interactions with the shell that
launches the process. This will also be platform specific.

----------------------------------------------------------------------

Comment By: Chris Cooper (coopstah13)
Date: 2009-12-04 19:02

Message:
forgot to pick category

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=368598&aid=2908989&group_id=18598

------------------------------------------------------------------------------
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.