Fix ObjectEqualityComparer used in aggregatorstore (#2177)
This commit is contained in:
parent
4b2e200ffb
commit
2476bdb219
|
|
@ -41,7 +41,7 @@ namespace OpenTelemetry.Metrics
|
|||
|
||||
for (int i = 0; i < len1; i++)
|
||||
{
|
||||
if (obj1[i] != obj2[i])
|
||||
if (!obj1[i].Equals(obj2[i]))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -110,6 +110,11 @@ namespace Benchmarks.Metrics
|
|||
}
|
||||
|
||||
[Benchmark]
|
||||
public void CounterWith1LabelLocal()
|
||||
{
|
||||
this.counter?.Add(100, new KeyValuePair<string, object>("key", "value"));
|
||||
}
|
||||
|
||||
public void CounterWith3LabelsHotPath()
|
||||
{
|
||||
this.counter?.Add(100, this.tag1, this.tag2, this.tag3);
|
||||
|
|
|
|||
Loading…
Reference in New Issue