The hash ID is used to conserve network bandwidth for duplicate
stack traces within a single trace.
Often multiple spans will have identical stack traces.
The first occurrence of a stack trace should contain both the
stackFrame content and a value in stackTraceHashId.
Subsequent spans within the same request can refer
to that stack trace by only setting stackTraceHashId.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-07 UTC."],[[["\u003cp\u003eThe latest version of the Google Cloud Trace v2 API class StackTrace is 3.6.0, with documentation available for versions back to 2.2.0.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eStackTrace\u003c/code\u003e class represents a call stack in a trace and inherits from \u003ccode\u003eobject\u003c/code\u003e, while implementing interfaces like \u003ccode\u003eIMessage\u003c/code\u003e, \u003ccode\u003eIEquatable\u003c/code\u003e, \u003ccode\u003eIDeepCloneable\u003c/code\u003e, and \u003ccode\u003eIBufferMessage\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eStackTrace\u003c/code\u003e class includes a \u003ccode\u003eStackFrames\u003c/code\u003e property to hold the stack frames, with a maximum limit of 128 frames allowed.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eStackTraceHashId\u003c/code\u003e property optimizes network bandwidth by providing a unique ID for duplicate stack traces within the same trace.\u003c/p\u003e\n"],["\u003cp\u003eThe class includes the ability to construct an instance of itself, through the use of two constructors.\u003c/p\u003e\n"]]],[],null,["# Google Cloud Trace v2 API - Class StackTrace (3.6.0)\n\nVersion latestkeyboard_arrow_down\n\n- [3.6.0 (latest)](/dotnet/docs/reference/Google.Cloud.Trace.V2/latest/Google.Cloud.Trace.V2.StackTrace)\n- [3.5.0](/dotnet/docs/reference/Google.Cloud.Trace.V2/3.5.0/Google.Cloud.Trace.V2.StackTrace)\n- [3.4.0](/dotnet/docs/reference/Google.Cloud.Trace.V2/3.4.0/Google.Cloud.Trace.V2.StackTrace)\n- [3.3.0](/dotnet/docs/reference/Google.Cloud.Trace.V2/3.3.0/Google.Cloud.Trace.V2.StackTrace)\n- [3.2.0](/dotnet/docs/reference/Google.Cloud.Trace.V2/3.2.0/Google.Cloud.Trace.V2.StackTrace)\n- [3.1.0](/dotnet/docs/reference/Google.Cloud.Trace.V2/3.1.0/Google.Cloud.Trace.V2.StackTrace)\n- [3.0.0](/dotnet/docs/reference/Google.Cloud.Trace.V2/3.0.0/Google.Cloud.Trace.V2.StackTrace)\n- [2.3.0](/dotnet/docs/reference/Google.Cloud.Trace.V2/2.3.0/Google.Cloud.Trace.V2.StackTrace)\n- [2.2.0](/dotnet/docs/reference/Google.Cloud.Trace.V2/2.2.0/Google.Cloud.Trace.V2.StackTrace) \n\n public sealed class StackTrace : IMessage\u003cStackTrace\u003e, IEquatable\u003cStackTrace\u003e, IDeepCloneable\u003cStackTrace\u003e, IBufferMessage, IMessage\n\nReference documentation and code samples for the Google Cloud Trace v2 API class StackTrace.\n\nA call stack appearing in a trace. \n\nInheritance\n-----------\n\n[object](https://learn.microsoft.com/dotnet/api/system.object) \\\u003e StackTrace \n\nImplements\n----------\n\n[IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage-1.html)[StackTrace](/dotnet/docs/reference/Google.Cloud.Trace.V2/latest/Google.Cloud.Trace.V2.StackTrace), [IEquatable](https://learn.microsoft.com/dotnet/api/system.iequatable-1)[StackTrace](/dotnet/docs/reference/Google.Cloud.Trace.V2/latest/Google.Cloud.Trace.V2.StackTrace), [IDeepCloneable](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IDeepCloneable-1.html)[StackTrace](/dotnet/docs/reference/Google.Cloud.Trace.V2/latest/Google.Cloud.Trace.V2.StackTrace), [IBufferMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IBufferMessage.html), [IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage.html) \n\nInherited Members\n-----------------\n\n[object.GetHashCode()](https://learn.microsoft.com/dotnet/api/system.object.gethashcode) \n[object.GetType()](https://learn.microsoft.com/dotnet/api/system.object.gettype) \n[object.ToString()](https://learn.microsoft.com/dotnet/api/system.object.tostring)\n\nNamespace\n---------\n\n[Google.Cloud.Trace.V2](/dotnet/docs/reference/Google.Cloud.Trace.V2/latest/Google.Cloud.Trace.V2)\n\nAssembly\n--------\n\nGoogle.Cloud.Trace.V2.dll\n\nConstructors\n------------\n\n### StackTrace()\n\n public StackTrace()\n\n### StackTrace(StackTrace)\n\n public StackTrace(StackTrace other)\n\nProperties\n----------\n\n### StackFrames\n\n public StackTrace.Types.StackFrames StackFrames { get; set; }\n\nStack frames in this stack trace. A maximum of 128 frames are allowed.\n\n### StackTraceHashId\n\n public long StackTraceHashId { get; set; }\n\nThe hash ID is used to conserve network bandwidth for duplicate\nstack traces within a single trace.\n\nOften multiple spans will have identical stack traces.\nThe first occurrence of a stack trace should contain both the\n`stackFrame` content and a value in `stackTraceHashId`.\n\nSubsequent spans within the same request can refer\nto that stack trace by only setting `stackTraceHashId`."]]