Project

General

Profile

1
<%@ page language="java" %>
2
<%@ page import="java.util.Set,java.util.Map,java.util.Vector,edu.ucsb.nceas.utilities.PropertiesMetaData" %>
3
<%@ page import="edu.ucsb.nceas.utilities.MetaDataGroup,edu.ucsb.nceas.utilities.MetaDataProperty" %>
4
<% 
5
/**
6
 *  '$RCSfile$'
7
 *    Copyright: 2008 Regents of the University of California and the
8
 *               National Center for Ecological Analysis and Synthesis
9
 *  For Details: http://www.nceas.ucsb.edu/
10
 *
11
 *   '$Author: tao $'
12
 *     '$Date: 2014-04-29 16:47:09 -0700 (Tue, 29 Apr 2014) $'
13
 * '$Revision: 8755 $'
14
 * 
15
 * This program is free software; you can redistribute it and/or modify
16
 * it under the terms of the GNU General Public License as published by
17
 * the Free Software Foundation; either version 2 of the License, or
18
 * (at your option) any later version.
19
 *
20
 * This program is distributed in the hope that it will be useful,
21
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
22
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
23
 * GNU General Public License for more details.
24
 *
25
 * You should have received a copy of the GNU General Public License
26
 * along with this program; if not, write to the Free Software
27
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
28
 */
29
%>
30

    
31
<html>
32
<head>
33

    
34
<title>DataONE Configuration</title>
35
<%@ include file="./head-section.jsp"%>
36
</head>
37
<body>
38
<%@ include file="./header-section.jsp"%>
39

    
40
<div class="document">
41
	<h2>DataONE Configuration</h2>
42
	
43
	<p> 
44
	    DataONE configuration is optional; choose 'Skip' below to proceed to the next configuration section,
45
	    unless you want to join the DataONE federation.
46
	</p>
47
	<p>
48
		<a href="http://www.dataone.org" target="_D1">DataONE</a> is a federation of data repositories (called Member Nodes)
49
	    that work together to create a seamless, interoperable network to store, preserve, discover, and publish scientific data.
50
		Becoming a DataONE Member Node is a means of distributing data and metadata using a common set of standards, making it
51
		easy to build software systems that can interact with any of the federated repository nodes.  Metacat can be used
52
		to join the DataONE federation by configuring Metacat to act as a Member Node and applying with DataONE to become a
53
		Member Node.  Once a node's application is approved and Metacat is configured, metadata will be synchronized in the 
54
		network for easy discovery, and replicas of data and metadata can be housed on other Member Nodes for 
55
		archival safe-keeping. In addition, a Metacat Member Node can optionally provide space to store replicas of data from 
56
		other Member Nodes that wish to preserve their data in the federation.
57
	<p/>
58
	<p> To configure Metacat as a Member Node, you must first obtain a Member Node X.509 certificate that will
59
	    be used to authenticate this node, and you must have a registered and verified account with DataONE that can
60
	    be used as the point of contact for the candidate Member Node.  Once you have this information, fill out
61
	    the form below with the proper configuration information, and then click 'Register', which will send the
62
	    registration data to DataONE. A unique Member Node ID will be assigned and should only be used for this 
63
	    node and never shared or altered.
64
	<p/>
65
	<br clear="right"/>
66
	
67
	<%@ include file="page-message-section.jsp"%>
68
	
69
	<form method="POST" name="configuration_form" action="<%= request.getContextPath() %>/admin" 
70
	                                        onsubmit="return submitForm(this);">
71
	
72
		<h3>Member Node Services</h3>
73
		Enable or disable DataONE Member Node Services for this deployment
74
		
75
		<div class="form-row">
76
			<div class="textinput-label"><label for="dataone.mn.services.enabled" title="Enable DataONE Member Node Services">Enable DataONE Services</label></div>
77
	
78
			<%
79
			
80
			boolean enableServices = false;
81
			String enableServicesString = (String) request.getAttribute("dataone.mn.services.enabled");
82
			if (enableServicesString != null) {
83
				enableServices = Boolean.parseBoolean(enableServicesString);
84
			}
85
			
