Problem: Customer has an id ... this is a string (or uuid). We want to use this id in a type-safe, ddd way, thus we need a CustomerId. could define this as a record, but since we are not allowed to reuse schema definitions from another schema, we woul have n definitions of this CustomerId record.
If we just provide it via conversion, we need to distribute libs containing the CustomerId.
Idea: Define a logical-type "value-id" and generate a value class based on naming conventions, so the type is alway present when we generate objects from schema.
Currently fails with value class CustomerId because of internal avro4k String/Charsequence erasure.
Problem: Customer has an id ... this is a string (or uuid). We want to use this id in a type-safe, ddd way, thus we need a CustomerId. could define this as a record, but since we are not allowed to reuse schema definitions from another schema, we woul have n definitions of this CustomerId record. If we just provide it via conversion, we need to distribute libs containing the CustomerId.
Idea: Define a logical-type "value-id" and generate a value class based on naming conventions, so the type is alway present when we generate objects from schema.
Currently fails with value class CustomerId because of internal avro4k String/Charsequence erasure.