Module: Rukawa

Defined in:
lib/rukawa.rb,
lib/rukawa/cli.rb,
lib/rukawa/dag.rb,
lib/rukawa/job.rb,
lib/rukawa/errors.rb,
lib/rukawa/runner.rb,
lib/rukawa/job_net.rb,
lib/rukawa/version.rb,
lib/rukawa/overview.rb,
lib/rukawa/dependency.rb,
lib/rukawa/abstract_job.rb,
lib/rukawa/configuration.rb

Defined Under Namespace

Modules: Dependency, Overview, State Classes: AbstractJob, Cli, Configuration, Dag, DependencyUnsatisfied, GraphConfig, GraphNodeConfig, Job, JobNet, Runner

Constant Summary collapse

VERSION =
"0.5.0"

Class Attribute Summary collapse

Class Method Summary collapse

Class Attribute Details

.executorObject (readonly)

Returns the value of attribute executor.



13
14
15
# File 'lib/rukawa.rb', line 13

def executor
  @executor
end

.semaphoreObject (readonly)

Returns the value of attribute semaphore.



13
14
15
# File 'lib/rukawa.rb', line 13

def semaphore
  @semaphore
end

.storeObject (readonly)

Returns the value of attribute store.



13
14
15
# File 'lib/rukawa.rb', line 13

def store
  @store
end

Class Method Details

.configObject



23
24
25
# File 'lib/rukawa.rb', line 23

def config
  Configuration.instance
end

.configure {|config| ... } ⇒ Object

Yields:



19
20
21
# File 'lib/rukawa.rb', line 19

def configure
  yield config
end

.initObject



5
6
7
8
9
10
11
12
# File 'lib/rukawa.rb', line 5

def init
  unless @initialized
    @store = Concurrent::Hash.new
    @executor = Concurrent::FixedThreadPool.new(config.concurrency)
    @semaphore = Concurrent::Semaphore.new(config.concurrency)
    @initialized = true
  end
end

.loggerObject



15
16
17
# File 'lib/rukawa.rb', line 15

def logger
  config.logger
end