86
			if (enableServices) { 
87
			%>
88
			<input type="checkbox" 
89
					class="textinput" 
90
					id="dataone.mn.services.enabled" 
91
					name="dataone.mn.services.enabled" 	             		    	    	           		    	             			
92
					value="true"
93
					checked="checked"/>
94
			<% } else {%>
95
			<input type="checkbox" 
96
					class="textinput" 
97
					id="dataone.mn.services.enabled" 
98
					name="dataone.mn.services.enabled" 	             		    	    	           		    	             			
99
					value="true"/>
100
			<% } %>
101
			
102
			<i class="icon-question-sign checkbox-help" onClick="helpWindow('<%= request.getContextPath() %>','docs/dataone.html#configuring-metacat-as-a-member-node')"></i>
103
		</div>
104
		<div class="clear"></div>
105
		<h3>Member Node Configuration</h3>
106
		General information identifiying this node, its owner, and contents.  You will need
107
		   a certificate to identify the node, and a DataONE account to act as a node contact.
108
		
109
		<div class="form-row">
110
			<div class="textinput-label">
111
				<label for="D1Client.CN_URL" title="The Coordinating node URL which the member node joins">Coordinating Node URL</label>
112
			</div>
113
			<input class="textinput" 
114
				id="D1Client.CN_URL" 
115
				name="D1Client.CN_URL" 	             		    	    	           		    	             			
116
				value="<%= request.getAttribute("D1Client.CN_URL") %>"/> 
117
			<i class="icon-question-sign" onClick="helpWindow('<%= request.getContextPath() %>','docs/dataone.html#configuring-metacat-as-a-member-node')"></i>
118
		</div>
119
		
120
		<div class="form-row">
121
			<div class="textinput-label">
122
				<label for="dataone.nodeName" title="A short, human-readable name for this node">Node Name</label>
123
			</div>
124
			<input class="textinput" 
125
				id="dataone.nodeName" 
126
				name="dataone.nodeName" 	             		    	    	           		    	             			
127
				value="<%= request.getAttribute("dataone.nodeName") %>"/> 
128
			<i class="icon-question-sign" onClick="helpWindow('<%= request.getContextPath() %>','docs/dataone.html#configuring-metacat-as-a-member-node')"></i>
129
		</div>
130
		<div class="form-row">
131
			<div class="textinput-label">
132
				<label for="dataone.nodeDescription" title="A brief description of the node and its holdings">Node Description</label>
133
			</div>
134
			<input class="textinput" 
135
				id="dataone.nodeDescription" 
136
				name="dataone.nodeDescription" 	             		    	    	           		    	             			
137
				value="<%= request.getAttribute("dataone.nodeDescription") %>"/> 
138
			<i class="icon-question-sign" onClick="helpWindow('<%= request.getContextPath() %>','docs/dataone.html#configuring-metacat-as-a-member-node')"></i>
139
		</div>
140
		<div class="form-row">
141
			<div class="textinput-label">
142
				<label for="dataone.nodeId" title="The DataONE-assigned unique identifier for this node">Node Identifier</label>
143
			</div>
144
			<input class="textinput" 
145
				id="dataone.nodeId" 
146
				name="dataone.nodeId" 	             		    	    	           		    	             			
147
				value="<%= request.getAttribute("dataone.nodeId") %>"/>
148
			<i class="icon-question-sign" onClick="helpWindow('<%= request.getContextPath() %>','docs/dataone.html#configuring-metacat-as-a-member-node')"></i>
149
		</div>
150
		<div class="form-row">
151
			<div class="textinput-label">
152
				<label for="dataone.subject" title="The account in Distinguished Name (DN) format that represents this node in all service interactions">Node Subject</label>
153
			</div>
154
			<input class="textinput" 
155
				id="dataone.subject" 
156
				name="dataone.subject" 	             		    	    	           		    	             			
157
				value="<%= request.getAttribute("dataone.subject") %>"/> 
158
			<i class="icon-question-sign" onClick="helpWindow('<%= request.getContextPath() %>','docs/dataone.html#configuring-metacat-as-a-member-node')"></i>
159
		</div>
160
		<div class="form-row">
161
			<div class="textinput-label">
162
				<label for="dataone.contactSubject" title="A verified account in DN format to be used as the primary node contact for this node">Contact Subject</label>
163
			</div>
164
			<input class="textinput" 
165
				id="dataone.contactSubject" 
166
				name="dataone.contactSubject" 	             		    	    	           		    	             			
167
				value="<%= request.getAttribute("dataone.contactSubject") %>"/> 
