| 1 | package Eixo::Queue::Mongo; | ||||||||||
| 2 | |||||||||||
| 3 | 1 | ▶ | use strict; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 4 | |||||||||||
| 5 | 1 | ▶ | use Eixo::Base::Clase qw(Eixo::Queue); | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 6 | 1 | ▶ | use Eixo::Queue::MongoDriver; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 7 | |||||||||||
| 8 | 1 | has( | |||||||||
| 9 | |||||||||||
| 10 | mongo_driver=>undef, | ||||||||||
| 11 | |||||||||||
| 12 | db=>undef, | ||||||||||
| 13 | |||||||||||
| 14 | collection => undef, | ||||||||||
| 15 | |||||||||||
| 16 | host=>undef, | ||||||||||
| 17 | |||||||||||
| 18 | port=>undef, | ||||||||||
| 19 | |||||||||||
| 20 | ); | ||||||||||
| 21 | |||||||||||
| 22 | 1 | ▶ | sub init{ | ||||||||
|
Subroutine
init: called CC=2 SCAR=7.6
Pod
undocumented
| |||||||||||
| 23 | |||||||||||
| 24 | 1 | ▶ | $_[0]->mongo_driver( | ||||||||
|
Branch: 1 branch
| |||||||||||
| 25 | |||||||||||
| 26 | Eixo::Queue::MongoDriver->new( | ||||||||||
| 27 | |||||||||||
| 28 | db=>$_[0]->db, | ||||||||||
| 29 | |||||||||||
| 30 | host=>$_[0]->host, | ||||||||||
| 31 | |||||||||||
| 32 | port=>$_[0]->port, | ||||||||||
| 33 | |||||||||||
| 34 | collection=>$_[0]->collection | ||||||||||
| 35 | |||||||||||
| 36 | ) | ||||||||||
| 37 | |||||||||||
| 38 | ) unless($_[0]->mongo_driver); | ||||||||||
| 39 | |||||||||||
| 40 | } | ||||||||||
| 41 | |||||||||||
| 42 | 1 | ▶ | sub add{ | ||||||||
|
Subroutine
add: called CC=1 SCAR=0.0
Pod
undocumented
| |||||||||||
| 43 | |||||||||||
| 44 | 1 | $_[0]->mongo_driver->addJob($_[1]); | |||||||||
| 45 | } | ||||||||||
| 46 | |||||||||||
| 47 | 0 | ▶ | sub status{ | ||||||||
|
Subroutine
status: not called CC=1 SCAR=6.9
Pod
undocumented
| |||||||||||
| 48 | |||||||||||
| 49 | 0 | $_[0]->mongo_driver->getJob(@_[1..$#_]); | |||||||||
| 50 | |||||||||||
| 51 | } | ||||||||||
| 52 | |||||||||||
| 53 | |||||||||||
| 54 | 1 | 1; | |||||||||