Skip to content

lifetime_pb2

frequenz.api.common.v1.microgrid.lifetime_pb2 ¤

Generated protocol buffer code.

Classes¤

frequenz.api.common.v1.microgrid.lifetime_pb2.Lifetime ¤

Bases: Message

Lifetime captures the timestamps indicating the active operational period of a microgrid asset, such as a component, connection, sensor, or any other entity with a limited operational lifetime.

It is normally used to track the historical evolution of assets, and it determines the validity period for the asset's data.

If the start_timestamp is not set, the asset is considered to be in operation since the beginning of the system's operational history.

If the end_timestamp is not set, the asset is considered to be in operation indefinitely into the future.

If the Lifetime message is completely missing, it means both timestamps are not set, which means the asset is considered to be in operation since the beginning of the system's operational history and indefinitely into the future.

Source code in frequenz/api/common/v1/microgrid/lifetime_pb2.py
# @@protoc_insertion_point(imports)

_sym_db = _symbol_database.Default()


from google.protobuf import timestamp_pb2 as google_dot_protobuf_dot_timestamp__pb2


DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n/frequenz/api/common/v1/microgrid/lifetime.proto\x12 frequenz.api.common.v1.microgrid\x1a\x1fgoogle/protobuf/timestamp.proto\"r\n\x08Lifetime\x12\x33\n\x0fstart_timestamp\x18\x01 \x01(\x0b\x32\x1a.google.protobuf.Timestamp\x12\x31\n\rend_timestamp\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.Timestampb\x06proto3')

_globals = globals()
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'frequenz.api.common.v1.microgrid.lifetime_pb2', _globals)
if not _descriptor._USE_C_DESCRIPTORS:
  DESCRIPTOR._loaded_options = None
  _globals['_LIFETIME']._serialized_start=118
  _globals['_LIFETIME']._serialized_end=232
# @@protoc_insertion_point(module_scope)
Attributes¤
end_timestamp property ¤

Optional timestamp when the asset's operational activity ceased. If not set, the asset is considered to be in operation indefinitely into the future.

start_timestamp property ¤

The timestamp when the asset became operationally active. If not set, the asset is considered to be in operation since the beginning of the system's operational history.