168
			<i class="icon-question-sign" onClick="helpWindow('<%= request.getContextPath() %>','docs/dataone.html#configuring-metacat-as-a-member-node')"></i>
169
		</div>
170
		<div class="form-row">
171
			<div class="textinput-label">
172
				<label for="D1Client.certificate.file" title="The absolute path to the X.509 certificate used to authenticate this node">Node Certificate Path</label>
173
			</div>
174
			<input class="textinput" 
175
				id="D1Client.certificate.file" 
176
				name="D1Client.certificate.file" 	             		    	    	           		    	             			
177
				value="<%= request.getAttribute("D1Client.certificate.file") %>"/> 
178
			<i class="icon-question-sign" onClick="helpWindow('<%= request.getContextPath() %>','docs/dataone.html#configuring-metacat-as-a-member-node')"></i>
179
		</div>
180
		<div class="form-row">
181
			<div class="textinput-label"><label for="dataone.nodeSynchronize" title="Enable DataONE metadata synchronization">Enable Metadata Synchronization</label></div>
182
	
183
			<%
184
			
185
			boolean synchronize = false;
186
			String nodeSynchronize = (String) request.getAttribute("dataone.nodeSynchronize");
187
			if (nodeSynchronize != null) {
188
				synchronize = Boolean.parseBoolean(nodeSynchronize);
189
			}
190
			
191
			if (synchronize) { 
192
			%>
193
			<input type="checkbox" 
194
					class="textinput" 
195
					id="dataone.nodeSynchronize" 
196
					name="dataone.nodeSynchronize" 	             		    	    	           		    	             			
197
					value="true"
198
					checked="checked"/>
199
			<% } else {%>
200
			<input type="checkbox" 
201
					class="textinput" 
202
					id="dataone.nodeSynchronize" 
203
					name="dataone.nodeSynchronize" 	             		    	    	           		    	             			
204
					value="true"/>
205
			<% } %>
206
			<i class="icon-question-sign checkbox-help" onClick="helpWindow('<%= request.getContextPath() %>','docs/dataone.html#configuring-metacat-as-a-member-node')"></i>
207
		</div>
208
	    <p>&nbsp;</p>
209
	    
210
	   	<div class="clear"></div>
211
	   	 
212
		<h3>Synchronization Schedule</h3>
213
		The schedule on which metadata should be synchronized with DataONE, expressed as a crontab entry.
214
		
215
		<div class="form-row">
216
			<div class="textinput-label">
217
				<label for="dataone.nodeSynchronization.schedule.year" title="Year">Year</label>
218
			</div>
219
			<input class="textinput" 
220
				id="dataone.nodeSynchronization.schedule.year" 
221
				name="dataone.nodeSynchronization.schedule.year" 	             		    	    	           		    	             			
222
				value="<%= request.getAttribute("dataone.nodeSynchronization.schedule.year") %>"/> 
223
			<i class="icon-question-sign" onClick="helpWindow('<%= request.getContextPath() %>','docs/dataone.html#configuring-metacat-as-a-member-node')"></i>
224
		</div>
225
		<div class="form-row">
226
			<div class="textinput-label">
227
				<label for="dataone.nodeSynchronization.schedule.mon" title="Month">Month</label>
228
			</div>
229
			<input class="textinput" 
230
				id="dataone.nodeSynchronization.schedule.mon" 
231
				name="dataone.nodeSynchronization.schedule.mon" 	             		    	    	           		    	             			
232
				value="<%= request.getAttribute("dataone.nodeSynchronization.schedule.mon") %>"/>
233
			<i class="icon-question-sign" onClick="helpWindow('<%= request.getContextPath() %>','docs/dataone.html#configuring-metacat-as-a-member-node')"></i> 
234
		</div>
235
		<div class="form-row">
236
			<div class="textinput-label">
237
				<label for="dataone.nodeSynchronization.schedule.mday" title="Day of Month">Day of Month</label>
238
			</div>
239
			<input class="textinput" 
240
				id="dataone.nodeSynchronization.schedule.mday" 
241
				name="dataone.nodeSynchronization.schedule.mday" 	             		    	    	           		    	             			
242
				value="<%= request.getAttribute("dataone.nodeSynchronization.schedule.mday") %>"/> 
