OctopusDeploy / Halibut

| Public | A secure communication stack for .NET using JSON-RPC over SSL.
Other
12 stars 44 forks source link

Extension of polymorphism in the TypeRegistry #593

Open Discolai opened 9 months ago

Discolai commented 9 months ago

Your recent change to the TypeRegistry allowing polymorphism is a great addition, but we find its contraints a bit too limiting.

The current implementation requires types to be either abstract or interefaces in order to pick up derived types, but this is not always feasible. My suggestion is to introduce a HalibutPolymorphicAttribute and optionally HalibutDerivedTypeAttribute similar to how microsoft did it with System.Text.Json