Class: Anthropic::Models::Beta::Environments::BetaSelfHostedWorkQueueStats

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/anthropic/models/beta/environments/beta_self_hosted_work_queue_stats.rb,
sig/anthropic/models/beta/environments/beta_self_hosted_work_queue_stats.rbs

Overview

See Also:

  • Anthropic::Resources::Beta::Environments::Work#stats

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, inspect, #inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize(depth:, oldest_queued_at:, pending:, workers_polling:, type: :work_queue_stats) ⇒ BetaSelfHostedWorkQueueStats

Statistics about the work queue for an environment.

Some parameter documentations has been truncated, see Anthropic::Models::Beta::Environments::BetaSelfHostedWorkQueueStats for more details.

Parameters:

  • depth (Integer) —

    Number of work items waiting to be picked up

  • oldest_queued_at (String, nil) —

    RFC 3339 timestamp of oldest item in the work stream (includes both queued and p

  • pending (Integer) —

    Number of work items being processed (polled but not acknowledged)

  • workers_polling (Integer, nil) —

    Number of workers that have polled for work in the last 30 seconds. Requires wor

  • type (Symbol, :work_queue_stats) (defaults to: :work_queue_stats) —

    The type of object

  • depth: (Integer)
  • oldest_queued_at: (String, nil)
  • pending: (Integer)
  • workers_polling: (Integer, nil)
  • type: (:work_queue_stats) (defaults to: :work_queue_stats)


# File 'lib/anthropic/models/beta/environments/beta_self_hosted_work_queue_stats.rb', line 41

Instance Attribute Details

#depth ⇒ Integer

Number of work items waiting to be picked up

Parameters:

  • value (Integer)

Returns:

  • (Integer)


13
# File 'lib/anthropic/models/beta/environments/beta_self_hosted_work_queue_stats.rb', line 13

required :depth, Integer

#oldest_queued_at ⇒ String?

RFC 3339 timestamp of oldest item in the work stream (includes both queued and pending items), null if stream empty

Parameters:

  • value (String, nil)

Returns:

  • (String, nil)


20
# File 'lib/anthropic/models/beta/environments/beta_self_hosted_work_queue_stats.rb', line 20

required :oldest_queued_at, String, nil?: true

#pending ⇒ Integer

Number of work items being processed (polled but not acknowledged)

Parameters:

  • value (Integer)

Returns:

  • (Integer)


26
# File 'lib/anthropic/models/beta/environments/beta_self_hosted_work_queue_stats.rb', line 26

required :pending, Integer

#type ⇒ Symbol, :work_queue_stats

The type of object

Parameters:

  • value (:work_queue_stats)

Returns:

  • (Symbol, :work_queue_stats)


32
# File 'lib/anthropic/models/beta/environments/beta_self_hosted_work_queue_stats.rb', line 32

required :type, const: :work_queue_stats

#workers_polling ⇒ Integer?

Number of workers that have polled for work in the last 30 seconds. Requires worker_id to be sent with poll requests.

Parameters:

  • value (Integer, nil)

Returns:

  • (Integer, nil)


39
# File 'lib/anthropic/models/beta/environments/beta_self_hosted_work_queue_stats.rb', line 39

required :workers_polling, Integer, nil?: true

Instance Method Details

#to_hash ⇒ { depth: Integer, oldest_queued_at: String?, pending: Integer, type: :work_queue_stats, workers_polling: Integer? }

Returns:

  • ({ depth: Integer, oldest_queued_at: String?, pending: Integer, type: :work_queue_stats, workers_polling: Integer? })


33
34
35
36
37
38
39
# File 'sig/anthropic/models/beta/environments/beta_self_hosted_work_queue_stats.rbs', line 33

def to_hash: -> {
  depth: Integer,
  oldest_queued_at: String?,
  pending: Integer,
  type: :work_queue_stats,
  workers_polling: Integer?
}