| Modifier and Type | Method and Description |
|---|---|
protected boolean |
CLICommand.checkHelp()
Check if the current request is a help request, either because
--help was specified as a program option or a command option.
|
int |
CLICommand.execute(String... argv)
Execute this command with the given arguemnts.
|
int |
CLICommand.execute(org.jline.terminal.Terminal terminal,
String... argv) |
int |
UnsetCommand.executeCommand() |
int |
ListCommandsCommand.executeCommand() |
int |
ExportCommand.executeCommand() |
protected int |
MultimodeCommand.executeCommand() |
protected int |
VersionCommand.executeCommand() |
protected int |
HelpCommand.executeCommand() |
protected int |
LoginCommand.executeCommand() |
protected abstract int |
CLICommand.executeCommand()
Execute the command using the options in options and the
operands in operands.
|
static CLICommand |
CLICommand.getCommand(CLIContainer cLIContainer,
String name) |
static CLICommand |
CLICommand.getCommand(org.glassfish.hk2.api.ServiceLocator serviceLocator,
String name)
Get a CLICommand object representing the named command.
|
static String[] |
CLIUtil.getRemoteCommands(CLIContainer container,
ProgramOptions po,
Environment env)
Get the list of commands from the remote server.
|
protected void |
CLICommand.initializePasswords()
Initialise the passwords field based on the password
file specified in the program options, and initialise the
program option's password if available in the password file.
|
protected void |
CLICommand.inject()
Inject this instance with the final values of all the command
parameters.
|
protected void |
CLICommand.parse()
The parse method sets the options and operands fields
based on the content of the command line arguments.
|
protected void |
CLICommand.prepare()
The prepare method must ensure that the commandModel field is set.
|
protected void |
CLICommand.prevalidate()
The prevalidate method supplies missing options from
the environment.
|
protected void |
CLICommand.processProgramOptions()
If the program options haven't already been set, parse them
on the command line and remove them from the command line.
|
static Map<String,String> |
CLIUtil.readPasswordFileOptions(String passwordFileName,
boolean withPrefix)
Read passwords from the password file and save them in a java.util.Map.
|
void |
ProgramOptions.updateOptions(ParameterMap newOptions)
Update the program options based on the specified
options from the command line.
|
protected void |
ListCommandsCommand.validate() |
protected void |
MultimodeCommand.validate()
The validate method validates that the type and quantity of parameters
and operands matches the requirements for this command.
|
protected void |
CLICommand.validate()
The validate method can be used by a subclass to validate
that the type and quantity of parameters and operands matches
the requirements for this command.
|
| Constructor and Description |
|---|
ProgramOptions(Environment env)
Initialize program options based only on environment defaults,
with no options from the command line.
|
ProgramOptions(ParameterMap options,
Environment env)
Initialize the programoptions based on parameters parsed
from the command line, with defaults supplied by the
environment.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
CreateLocalInstanceCommand.createMasterPasswordFile(String masterPassword)
Create the master password keystore.
|
protected int |
StopLocalInstanceCommand.doRemoteCommand()
Execute the actual stop-domain command.
|
protected int |
RestartLocalInstanceCommand.doRemoteCommand() |
int |
ChangeNodeMasterPasswordCommand.execute(String... argv) |
protected int |
StopLocalInstanceCommand.executeCommand() |
protected int |
DeleteInstanceFilesystem.executeCommand() |
protected int |
ImportSyncBundleCommand.executeCommand() |
protected int |
StartLocalInstanceCommand.executeCommand() |
protected int |
DeleteLocalInstanceCommand.executeCommand() |
protected int |
CreateLocalInstanceCommand.executeCommand() |
protected int |
SetupSshKey.executeCommand() |
protected int |
SynchronizeInstanceCommand.executeCommand() |
protected int |
SetupLocalDcom.executeCommand() |
protected int |
RestartLocalInstanceCommand.executeCommand() |
protected int |
ValidateDasOptions.executeCommand() |
protected int |
CreateLocalInstanceFilesystemCommand.executeCommand() |
protected int |
ChangeNodeMasterPasswordCommand.executeCommand() |
protected String |
ChangeNodeMasterPasswordCommand.findOldPassword()
Find the old password from the property in the password file with the name
ChangeNodeMasterPasswordCommand.OLD_PASSWORD_ALIAS if it exists, or by prompting the user otherwise. |
protected Properties |
LocalInstanceCommand.getDasProperties(File propfile) |
protected String |
LocalInstanceCommand.getInstallRootPath()
Gets the GlassFish installation root (using property com.sun.aas.installRoot),
first from asenv.conf.
|
protected String |
LocalInstanceCommand.getNodeInstallDir() |
protected Properties |
LocalInstanceCommand.getNodeProperties(File propertyFile) |
protected String |
LocalInstanceCommand.getProductRootPath()
Gets the GlassFish product installation root (using property
com.sun.aas.productRoot), first from asenv.conf.
|
protected void |
StopLocalInstanceCommand.initInstance()
Big trouble if you allow the super implementation to run
because it creates directories.
|
protected void |
DeleteLocalInstanceCommand.initInstance()
initInstance goes to great lengths to figure out the correct directory structure.
|
protected void |
LocalInstanceCommand.initInstance() |
protected void |
ChangeNodeMasterPasswordCommand.inject() |
protected int |
StopLocalInstanceCommand.instanceNotRunning()
Print message and return exit code when
we detect that the DAS is not running.
|
protected int |
RestartLocalInstanceCommand.instanceNotRunning() |
protected void |
LocalInstanceCommand.setDasDefaults(File propfile)
Set the programOpts based on the das.properties file.
|
protected void |
ChangeNodeMasterPasswordCommand.setNewPassword()
Set the
ChangeNodeMasterPasswordCommand.newPassword field from the property in the password file
with the name ChangeNodeMasterPasswordCommand.OLD_PASSWORD_ALIAS if it exists, or by prompting the
user twice otherwise. |
protected boolean |
SynchronizeInstanceCommand.synchronizeInstance()
Synchronize this server instance.
|
protected void |
StopLocalInstanceCommand.validate() |
protected void |
DeleteInstanceFilesystem.validate() |
protected void |
ImportSyncBundleCommand.validate() |
protected void |
StartLocalInstanceCommand.validate() |
protected void |
DeleteLocalInstanceCommand.validate() |
protected void |
CreateLocalInstanceCommand.validate() |
protected void |
UninstallNodeSshCommand.validate() |
protected void |
SetupSshKey.validate() |
protected void |
SynchronizeInstanceCommand.validate() |
protected void |
SetupLocalDcom.validate() |
protected void |
UninstallNodeDcomCommand.validate()
DCOM won't work right on localhost.
|
protected void |
LocalInstanceCommand.validate() |
protected void |
RestartLocalInstanceCommand.validate() |
protected void |
ValidateDasOptions.validate() |
protected void |
CreateLocalInstanceFilesystemCommand.validate() |
protected void |
ChangeNodeMasterPasswordCommand.validate() |
protected void |
InstallNodeDcomCommand.validate()
DCOM won't work right on localhost.
|
protected void |
InstallNodeSshCommand.validate() |
protected void |
LocalInstanceCommand.validateDasOptions(String hostOption,
String portOption,
String isSecureOption,
File propfile)
Checks if programOpts values match das.properties file.
|
protected void |
LocalInstanceCommand.whackFilesystem() |
| Modifier and Type | Method and Description |
|---|---|
void |
DerbyManager.buildDatabaseClasspath(File dbLocation,
ClassPathBuilder sDatabaseClasspath) |
void |
H2Manager.buildDatabaseClasspath(File dbLocation,
ClassPathBuilder sDatabaseClasspath) |
void |
DerbyManager.checkIfDbInstalled(File dbLocation)
Check if database is installed.
|
void |
H2Manager.checkIfDbInstalled(File dbLocation)
Check if database is installed.
|
protected void |
BackupCommands.checkOptions()
A method that checks the options and operand that the user supplied.
|
protected int |
StopDatabaseCommand.executeCommand()
Executes the command
|
protected int |
ListBackupsCommand.executeCommand() |
protected int |
RestoreDomainCommand.executeCommand() |
protected int |
BackupDomainCommand.executeCommand() |
protected int |
StartDatabaseCommand.executeCommand()
Execute the command
|
protected void |
ListBackupsCommand.validate() |
protected void |
RestoreDomainCommand.validate() |
protected void |
BackupDomainCommand.validate() |
| Modifier and Type | Class and Description |
|---|---|
class |
ReExecuted
This is a trick for
RemoteRestCommand where command lifecycle must be
restarted. |
| Modifier and Type | Method and Description |
|---|---|
protected boolean |
RemoteCommand.checkHelp()
We do all our help processing in executeCommand.
|
int |
RemoteCLICommand.execute(String... argv) |
int |
RemoteCommand.execute(String... argv) |
ActionReport |
RemoteCLICommand.executeAndReturnActionReport(String... args)
Execute the command and return the main attributes from the manifest
instead of writing out the output.
|
Map<String,String> |
RemoteCommand.executeAndReturnAttributes(String... args)
Execute the command and return the main attributes from the manifest
instead of writing out the output.
|
String |
RemoteCLICommand.executeAndReturnOutput(String... args)
Execute the command and return the output as a string instead of writing
it out.
|
String |
RemoteCommand.executeAndReturnOutput(String... args)
Execute the command and return the output as a string
instead of writing it out.
|
protected int |
RemoteCLICommand.executeCommand() |
protected int |
RemoteCommand.executeCommand() |
protected void |
RemoteCLICommand.inject() |
protected void |
RemoteCommand.inject() |
protected void |
RemoteCLICommand.parse() |
static DASUtils.Error |
DASUtils.pingDASWithAuth(ProgramOptions programOpts,
Environment env)
See if DAS is alive, but insist that athentication is correct.
|
protected void |
RemoteCLICommand.prepare() |
protected void |
RemoteCommand.prepare() |
protected void |
RemoteCLICommand.prevalidate() |
protected void |
RemoteCommand.prevalidate() |
protected void |
RemoteCLICommand.validate() |
protected void |
RemoteCommand.validate() |
| Constructor and Description |
|---|
RemoteCLICommand()
Construct a new remote command object.
|
RemoteCLICommand(String name,
ProgramOptions po,
Environment env)
Construct a new remote command object.
|
RemoteCLICommand(String name,
ProgramOptions po,
Environment env,
String responseFormatType,
OutputStream userOut)
Construct a new remote command object.
|
RemoteCommand()
Construct a new remote command object.
|
RemoteCommand(String name,
ProgramOptions po,
Environment env)
Construct a new remote command object.
|
RemoteCommand(String name,
ProgramOptions po,
Environment env,
String responseFormatType,
OutputStream userOut)
Construct a new remote command object.
|
| Modifier and Type | Method and Description |
|---|---|
String |
RemoteRestAdminCommand.executeCommand(ParameterMap opts)
Run the command using the specified arguments.
|
String |
RemoteAdminCommand.executeCommand(ParameterMap opts)
Run the command using the specified arguments.
|
protected void |
RemoteRestAdminCommand.fetchCommandModel()
Fetch the command metadata from the remote server.
|
protected void |
RemoteAdminCommand.fetchCommandModel()
Fetch the command metadata from the remote server.
|
CommandModel |
RemoteRestAdminCommand.getCommandModel()
Get the CommandModel for the command from the server.
|
CommandModel |
RemoteAdminCommand.getCommandModel()
Get the CommandModel for the command from the server.
|
String |
RemoteRestAdminCommand.getManPage() |
protected boolean |
RemoteRestAdminCommand.useSse() |
| Constructor and Description |
|---|
RemoteAdminCommand(String name,
String host,
int port) |
RemoteAdminCommand(String name,
String host,
int port,
boolean secure,
String user,
char[] password,
Logger logger) |
RemoteAdminCommand(String name,
String host,
int port,
boolean secure,
String user,
char[] password,
Logger logger,
String scope,
String authToken,
boolean prohibitDirectoryUploads)
Construct a new remote command object.
|
RemoteRestAdminCommand(String name,
String host,
int port) |
RemoteRestAdminCommand(String name,
String host,
int port,
boolean secure,
String user,
char[] password,
Logger logger,
boolean notify) |
RemoteRestAdminCommand(String name,
String host,
int port,
boolean secure,
String user,
char[] password,
Logger logger,
String scope,
String authToken,
boolean prohibitDirectoryUploads,
boolean notify)
Construct a new remote command object.
|
ServerRemoteAdminCommand(org.glassfish.hk2.api.ServiceLocator habitat,
String name,
String host,
int port,
boolean secure,
String user,
String password,
Logger logger) |
ServerRemoteRestAdminCommand(org.glassfish.hk2.api.ServiceLocator habitat,
String name,
String host,
int port,
boolean secure,
String user,
String password,
Logger logger) |
| Modifier and Type | Method and Description |
|---|---|
protected int |
StopDomainCommand.dasNotRunning()
Print message and return exit code when we detect that the DAS is not running.
|
protected int |
RestartDomainCommand.dasNotRunning()
If the server isn't running, try to start it.
|
protected void |
StopDomainCommand.doCommand()
Execute the actual stop-domain command.
|
protected void |
RestartDomainCommand.doCommand()
Execute the restart-domain command.
|
int |
ChangeMasterPasswordCommand.execute(String... args) |
protected int |
ListDomainsCommand.executeCommand() |
protected int |
DeleteServiceCommand.executeCommand() |
protected int |
StartDomainCommand.executeCommand() |
protected int |
ChangeAdminPasswordCommand.executeCommand()
Execute the remote command using the parameters we've collected.
|
protected int |
DeleteDomainCommand.executeCommand() |
protected int |
ChangeMasterPasswordCommandDAS.executeCommand() |
protected int |
ChangeMasterPasswordCommand.executeCommand() |
protected int |
StopDomainCommand.executeCommand() |
protected int |
VerifyDomainXmlCommand.executeCommand() |
protected int |
MonitorCommand.executeCommand() |
protected int |
CreateDomainCommand.executeCommand() |
protected int |
CreateServiceCommand.executeCommand() |
protected HostAndPort |
LocalServerCommand.getAdminAddress()
Returns the admin address of the local domain.
|
protected HostAndPort |
LocalServerCommand.getAdminAddress(String serverName)
Returns the admin address of a particular server.
|
protected Map<String,Boolean> |
ListDomainsCommand.getDomains()
Get a list of domains and their status
|
protected String |
LocalServerCommand.getMasterPassword()
Get the master password, either from a password file or
by asking the user.
|
protected long |
LocalServerCommand.getUptime()
Get uptime from the server.
|
protected void |
LocalDomainCommand.initDomain() |
protected void |
StopDomainCommand.initDomain()
Override initDomain in LocalDomainCommand to only initialize the local domain information (name, directory) in
the local case, when no --host has been specified.
|
protected boolean |
LocalServerCommand.isRestartable()
See if the server is restartable
As of March 2011 -- this only returns false if a passwordfile argument was given
when the server started -- but it is no longer available - i.e.the user
deleted it or made it unreadable.
|
protected int |
StopDomainCommand.kill() |
protected void |
LocalDomainCommand.prepare() |
boolean |
StartServerHelper.prepareForLaunch()
Run a series of commands to prepare for a launch.
|
protected void |
ListDomainsCommand.validate() |
protected void |
DeleteServiceCommand.validate() |
protected void |
StartDomainCommand.validate() |
protected void |
ChangeAdminPasswordCommand.validate()
Require the user to actually type the passwords unless they are in the file specified by the --passwordfile option.
|
protected void |
DeleteDomainCommand.validate() |
protected void |
LocalDomainCommand.validate() |
protected void |
ChangeMasterPasswordCommandDAS.validate() |
protected void |
StopDomainCommand.validate() |
protected void |
VerifyDomainXmlCommand.validate() |
protected void |
CreateDomainCommand.validate() |
protected void |
CreateServiceCommand.validate() |
protected void |
StopDomainCommand.waitForDeath()
Wait for the server to die.
|
protected void |
LocalServerCommand.waitForRestart(int oldServerPid)
Byron Nevins Says: We have quite a historical assortment of ways to
determine if a server has restarted.
|
void |
StartServerHelper.waitForServer() |
void |
StartServerHelper.waitForServer(long timeout,
TimeUnit unit) |
| Constructor and Description |
|---|
MonitorTask(Timer timer,
String[] remoteArgs,
ProgramOptions programOpts,
Environment env,
String type,
String filter,
File fileName) |
| Modifier and Type | Method and Description |
|---|---|
static ServerDirsSelector |
ServerDirsSelector.getInstance(File domainDirParent,
String serverName,
String nodeDir,
String node)
Creates a selector for choosing the correct set of directories.
|
| Constructor and Description |
|---|
InstanceCommandExecutor(org.glassfish.hk2.api.ServiceLocator habitat,
String name,
FailurePolicy fail,
FailurePolicy offline,
Server server,
String host,
int port,
Logger logger,
ParameterMap p,
ActionReport r,
InstanceCommandResult res) |
InstanceRestCommandExecutor(org.glassfish.hk2.api.ServiceLocator habitat,
String name,
FailurePolicy fail,
FailurePolicy offline,
Server server,
String host,
int port,
Logger logger,
ParameterMap p,
ActionReport r,
InstanceCommandResult res) |
| Modifier and Type | Method and Description |
|---|---|
ActionReport |
ClusterCommandHelper.runCommand(String command,
ParameterMap map,
String targetName,
AdminCommandContext context,
boolean verbose)
Loop through all instances in a cluster and execute a command for each one.
|
ActionReport |
ClusterCommandHelper.runCommand(String command,
ParameterMap map,
String targetName,
AdminCommandContext context,
boolean verbose,
boolean rolling)
Loop through all instances in a cluster and execute a command for each one.
|
| Modifier and Type | Method and Description |
|---|---|
protected int |
StopAllDomainsCommand.dasNotRunning() |
protected int |
StopDomainsCommand.dasNotRunning() |
protected int |
StopAllDomainsCommand.executeCommand() |
protected int |
StopDomainsCommand.executeCommand() |
protected int |
AddKeypairCommand.executeCommand() |
protected int |
StartDomainsCommand.executeCommand() |
protected int |
PrintCertificateCommand.executeCommand() |
protected int |
RestartDomainsCommand.executeCommand() |
protected void |
StopAllDomainsCommand.prevalidate() |
protected void |
StopAllDomainsCommand.validate() |
protected void |
StopDomainsCommand.validate() |
protected void |
AddKeypairCommand.validate() |
protected void |
StartDomainsCommand.validate() |
protected void |
PrintCertificateCommand.validate() |
protected void |
RestartDomainsCommand.validate() |
| Modifier and Type | Class and Description |
|---|---|
class |
AuthenticationException
A specialized CommandException that indicates an authentication failure.
|
class |
CommandValidationException |
class |
InvalidCommandException |
class |
SSHCommandExecutionException
Created by IntelliJ IDEA.
|
| Modifier and Type | Method and Description |
|---|---|
static boolean |
SSHUtil.isEncryptedKey(String keyFile)
Simple method to validate an encrypted key file
|
static boolean |
SSHUtil.validateKeyFile(String file)
This method validates either private or public key file.
|
| Modifier and Type | Method and Description |
|---|---|
protected abstract AbstractDeploymentFacility.DFCommandRunner |
AbstractDeploymentFacility.getDFCommandRunner(String commandName,
Map<String,Object> commandOptions,
String[] operands)
Returns a command runner for the concrete implementation.
|
protected AbstractDeploymentFacility.DFCommandRunner |
RemoteDeploymentFacility.getDFCommandRunner(String commandName,
Map<String,Object> commandOptions,
String[] operands) |
protected ProgramOptions |
RemoteDeploymentFacility.prepareRemoteCommandProgramOptions(Environment env) |
DFDeploymentStatus |
AbstractDeploymentFacility.DFCommandRunner.run()
Runs the command.
|
| Modifier and Type | Method and Description |
|---|---|
protected int |
LocalOSGiShellCommand.executeCommand() |
protected String |
LocalOSGiShellCommand.startSession() |
protected int |
LocalOSGiShellCommand.stopSession(String sessionId) |
protected void |
LocalOSGiShellCommand.validate()
The validate method validates that the type and quantity of
parameters and operands matches the requirements for this
command.
|
Copyright © 2019. All rights reserved.