243
			<i class="icon-question-sign" onClick="helpWindow('<%= request.getContextPath() %>','docs/dataone.html#configuring-metacat-as-a-member-node')"></i>
244
		</div>
245
		<div class="form-row">
246
			<div class="textinput-label">
247
				<label for="dataone.nodeSynchronization.schedule.wday" title="Day of Week">Day of Week</label>
248
			</div>
249
			<input class="textinput" 
250
				id="dataone.nodeSynchronization.schedule.wday" 
251
				name="dataone.nodeSynchronization.schedule.wday" 	             		    	    	           		    	             			
252
				value="<%= request.getAttribute("dataone.nodeSynchronization.schedule.wday") %>"/> 
253
			<i class="icon-question-sign" onClick="helpWindow('<%= request.getContextPath() %>','docs/dataone.html#configuring-metacat-as-a-member-node')"></i>
254
		</div>
255
		<div class="form-row">
256
			<div class="textinput-label">
257
				<label for="dataone.nodeSynchronization.schedule.hour" title="Hours">Hours</label>
258
			</div>
259
			<input class="textinput" 
260
				id="dataone.nodeSynchronization.schedule.hour" 
261
				name="dataone.nodeSynchronization.schedule.hour" 	             		    	    	           		    	             			
262
				value="<%= request.getAttribute("dataone.nodeSynchronization.schedule.hour") %>"/> 
263
			<i class="icon-question-sign" onClick="helpWindow('<%= request.getContextPath() %>','docs/dataone.html#configuring-metacat-as-a-member-node')"></i>
264
		</div>
265
		<div class="form-row">
266
			<div class="textinput-label">
267
				<label for="dataone.nodeSynchronization.schedule.min" title="Minutes">Minutes</label>
268
			</div>
269
			<input class="textinput" 
270
				id="dataone.nodeSynchronization.schedule.min" 
271
				name="dataone.nodeSynchronization.schedule.min" 	             		    	    	           		    	             			
272
				value="<%= request.getAttribute("dataone.nodeSynchronization.schedule.min") %>"/> 
273
			<i class="icon-question-sign" onClick="helpWindow('<%= request.getContextPath() %>','docs/dataone.html#configuring-metacat-as-a-member-node')"></i>
274
		</div>
275
		<div class="form-row">
276
			<div class="textinput-label">
277
				<label for="dataone.nodeSynchronization.schedule.sec" title="Seconds">Seconds</label>
278
			</div>
279
			<input class="textinput" 
280
				id="dataone.nodeSynchronization.schedule.sec" 
281
				name="dataone.nodeSynchronization.schedule.sec" 	             		    	    	           		    	             			
282
				value="<%= request.getAttribute("dataone.nodeSynchronization.schedule.sec") %>"/> 
283
			<i class="icon-question-sign" onClick="helpWindow('<%= request.getContextPath() %>','docs/dataone.html#configuring-metacat-as-a-member-node')"></i>
284
		</div>
285
		
286
		<div class="clear"></div>
287
	
288
		<h3>Replication</h3>
289
		Configuration for replication, including whether this node can be used to house replicas of
290
		objects from other nodes, as well as default replication policies for the objects originating
291
		on this Member Node.
292
		
293
		<div class="form-row">
294
			<div class="textinput-label"><label for="dataone.nodeReplicate" title="Store replicas from other Member Nodes">Accept and Store Replicas</label></div>
295
	
296
			<%
297
			boolean replicate = false;
298
			String nodeReplicate = (String) request.getAttribute("dataone.nodeReplicate");
299
			if (nodeReplicate != null) {
300
				replicate = Boolean.parseBoolean(nodeReplicate);
301
			}
302
			if (replicate) { 
303
			%>
304
			<input type="checkbox" 
305
					class="textinput" 
306
					id="dataone.nodeReplicate" 
307
					name="dataone.nodeReplicate" 	             		    	    	           		    	             			
308
					value="true"
309
					checked="checked"/>
310
			<% } else {%>
311
			<input type="checkbox" 
312
					class="textinput" 
313
					id="dataone.nodeReplicate" 
314
					name="dataone.nodeReplicate" 	             		    	    	           		    	             			
315
					value="true"/>
316
			<% } %>
317
			<i class="icon-question-sign checkbox-help" onClick="helpWindow('<%= request.getContextPath() %>','docs/dataone.html#configuring-metacat-as-a-member-node')"></i>
