Skip to content
This repository has been archived by the owner on Jan 12, 2022. It is now read-only.

Supported collection types #18

Open
mariussoutier opened this issue Jul 7, 2015 · 2 comments
Open

Supported collection types #18

mariussoutier opened this issue Jul 7, 2015 · 2 comments

Comments

@mariussoutier
Copy link

When I use Seq or Array, I get the following error:

java.lang.UnsupportedOperationException: Could not generate schema. Cannot support yet: Seq[String]

With List, it seems to work. Please document which collection types are supported, and if possible support Seq as well.

@julianpeeters
Copy link
Owner

Sorry you ran into this, and thanks for the feedback.

Avro array is represented by List[T], and I've made that a little more clear in the readme.

Telling @AvroTypeProvider which collection type to generate is going to be ugly (can only pass one string literal into a macro), but I'll see what I can do.

@mariussoutier
Copy link
Author

@AvroTypeProvider could generate Seq instead of List to be more generic? Otherwise it doesn't really matter for generated code. So documenting which types work with @AvroRecord should be enough for now.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants