|
Replies:
6
-
Last Post:
Sep 24, 2008 7:41 AM
by: bryanut
|
|
|
|
|
|
|
Precompile JSP problems
Posted:
Sep 23, 2008 9:33 AM
|
|
|
I am having a couple of issues with using precompile JSPs.
The first is with asadmin. We have a non-clustered glassfish installation with about 5 seperate domains.
Using this command:
./asadmin deploy --precompilejsp=true --target myDomain myApp.ear
I get this error: CLI175 The target myDomain is invalid. Valid target types are cluster, domain, unclustered server instance, domain administration server.
The second is with the Admin Console. If I enable Precompile in the Auto Deploy Setting my EAR file never autodeploys.
BTW - If I manually deploy the EAR from Admin Console with precompile enabled the deployment is successful.
I really need the command line work, but will settle for the autodeploy. Thanks in advance for any help.
|
|
|
|
|
|
|
Re: Precompile JSP problems
Posted:
Sep 23, 2008 9:38 AM
in response to: bryanut
|
|
|
Sorry, the autodeploy is working.
|
|
|
|
|
|
|
|
Re: Precompile JSP problems
Posted:
Sep 23, 2008 12:19 PM
in response to: bryanut
|
|
|
Right. Please use "asadmin deploy" command without any specification of the target. The defaults do the right thing.
Sorry, it was not obvious. We thought you'll not use the --target option at all if all you have is a single server (domain).
Regards, Kedar
|
|
|
|
|
|
|
|
Re: Precompile JSP problems
Posted:
Sep 23, 2008 12:36 PM
in response to: km
|
|
|
But it doesn't do the right thing.
It gets deployed to domain1 and not myDomain.
We have 5 domains and I want to be able to selectively deploy ear files to each of the domains.
I run asadamin from /vend/SUNWappserver/bin as my current directory. Do I need to run it with my current directory set to: /vend/SUNWappserver/domains/myDomain?
Thanks,
Bryan
|
|
|
|
|
|
|
|
RE: Precompile JSP problems
Posted:
Sep 23, 2008 12:57 PM
in response to: bryanut
|
|
|
You are missing the options that specify what admin service to connect to. Each domain has its own admin port (default domain is 4848, if you created a domain with portbase 9000, it would be 9048 etc).
For example, here is a sample batch file on windows used to deploy an arbitrary component to a glassfish server:
REM Arguments: REM host = %1 REM port = %2 REM user = %3 REM password file = %4 REM component name = %5 REM component path = %6
"C:\Program Files\Sun\AppServer\bin\asadmin.bat" deploy --host %1 --port %2 --user %3 --passwordfile %4 --name %5 %6
Where host is the hostname of target domain, port is the admin port, user is the admin user and password file is the location of a file in the format:
AS_ADMIN_PASSWORD=theAdminPassword
Component name is the name it will be deployed with, and path is the physical location of the file that is to be deployed.
Check the usage of deploy for the full list of arguments: asadmin deploy --help
Keep in mind anytime you are using a multi-domain configuration, you pretty much always need to use the --host and --port options to specify the correct domain you are trying to do actions on.
Alex Sherwin alex.sherwin@acadiasoft.com
-----Original Message----- From: glassfish@javadesktop.org [mailto:glassfish@javadesktop.org] Sent: Tuesday, September 23, 2008 3:36 PM To: users@glassfish.dev.java.net Subject: Re: Precompile JSP problems
But it doesn't do the right thing.
It gets deployed to domain1 and not myDomain.
We have 5 domains and I want to be able to selectively deploy ear files to each of the domains.
I run asadamin from /vend/SUNWappserver/bin as my current directory. Do I need to run it with my current directory set to: /vend/SUNWappserver/domains/myDomain?
Thanks,
Bryan [Message sent by forum member 'bryanut' (bryanut)]
http://forums.java.net/jive/thread.jspa?messageID=301096
--------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@glassfish.dev.java.net For additional commands, e-mail: users-help@glassfish.dev.java.net
--------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@glassfish.dev.java.net For additional commands, e-mail: users-help@glassfish.dev.java.net
|
|
|
|
|
|
|
|
Re: Precompile JSP problems
Posted:
Sep 23, 2008 4:03 PM
in response to: bryanut
|
 |
Correct |
|
|
See Alex Sherwin's response.
Again, I am sorry that this is all not obvious. The most important point about asadmin is that it is a remotable admin client. You can have asadmin running on your laptop and all your domains on other (big) machines and still, you can manage all of them from your laptop. That brings in a fine point about asadmin that ~95% of its commands are "remote", working on a particular "domain" and work based on that domain's admin server's 5-tuple -- host name, admin port-number, admin user name, password and security status. The default values for 3 of them make it indistinguishable what asadmin really does. Since default values are "localhost", "4848" and false for host, port and security status respectively, it's not immediately clear that asadmin running on "localhost" would actually send an HTTP request to the domain that's listening on 4848 on "localhost".
Hope this makes it clear(er).
Regards, Kedar
|
|
|
|
|
|
|
|
Re: Precompile JSP problems
Posted:
Sep 24, 2008 7:41 AM
in response to: km
|
|
|
Thanks for the help!
For some reason I go hung up on the --target option. I guess because I had been working on clusters just a few weeks ago.
|
|
|
|
|