Skip to content

airframe-codec: Check the presence of non-serializable types #836

@xerial

Description

@xerial

When a type X contains non-serializable types in its parameters, MessageCodec.of[X].toXXX will throw a runtime exception.

For the application safety, we should be able to check whether the type is serializable or not when creating a codec:

case class X(p:Y)
case class Y(a:NonSerializableType) 

val codec = MessageCodec.of[X] // Throw NonSerializable exception (e.g., "Y.a" is not serializable)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions