java.lang.Object
com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessage
com.google.protobuf.GeneratedMessage
io.opentelemetry.proto.profiles.v1development.Profile
All Implemented Interfaces:
com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, ProfileOrBuilder, Serializable

@Generated public final class Profile extends com.google.protobuf.GeneratedMessage implements ProfileOrBuilder
 Represents a complete profile, including sample types, samples, mappings to
 binaries, stacks, locations, functions, string table, and additional
 metadata. It modifies and annotates pprof Profile with OpenTelemetry
 specific fields.

 Note that whilst fields in this message retain the name and field id from pprof in most cases
 for ease of understanding data migration, it is not intended that pprof:Profile and
 OpenTelemetry:Profile encoding be wire compatible.
 
Protobuf type opentelemetry.proto.profiles.v1development.Profile
See Also:
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static final class 
    Represents a complete profile, including sample types, samples, mappings to binaries, stacks, locations, functions, string table, and additional metadata.

    Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessage

    com.google.protobuf.GeneratedMessage.ExtendableBuilder<MessageT extends com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT>,BuilderT extends com.google.protobuf.GeneratedMessage.ExtendableBuilder<MessageT,BuilderT>>, com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT extends com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessage.ExtendableMessageOrBuilder<MessageT extends com.google.protobuf.GeneratedMessage.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessage.FieldAccessorTable, com.google.protobuf.GeneratedMessage.GeneratedExtension<ContainingT extends com.google.protobuf.Message,T extends Object>, com.google.protobuf.GeneratedMessage.UnusedPrivateParameter

    Nested classes/interfaces inherited from class com.google.protobuf.AbstractMessage

    com.google.protobuf.AbstractMessage.BuilderParent

    Nested classes/interfaces inherited from class com.google.protobuf.AbstractMessageLite

    com.google.protobuf.AbstractMessageLite.InternalOneOfEnum
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final int
     
    static final int
     
    static final int
     
    static final int
     
    static final int
     
    static final int
     
    static final int
     
    static final int
     
    static final int
     
    static final int
     
    static final int
     
    static final int
     

    Fields inherited from class com.google.protobuf.GeneratedMessage

    alwaysUseFieldBuilders, loggedPre22TypeNames, unknownFields

    Fields inherited from class com.google.protobuf.AbstractMessage

    memoizedSize

    Fields inherited from class com.google.protobuf.AbstractMessageLite

    memoizedHashCode
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
     
    int
    References to attributes in attribute_table.
    int
    References to attributes in attribute_table.
    References to attributes in attribute_table.
    int
    Free-form text associated with the profile.
    int
    Free-form text associated with the profile.
    Free-form text associated with the profile.
    static Profile
     
     
    static final com.google.protobuf.Descriptors.Descriptor
     
    int
    dropped_attributes_count is the number of attributes that were discarded.
    long
    Duration of the profile, if a duration makes sense.
    com.google.protobuf.ByteString
    Original payload can be stored in this field.
    Specifies format of the original payload.
    com.google.protobuf.ByteString
    Specifies format of the original payload.
    com.google.protobuf.Parser<Profile>
     
    long
    The number of events between sampled occurrences.
    The kind of events between sampled occurrences.
    The kind of events between sampled occurrences.
    com.google.protobuf.ByteString
    A globally unique identifier for a profile.
    getSample(int index)
    The set of samples recorded in this profile.
    int
    The set of samples recorded in this profile.
    The set of samples recorded in this profile.
    getSampleOrBuilder(int index)
    The set of samples recorded in this profile.
    The set of samples recorded in this profile.
    The type and unit of all Sample.values in this profile.
    The type and unit of all Sample.values in this profile.
    int
     
    long
    Time of collection (UTC) represented as nanoseconds past the epoch.
    int
     
    boolean
    The kind of events between sampled occurrences.
    boolean
    The type and unit of all Sample.values in this profile.
    protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
     
    final boolean
     
     
    newBuilder(Profile prototype)
     
     
    protected Profile.Builder
    newBuilderForType(com.google.protobuf.AbstractMessage.BuilderParent parent)
     
    static Profile
     
    static Profile
    parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
     
    static Profile
    parseFrom(byte[] data)
     
    static Profile
    parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
     
    static Profile
    parseFrom(com.google.protobuf.ByteString data)
     
    static Profile
    parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
     
    static Profile
    parseFrom(com.google.protobuf.CodedInputStream input)
     
    static Profile
    parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
     
    static Profile
     
    static Profile
    parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
     
    static Profile
     
    static Profile
    parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
     
    static com.google.protobuf.Parser<Profile>
     
     
    void
    writeTo(com.google.protobuf.CodedOutputStream output)
     

    Methods inherited from class com.google.protobuf.GeneratedMessage

    canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, isStringEmpty, makeExtensionsImmutable, makeMutableCopy, makeMutableCopy, mergeFromAndMakeImmutableInternal, newFileScopedGeneratedExtension, newInstance, newMessageScopedGeneratedExtension, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTag

    Methods inherited from class com.google.protobuf.AbstractMessage

    findInitializationErrors, getInitializationErrorString, hashFields, toString

    Methods inherited from class com.google.protobuf.AbstractMessageLite

    addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeTo

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait

    Methods inherited from interface com.google.protobuf.MessageLite

    toByteArray, toByteString, writeDelimitedTo, writeTo

    Methods inherited from interface com.google.protobuf.MessageOrBuilder

    findInitializationErrors, getAllFields, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
  • Field Details

    • SAMPLE_TYPE_FIELD_NUMBER

      public static final int SAMPLE_TYPE_FIELD_NUMBER
      See Also:
    • SAMPLE_FIELD_NUMBER

      public static final int SAMPLE_FIELD_NUMBER
      See Also:
    • TIME_UNIX_NANO_FIELD_NUMBER

      public static final int TIME_UNIX_NANO_FIELD_NUMBER
      See Also:
    • DURATION_NANO_FIELD_NUMBER

      public static final int DURATION_NANO_FIELD_NUMBER
      See Also:
    • PERIOD_TYPE_FIELD_NUMBER

      public static final int PERIOD_TYPE_FIELD_NUMBER
      See Also:
    • PERIOD_FIELD_NUMBER

      public static final int PERIOD_FIELD_NUMBER
      See Also:
    • COMMENT_STRINDICES_FIELD_NUMBER

      public static final int COMMENT_STRINDICES_FIELD_NUMBER
      See Also:
    • PROFILE_ID_FIELD_NUMBER

      public static final int PROFILE_ID_FIELD_NUMBER
      See Also:
    • DROPPED_ATTRIBUTES_COUNT_FIELD_NUMBER

      public static final int DROPPED_ATTRIBUTES_COUNT_FIELD_NUMBER
      See Also:
    • ORIGINAL_PAYLOAD_FORMAT_FIELD_NUMBER

      public static final int ORIGINAL_PAYLOAD_FORMAT_FIELD_NUMBER
      See Also:
    • ORIGINAL_PAYLOAD_FIELD_NUMBER

      public static final int ORIGINAL_PAYLOAD_FIELD_NUMBER
      See Also:
    • ATTRIBUTE_INDICES_FIELD_NUMBER

      public static final int ATTRIBUTE_INDICES_FIELD_NUMBER
      See Also:
  • Method Details

    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage
    • hasSampleType

      public boolean hasSampleType()
       The type and unit of all Sample.values in this profile.
       For a cpu or off-cpu profile this might be:
       ["cpu","nanoseconds"] or ["off_cpu","nanoseconds"]
       For a heap profile, this might be:
       ["allocated_objects","count"] or ["allocated_space","bytes"],
       
      .opentelemetry.proto.profiles.v1development.ValueType sample_type = 1;
      Specified by:
      hasSampleType in interface ProfileOrBuilder
      Returns:
      Whether the sampleType field is set.
    • getSampleType

      public ValueType getSampleType()
       The type and unit of all Sample.values in this profile.
       For a cpu or off-cpu profile this might be:
       ["cpu","nanoseconds"] or ["off_cpu","nanoseconds"]
       For a heap profile, this might be:
       ["allocated_objects","count"] or ["allocated_space","bytes"],
       
      .opentelemetry.proto.profiles.v1development.ValueType sample_type = 1;
      Specified by:
      getSampleType in interface ProfileOrBuilder
      Returns:
      The sampleType.
    • getSampleTypeOrBuilder

      public ValueTypeOrBuilder getSampleTypeOrBuilder()
       The type and unit of all Sample.values in this profile.
       For a cpu or off-cpu profile this might be:
       ["cpu","nanoseconds"] or ["off_cpu","nanoseconds"]
       For a heap profile, this might be:
       ["allocated_objects","count"] or ["allocated_space","bytes"],
       
      .opentelemetry.proto.profiles.v1development.ValueType sample_type = 1;
      Specified by:
      getSampleTypeOrBuilder in interface ProfileOrBuilder
    • getSampleList

      public List<Sample> getSampleList()
       The set of samples recorded in this profile.
       
      repeated .opentelemetry.proto.profiles.v1development.Sample sample = 2;
      Specified by:
      getSampleList in interface ProfileOrBuilder
    • getSampleOrBuilderList

      public List<? extends SampleOrBuilder> getSampleOrBuilderList()
       The set of samples recorded in this profile.
       
      repeated .opentelemetry.proto.profiles.v1development.Sample sample = 2;
      Specified by:
      getSampleOrBuilderList in interface ProfileOrBuilder
    • getSampleCount

      public int getSampleCount()
       The set of samples recorded in this profile.
       
      repeated .opentelemetry.proto.profiles.v1development.Sample sample = 2;
      Specified by:
      getSampleCount in interface ProfileOrBuilder
    • getSample

      public Sample getSample(int index)
       The set of samples recorded in this profile.
       
      repeated .opentelemetry.proto.profiles.v1development.Sample sample = 2;
      Specified by:
      getSample in interface ProfileOrBuilder
    • getSampleOrBuilder

      public SampleOrBuilder getSampleOrBuilder(int index)
       The set of samples recorded in this profile.
       
      repeated .opentelemetry.proto.profiles.v1development.Sample sample = 2;
      Specified by:
      getSampleOrBuilder in interface ProfileOrBuilder
    • getTimeUnixNano

      public long getTimeUnixNano()
       Time of collection (UTC) represented as nanoseconds past the epoch.
       
      fixed64 time_unix_nano = 3;
      Specified by:
      getTimeUnixNano in interface ProfileOrBuilder
      Returns:
      The timeUnixNano.
    • getDurationNano

      public long getDurationNano()
       Duration of the profile, if a duration makes sense.
       
      uint64 duration_nano = 4;
      Specified by:
      getDurationNano in interface ProfileOrBuilder
      Returns:
      The durationNano.
    • hasPeriodType

      public boolean hasPeriodType()
       The kind of events between sampled occurrences.
       e.g [ "cpu","cycles" ] or [ "heap","bytes" ]
       
      .opentelemetry.proto.profiles.v1development.ValueType period_type = 5;
      Specified by:
      hasPeriodType in interface ProfileOrBuilder
      Returns:
      Whether the periodType field is set.
    • getPeriodType

      public ValueType getPeriodType()
       The kind of events between sampled occurrences.
       e.g [ "cpu","cycles" ] or [ "heap","bytes" ]
       
      .opentelemetry.proto.profiles.v1development.ValueType period_type = 5;
      Specified by:
      getPeriodType in interface ProfileOrBuilder
      Returns:
      The periodType.
    • getPeriodTypeOrBuilder

      public ValueTypeOrBuilder getPeriodTypeOrBuilder()
       The kind of events between sampled occurrences.
       e.g [ "cpu","cycles" ] or [ "heap","bytes" ]
       
      .opentelemetry.proto.profiles.v1development.ValueType period_type = 5;
      Specified by:
      getPeriodTypeOrBuilder in interface ProfileOrBuilder
    • getPeriod

      public long getPeriod()
       The number of events between sampled occurrences.
       
      int64 period = 6;
      Specified by:
      getPeriod in interface ProfileOrBuilder
      Returns:
      The period.
    • getCommentStrindicesList

      public List<Integer> getCommentStrindicesList()
       Free-form text associated with the profile. The text is displayed as is
       to the user by the tools that read profiles (e.g. by pprof). This field
       should not be used to store any machine-readable information, it is only
       for human-friendly content. The profile must stay functional if this field
       is cleaned.
       
      repeated int32 comment_strindices = 7;
      Specified by:
      getCommentStrindicesList in interface ProfileOrBuilder
      Returns:
      A list containing the commentStrindices.
    • getCommentStrindicesCount

      public int getCommentStrindicesCount()
       Free-form text associated with the profile. The text is displayed as is
       to the user by the tools that read profiles (e.g. by pprof). This field
       should not be used to store any machine-readable information, it is only
       for human-friendly content. The profile must stay functional if this field
       is cleaned.
       
      repeated int32 comment_strindices = 7;
      Specified by:
      getCommentStrindicesCount in interface ProfileOrBuilder
      Returns:
      The count of commentStrindices.
    • getCommentStrindices

      public int getCommentStrindices(int index)
       Free-form text associated with the profile. The text is displayed as is
       to the user by the tools that read profiles (e.g. by pprof). This field
       should not be used to store any machine-readable information, it is only
       for human-friendly content. The profile must stay functional if this field
       is cleaned.
       
      repeated int32 comment_strindices = 7;
      Specified by:
      getCommentStrindices in interface ProfileOrBuilder
      Parameters:
      index - The index of the element to return.
      Returns:
      The commentStrindices at the given index.
    • getProfileId

      public com.google.protobuf.ByteString getProfileId()
       A globally unique identifier for a profile. The ID is a 16-byte array. An ID with
       all zeroes is considered invalid. It may be used for deduplication and signal
       correlation purposes. It is acceptable to treat two profiles with different values
       in this field as not equal, even if they represented the same object at an earlier
       time.
       This field is optional; an ID may be assigned to an ID-less profile in a later step.
       
      bytes profile_id = 8;
      Specified by:
      getProfileId in interface ProfileOrBuilder
      Returns:
      The profileId.
    • getDroppedAttributesCount

      public int getDroppedAttributesCount()
       dropped_attributes_count is the number of attributes that were discarded. Attributes
       can be discarded because their keys are too long or because there are too many
       attributes. If this value is 0, then no attributes were dropped.
       
      uint32 dropped_attributes_count = 9;
      Specified by:
      getDroppedAttributesCount in interface ProfileOrBuilder
      Returns:
      The droppedAttributesCount.
    • getOriginalPayloadFormat

      public String getOriginalPayloadFormat()
       Specifies format of the original payload. Common values are defined in semantic conventions. [required if original_payload is present]
       
      string original_payload_format = 10;
      Specified by:
      getOriginalPayloadFormat in interface ProfileOrBuilder
      Returns:
      The originalPayloadFormat.
    • getOriginalPayloadFormatBytes

      public com.google.protobuf.ByteString getOriginalPayloadFormatBytes()
       Specifies format of the original payload. Common values are defined in semantic conventions. [required if original_payload is present]
       
      string original_payload_format = 10;
      Specified by:
      getOriginalPayloadFormatBytes in interface ProfileOrBuilder
      Returns:
      The bytes for originalPayloadFormat.
    • getOriginalPayload

      public com.google.protobuf.ByteString getOriginalPayload()
       Original payload can be stored in this field. This can be useful for users who want to get the original payload.
       Formats such as JFR are highly extensible and can contain more information than what is defined in this spec.
       Inclusion of original payload should be configurable by the user. Default behavior should be to not include the original payload.
       If the original payload is in pprof format, it SHOULD not be included in this field.
       The field is optional, however if it is present then equivalent converted data should be populated in other fields
       of this message as far as is practicable.
       
      bytes original_payload = 11;
      Specified by:
      getOriginalPayload in interface ProfileOrBuilder
      Returns:
      The originalPayload.
    • getAttributeIndicesList

      public List<Integer> getAttributeIndicesList()
       References to attributes in attribute_table. [optional]
       
      repeated int32 attribute_indices = 12;
      Specified by:
      getAttributeIndicesList in interface ProfileOrBuilder
      Returns:
      A list containing the attributeIndices.
    • getAttributeIndicesCount

      public int getAttributeIndicesCount()
       References to attributes in attribute_table. [optional]
       
      repeated int32 attribute_indices = 12;
      Specified by:
      getAttributeIndicesCount in interface ProfileOrBuilder
      Returns:
      The count of attributeIndices.
    • getAttributeIndices

      public int getAttributeIndices(int index)
       References to attributes in attribute_table. [optional]
       
      repeated int32 attribute_indices = 12;
      Specified by:
      getAttributeIndices in interface ProfileOrBuilder
      Parameters:
      index - The index of the element to return.
      Returns:
      The attributeIndices at the given index.
    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessage
    • writeTo

      public void writeTo(com.google.protobuf.CodedOutputStream output) throws IOException
      Specified by:
      writeTo in interface com.google.protobuf.MessageLite
      Overrides:
      writeTo in class com.google.protobuf.GeneratedMessage
      Throws:
      IOException
    • getSerializedSize

      public int getSerializedSize()
      Specified by:
      getSerializedSize in interface com.google.protobuf.MessageLite
      Overrides:
      getSerializedSize in class com.google.protobuf.GeneratedMessage
    • equals

      public boolean equals(Object obj)
      Specified by:
      equals in interface com.google.protobuf.Message
      Overrides:
      equals in class com.google.protobuf.AbstractMessage
    • hashCode

      public int hashCode()
      Specified by:
      hashCode in interface com.google.protobuf.Message
      Overrides:
      hashCode in class com.google.protobuf.AbstractMessage
    • parseFrom

      public static Profile parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static Profile parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static Profile parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static Profile parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static Profile parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static Profile parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static Profile parseFrom(InputStream input) throws IOException
      Throws:
      IOException
    • parseFrom

      public static Profile parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • parseDelimitedFrom

      public static Profile parseDelimitedFrom(InputStream input) throws IOException
      Throws:
      IOException
    • parseDelimitedFrom

      public static Profile parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • parseFrom

      public static Profile parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
      Throws:
      IOException
    • parseFrom

      public static Profile parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • newBuilderForType

      public Profile.Builder newBuilderForType()
      Specified by:
      newBuilderForType in interface com.google.protobuf.Message
      Specified by:
      newBuilderForType in interface com.google.protobuf.MessageLite
    • newBuilder

      public static Profile.Builder newBuilder()
    • newBuilder

      public static Profile.Builder newBuilder(Profile prototype)
    • toBuilder

      public Profile.Builder toBuilder()
      Specified by:
      toBuilder in interface com.google.protobuf.Message
      Specified by:
      toBuilder in interface com.google.protobuf.MessageLite
    • newBuilderForType

      protected Profile.Builder newBuilderForType(com.google.protobuf.AbstractMessage.BuilderParent parent)
      Overrides:
      newBuilderForType in class com.google.protobuf.AbstractMessage
    • getDefaultInstance

      public static Profile getDefaultInstance()
    • parser

      public static com.google.protobuf.Parser<Profile> parser()
    • getParserForType

      public com.google.protobuf.Parser<Profile> getParserForType()
      Specified by:
      getParserForType in interface com.google.protobuf.Message
      Specified by:
      getParserForType in interface com.google.protobuf.MessageLite
      Overrides:
      getParserForType in class com.google.protobuf.GeneratedMessage
    • getDefaultInstanceForType

      public Profile getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder