(input []*v1.KeyValue, generic *[]Attribute, dedicated *DedicatedAttributes, mapping dedicatedColumnMapping)
| 545 | } |
| 546 | |
| 547 | func writeAttrs(input []*v1.KeyValue, generic *[]Attribute, dedicated *DedicatedAttributes, mapping dedicatedColumnMapping) { |
| 548 | *generic = extendReuseSlice(len(input), *generic) |
| 549 | dedicated.Reset() |
| 550 | |
| 551 | attrCount := 0 |
| 552 | for _, a := range input { |
| 553 | written := false |
| 554 | |
| 555 | if spareColumn, exists := mapping.get(a.Key); exists { |
| 556 | written = spareColumn.writeValue(dedicated, a.Value) |
| 557 | } |
| 558 | |
| 559 | if !written { |
| 560 | attrToParquet(a, &(*generic)[attrCount]) |
| 561 | attrCount++ |
| 562 | } |
| 563 | } |
| 564 | *generic = (*generic)[:attrCount] |
| 565 | } |
| 566 | |
| 567 | // finalizeTrace augments and optimized the trace by calculating service stats, nested set model bounds |
| 568 | // and removing redundant scope spans and resource spans. The function returns the modified trace as well |
no test coverage detected