Class: PostHog::NoopWorker Private

Inherits:
Object
  • Object
show all
Defined in:
lib/posthog/noop_worker.rb

Overview

This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.

A worker that doesn’t consume jobs.

Instance Method Summary collapse

Constructor Details

#initialize(queue) ⇒ NoopWorker

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns a new instance of NoopWorker.

Parameters:

  • queue (Queue)


9
10
11
# File 'lib/posthog/noop_worker.rb', line 9

def initialize(queue)
  @queue = queue
end

Instance Method Details

#is_requesting?Boolean

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

TODO: Rename to ‘requesting?` in future version

Returns:

  • (Boolean)


20
21
22
# File 'lib/posthog/noop_worker.rb', line 20

def is_requesting? # rubocop:disable Naming/PredicateName
  false
end

#runvoid

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

This method returns an undefined value.



14
15
16
# File 'lib/posthog/noop_worker.rb', line 14

def run
  # Does nothing
end

#shutdownvoid

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

This method returns an undefined value.



25
26
27
# File 'lib/posthog/noop_worker.rb', line 25

def shutdown
  # Does nothing
end