GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Implement MessagePackFactory.copy() method · Issue #453 · msgpack/msgpack-java

Implement MessagePackFactory.copy() method #453

New issue
Copy link
New issue
Copy link
Closed
Closed
Implement MessagePackFactory.copy() method#453
Copy link
Assignees
komamitsu

Description

@mrniko
mrniko
opened on Jan 29, 2018
Issue body actions

Hi!

MessagePackFactory should override copy method to avoid such exception during ObjectMapper.copy() method invocation:

java.lang.IllegalStateException: Failed copy(): org.msgpack.jackson.dataformat.MessagePackFactory (version: 2.9.4) does not override copy(); it has to
at com.fasterxml.jackson.core.JsonFactory._checkInvalidCopy(JsonFactory.java:332)
at com.fasterxml.jackson.core.JsonFactory.copy(JsonFactory.java:320)
at com.fasterxml.jackson.databind.ObjectMapper.(ObjectMapper.java:499)
at com.fasterxml.jackson.databind.ObjectMapper.copy(ObjectMapper.java:617)
at org.redisson.codec.JsonJacksonCodec.(JsonJacksonCodec.java:106)
at org.redisson.codec.MsgPackJacksonCodec.(MsgPackJacksonCodec.java:31)

Activity

  1. xerial commented on Jan 29, 2018

    @xerial
    xerial
    on Jan 29, 2018
    Member
    More actions

    @komamitsu What do you think?

  2. xerial
    assigned
    komamitsu
    on Jan 29, 2018
  3. komamitsu
    closed this as completedin #454on Feb 4, 2018
  4. komamitsu commented on Feb 4, 2018

    @komamitsu
    komamitsu
    on Feb 4, 2018
    Member
    More actions

    @mrniko Thanks for reporting this issue. Fixed it at #454

  5. mrniko commented on Apr 13, 2018

    @mrniko
    mrniko
    on Apr 13, 2018
    Author
    More actions

    @komamitsu Hi! I'm afraid bug is not fixed completely redisson/redisson#1314 (comment)

  6. komamitsu commented on Apr 14, 2018

    @komamitsu
    komamitsu
    on Apr 14, 2018
    Member
    More actions

    Yeah, the test I wrote checked only the case that MessagePackFactory has ExtensionTypeCustomDeserializers...
    https://github.com/msgpack/msgpack-java/blob/develop/msgpack-jackson/src/test/java/org/msgpack/jackson/dataformat/MessagePackFactoryTest.java#L69-L79

    This can be a workaround. But anyway I'll fix it soon.

    ObjectMapper copy = new ObjectMapper(new MessagePackFactory()
                             .setExtTypeCustomDesers(new ExtensionTypeCustomDeserializers())).copy();
    
    Reacted by Nikita Koksharov
  7. mrniko commented on Apr 16, 2018

    @mrniko
    mrniko
    on Apr 16, 2018
    Author
    More actions

    @komamitsu

    Thank you!

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

Metadata

Metadata

Assignees

  • @komamitsu
    komamitsu

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    You are visitor 01402503 — GeezerVison does not store the pages you look up.
    Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.