Class: Storm::BoltStats

Inherits:
Object
  • Object
show all
Includes:
Thrift::Struct, Thrift::Struct_Union
Defined in:
lib/storm/thrift/storm_types.rb

Constant Summary collapse

ACKED =
1
FAILED =
2
PROCESS_MS_AVG =
3
FIELDS =
{
  ACKED => {:type => ::Thrift::Types::MAP, :name => 'acked', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::MAP, :key => {:type => ::Thrift::Types::STRUCT, :class => GlobalStreamId}, :value => {:type => ::Thrift::Types::I64}}},
  FAILED => {:type => ::Thrift::Types::MAP, :name => 'failed', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::MAP, :key => {:type => ::Thrift::Types::STRUCT, :class => GlobalStreamId}, :value => {:type => ::Thrift::Types::I64}}},
  PROCESS_MS_AVG => {:type => ::Thrift::Types::MAP, :name => 'process_ms_avg', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::MAP, :key => {:type => ::Thrift::Types::STRUCT, :class => GlobalStreamId}, :value => {:type => ::Thrift::Types::DOUBLE}}}
}

Instance Method Summary collapse

Instance Method Details

#struct_fieldsObject



551
# File 'lib/storm/thrift/storm_types.rb', line 551

def struct_fields; FIELDS; end

#validateObject

Raises:

  • (::Thrift::ProtocolException)


553
554
555
556
557
# File 'lib/storm/thrift/storm_types.rb', line 553

def validate
  raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field acked is unset!') unless @acked
  raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field failed is unset!') unless @failed
  raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field process_ms_avg is unset!') unless @process_ms_avg
end