neptune 0.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/LICENSE +39 -0
- data/README +50 -0
- data/bin/neptune +16 -0
- data/doc/AppControllerClient.html +468 -0
- data/doc/CommonFunctions.html +368 -0
- data/doc/LICENSE.html +131 -0
- data/doc/Object.html +431 -0
- data/doc/README.html +135 -0
- data/doc/bin/neptune.html +58 -0
- data/doc/created.rid +7 -0
- data/doc/images/brick.png +0 -0
- data/doc/images/brick_link.png +0 -0
- data/doc/images/bug.png +0 -0
- data/doc/images/bullet_black.png +0 -0
- data/doc/images/bullet_toggle_minus.png +0 -0
- data/doc/images/bullet_toggle_plus.png +0 -0
- data/doc/images/date.png +0 -0
- data/doc/images/find.png +0 -0
- data/doc/images/loadingAnimation.gif +0 -0
- data/doc/images/macFFBgHack.png +0 -0
- data/doc/images/package.png +0 -0
- data/doc/images/page_green.png +0 -0
- data/doc/images/page_white_text.png +0 -0
- data/doc/images/page_white_width.png +0 -0
- data/doc/images/plugin.png +0 -0
- data/doc/images/ruby.png +0 -0
- data/doc/images/tag_green.png +0 -0
- data/doc/images/wrench.png +0 -0
- data/doc/images/wrench_orange.png +0 -0
- data/doc/images/zoom.png +0 -0
- data/doc/index.html +90 -0
- data/doc/js/darkfish.js +116 -0
- data/doc/js/jquery.js +32 -0
- data/doc/js/quicksearch.js +114 -0
- data/doc/js/thickbox-compressed.js +10 -0
- data/doc/lib/app_controller_client_rb.html +60 -0
- data/doc/lib/common_functions_rb.html +68 -0
- data/doc/lib/job_rb.html +55 -0
- data/doc/scripts/appscale/add_appserver_rb.html +52 -0
- data/doc/scripts/appscale/add_database_rb.html +52 -0
- data/doc/scripts/appscale/add_loadbalancer_rb.html +52 -0
- data/doc/scripts/appscale/add_slave_rb.html +52 -0
- data/doc/scripts/cewssa/cewssa-output.html +104 -0
- data/doc/scripts/cewssa/get_cewssa_output_rb.html +52 -0
- data/doc/scripts/cewssa/run_cewssa_rb.html +52 -0
- data/doc/scripts/cewssa/test_dfsp_rb.html +52 -0
- data/doc/scripts/dfsp/get_dfsp_output_rb.html +52 -0
- data/doc/scripts/dfsp/make_output_public_rb.html +52 -0
- data/doc/scripts/dfsp/run_dfsp_rb.html +52 -0
- data/doc/scripts/dfsp/see_acl_rb.html +52 -0
- data/doc/scripts/dfsp/test_dfsp_rb.html +52 -0
- data/doc/scripts/mapreduce/get_mapreduce_output_rb.html +52 -0
- data/doc/scripts/mapreduce/input-10.html +114 -0
- data/doc/scripts/mapreduce/input-30.html +114 -0
- data/doc/scripts/mapreduce/input-7.html +104 -0
- data/doc/scripts/mapreduce/map_rb.html +56 -0
- data/doc/scripts/mapreduce/reduce_rb.html +56 -0
- data/doc/scripts/mapreduce/run_java_mr_rb.html +52 -0
- data/doc/scripts/mapreduce/run_mapreduce_rb.html +52 -0
- data/doc/scripts/mpi/Makefile.html +125 -0
- data/doc/scripts/mpi/get_mpi_output_rb.html +52 -0
- data/doc/scripts/mpi/hw2_c.html +52 -0
- data/doc/scripts/mpi/hw2harness_c.html +52 -0
- data/doc/scripts/mpi/hw2harness_h.html +52 -0
- data/doc/scripts/mpi/run_mpi_cpi_rb.html +52 -0
- data/doc/scripts/mpi/run_mpi_powermethod_rb.html +52 -0
- data/doc/scripts/mpi/test_rb.html +52 -0
- data/doc/scripts/x10/Makefile.html +106 -0
- data/doc/scripts/x10/get_x10_output_rb.html +52 -0
- data/doc/scripts/x10/run_x10_kmeans_rb.html +52 -0
- data/doc/scripts/x10/run_x10_montypi_rb.html +52 -0
- data/doc/scripts/x10/run_x10_nqueens_rb.html +52 -0
- data/doc/scripts/x10/run_x10_powermethod_rb.html +52 -0
- data/doc/scripts/x10/run_x10_qsort_rb.html +52 -0
- data/doc/scripts/x10/test_rb.html +52 -0
- data/lib/app_controller_client.rb +135 -0
- data/lib/common_functions.rb +107 -0
- data/lib/job.rb +161 -0
- metadata +145 -0
data/doc/Object.html
ADDED
|
@@ -0,0 +1,431 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
|
3
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
|
4
|
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
|
5
|
+
<head>
|
|
6
|
+
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type" />
|
|
7
|
+
|
|
8
|
+
<title>Class: Object</title>
|
|
9
|
+
|
|
10
|
+
<link rel="stylesheet" href="./rdoc.css" type="text/css" media="screen" />
|
|
11
|
+
|
|
12
|
+
<script src="./js/jquery.js" type="text/javascript"
|
|
13
|
+
charset="utf-8"></script>
|
|
14
|
+
<script src="./js/thickbox-compressed.js" type="text/javascript"
|
|
15
|
+
charset="utf-8"></script>
|
|
16
|
+
<script src="./js/quicksearch.js" type="text/javascript"
|
|
17
|
+
charset="utf-8"></script>
|
|
18
|
+
<script src="./js/darkfish.js" type="text/javascript"
|
|
19
|
+
charset="utf-8"></script>
|
|
20
|
+
|
|
21
|
+
</head>
|
|
22
|
+
<body class="class">
|
|
23
|
+
|
|
24
|
+
<div id="metadata">
|
|
25
|
+
<div id="home-metadata">
|
|
26
|
+
<div id="home-section" class="section">
|
|
27
|
+
<h3 class="section-header">
|
|
28
|
+
<a href="./index.html">Home</a>
|
|
29
|
+
<a href="./index.html#classes">Classes</a>
|
|
30
|
+
<a href="./index.html#methods">Methods</a>
|
|
31
|
+
</h3>
|
|
32
|
+
</div>
|
|
33
|
+
</div>
|
|
34
|
+
|
|
35
|
+
<div id="file-metadata">
|
|
36
|
+
<div id="file-list-section" class="section">
|
|
37
|
+
<h3 class="section-header">In Files</h3>
|
|
38
|
+
<div class="section-body">
|
|
39
|
+
<ul>
|
|
40
|
+
|
|
41
|
+
<li><a href="./lib/app_controller_client_rb.html?TB_iframe=true&height=550&width=785"
|
|
42
|
+
class="thickbox" title="lib/app_controller_client.rb">lib/app_controller_client.rb</a></li>
|
|
43
|
+
|
|
44
|
+
<li><a href="./lib/job_rb.html?TB_iframe=true&height=550&width=785"
|
|
45
|
+
class="thickbox" title="lib/job.rb">lib/job.rb</a></li>
|
|
46
|
+
|
|
47
|
+
</ul>
|
|
48
|
+
</div>
|
|
49
|
+
</div>
|
|
50
|
+
|
|
51
|
+
|
|
52
|
+
</div>
|
|
53
|
+
|
|
54
|
+
<div id="class-metadata">
|
|
55
|
+
|
|
56
|
+
<!-- Parent Class -->
|
|
57
|
+
|
|
58
|
+
<div id="parent-class-section" class="section">
|
|
59
|
+
<h3 class="section-header">Parent</h3>
|
|
60
|
+
|
|
61
|
+
<p class="link"></p>
|
|
62
|
+
|
|
63
|
+
</div>
|
|
64
|
+
|
|
65
|
+
|
|
66
|
+
<!-- Namespace Contents -->
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
<!-- Method Quickref -->
|
|
70
|
+
|
|
71
|
+
<div id="method-list-section" class="section">
|
|
72
|
+
<h3 class="section-header">Methods</h3>
|
|
73
|
+
<ul class="link-list">
|
|
74
|
+
|
|
75
|
+
<li><a href="#method-i-do_preprocessing">#do_preprocessing</a></li>
|
|
76
|
+
|
|
77
|
+
<li><a href="#method-i-job">#job</a></li>
|
|
78
|
+
|
|
79
|
+
<li><a href="#method-i-preprocess_mapreduce">#preprocess_mapreduce</a></li>
|
|
80
|
+
|
|
81
|
+
<li><a href="#method-i-preprocess_mpi">#preprocess_mpi</a></li>
|
|
82
|
+
|
|
83
|
+
</ul>
|
|
84
|
+
</div>
|
|
85
|
+
|
|
86
|
+
|
|
87
|
+
<!-- Included Modules -->
|
|
88
|
+
|
|
89
|
+
</div>
|
|
90
|
+
|
|
91
|
+
<div id="project-metadata">
|
|
92
|
+
|
|
93
|
+
|
|
94
|
+
<div id="fileindex-section" class="section project-section">
|
|
95
|
+
<h3 class="section-header">Files</h3>
|
|
96
|
+
<ul>
|
|
97
|
+
|
|
98
|
+
<li class="file"><a href="./LICENSE.html">LICENSE</a></li>
|
|
99
|
+
|
|
100
|
+
<li class="file"><a href="./README.html">README</a></li>
|
|
101
|
+
|
|
102
|
+
</ul>
|
|
103
|
+
</div>
|
|
104
|
+
|
|
105
|
+
|
|
106
|
+
<div id="classindex-section" class="section project-section">
|
|
107
|
+
<h3 class="section-header">Class/Module Index
|
|
108
|
+
<span class="search-toggle"><img src="./images/find.png"
|
|
109
|
+
height="16" width="16" alt="[+]"
|
|
110
|
+
title="show/hide quicksearch" /></span></h3>
|
|
111
|
+
<form action="#" method="get" accept-charset="utf-8" class="initially-hidden">
|
|
112
|
+
<fieldset>
|
|
113
|
+
<legend>Quicksearch</legend>
|
|
114
|
+
<input type="text" name="quicksearch" value=""
|
|
115
|
+
class="quicksearch-field" />
|
|
116
|
+
</fieldset>
|
|
117
|
+
</form>
|
|
118
|
+
|
|
119
|
+
<ul class="link-list">
|
|
120
|
+
|
|
121
|
+
<li><a href="./AppControllerClient.html">AppControllerClient</a></li>
|
|
122
|
+
|
|
123
|
+
<li><a href="./CommonFunctions.html">CommonFunctions</a></li>
|
|
124
|
+
|
|
125
|
+
<li><a href="./Object.html">Object</a></li>
|
|
126
|
+
|
|
127
|
+
</ul>
|
|
128
|
+
<div id="no-class-search-results" style="display: none;">No matching classes.</div>
|
|
129
|
+
</div>
|
|
130
|
+
|
|
131
|
+
|
|
132
|
+
</div>
|
|
133
|
+
</div>
|
|
134
|
+
|
|
135
|
+
<div id="documentation">
|
|
136
|
+
<h1 class="class">Object</h1>
|
|
137
|
+
|
|
138
|
+
<div id="description">
|
|
139
|
+
|
|
140
|
+
<p>A set of methods and constants that we’ve monkey-patched to enable
|
|
141
|
+
Neptune support. In the future, it is likely that the only exposed /
|
|
142
|
+
monkey-patched method should be job, while the others could probably be
|
|
143
|
+
folded into either a Neptune-specific class or into <a
|
|
144
|
+
href="CommonFunctions.html">CommonFunctions</a>.</p>
|
|
145
|
+
|
|
146
|
+
</div>
|
|
147
|
+
|
|
148
|
+
<!-- Constants -->
|
|
149
|
+
|
|
150
|
+
<div id="constants-list" class="section">
|
|
151
|
+
<h3 class="section-header">Constants</h3>
|
|
152
|
+
<dl>
|
|
153
|
+
|
|
154
|
+
<dt><a name="NO_TIMEOUT">NO_TIMEOUT</a></dt>
|
|
155
|
+
|
|
156
|
+
<dd class="description"><p>Sometimes SOAP calls take a long time if large amounts of data are being
|
|
157
|
+
sent over the network: for this first version we don’t want these calls
|
|
158
|
+
to endlessly timeout and retry, so as a hack, just don’t let them
|
|
159
|
+
timeout. The next version should replace this and properly timeout and not
|
|
160
|
+
use long calls unless necessary.</p></dd>
|
|
161
|
+
|
|
162
|
+
|
|
163
|
+
<dt><a name="NEED_PREPROCESSING">NEED_PREPROCESSING</a></dt>
|
|
164
|
+
|
|
165
|
+
<dd class="description"><p>A list of jobs that require some kind of work to be done before the actual
|
|
166
|
+
computation can be performed.</p></dd>
|
|
167
|
+
|
|
168
|
+
|
|
169
|
+
</dl>
|
|
170
|
+
</div>
|
|
171
|
+
|
|
172
|
+
|
|
173
|
+
<!-- Attributes -->
|
|
174
|
+
|
|
175
|
+
|
|
176
|
+
<!-- Methods -->
|
|
177
|
+
|
|
178
|
+
<div id="public-instance-method-details" class="method-section section">
|
|
179
|
+
<h3 class="section-header">Public Instance Methods</h3>
|
|
180
|
+
|
|
181
|
+
|
|
182
|
+
<div id="do_preprocessing-method" class="method-detail ">
|
|
183
|
+
<a name="method-i-do_preprocessing"></a>
|
|
184
|
+
|
|
185
|
+
|
|
186
|
+
<div class="method-heading">
|
|
187
|
+
<span class="method-name">do_preprocessing</span><span
|
|
188
|
+
class="method-args">(job_data)</span>
|
|
189
|
+
<span class="method-click-advice">click to toggle source</span>
|
|
190
|
+
</div>
|
|
191
|
+
|
|
192
|
+
|
|
193
|
+
<div class="method-description">
|
|
194
|
+
|
|
195
|
+
<p>Certain types of jobs need steps to be taken before they can be started
|
|
196
|
+
(e.g., copying input data or code over). This method dispatches the right
|
|
197
|
+
method to use based on the type of the job that the user has asked to run.</p>
|
|
198
|
+
|
|
199
|
+
|
|
200
|
+
|
|
201
|
+
<div class="method-source-code"
|
|
202
|
+
id="do_preprocessing-source">
|
|
203
|
+
<pre>
|
|
204
|
+
<span class="ruby-comment"># File lib/job.rb, line 34</span>
|
|
205
|
+
def do_preprocessing(job_data)
|
|
206
|
+
job_type = job_data[<span class="ruby-string">"@type"</span>]
|
|
207
|
+
return unless <span class="ruby-constant">NEED_PREPROCESSING</span>.include?(job_type)
|
|
208
|
+
|
|
209
|
+
preprocess = "preprocess_#{job_type}".to_sym
|
|
210
|
+
send(preprocess, job_data)
|
|
211
|
+
end</pre>
|
|
212
|
+
</div>
|
|
213
|
+
|
|
214
|
+
</div>
|
|
215
|
+
|
|
216
|
+
|
|
217
|
+
|
|
218
|
+
|
|
219
|
+
</div>
|
|
220
|
+
|
|
221
|
+
|
|
222
|
+
<div id="job-method" class="method-detail ">
|
|
223
|
+
<a name="method-i-job"></a>
|
|
224
|
+
|
|
225
|
+
|
|
226
|
+
<div class="method-heading">
|
|
227
|
+
<span class="method-name">job</span><span
|
|
228
|
+
class="method-args">(name, &block)</span>
|
|
229
|
+
<span class="method-click-advice">click to toggle source</span>
|
|
230
|
+
</div>
|
|
231
|
+
|
|
232
|
+
|
|
233
|
+
<div class="method-description">
|
|
234
|
+
|
|
235
|
+
<p>This method is the heart of Neptune - here, we take blocks of code that the
|
|
236
|
+
user has written and convert them into HPC job requests. At a high level,
|
|
237
|
+
the user can request to run a job, retrieve a job’s output, or modify the
|
|
238
|
+
access policy (ACL) for the output of a job. By default, job data is
|
|
239
|
+
private, but a Neptune job can be used to set it to public later (and
|
|
240
|
+
vice-versa).</p>
|
|
241
|
+
|
|
242
|
+
|
|
243
|
+
|
|
244
|
+
<div class="method-source-code"
|
|
245
|
+
id="job-source">
|
|
246
|
+
<pre>
|
|
247
|
+
<span class="ruby-comment"># File lib/job.rb, line 101</span>
|
|
248
|
+
def job(name, &block)
|
|
249
|
+
puts <span class="ruby-string">"Received a request to run a job."</span>
|
|
250
|
+
puts name
|
|
251
|
+
block.call()
|
|
252
|
+
|
|
253
|
+
if <span class="ruby-ivar">@keyname</span>.nil?
|
|
254
|
+
keyname = <span class="ruby-string">"appscale"</span>
|
|
255
|
+
else
|
|
256
|
+
keyname = <span class="ruby-ivar">@keyname</span>
|
|
257
|
+
end
|
|
258
|
+
|
|
259
|
+
shadow_ip = <span class="ruby-constant">CommonFunctions</span>.get_from_yaml(keyname, :shadow)
|
|
260
|
+
secret = <span class="ruby-constant">CommonFunctions</span>.get_secret_key(keyname)
|
|
261
|
+
controller = <span class="ruby-constant">AppControllerClient</span>.new(shadow_ip, secret)
|
|
262
|
+
ssh_key = <span class="ruby-constant">File</span>.expand_path("~/.appscale/#{keyname}.key")
|
|
263
|
+
|
|
264
|
+
job_data = {}
|
|
265
|
+
instance_variables.each { |var|
|
|
266
|
+
job_data[var] = instance_variable_get(var)
|
|
267
|
+
}
|
|
268
|
+
|
|
269
|
+
job_data[<span class="ruby-string">"@job"</span>] = nil
|
|
270
|
+
job_data[<span class="ruby-string">"@type"</span>] = name
|
|
271
|
+
job_data[<span class="ruby-string">"@keyname"</span>] = keyname
|
|
272
|
+
|
|
273
|
+
if job_data[<span class="ruby-string">"@output"</span>].nil? or job_data[<span class="ruby-string">"@output"</span>] == <span class="ruby-string">""</span>
|
|
274
|
+
abort(<span class="ruby-string">"Job output must be specified"</span>)
|
|
275
|
+
end
|
|
276
|
+
|
|
277
|
+
if job_data[<span class="ruby-string">"@output"</span>][0].chr != <span class="ruby-string">"/"</span>
|
|
278
|
+
abort(<span class="ruby-string">"Job output must begin with a slash ('/')"</span>)
|
|
279
|
+
end
|
|
280
|
+
|
|
281
|
+
<span class="ruby-comment">#if job_data["@can_run_on"].class == Range</span>
|
|
282
|
+
<span class="ruby-comment"># job_data["@can_run_on"] = job_data["@can_run_on"].to_a</span>
|
|
283
|
+
<span class="ruby-comment">#elsif job_data["@can_run_on"].class == Fixnum</span>
|
|
284
|
+
<span class="ruby-comment"># job_data["@can_run_on"] = [job_data["@can_run_on"]]</span>
|
|
285
|
+
<span class="ruby-comment">#end</span>
|
|
286
|
+
|
|
287
|
+
puts "job data = #{job_data.inspect}"
|
|
288
|
+
|
|
289
|
+
do_preprocessing(job_data)
|
|
290
|
+
|
|
291
|
+
if job_data[<span class="ruby-string">"@type"</span>] == <span class="ruby-string">"output"</span>
|
|
292
|
+
return controller.get_output(job_data)
|
|
293
|
+
elsif job_data[<span class="ruby-string">"@type"</span>] == <span class="ruby-string">"get-acl"</span>
|
|
294
|
+
job_data[<span class="ruby-string">"@type"</span>] = <span class="ruby-string">"acl"</span>
|
|
295
|
+
return controller.get_acl(job_data)
|
|
296
|
+
elsif job_data[<span class="ruby-string">"@type"</span>] == <span class="ruby-string">"set-acl"</span>
|
|
297
|
+
job_data[<span class="ruby-string">"@type"</span>] = <span class="ruby-string">"acl"</span>
|
|
298
|
+
return controller.set_acl(job_data)
|
|
299
|
+
else
|
|
300
|
+
result = controller.start_neptune_job(job_data)
|
|
301
|
+
if result =~ <span class="ruby-regexp">/job is now running\Z/</span>
|
|
302
|
+
return :success
|
|
303
|
+
else
|
|
304
|
+
return :failure
|
|
305
|
+
end
|
|
306
|
+
end
|
|
307
|
+
end</pre>
|
|
308
|
+
</div>
|
|
309
|
+
|
|
310
|
+
</div>
|
|
311
|
+
|
|
312
|
+
|
|
313
|
+
|
|
314
|
+
|
|
315
|
+
</div>
|
|
316
|
+
|
|
317
|
+
|
|
318
|
+
<div id="preprocess_mapreduce-method" class="method-detail ">
|
|
319
|
+
<a name="method-i-preprocess_mapreduce"></a>
|
|
320
|
+
|
|
321
|
+
|
|
322
|
+
<div class="method-heading">
|
|
323
|
+
<span class="method-name">preprocess_mapreduce</span><span
|
|
324
|
+
class="method-args">(job_data)</span>
|
|
325
|
+
<span class="method-click-advice">click to toggle source</span>
|
|
326
|
+
</div>
|
|
327
|
+
|
|
328
|
+
|
|
329
|
+
<div class="method-description">
|
|
330
|
+
|
|
331
|
+
<p>This preprocessing method handles copying data for regular Hadoop MapReduce
|
|
332
|
+
and Hadoop MapReduce Streaming. For the former case, we copy over just the
|
|
333
|
+
JAR the user has given us, and in the latter case, we copy over the Map and
|
|
334
|
+
Reduce files that have been specified. In either case, if the user has
|
|
335
|
+
specified to us to copy over an input file, we do that as well: AppScale
|
|
336
|
+
will copy it into HDFS for us.</p>
|
|
337
|
+
|
|
338
|
+
|
|
339
|
+
|
|
340
|
+
<div class="method-source-code"
|
|
341
|
+
id="preprocess_mapreduce-source">
|
|
342
|
+
<pre>
|
|
343
|
+
<span class="ruby-comment"># File lib/job.rb, line 65</span>
|
|
344
|
+
def preprocess_mapreduce(job_data)
|
|
345
|
+
items_to_copy = [<span class="ruby-string">"@map"</span>, <span class="ruby-string">"@reduce"</span>] if job_data[<span class="ruby-string">"@map"</span>] and job_data[<span class="ruby-string">"@reduce"</span>]
|
|
346
|
+
items_to_copy = [<span class="ruby-string">"@mapreducejar"</span>] if job_data[<span class="ruby-string">"@mapreducejar"</span>]
|
|
347
|
+
items_to_copy << <span class="ruby-string">"@input"</span> if job_data[<span class="ruby-string">"@copy_input"</span>]
|
|
348
|
+
items_to_copy.each { |item|
|
|
349
|
+
source = <span class="ruby-constant">File</span>.expand_path(job_data[item])
|
|
350
|
+
unless <span class="ruby-constant">File</span>.exists?(source)
|
|
351
|
+
abort("The #{item} file #{source} does not exist.")
|
|
352
|
+
end
|
|
353
|
+
|
|
354
|
+
suffix = source.split(<span class="ruby-string">'/'</span>)[-1]
|
|
355
|
+
dest = "/tmp/#{suffix}"
|
|
356
|
+
|
|
357
|
+
keyname = job_data[<span class="ruby-string">"@keyname"</span>]
|
|
358
|
+
<span class="ruby-constant">CommonFunctions</span>.scp_to_shadow(source, dest, keyname)
|
|
359
|
+
|
|
360
|
+
job_data[item] = dest
|
|
361
|
+
}
|
|
362
|
+
end</pre>
|
|
363
|
+
</div>
|
|
364
|
+
|
|
365
|
+
</div>
|
|
366
|
+
|
|
367
|
+
|
|
368
|
+
|
|
369
|
+
|
|
370
|
+
</div>
|
|
371
|
+
|
|
372
|
+
|
|
373
|
+
<div id="preprocess_mpi-method" class="method-detail ">
|
|
374
|
+
<a name="method-i-preprocess_mpi"></a>
|
|
375
|
+
|
|
376
|
+
|
|
377
|
+
<div class="method-heading">
|
|
378
|
+
<span class="method-name">preprocess_mpi</span><span
|
|
379
|
+
class="method-args">(job_data)</span>
|
|
380
|
+
<span class="method-click-advice">click to toggle source</span>
|
|
381
|
+
</div>
|
|
382
|
+
|
|
383
|
+
|
|
384
|
+
<div class="method-description">
|
|
385
|
+
|
|
386
|
+
<p>This preprocessing method copies over the user’s MPI code to the master
|
|
387
|
+
node in AppScale - this node will then copy it to whoever will run the MPI
|
|
388
|
+
job.</p>
|
|
389
|
+
|
|
390
|
+
|
|
391
|
+
|
|
392
|
+
<div class="method-source-code"
|
|
393
|
+
id="preprocess_mpi-source">
|
|
394
|
+
<pre>
|
|
395
|
+
<span class="ruby-comment"># File lib/job.rb, line 45</span>
|
|
396
|
+
def preprocess_mpi(job_data)
|
|
397
|
+
source_code = <span class="ruby-constant">File</span>.expand_path(job_data[<span class="ruby-string">"@code"</span>])
|
|
398
|
+
unless <span class="ruby-constant">File</span>.exists?(source_code)
|
|
399
|
+
file_not_found = "The specified code, #{job_data['@code']}," +
|
|
400
|
+
<span class="ruby-string">" didn't exist. Please specify one that exists and try again"</span>
|
|
401
|
+
abort(file_not_found)
|
|
402
|
+
end
|
|
403
|
+
dest_code = <span class="ruby-string">"/tmp/thempicode"</span>
|
|
404
|
+
|
|
405
|
+
keyname = job_data[<span class="ruby-string">"@keyname"</span>]
|
|
406
|
+
<span class="ruby-constant">CommonFunctions</span>.scp_to_shadow(source_code, dest_code, keyname)
|
|
407
|
+
end</pre>
|
|
408
|
+
</div>
|
|
409
|
+
|
|
410
|
+
</div>
|
|
411
|
+
|
|
412
|
+
|
|
413
|
+
|
|
414
|
+
|
|
415
|
+
</div>
|
|
416
|
+
|
|
417
|
+
|
|
418
|
+
</div>
|
|
419
|
+
|
|
420
|
+
|
|
421
|
+
</div>
|
|
422
|
+
|
|
423
|
+
<div id="validator-badges">
|
|
424
|
+
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
|
425
|
+
<p><small>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish
|
|
426
|
+
Rdoc Generator</a> 2</small>.</p>
|
|
427
|
+
</div>
|
|
428
|
+
|
|
429
|
+
</body>
|
|
430
|
+
</html>
|
|
431
|
+
|
data/doc/README.html
ADDED
|
@@ -0,0 +1,135 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="utf-8"?>
|
|
2
|
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
|
3
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
|
4
|
+
|
|
5
|
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
|
6
|
+
<head>
|
|
7
|
+
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type" />
|
|
8
|
+
|
|
9
|
+
<title>File: README [RDoc Documentation]</title>
|
|
10
|
+
|
|
11
|
+
<link type="text/css" media="screen" href="./rdoc.css" rel="stylesheet" />
|
|
12
|
+
|
|
13
|
+
<script src="./js/jquery.js" type="text/javascript"
|
|
14
|
+
charset="utf-8"></script>
|
|
15
|
+
<script src="./js/thickbox-compressed.js" type="text/javascript"
|
|
16
|
+
charset="utf-8"></script>
|
|
17
|
+
<script src="./js/quicksearch.js" type="text/javascript"
|
|
18
|
+
charset="utf-8"></script>
|
|
19
|
+
<script src="./js/darkfish.js" type="text/javascript"
|
|
20
|
+
charset="utf-8"></script>
|
|
21
|
+
</head>
|
|
22
|
+
|
|
23
|
+
<body class="file">
|
|
24
|
+
<div id="metadata">
|
|
25
|
+
<div id="home-metadata">
|
|
26
|
+
<div id="home-section" class="section">
|
|
27
|
+
<h3 class="section-header">
|
|
28
|
+
<a href="./index.html">Home</a>
|
|
29
|
+
<a href="./index.html#classes">Classes</a>
|
|
30
|
+
<a href="./index.html#methods">Methods</a>
|
|
31
|
+
</h3>
|
|
32
|
+
</div>
|
|
33
|
+
</div>
|
|
34
|
+
|
|
35
|
+
<div id="project-metadata">
|
|
36
|
+
|
|
37
|
+
|
|
38
|
+
<div id="fileindex-section" class="section project-section">
|
|
39
|
+
<h3 class="section-header">Files</h3>
|
|
40
|
+
<ul>
|
|
41
|
+
|
|
42
|
+
<li class="file"><a href="./LICENSE.html">LICENSE</a></li>
|
|
43
|
+
|
|
44
|
+
<li class="file"><a href="./README.html">README</a></li>
|
|
45
|
+
|
|
46
|
+
</ul>
|
|
47
|
+
</div>
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
<div id="classindex-section" class="section project-section">
|
|
51
|
+
<h3 class="section-header">Class Index
|
|
52
|
+
<span class="search-toggle"><img src="./images/find.png"
|
|
53
|
+
height="16" width="16" alt="[+]"
|
|
54
|
+
title="show/hide quicksearch" /></span></h3>
|
|
55
|
+
<form action="#" method="get" accept-charset="utf-8" class="initially-hidden">
|
|
56
|
+
<fieldset>
|
|
57
|
+
<legend>Quicksearch</legend>
|
|
58
|
+
<input type="text" name="quicksearch" value=""
|
|
59
|
+
class="quicksearch-field" />
|
|
60
|
+
</fieldset>
|
|
61
|
+
</form>
|
|
62
|
+
|
|
63
|
+
<ul class="link-list">
|
|
64
|
+
|
|
65
|
+
<li><a href="./AppControllerClient.html">AppControllerClient</a></li>
|
|
66
|
+
|
|
67
|
+
<li><a href="./CommonFunctions.html">CommonFunctions</a></li>
|
|
68
|
+
|
|
69
|
+
<li><a href="./Object.html">Object</a></li>
|
|
70
|
+
|
|
71
|
+
</ul>
|
|
72
|
+
<div id="no-class-search-results" style="display: none;">No matching classes.</div>
|
|
73
|
+
</div>
|
|
74
|
+
|
|
75
|
+
|
|
76
|
+
</div>
|
|
77
|
+
</div>
|
|
78
|
+
|
|
79
|
+
<div id="documentation">
|
|
80
|
+
|
|
81
|
+
<h1>begin rdoc</h1>
|
|
82
|
+
|
|
83
|
+
<p>Neptune: A Domain Specific Language for Deploying HPC Software on Cloud
|
|
84
|
+
Platforms</p>
|
|
85
|
+
|
|
86
|
+
<p>Neptune provides programmers with a simple interface by which they can
|
|
87
|
+
deploy MPI, X10, and MapReduce jobs to without needing to know the
|
|
88
|
+
particulars of the underlying cloud platform. You only need to give Neptune
|
|
89
|
+
your code, tell it how many machines to run on and where to put the output:
|
|
90
|
+
Neptune handles everything else. No more writing configuration files,
|
|
91
|
+
having to start up NFS on all your machines, yada yada yada. Neptune works
|
|
92
|
+
together with supported cloud platforms (currently AppScale is recommended)
|
|
93
|
+
and can deploy over anything AppScale can - Xen or KVM virtual machines as
|
|
94
|
+
well as Eucalyptus and Amazon EC2. There’s nothing virtualization
|
|
95
|
+
specific in there, so in theory any machine installed with the AppScale
|
|
96
|
+
software should work fine.</p>
|
|
97
|
+
|
|
98
|
+
<p>Although Neptune is designed to automate deploying HPC jobs, it also can be
|
|
99
|
+
used to deploy other types of software. For example, Neptune has support
|
|
100
|
+
for user-specified scaling of the underlying cloud platform: users can
|
|
101
|
+
write Neptune jobs that manually add load balancers, application servers,
|
|
102
|
+
or database servers to a running AppScale deployment.</p>
|
|
103
|
+
|
|
104
|
+
<p>Sample Neptune job scripts can be found in samples. Test scripts will be
|
|
105
|
+
added to test in the next release.</p>
|
|
106
|
+
|
|
107
|
+
<p>Developed by Chris Bunch as part of the AppScale project. See <a
|
|
108
|
+
href="LICENSE.html">LICENSE</a> for the specifics of the New BSD License by
|
|
109
|
+
which Neptune is released.</p>
|
|
110
|
+
|
|
111
|
+
<p>Check us out on the web:</p>
|
|
112
|
+
|
|
113
|
+
<p><a href="http://code.google.com/p/appscale">code.google.com/p/appscale</a></p>
|
|
114
|
+
|
|
115
|
+
<p><a href="http://appscale.cs.ucsb.edu">appscale.cs.ucsb.edu</a></p>
|
|
116
|
+
|
|
117
|
+
<p>Contributors welcome! We would love to add support for other cloud
|
|
118
|
+
platforms and test out Neptune more on non-virtualized deployments, as well
|
|
119
|
+
as adding capabilities for other types of computation.</p>
|
|
120
|
+
|
|
121
|
+
<p>An academic paper describing Neptune is in the works - check in for a link
|
|
122
|
+
to that as it becomes available.</p>
|
|
123
|
+
|
|
124
|
+
<h1>end</h1>
|
|
125
|
+
|
|
126
|
+
</div>
|
|
127
|
+
|
|
128
|
+
<div id="validator-badges">
|
|
129
|
+
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
|
130
|
+
<p><small>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish
|
|
131
|
+
Rdoc Generator</a> 2</small>.</p>
|
|
132
|
+
</div>
|
|
133
|
+
</body>
|
|
134
|
+
</html>
|
|
135
|
+
|