public class RuntimeParamUtil extends Object
Modifier and Type | Field and Description |
---|---|
protected static String |
BASE_DIR_FLAG
Pipeline parent directory file-path runtime parameter switch: "b"
|
protected static String |
CONFIG_DIR_FLAG
Config file directory path runtime parameter switch: "C" |
protected static String |
CONFIG_FLAG
Config file path runtime parameter switch: "c" |
protected static String |
DIRECT_FLAG
Direct mode runtime parameter switch: "d"
|
protected static String |
DOCKER_FLAG
Docker mode runtime parameter switch: "-docker"
|
protected static String |
HOST_BLJ
Host BioLockJ deployment to run - used to override installed $BLJ in Docker containers with BioLockJ installed:
"-blj"
|
protected static String |
HOST_BLJ_SUP
Host BioLockJ deployment to run - used to map $BLJ_SUP volume in Docker containers with BioLockJ installed:
"-bljSup"
|
protected static String |
HOST_HOME_USER_DIR
Host $USER $HOME param: "u"
|
protected static String |
INPUT_DIR_FLAG
Input directory file-path runtime parameter switch: "i"
|
protected static String |
META_DIR_FLAG
Metadata file directory path runtime parameter switch: "m"
|
protected static String |
PASSWORD_FLAG
Change password runtime parameter switch: "p"
|
protected static String |
RESTART_FLAG
Restart pipeline runtime parameter switch: "r"
|
Constructor and Description |
---|
RuntimeParamUtil() |
Modifier and Type | Method and Description |
---|---|
static boolean |
doChangePassword()
Return TRUE if runtime parameters indicate change password request
|
static boolean |
doRestart()
Return TRUE if runtime parameters indicate attempt to restart pipeline
|
static String |
getAdminEmailPassword()
Runtime property getter for "p"
|
static File |
getBaseDir()
Runtime property getter for "b"
|
static String |
getBaseDirParam()
Get the baseDir param and value
|
static File |
getConfigFile()
Runtime property getter for "c"
|
static String |
getConfigFileParam()
Used to build Docker run commands.
|
static String |
getDirectModuleDir()
Runtime property getter for "d"
|
static String |
getDirectModuleParam(BioModule module)
Direct module parameters contain 2 parts separated by a colon: (pipeline directory name):(module name)
|
static File |
getDirectPipelineDir()
Runtime property getter for direct module pipeline directory
|
static File |
getDockerHostBLJ_SUP()
Runtime property getter for Docker host blj_support dir
|
static File |
getDockerHostBLJ()
Runtime property getter for Docker host BioLockJ dir
|
static String |
getDockerHostConfigDir()
Runtime property getter for "C"
|
static File |
getDockerHostHomeUserDir()
Runtime property getter for Docker host $USER $HOME dir
|
static String |
getDockerHostInputDir()
Runtime property getter for "i"
|
static String |
getDockerHostMetaDir()
Runtime property getter for "m"
|
static String |
getDockerHostPipelineDir()
Runtime property getter for Docker host pipeline dir
|
static String |
getDockerJavaModuleParams()
Get Docker runtime arguments passed to BioLockJ from dockblj script.
These are used to to populate BLJ_OPTIONS in Docker java_module scripts. |
static String |
getProjectName()
Extract the project name from the Config file.
|
static File |
getRestartDir()
Return restart pipeline directory
|
static boolean |
isDockerMode()
Return TRUE if runtime parameter "-docker" was found
|
static void |
printRuntimeArgs(String[] args,
boolean useSysOut)
Print the runtime args to System.out or using the Logger based on useSysOut parameter.
|
static void |
registerRuntimeParameters(String[] args)
Register and verify the runtime parameters.
|
protected static final String BASE_DIR_FLAG
protected static final String CONFIG_DIR_FLAG
Config
file directory path runtime parameter switch: "C"protected static final String CONFIG_FLAG
Config
file path runtime parameter switch: "c"protected static final String DIRECT_FLAG
protected static final String DOCKER_FLAG
protected static final String HOST_BLJ
protected static final String HOST_BLJ_SUP
protected static final String HOST_HOME_USER_DIR
protected static final String INPUT_DIR_FLAG
protected static final String META_DIR_FLAG
protected static final String PASSWORD_FLAG
protected static final String RESTART_FLAG
public static boolean doChangePassword()
public static boolean doRestart()
public static String getAdminEmailPassword()
public static File getBaseDir()
public static String getBaseDirParam()
public static File getConfigFile()
Config
filepublic static String getConfigFileParam()
Config
file param and value.public static String getDirectModuleDir()
public static String getDirectModuleParam(BioModule module)
module
- BioModulepublic static File getDirectPipelineDir()
public static File getDockerHostBLJ()
public static File getDockerHostBLJ_SUP()
public static String getDockerHostConfigDir()
public static File getDockerHostHomeUserDir()
public static String getDockerHostInputDir()
public static String getDockerHostMetaDir()
public static String getDockerHostPipelineDir()
public static String getDockerJavaModuleParams()
public static String getProjectName()
public static File getRestartDir()
public static boolean isDockerMode()
public static void printRuntimeArgs(String[] args, boolean useSysOut)
args
- Runtime ArgsuseSysOut
- Set TRUE if should use System.out to printpublic static void registerRuntimeParameters(String[] args) throws Exception
Config
file path
args
- Program runtime parametersException
- if invalid parameters detected