318
		</div>
319
		
320
		
321
	
322
	 	<div class="form-row">
323
			<div class="textinput-label">
324
				<label for="dataone.replicationpolicy.default.numreplicas" title="Default Number of Replicas to be created for local objects">Default Number of Replicas</label>
325
			</div>
326
			<input class="textinput" 
327
				id="dataone.replicationpolicy.default.numreplicas" 
328
				name="dataone.replicationpolicy.default.numreplicas" 	             		    	    	           		    	             			
329
				value="<%= request.getAttribute("dataone.replicationpolicy.default.numreplicas") %>"/> 
330
			<i class="icon-question-sign" onClick="helpWindow('<%= request.getContextPath() %>','docs/dataone.html#configuring-metacat-as-a-member-node')"></i>
331
		</div>
332
	  	<div class="form-row">
333
			<div class="textinput-label">
334
				<label for="dataone.replicationpolicy.default.preferredNodeList" title="A comma-separated list of preferred nodes to house replicas">Default Preferred Nodes</label>
335
			</div>
336
			<input class="textinput" 
337
				id="dataone.replicationpolicy.default.preferredNodeList" 
338
				name="dataone.replicationpolicy.default.preferredNodeList" 	             		    	    	           		    	             			
339
				value="<%= request.getAttribute("dataone.replicationpolicy.default.preferredNodeList") %>"/> 
340
			<i class="icon-question-sign" onClick="helpWindow('<%= request.getContextPath() %>','docs/dataone.html#configuring-metacat-as-a-member-node')"></i>
341
		</div>
342
	   	<div class="form-row">
343
			<div class="textinput-label">
344
				<label for="dataone.replicationpolicy.default.blockedNodeList" title="A comma-separated list of blocked nodes never to house replicas">Default Blocked Nodes</label>
345
			</div>
346
			<input class="textinput" 
347
				id="dataone.replicationpolicy.default.blockedNodeList" 
348
				name="dataone.replicationpolicy.default.blockedNodeList" 	             		    	    	           		    	             			
349
				value="<%= request.getAttribute("dataone.replicationpolicy.default.blockedNodeList") %>"/> 
350
			<i class="icon-question-sign" onClick="helpWindow('<%= request.getContextPath() %>','docs/dataone.html#configuring-metacat-as-a-member-node')"></i>
351
		</div>
352
	 
353
	 	<div class="buttons-wrapper">
354
			<input type="hidden" name="configureType" value="dataone"/>
355
			<input type="hidden" name="processForm" value="true"/>
356
		
357
			<%
358
				// do we know if it is an update or a new registration?
359
				boolean isUpdate = false;
360
				String isUpdateString = (String) request.getAttribute("dataone.isUpdate");
361
				if (isUpdateString != null) {
362
					isUpdate = Boolean.parseBoolean(isUpdateString);
363
				}
364
				// do we know if it is pending approval?
365
				boolean isSubmitted = false;
366
				String isSubmittedString = (String) request.getAttribute("dataone.mn.registration.submitted");
367
				if (isSubmittedString != null) {
368
					isSubmitted = Boolean.parseBoolean(isSubmittedString);
369
				}
370
			%>
371
			<%if (isUpdate) { %>
372
				<input class=button type="submit" value="Update"/>
373
			<%} else if (isSubmitted) { %>
374
				<input class=button type="submit" value="Update"/>
375
			<%} else { %>
376
				<input class=button type="submit" value="Register"/>
377
			<%} %>
378
			<%
379
				// if have we already configured this section, then we cannot skip it
380
				boolean previouslyConfigured = false;
381
				String previouslyConfiguredString = (String) request.getAttribute("configutil.dataoneConfigured");
382
				if (previouslyConfiguredString != null) {
383
					previouslyConfigured = Boolean.parseBoolean(previouslyConfiguredString);
384
				}
385
			%>
386
			<%if (!previouslyConfigured) { %>
387
				<input class=button type="button" value="Bypass" onClick="forward('./admin?configureType=dataone&bypass=true&processForm=true')">
388
			<%} %>
389
			<input class=button type="button" value="Cancel" onClick="forward('./admin')"> 
390
		</div>
391
	</form>
392
</div>
393
<%@ include file="./footer-section.jsp"%>
394

    
395
</body>
396
</html>
(8-8/20)