示例#1
0
    def _test():
        transaction = current_transaction()

        for i in range(128):
            transaction.add_custom_parameter('txn_attr%i' % i, 'txnValue')
            if i < 64:
                add_custom_span_attribute('span_attr%i' % i, 'spanValue')
示例#2
0
    def _test():
        transaction = current_transaction()
        transaction._sampled = True

        with trace_type(*args):
            add_custom_span_attribute('trace1_a', 'foobar')
            add_custom_span_attribute('trace1_b', 'barbaz')
            add_custom_span_attribute('invalid_value', sys.maxsize + 1)
示例#3
0
def test_span_user_attribute_overrides_transaction_attribute():
    transaction = current_transaction()

    transaction.add_custom_parameter('foo', 'a')
    add_custom_span_attribute('foo', 'b')
    transaction.add_custom_parameter('foo', 'c')