HashIdentifierExceptVersion
Computes a hash for a given identifier, excluding the version from the hash calculation. This supports cache hits across different versions of the same resource.
def HashIdentifierExceptVersion(
ctx: context.Context,
id: *core.Identifier
) - > string
Computes a hash string for a given identifier, excluding the version field. This function is used to support cache hits across different versions of the same resource by ensuring the hash remains consistent.
Parameters
| Name | Type | Description |
|---|---|---|
| ctx | context.Context | The context for the operation, typically used for cancellation or deadlines. |
| id | *core.Identifier | The identifier object for which the hash needs to be computed. Its ResourceType, Project, Domain, Name, and Org fields will be used. |
Returns
| Type | Description |
|---|---|
string | The computed hash string for the identifier, or an empty string if an error occurs. |