jackson-module-scala icon indicating copy to clipboard operation
jackson-module-scala copied to clipboard

Is Try object supported?

Open emanodame opened this issue 6 years ago • 1 comments

I get this exception:

Can not construct instance of scala.util.Try, problem: abstract types either need to be mapped to concrete types, have custom deserializer

emanodame avatar Sep 27 '19 17:09 emanodame

Would you be able to provide a code sample? Serialization seems to work for me but I suspect that deserialization might be a problem. We don't have an explicit module for Trys like there are for other types like Either. You might be able to write a module of your own (see com.fasterxml.jackson.module.scala.EitherModule for an example)

pjfanning avatar Sep 27 '19 18:09 pjfanning