Revision 6864
Added by ben leinfelder over 12 years ago
D1Admin.java | ||
---|---|---|
48 | 48 |
import edu.ucsb.nceas.metacat.util.RequestUtil; |
49 | 49 |
import edu.ucsb.nceas.utilities.GeneralPropertyException; |
50 | 50 |
import edu.ucsb.nceas.utilities.PropertyNotFoundException; |
51 |
import edu.ucsb.nceas.utilities.SortedProperties; |
|
51 | 52 |
|
52 | 53 |
/** |
53 | 54 |
* Control the display of the database configuration page and the processing |
... | ... | |
141 | 142 |
request.setAttribute("dataone.nodeName", nodeName); |
142 | 143 |
request.setAttribute("dataone.nodeDescription", nodeDescription); |
143 | 144 |
request.setAttribute("dataone.memberNodeId", memberNodeId); |
144 |
request.setAttribute("dataone.nodeSynchronize", synchronize);
|
|
145 |
request.setAttribute("dataone.nodeReplicate", replicate);
|
|
145 |
request.setAttribute("dataone.nodeSynchronize", Boolean.toString(synchronize));
|
|
146 |
request.setAttribute("dataone.nodeReplicate", Boolean.toString(replicate));
|
|
146 | 147 |
request.setAttribute("dataone.subject", subject); |
147 | 148 |
request.setAttribute("D1Client.certificate.file", certpath); |
148 | 149 |
|
... | ... | |
155 | 156 |
request.setAttribute("dataone.nodeSynchronization.schedule.min", min); |
156 | 157 |
request.setAttribute("dataone.nodeSynchronization.schedule.sec", sec); |
157 | 158 |
|
159 |
// try the backup properties |
|
160 |
SortedProperties backupProperties = null; |
|
161 |
if ((backupProperties = |
|
162 |
PropertyService.getMainBackupProperties()) != null) { |
|
163 |
Vector<String> backupKeys = backupProperties.getPropertyNames(); |
|
164 |
for (String key : backupKeys) { |
|
165 |
String value = backupProperties.getProperty(key); |
|
166 |
if (value != null) { |
|
167 |
request.setAttribute(key, value); |
|
168 |
} |
|
169 |
} |
|
170 |
} |
|
171 |
|
|
158 | 172 |
// Forward the request to the JSP page |
159 | 173 |
RequestUtil.forwardRequest(request, response, "/admin/dataone-configuration.jsp", null); |
160 | 174 |
} catch (GeneralPropertyException gpe) { |
Also available in: Unified diff
store D1 configuration properties in the main backup so that they persist between upgrades.