Revision 5030
Added by daigle about 15 years ago
PropertiesAdmin.java | ||
---|---|---|
37 | 37 |
|
38 | 38 |
import edu.ucsb.nceas.metacat.MetacatVersion; |
39 | 39 |
import edu.ucsb.nceas.metacat.database.DBVersion; |
40 |
import edu.ucsb.nceas.metacat.service.PropertyService;
|
|
40 |
import edu.ucsb.nceas.metacat.properties.PropertyService;
|
|
41 | 41 |
import edu.ucsb.nceas.metacat.service.ServiceService; |
42 | 42 |
import edu.ucsb.nceas.metacat.shared.ServiceException; |
43 | 43 |
import edu.ucsb.nceas.metacat.util.RequestUtil; |
... | ... | |
160 | 160 |
"/admin/properties-configuration.jsp", null); |
161 | 161 |
|
162 | 162 |
} catch (GeneralPropertyException gpe) { |
163 |
throw new AdminException("Problem getting or setting property while "
|
|
164 |
+ "initializing system properties page: " + gpe.getMessage());
|
|
163 |
throw new AdminException("PropertiesAdmin.configureProperties - Problem getting or " +
|
|
164 |
"setting property while initializing system properties page: " + gpe.getMessage());
|
|
165 | 165 |
} catch (IOException ioe) { |
166 |
throw new AdminException("IO problem while initializing " |
|
166 |
throw new AdminException("PropertiesAdmin.configureProperties - IO problem while initializing "
|
|
167 | 167 |
+ "system properties page:" + ioe.getMessage()); |
168 | 168 |
} catch (ServiceException se) { |
169 |
throw new AdminException("Service problem while initializing " |
|
169 |
throw new AdminException("PropertiesAdmin.configureProperties - Service problem while initializing "
|
|
170 | 170 |
+ "system properties page:" + se.getMessage()); |
171 | 171 |
} catch (ServletException se) { |
172 |
throw new AdminException("problem forwarding request while " |
|
172 |
throw new AdminException("PropertiesAdmin.configureProperties - problem forwarding request while "
|
|
173 | 173 |
+ "initializing system properties page: " + se.getMessage()); |
174 | 174 |
} |
175 | 175 |
} else { |
... | ... | |
205 | 205 |
try { |
206 | 206 |
FileUtil.createDirectory(dataDir); |
207 | 207 |
} catch (UtilException ue) { |
208 |
String errorString = "Could not create directory: " + dataDir + |
|
208 |
String errorString = "PropertiesAdmin.configureProperties - Could not create directory: " + dataDir +
|
|
209 | 209 |
" : " + ue.getMessage(); |
210 | 210 |
logMetacat.error(errorString); |
211 | 211 |
validationErrors.add(errorString); |
... | ... | |
216 | 216 |
try { |
217 | 217 |
FileUtil.createDirectory(inlineDataDir); |
218 | 218 |
} catch (UtilException ue) { |
219 |
String errorString = "Could not create directory: " + inlineDataDir + |
|
219 |
String errorString = "PropertiesAdmin.configureProperties - Could not create directory: " + inlineDataDir +
|
|
220 | 220 |
" : " + ue.getMessage(); |
221 | 221 |
logMetacat.error(errorString); |
222 | 222 |
validationErrors.add(errorString); |
... | ... | |
227 | 227 |
try { |
228 | 228 |
FileUtil.createDirectory(documentfilepath); |
229 | 229 |
} catch (UtilException ue) { |
230 |
String errorString = "Could not create directory: " + documentfilepath + |
|
230 |
String errorString = "PropertiesAdmin.configureProperties - Could not create directory: " + documentfilepath +
|
|
231 | 231 |
" : " + ue.getMessage(); |
232 | 232 |
logMetacat.error(errorString); |
233 | 233 |
validationErrors.add(errorString); |
... | ... | |
238 | 238 |
try { |
239 | 239 |
FileUtil.createDirectory(tempDir); |
240 | 240 |
} catch (UtilException ue) { |
241 |
String errorString = "Could not create directory: " + tempDir + |
|
241 |
String errorString = "PropertiesAdmin.configureProperties - Could not create directory: " + tempDir +
|
|
242 | 242 |
" : " + ue.getMessage(); |
243 | 243 |
logMetacat.error(errorString); |
244 | 244 |
validationErrors.add(errorString); |
... | ... | |
249 | 249 |
try { |
250 | 250 |
FileUtil.createDirectory(replLogDir); |
251 | 251 |
} catch (UtilException ue) { |
252 |
String errorString = "Could not create directory: " + replLogDir + |
|
252 |
String errorString = "PropertiesAdmin.configureProperties - Could not create directory: " + replLogDir +
|
|
253 | 253 |
" : " + ue.getMessage(); |
254 | 254 |
logMetacat.error(errorString); |
255 | 255 |
validationErrors.add(errorString); |
... | ... | |
261 | 261 |
PropertyService.persistMainBackupProperties(); |
262 | 262 |
|
263 | 263 |
} catch (GeneralPropertyException gpe) { |
264 |
String errorMessage = "Problem getting or setting property while " |
|
264 |
String errorMessage = "PropertiesAdmin.configureProperties - Problem getting or setting property while "
|
|
265 | 265 |
+ "processing system properties page: " + gpe.getMessage(); |
266 | 266 |
logMetacat.error(errorMessage); |
267 | 267 |
processingErrors.add(errorMessage); |
... | ... | |
298 | 298 |
} |
299 | 299 |
|
300 | 300 |
} catch (ServletException se) { |
301 |
throw new AdminException("problem forwarding request while " |
|
301 |
throw new AdminException("PropertiesAdmin.configureProperties - problem forwarding request while "
|
|
302 | 302 |
+ "processing system properties page: " + se.getMessage()); |
303 | 303 |
} catch (IOException ioe) { |
304 |
throw new AdminException("IO problem while processing system " |
|
304 |
throw new AdminException("PropertiesAdmin.configureProperties - IO problem while processing system "
|
|
305 | 305 |
+ "properties page: " + ioe.getMessage()); |
306 | 306 |
} catch (GeneralPropertyException gpe) { |
307 |
throw new AdminException("problem with properties while " |
|
307 |
throw new AdminException("PropertiesAdmin.configureProperties - problem with properties while "
|
|
308 | 308 |
+ "processing system properties page: " + gpe.getMessage()); |
309 | 309 |
} |
310 | 310 |
} |
Also available in: Unified diff
Change location of PropertyService to properties directory