Make `CodecMetadata.getDataTypes()` more flexible
skykatik opened this issue · comments
Skat commented
Feature Request
Is your feature request related to a problem? Please describe
I was making my own codec and noticed that CodecMetadata.getDataTypes()
does not allow to return subtypes of PostgresTypeIdentifier
(like a PostgresqlObjectId
) when they are cached in static fields .
Describe the solution you'd like
Change return type of method to covariant, i.e. Iterable<? extends PostgresTypeIdentifier>
.
Teachability, Documentation, Adoption, Migration Strategy
That method is already designed to return any type of iterable, and usages of it related to read, so therefore, there will be no problems with the existing code
Mark Paluch commented
Good catch, we can easily do that.
Mark Paluch commented
For the time being, I suggest casting to work around that limitation.