Class: Temporalio::Internal::Worker::ActivityWorker::RunningActivity
- Inherits:
-
Activity::Context
- Object
- Activity::Context
- Temporalio::Internal::Worker::ActivityWorker::RunningActivity
- Defined in:
- lib/temporalio/internal/worker/activity_worker.rb
Instance Attribute Summary collapse
-
#_outbound_impl ⇒ Object
Returns the value of attribute _outbound_impl.
-
#_server_requested_cancel ⇒ Object
Returns the value of attribute _server_requested_cancel.
-
#cancellation ⇒ Object
readonly
Returns the value of attribute cancellation.
-
#info ⇒ Object
readonly
Returns the value of attribute info.
-
#logger ⇒ Object
readonly
Returns the value of attribute logger.
-
#payload_converter ⇒ Object
readonly
Returns the value of attribute payload_converter.
-
#worker_shutdown_cancellation ⇒ Object
readonly
Returns the value of attribute worker_shutdown_cancellation.
Instance Method Summary collapse
- #heartbeat(*details) ⇒ Object
-
#initialize(info:, cancellation:, worker_shutdown_cancellation:, payload_converter:, logger:) ⇒ RunningActivity
constructor
rubocop:disable Lint/MissingSuper.
Methods inherited from Activity::Context
current, current_or_nil, exist?
Constructor Details
#initialize(info:, cancellation:, worker_shutdown_cancellation:, payload_converter:, logger:) ⇒ RunningActivity
rubocop:disable Lint/MissingSuper
285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 |
# File 'lib/temporalio/internal/worker/activity_worker.rb', line 285 def initialize( # rubocop:disable Lint/MissingSuper info:, cancellation:, worker_shutdown_cancellation:, payload_converter:, logger: ) @info = info @cancellation = cancellation @worker_shutdown_cancellation = worker_shutdown_cancellation @payload_converter = payload_converter @logger = logger @_outbound_impl = nil @_server_requested_cancel = false end |
Instance Attribute Details
#_outbound_impl ⇒ Object
Returns the value of attribute _outbound_impl.
283 284 285 |
# File 'lib/temporalio/internal/worker/activity_worker.rb', line 283 def _outbound_impl @_outbound_impl end |
#_server_requested_cancel ⇒ Object
Returns the value of attribute _server_requested_cancel.
283 284 285 |
# File 'lib/temporalio/internal/worker/activity_worker.rb', line 283 def _server_requested_cancel @_server_requested_cancel end |
#cancellation ⇒ Object (readonly)
Returns the value of attribute cancellation.
282 283 284 |
# File 'lib/temporalio/internal/worker/activity_worker.rb', line 282 def cancellation @cancellation end |
#info ⇒ Object (readonly)
Returns the value of attribute info.
282 283 284 |
# File 'lib/temporalio/internal/worker/activity_worker.rb', line 282 def info @info end |
#logger ⇒ Object (readonly)
Returns the value of attribute logger.
282 283 284 |
# File 'lib/temporalio/internal/worker/activity_worker.rb', line 282 def logger @logger end |
#payload_converter ⇒ Object (readonly)
Returns the value of attribute payload_converter.
282 283 284 |
# File 'lib/temporalio/internal/worker/activity_worker.rb', line 282 def payload_converter @payload_converter end |
#worker_shutdown_cancellation ⇒ Object (readonly)
Returns the value of attribute worker_shutdown_cancellation.
282 283 284 |
# File 'lib/temporalio/internal/worker/activity_worker.rb', line 282 def worker_shutdown_cancellation @worker_shutdown_cancellation end |
Instance Method Details
#heartbeat(*details) ⇒ Object
301 302 303 304 305 |
# File 'lib/temporalio/internal/worker/activity_worker.rb', line 301 def heartbeat(*details) raise 'Implementation not set yet' if _outbound_impl.nil? _outbound_impl.heartbeat(Temporalio::Worker::Interceptor::HeartbeatActivityInput.new(details:)) end |