dev@glassfish.java.net

asadmin vs java -jar

From: Bobby Bissett <Robert.Bissett_at_Sun.COM>
Date: Thu, 03 Sep 2009 15:24:36 -0400

This falls under the category of "things I don't know that I don't
know."

Given the asadmin pipe issue in another thread, I was going to have
upgrade tool do a Runtime.exec() of "java -jar glassfish.jar [etc]"
rather than "asadmin [etc]." Is there any downside to doing this? I'd
be switching this:

asadmin start-domain --upgrade [--user <b> [--passwordfile <c>]]
<domain>

to this:

java -jar modules/glassfish.jar -upgrade true <domain>

It may mean problems finding or specifying a Java to use since it's
not checking asenv.conf, but using the same Java that the asupgrade
tool is using should be fine for upgrade. What other headaches am I
causing myself if I go this route?

Also, are there versions of --user and --password file to use here? I
can't find them and it seems to accept anything I try.

Thanks,
Bobby