tango-etl 0.0.1 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (44) hide show
  1. checksums.yaml +4 -4
  2. data/{changelog.md → CHANGELOG.md} +5 -1
  3. data/{readme.md → README.md} +1 -1
  4. data/doc/Multidb/Balancer.html +202 -0
  5. data/doc/Multidb.html +184 -0
  6. data/doc/Tango/AbstractModel.html +608 -0
  7. data/doc/Tango/App.html +1334 -0
  8. data/doc/Tango/DatabaseLocker.html +541 -0
  9. data/doc/Tango/ETL/Dispatcher.html +465 -0
  10. data/doc/Tango/ETL/HandlerInterface.html +639 -0
  11. data/doc/Tango/ETL/OperatorInterface.html +494 -0
  12. data/doc/Tango/ETL.html +117 -0
  13. data/doc/Tango/Kernel.html +432 -0
  14. data/doc/Tango/LinkStack.html +737 -0
  15. data/doc/Tango/Resource/Buffer.html +565 -0
  16. data/doc/Tango/Resource/Cache.html +834 -0
  17. data/doc/Tango/Resource.html +117 -0
  18. data/doc/Tango.html +131 -0
  19. data/doc/_index.html +297 -0
  20. data/doc/class_list.html +54 -0
  21. data/doc/css/common.css +1 -0
  22. data/doc/css/full_list.css +57 -0
  23. data/doc/css/style.css +339 -0
  24. data/doc/file.README.html +80 -0
  25. data/doc/file_list.html +56 -0
  26. data/doc/frames.html +26 -0
  27. data/doc/index.html +80 -0
  28. data/doc/js/app.js +219 -0
  29. data/doc/js/full_list.js +178 -0
  30. data/doc/js/jquery.js +4 -0
  31. data/doc/method_list.html +365 -0
  32. data/doc/top-level-namespace.html +112 -0
  33. data/lib/tango/abstract_model.rb +1 -0
  34. data/lib/tango/app.rb +4 -7
  35. data/lib/tango/database_locker.rb +23 -2
  36. data/lib/tango/etl/handler_interface.rb +12 -6
  37. data/lib/tango/resource/buffer.rb +7 -7
  38. data/lib/tango/resource/cache.rb +18 -13
  39. data/lib/tango/version.rb +1 -1
  40. data/test/support/lib/simple_handler.rb +5 -14
  41. data/test/unit/etl/test_dispatcher.rb +21 -5
  42. metadata +33 -6
  43. data/config/app.yml.sample +0 -6
  44. data/config/database.yml.sample +0 -27
