| | |
| | | |
| | | try |
| | | { |
| | | context.notifyProgress(pnc.changeProgress(20)); |
| | | context.notifyProgress(pnc.setProgress(20)); |
| | | |
| | | copy(schemaFileTemplate, configSchemaDirectory, true); |
| | | context.notifyProgress(pnc.changeProgress(100)); |
| | | context.notifyProgress(pnc.setProgress(100)); |
| | | } |
| | | catch (final IOException e) |
| | | { |
| | |
| | | |
| | | try |
| | | { |
| | | context.notifyProgress(pnc.changeProgress(20)); |
| | | context.notifyProgress(pnc.setProgress(20)); |
| | | |
| | | copy(configFile, configDirectory, true); |
| | | context.notifyProgress(pnc.changeProgress(100)); |
| | | context.notifyProgress(pnc.setProgress(100)); |
| | | } |
| | | catch (final IOException e) |
| | | { |
| | |
| | | |
| | | displayChangeCount(pathDestination.getPath(), changeCount); |
| | | |
| | | context.notifyProgress(pnc.changeProgress(100)); |
| | | context.notifyProgress(pnc.setProgress(100)); |
| | | } |
| | | catch (final IOException e) |
| | | { |
| | |
| | | |
| | | final File pathDestination = new File(configSchemaDirectory, fileName); |
| | | |
| | | context.notifyProgress(pnc.changeProgress(20)); |
| | | context.notifyProgress(pnc.setProgress(20)); |
| | | |
| | | try |
| | | { |
| | |
| | | |
| | | displayChangeCount(pathDestination.getPath(), changeCount); |
| | | |
| | | context.notifyProgress(pnc.changeProgress(100)); |
| | | context.notifyProgress(pnc.setProgress(100)); |
| | | } |
| | | catch (final IOException e) |
| | | { |
| | |
| | | updateConfigUpgradeSchemaFile(configSchemaDirectory, String |
| | | .valueOf(context.getToVersion().getRevisionNumber())); |
| | | |
| | | context.notifyProgress(pnc.changeProgress(100)); |
| | | context.notifyProgress(pnc.setProgress(100)); |
| | | } |
| | | catch (final Exception ex) |
| | | { |
| | |
| | | + File.separator + "opends-snmp.security"); |
| | | if (oldSnmpConfig.exists()) |
| | | { |
| | | context.notifyProgress(pnc.changeProgress(20)); |
| | | context.notifyProgress(pnc.setProgress(20)); |
| | | LOG.log(Level.INFO, summary.toString()); |
| | | |
| | | final File snmpConfig = |
| | |
| | | |
| | | FileManager.rename(oldSnmpConfig, snmpConfig); |
| | | |
| | | context.notifyProgress(pnc.changeProgress(100)); |
| | | context.notifyProgress(pnc.setProgress(100)); |
| | | } |
| | | } |
| | | catch (final Exception ex) |
| | |
| | | |
| | | displayChangeCount(configFile.getPath(), changeCount); |
| | | |
| | | context.notifyProgress(pnc.changeProgress(100)); |
| | | context.notifyProgress(pnc.setProgress(100)); |
| | | } |
| | | catch (final Exception e) |
| | | { |
| | |
| | | throws ClientException |
| | | { |
| | | countErrors++; |
| | | context.notifyProgress(pnc.changeProgress(-100)); |
| | | context.notifyProgress(pnc.setProgress(-100)); |
| | | LOG.log(Level.SEVERE, message.toString()); |
| | | if (!context.isIgnoreErrorsMode()) |
| | | { |
| | |
| | | |
| | | displayChangeCount(configFile.getPath(), changeCount); |
| | | |
| | | context.notifyProgress(pnc.changeProgress(100)); |
| | | context.notifyProgress(pnc.setProgress(100)); |
| | | } |
| | | catch (final Exception e) |
| | | { |