Class: Skywalking::Tracing::EntrySpan

Inherits:
Span
  • Object
show all
Defined in:
lib/skywalking/tracing/entry_span.rb

Instance Attribute Summary

Attributes inherited from Span

#component, #context, #end_time, #error_occurred, #inherit, #kind, #layer, #operation, #parent_id, #peer, #refs, #span_id, #stack_depth, #start_time, #tags

Instance Method Summary collapse

Methods inherited from Span

#extract, #finish?, #inject, #stop?, #tag, #tags_item

Constructor Details

#initialize(context:, span_id: -1,, parent_id: -1,, operation: nil, peer: nil, component: nil, layer: nil) ⇒ EntrySpan

Returns a new instance of EntrySpan.



21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
# File 'lib/skywalking/tracing/entry_span.rb', line 21

def initialize(
  context:,
  span_id: -1,
  parent_id: -1,
  operation: nil,
  peer: nil,
  component: nil,
  layer: nil
)
  super(context: context, span_id: span_id, parent_id: parent_id,
        operation: operation, peer: peer, kind: Kind::Entry,
        component: component, layer: layer)

  @current_max_depth = 0
end

Instance Method Details

#startObject



37
38
39
40
41
42
43
44
45
# File 'lib/skywalking/tracing/entry_span.rb', line 37

def start
  super

  @current_max_depth = @stack_depth
  @component = Component::Unknown
  @layer = Layer::Unknown
  @lags = []
  @tags = Hash.new { |hash, key| hash[key] = [] }
end