@@ -0,0 +1,608 @@
1
+ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
2
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3
+ <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
+ <head>
5
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6
+ <title>
7
+ Class: Tango::AbstractModel
8
+
9
+ &mdash; Documentation by YARD 0.8.7.4
10
+
11
+ </title>
12
+
13
+ <link rel="stylesheet" href="../css/style.css" type="text/css" charset="utf-8" />
14
+
15
+ <link rel="stylesheet" href="../css/common.css" type="text/css" charset="utf-8" />
16
+
17
+ <script type="text/javascript" charset="utf-8">
18
+ hasFrames = window.top.frames.main ? true : false;
19
+ relpath = '../';
20
+ framesUrl = "../frames.html#!Tango/AbstractModel.html";
21
+ </script>
22
+
23
+
24
+ <script type="text/javascript" charset="utf-8" src="../js/jquery.js"></script>
25
+
26
+ <script type="text/javascript" charset="utf-8" src="../js/app.js"></script>
27
+
28
+
29
+ </head>
30
+ <body>
31
+ <div id="header">
32
+ <div id="menu">
33
+
34
+ <a href="../_index.html">Index (A)</a> &raquo;
35
+ <span class='title'><span class='object_link'><a href="../Tango.html" title="Tango (module)">Tango</a></span></span>
36
+ &raquo;
37
+ <span class="title">AbstractModel</span>
38
+
39
+
40
+ <div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
41
+ </div>
42
+
43
+ <div id="search">
44
+
45
+ <a class="full_list_link" id="class_list_link"
46
+ href="../class_list.html">
47
+ Class List
48
+ </a>
49
+
50
+ <a class="full_list_link" id="method_list_link"
51
+ href="../method_list.html">
52
+ Method List
53
+ </a>
54
+
55
+ <a class="full_list_link" id="file_list_link"
56
+ href="../file_list.html">
57
+ File List
58
+ </a>
59
+
60
+ </div>
61
+ <div class="clear"></div>
62
+ </div>
63
+
64
+ <iframe id="search_frame"></iframe>
65
+
66
+ <div id="content"><h1>Class: Tango::AbstractModel
67
+
68
+
69
+
70
+ </h1>
71
+
72
+ <dl class="box">
73
+
74
+ <dt class="r1">Inherits:</dt>
75
+ <dd class="r1">
76
+ <span class="inheritName">ActiveRecord::Base</span>
77
+
78
+ <ul class="fullTree">
79
+ <li>Object</li>
80
+
81
+ <li class="next">ActiveRecord::Base</li>
82
+
83
+ <li class="next">Tango::AbstractModel</li>
84
+
85
+ </ul>
86
+ <a href="#" class="inheritanceTree">show all</a>
87
+
88
+ </dd>
89
+
90
+
91
+
92
+
93
+
94
+
95
+
96
+
97
+
98
+ <dt class="r2 last">Defined in:</dt>
99
+ <dd class="r2 last">lib/tango/abstract_model.rb</dd>
100
+
101
+ </dl>
102
+ <div class="clear"></div>
103
+
104
+ <h2>Overview</h2><div class="docstring">
105
+ <div class="discussion">
106
+
107
+ <p>Base model for Tango resources</p>
108
+
109
+
110
+ </div>
111
+ </div>
112
+ <div class="tags">
113
+
114
+ <p class="tag_title">Author:</p>
115
+ <ul class="author">
116
+
117
+ <li>
118
+
119
+
120
+
121
+
122
+
123
+ <div class='inline'>
124
+ <p>Mckomo</p>
125
+ </div>
126
+
127
+ </li>
128
+
129
+ </ul>
130
+
131
+ </div>
132
+
133
+
134
+
135
+
136
+
137
+
138
+
139
+ <h2>
140
+ Class Method Summary
141
+ <small>(<a href="#" class="summary_toggle">collapse</a>)</small>
142
+ </h2>
143
+
144
+ <ul class="summary">
145
+
146
+ <li class="public ">
147
+ <span class="summary_signature">
148
+
149
+ <a href="#next_id-class_method" title="next_id (class method)">+ (Integer) <strong>next_id</strong> </a>
150
+
151
+
152
+
153
+ </span>
154
+
155
+
156
+
157
+
158
+
159
+
160
+
161
+
162
+
163
+ <span class="summary_desc"><div class='inline'>
164
+ <p>Return incremented value of last id in the model&#39;s table.</p>
165
+ </div></span>
166
+
167
+ </li>
168
+
169
+
170
+ <li class="public ">
171
+ <span class="summary_signature">
172
+
173
+ <a href="#persistent%3F-class_method" title="persistent? (class method)">+ (Boolean) <strong>persistent?</strong> </a>
174
+
175
+
176
+
177
+ </span>
178
+
179
+
180
+
181
+
182
+
183
+
184
+
185
+
186
+
187
+ <span class="summary_desc"><div class='inline'>
188
+ <p>State wether model should be cached or not.</p>
189
+ </div></span>
190
+
191
+ </li>
192
+
193
+
194
+ <li class="public ">
195
+ <span class="summary_signature">
196
+
197
+ <a href="#properties-class_method" title="properties (class method)">+ (Array) <strong>properties</strong> </a>
198
+
199
+
200
+
201
+ </span>
202
+
203
+
204
+
205
+
206
+
207
+
208
+
209
+
210
+
211
+ <span class="summary_desc"><div class='inline'>
212
+ <p>Return array with names of model properties.</p>
213
+ </div></span>
214
+
215
+ </li>
216
+
217
+
218
+ </ul>
219
+
220
+ <h2>
221
+ Instance Method Summary
222
+ <small>(<a href="#" class="summary_toggle">collapse</a>)</small>
223
+ </h2>
224
+
225
+ <ul class="summary">
226
+
227
+ <li class="public ">
228
+ <span class="summary_signature">
229
+
230
+ <a href="#cache_key-instance_method" title="#cache_key (instance method)">- (Object) <strong>cache_key</strong> </a>
231
+
232
+
233
+
234
+ </span>
235
+
236
+
237
+
238
+
239
+
240
+
241
+
242
+
243
+
244
+ <span class="summary_desc"><div class='inline'>
245
+ <p>Return cache key of model instance.</p>
246
+ </div></span>
247
+
248
+ </li>
249
+
250
+
251
+ <li class="public ">
252
+ <span class="summary_signature">
253
+
254
+ <a href="#values-instance_method" title="#values (instance method)">- (Array) <strong>values</strong> </a>
255
+
256
+
257
+
258
+ </span>
259
+
260
+
261
+
262
+
263
+
264
+
265
+
266
+
267
+
268
+ <span class="summary_desc"><div class='inline'>
269
+ <p>Return array with values of model properties.</p>
270
+ </div></span>
271
+
272
+ </li>
273
+
274
+
275
+ </ul>
276
+
277
+
278
+
279
+
280
+
281
+ <div id="class_method_details" class="method_details_list">
282
+ <h2>Class Method Details</h2>
283
+
284
+
285
+ <div class="method_details first">
286
+ <h3 class="signature first" id="next_id-class_method">
287
+
288
+ + (<tt>Integer</tt>) <strong>next_id</strong>
289
+
290
+
291
+
292
+
293
+
294
+ </h3><div class="docstring">
295
+ <div class="discussion">
296
+
297
+ <p>Return incremented value of last id in the model&#39;s table</p>
298
+
299
+
300
+ </div>
301
+ </div>
302
+ <div class="tags">
303
+
304
+ <p class="tag_title">Returns:</p>
305
+ <ul class="return">
306
+
307
+ <li>
308
+
309
+
310
+ <span class='type'>(<tt>Integer</tt>)</span>
311
+
312
+
313
+
314
+ </li>
315
+
316
+ </ul>
317
+
318
+ </div><table class="source_code">
319
+ <tr>
320
+ <td>
321
+ <pre class="lines">
322
+
323
+
324
+ 38
325
+ 39
326
+ 40
327
+ 41</pre>
328
+ </td>
329
+ <td>
330
+ <pre class="code"><span class="info file"># File 'lib/tango/abstract_model.rb', line 38</span>
331
+
332
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_next_id'>next_id</span>
333
+ <span class='ivar'>@last_id</span> <span class='op'>||=</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_pluck'>pluck</span><span class='lparen'>(</span> <span class='symbol'>:id</span> <span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_last'>last</span> <span class='op'>||</span> <span class='int'>0</span>
334
+ <span class='ivar'>@last_id</span> <span class='op'>+=</span> <span class='int'>1</span>
335
+ <span class='kw'>end</span></pre>
336
+ </td>
337
+ </tr>
338
+ </table>
339
+ </div>
340
+
341
+ <div class="method_details ">
342
+ <h3 class="signature " id="persistent?-class_method">
343
+
344
+ + (<tt>Boolean</tt>) <strong>persistent?</strong>
345
+
346
+
347
+
348
+
349
+
350
+ </h3><div class="docstring">
351
+ <div class="discussion">
352
+
353
+ <div class="note notetag">
354
+ <strong>Note:</strong>
355
+ <div class='inline'>
356
+ <p>If model is not persistent, model&#39;s table will be truncated</p>
357
+ </div>
358
+ </div>
359
+
360
+
361
+ <p>State wether model should be cached or not</p>
362
+
363
+
364
+ </div>
365
+ </div>
366
+ <div class="tags">
367
+
368
+ <p class="tag_title">Returns:</p>
369
+ <ul class="return">
370
+
371
+ <li>
372
+
373
+
374
+ <span class='type'>(<tt>Boolean</tt>)</span>
375
+
376
+
377
+
378
+ </li>
379
+
380
+ </ul>
381
+ <p class="tag_title">Raises:</p>
382
+ <ul class="raise">
383
+
384
+ <li>
385
+
386
+
387
+ <span class='type'>(<tt>NotImplementedError</tt>)</span>
388
+
389
+
390
+
391
+ </li>
392
+
393
+ </ul>
394
+
395
+ </div><table class="source_code">
396
+ <tr>
397
+ <td>
398
+ <pre class="lines">
399
+
400
+
401
+ 47
402
+ 48
403
+ 49</pre>
404
+ </td>
405
+ <td>
406
+ <pre class="code"><span class="info file"># File 'lib/tango/abstract_model.rb', line 47</span>
407
+
408
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_persistent?'>persistent?</span>
409
+ <span class='id identifier rubyid_raise'>raise</span> <span class='const'>NotImplementedError</span>
410
+ <span class='kw'>end</span></pre>
411
+ </td>
412
+ </tr>
413
+ </table>
414
+ </div>
415
+
416
+ <div class="method_details ">
417
+ <h3 class="signature " id="properties-class_method">
418
+
419
+ + (<tt>Array</tt>) <strong>properties</strong>
420
+
421
+
422
+
423
+
424
+
425
+ </h3><div class="docstring">
426
+ <div class="discussion">
427
+
428
+ <p>Return array with names of model properties</p>
429
+
430
+
431
+ </div>
432
+ </div>
433
+ <div class="tags">
434
+
435
+ <p class="tag_title">Returns:</p>
436
+ <ul class="return">
437
+
438
+ <li>
439
+
440
+
441
+ <span class='type'>(<tt>Array</tt>)</span>
442
+
443
+
444
+
445
+ </li>
446
+
447
+ </ul>
448
+
449
+ </div><table class="source_code">
450
+ <tr>
451
+ <td>
452
+ <pre class="lines">
453
+
454
+
455
+ 31
456
+ 32
457
+ 33</pre>
458
+ </td>
459
+ <td>
460
+ <pre class="code"><span class="info file"># File 'lib/tango/abstract_model.rb', line 31</span>
461
+
462
+ <span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_properties'>properties</span>
463
+ <span class='ivar'>@properties</span> <span class='op'>||</span> <span class='ivar'>@properties</span> <span class='op'>=</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_attribute_names'>attribute_names</span><span class='period'>.</span><span class='id identifier rubyid_map'>map</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id identifier rubyid_a'>a</span><span class='op'>|</span> <span class='id identifier rubyid_a'>a</span><span class='period'>.</span><span class='id identifier rubyid_to_sym'>to_sym</span> <span class='rbrace'>}</span>
464
+ <span class='kw'>end</span></pre>
465
+ </td>
466
+ </tr>
467
+ </table>
468
+ </div>
469
+
470
+ </div>
471
+
472
+ <div id="instance_method_details" class="method_details_list">
473
+ <h2>Instance Method Details</h2>
474
+
475
+
476
+ <div class="method_details first">
477
+ <h3 class="signature first" id="cache_key-instance_method">
478
+
479
+ - (<tt>Object</tt>) <strong>cache_key</strong>
480
+
481
+
482
+
483
+
484
+
485
+ </h3><div class="docstring">
486
+ <div class="discussion">
487
+
488
+ <p>Return cache key of model instance</p>
489
+
490
+
491
+ </div>
492
+ </div>
493
+ <div class="tags">
494
+
495
+ <p class="tag_title">Returns:</p>
496
+ <ul class="return">
497
+
498
+ <li>
499
+
500
+
501
+ <span class='type'>(<tt>Object</tt>)</span>
502
+
503
+
504
+
505
+ </li>
506
+
507
+ </ul>
508
+ <p class="tag_title">Raises:</p>
509
+ <ul class="raise">
510
+
511
+ <li>
512
+
513
+
514
+ <span class='type'>(<tt>NotImplementedError</tt>)</span>
515
+
516
+
517
+
518
+ </li>
519
+
520
+ </ul>
521
+
522
+ </div><table class="source_code">
523
+ <tr>
524
+ <td>
525
+ <pre class="lines">
526
+
527
+
528
+ 24
529
+ 25
530
+ 26</pre>
531
+ </td>
532
+ <td>
533
+ <pre class="code"><span class="info file"># File 'lib/tango/abstract_model.rb', line 24</span>
534
+
535
+ <span class='kw'>def</span> <span class='id identifier rubyid_cache_key'>cache_key</span>
536
+ <span class='id identifier rubyid_raise'>raise</span> <span class='const'>NotImplementedError</span>
537
+ <span class='kw'>end</span></pre>
538
+ </td>
539
+ </tr>
540
+ </table>
541
+ </div>
542
+
543
+ <div class="method_details ">
544
+ <h3 class="signature " id="values-instance_method">
545
+
546
+ - (<tt>Array</tt>) <strong>values</strong>
547
+
548
+
549
+
550
+
551
+
552
+ </h3><div class="docstring">
553
+ <div class="discussion">
554
+
555
+ <p>Return array with values of model properties</p>
556
+
557
+
558
+ </div>
559
+ </div>
560
+ <div class="tags">
561
+
562
+ <p class="tag_title">Returns:</p>
563
+ <ul class="return">
564
+
565
+ <li>
566
+
567
+
568
+ <span class='type'>(<tt>Array</tt>)</span>
569
+
570
+
571
+
572
+ </li>
573
+
574
+ </ul>
575
+
576
+ </div><table class="source_code">
577
+ <tr>
578
+ <td>
579
+ <pre class="lines">
580
+
581
+
582
+ 17
583
+ 18
584
+ 19</pre>
585
+ </td>
586
+ <td>
587
+ <pre class="code"><span class="info file"># File 'lib/tango/abstract_model.rb', line 17</span>
588
+
589
+ <span class='kw'>def</span> <span class='id identifier rubyid_values'>values</span>
590
+ <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_attributes'>attributes</span><span class='period'>.</span><span class='id identifier rubyid_values'>values</span>
591
+ <span class='kw'>end</span></pre>
592
+ </td>
593
+ </tr>
594
+ </table>
595
+ </div>
596
+
597
+ </div>
598
+
599
+ </div>
600
+
601
+ <div id="footer">
602
+ Generated on Tue Apr 15 02:47:42 2014 by
603
+ <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
604
+ 0.8.7.4 (ruby-2.0.0).
605
+ </div>
606
+
607
+ </body>
608
+ </html>