| | |
| | | // been abandoned. |
| | | private boolean notifyAbandonedOperations; |
| | | |
| | | // Indicates whether to save a copy of the configuration on successful |
| | | // startup. |
| | | private boolean saveConfigOnSuccessfulStartup; |
| | | |
| | | // Indicates whether the server is currently in the process of shutting down. |
| | | private boolean shuttingDown; |
| | | |
| | |
| | | } |
| | | |
| | | |
| | | // If we should write a copy of the config on successful startup, then do |
| | | // so now. |
| | | if (saveConfigOnSuccessfulStartup) |
| | | { |
| | | configHandler.writeSuccessfulStartupConfig(); |
| | | } |
| | | |
| | | |
| | | // Mark the current time as the start time and indicate that the server is |
| | | // now running. |
| | | startUpTime = System.currentTimeMillis(); |
| | |
| | | |
| | | |
| | | /** |
| | | * Indicates whether the Directory Server should save a copy of its |
| | | * configuration whenever it is started successfully. |
| | | * |
| | | * @return {@code true} if the server should save a copy of its configuration |
| | | * whenever it is started successfully, or {@code false} if not. |
| | | */ |
| | | public static boolean saveConfigOnSuccessfulStartup() |
| | | { |
| | | return directoryServer.saveConfigOnSuccessfulStartup; |
| | | } |
| | | |
| | | |
| | | |
| | | /** |
| | | * Specifies whether the Directory Server should save a copy of its |
| | | * configuration whenever it is started successfully. |
| | | * |
| | | * @param saveConfigOnSuccessfulStartup Specifies whether the server should |
| | | * save a copy of its configuration |
| | | * whenever it is started successfully. |
| | | */ |
| | | public static void setSaveConfigOnSuccessfulStartup( |
| | | boolean saveConfigOnSuccessfulStartup) |
| | | { |
| | | directoryServer.saveConfigOnSuccessfulStartup = |
| | | saveConfigOnSuccessfulStartup; |
| | | } |
| | | |
| | | |
| | | |
| | | /** |
| | | * Registers the provided backup task listener with the Directory Server. |
| | | * |
| | | * @param listener The backup task listener to register with the Directory |
| | |
| | | public static void main(String[] args) |
| | | { |
| | | // Define the arguments that may be provided to the server. |
| | | BooleanArgument checkStartability = null; |
| | | BooleanArgument quietMode = null; |
| | | BooleanArgument windowsNetStart = null; |
| | | BooleanArgument displayUsage = null; |
| | | BooleanArgument fullVersion = null; |
| | | BooleanArgument noDetach = null; |
| | | BooleanArgument systemInfo = null; |
| | | StringArgument configClass = null; |
| | | StringArgument configFile = null; |
| | | BooleanArgument checkStartability = null; |
| | | BooleanArgument quietMode = null; |
| | | BooleanArgument windowsNetStart = null; |
| | | BooleanArgument displayUsage = null; |
| | | BooleanArgument fullVersion = null; |
| | | BooleanArgument noDetach = null; |
| | | BooleanArgument systemInfo = null; |
| | | BooleanArgument useLastKnownGoodConfig = null; |
| | | StringArgument configClass = null; |
| | | StringArgument configFile = null; |
| | | |
| | | |
| | | // Create the command-line argument parser for use with this program. |
| | |
| | | argParser.addArgument(systemInfo); |
| | | |
| | | |
| | | useLastKnownGoodConfig = |
| | | new BooleanArgument("lastknowngoodconfig", 'L', |
| | | "useLastKnownGoodConfig", |
| | | INFO_DSCORE_DESCRIPTION_LASTKNOWNGOODCFG.get()); |
| | | argParser.addArgument(useLastKnownGoodConfig); |
| | | |
| | | |
| | | noDetach = new BooleanArgument("nodetach", 'N', "nodetach", |
| | | INFO_DSCORE_DESCRIPTION_NODETACH.get()); |
| | | argParser.addArgument(noDetach); |
| | |
| | | configClass.getValue()); |
| | | environmentConfig.setProperty(PROPERTY_CONFIG_FILE, |
| | | configFile.getValue()); |
| | | environmentConfig.setProperty(PROPERTY_USE_LAST_KNOWN_GOOD_CONFIG, |
| | | String.valueOf(useLastKnownGoodConfig.isPresent())); |
| | | |
| | | |
| | | startupErrorLogPublisher = |