Skip to content

Unnecessary IOException in IonObjectMapper method signatures #629

Description

@mcliedtke

With the move to RuntimeException's as a baseline in Jackson-3, there are some unnecessary throws IOException declarations in the method signatures of readValue and writeValue methods int he IonObjectMapper class. Could these throws declarations be removed?

There is one method - writeValueAsIonValue which technically does have an uncaught IOException, but given that it both opens and closes the writer to just in-memory objects, I don't see how an actual IOException would be anything other than an illegal state. I am not sure if there is a conventional way to handle this, but it would be nice to see this caught and rethrown as a RuntimeException base as well (is there a good corresponding JacksonException that fits? JacksonIOException?)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions