private static Attributes toAttributesProto ( io . opencensus . trace . export . SpanData . Attributes attributes , Map < String , AttributeValue > resourceLabels , Map < String , AttributeValue > fixedAttributes ) { Attributes . Builder attributesBuilder = toAttributesBuilderProto ( attributes . getAttributeMap ( ) , attributes . getDroppedAttributesCount ( ) ) ; attributesBuilder . putAttributeMap ( AGENT_LABEL_KEY , AGENT_LABEL_VALUE ) ; for ( Entry < String , AttributeValue > entry : resourceLabels . entrySet ( ) ) { attributesBuilder . putAttributeMap ( entry . getKey ( ) , entry . getValue ( ) ) ; } for ( Entry < String , AttributeValue > entry : fixedAttributes . entrySet ( ) ) { attributesBuilder . putAttributeMap ( entry . getKey ( ) , entry . getValue ( ) ) ; } return attributesBuilder . build ( ) ; }
These are the attributes of the Span where usually we may add more attributes like the agent .