Closed
Description
The operation ID generator wrongly assumes that the endpoint is secondary only when the secondary resource type differs from the primary resource type. This is incorrect when both types are the same.
For example:
public sealed class Node : Identifiable<long>
{
[Attr]
public string Name { get; set; } = null!;
[HasOne]
public Node? Parent { get; set; }
[HasMany]
public ISet<Node> Children { get; set; } = new HashSet<Node>();
}
This generates "operationId": "getNodeCollection"
for both /nodes
and /nodes/{id}/parent
. The C# client generator then produces methods GetNodeCollectionAsync
and GetNodeCollection2Async
.