{"action":"created","issue":{"url":"https://api.github.com/repos/EsotericSoftware/kryo/issues/573","repository_url":"https://api.github.com/repos/EsotericSoftware/kryo","labels_url":"https://api.github.com/repos/EsotericSoftware/kryo/issues/573/labels{/name}","comments_url":"https://api.github.com/repos/EsotericSoftware/kryo/issues/573/comments","events_url":"https://api.github.com/repos/EsotericSoftware/kryo/issues/573/events","html_url":"https://github.com/EsotericSoftware/kryo/issues/573","id":300761786,"number":573,"title":"Transient fields not copied when using StdInstantiatorStrategy","user":{"login":"emichael","id":1312141,"avatar_url":"https://avatars0.githubusercontent.com/u/1312141?v=4","gravatar_id":"","url":"https://api.github.com/users/emichael","html_url":"https://github.com/emichael","followers_url":"https://api.github.com/users/emichael/followers","following_url":"https://api.github.com/users/emichael/following{/other_user}","gists_url":"https://api.github.com/users/emichael/gists{/gist_id}","starred_url":"https://api.github.com/users/emichael/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/emichael/subscriptions","organizations_url":"https://api.github.com/users/emichael/orgs","repos_url":"https://api.github.com/users/emichael/repos","events_url":"https://api.github.com/users/emichael/events{/privacy}","received_events_url":"https://api.github.com/users/emichael/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2018-02-27T19:28:15Z","updated_at":"2018-03-25T20:08:58Z","closed_at":null,"author_association":"NONE","body":"Whenever I create a basic kryo object with the `StdInstantiatorStrategy`, transient fields are not cloned. This leads to errors; for example, a null pointer when trying to use a cloned `HashSet` (it's backed by a `    private transient HashMap<E,Object> map`). When I use `DefaultInstantiatorStrategy(new StdInstantiatorStrategy())`, the `HashSet` is cloned properly. However, then `HashMultimap` from Guava fails in the exact same way, presumably because unlike `HashSet`, it doesn't have a 0 arg constructor.\r\n\r\nSee also: https://stackoverflow.com/questions/27771421/how-to-serialize-multimaps-with-kryo\r\n\r\nI would rather not resort to one-at-a-time reverting to default serialization, though."},"comment":{"url":"https://api.github.com/repos/EsotericSoftware/kryo/issues/comments/375999398","html_url":"https://github.com/EsotericSoftware/kryo/issues/573#issuecomment-375999398","issue_url":"https://api.github.com/repos/EsotericSoftware/kryo/issues/573","id":375999398,"user":{"login":"emichael","id":1312141,"avatar_url":"https://avatars0.githubusercontent.com/u/1312141?v=4","gravatar_id":"","url":"https://api.github.com/users/emichael","html_url":"https://github.com/emichael","followers_url":"https://api.github.com/users/emichael/followers","following_url":"https://api.github.com/users/emichael/following{/other_user}","gists_url":"https://api.github.com/users/emichael/gists{/gist_id}","starred_url":"https://api.github.com/users/emichael/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/emichael/subscriptions","organizations_url":"https://api.github.com/users/emichael/orgs","repos_url":"https://api.github.com/users/emichael/repos","events_url":"https://api.github.com/users/emichael/events{/privacy}","received_events_url":"https://api.github.com/users/emichael/received_events","type":"User","site_admin":false},"created_at":"2018-03-25T20:08:58Z","updated_at":"2018-03-25T20:08:58Z","author_association":"NONE","body":"Transient fields aren't intended to be serialized **when the default serialization methods are used.** Not serializing them and not using the `writeObject(ObjectOutputStream out)` and `writeObject(ObjectOutputStream out)` is usually going to be wrong."}}
{"actor":{"display_login":"emichael"}}