{"action":"opened","issue":{"url":"https://api.github.com/repos/FasterXML/jackson-databind/issues/874","labels_url":"https://api.github.com/repos/FasterXML/jackson-databind/issues/874/labels{/name}","comments_url":"https://api.github.com/repos/FasterXML/jackson-databind/issues/874/comments","events_url":"https://api.github.com/repos/FasterXML/jackson-databind/issues/874/events","html_url":"https://github.com/FasterXML/jackson-databind/issues/874","id":96738662,"number":874,"title":"Json deserialization of class with no default constructor and referenced field in the provided constructor","user":{"login":"larjohn","id":1288985,"avatar_url":"https://avatars.githubusercontent.com/u/1288985?v=3","gravatar_id":"","url":"https://api.github.com/users/larjohn","html_url":"https://github.com/larjohn","followers_url":"https://api.github.com/users/larjohn/followers","following_url":"https://api.github.com/users/larjohn/following{/other_user}","gists_url":"https://api.github.com/users/larjohn/gists{/gist_id}","starred_url":"https://api.github.com/users/larjohn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/larjohn/subscriptions","organizations_url":"https://api.github.com/users/larjohn/orgs","repos_url":"https://api.github.com/users/larjohn/repos","events_url":"https://api.github.com/users/larjohn/events{/privacy}","received_events_url":"https://api.github.com/users/larjohn/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-07-23T05:57:58Z","updated_at":"2015-07-23T05:57:59Z","closed_at":null,"body":"_From @larjohn on July 17, 2015 12:8_\n\nHi,\r\n\r\nI am using mysema QueryDSL for persistence-ORM functionality. I would like to store built query objects together in JSON format, so that I can load and reuse them. As most of the classes in QueryDSL are abstract, and I would not modify them, I have used mixins to configure their JSON serialization/deserialization: \r\n\r\nMy issue is with the PathMetadata mixin. The original PathMetadata class can be seen here:\r\n\r\nhttps://github.com/querydsl/querydsl/blob/master/querydsl-core/src/main/java/com/querydsl/core/types/PathMetadata.java\r\n\r\nThe mixin that I have created for this class is the following:\r\n\r\nimport com.fasterxml.jackson.annotation.JsonCreator;\r\nimport com.fasterxml.jackson.annotation.JsonIgnore;\r\nimport com.fasterxml.jackson.annotation.JsonProperty;\r\nimport com.mysema.query.types.Path;\r\nimport com.mysema.query.types.PathType;\r\n\r\nimport javax.annotation.Nullable;\r\n\r\npublic abstract class PathMetadataMixin {\r\n\r\n    @JsonProperty\r\n    private Path<?>parent;\r\n\r\n    @JsonIgnore\r\n    private Path<?>root;\r\n\r\n\r\n    @JsonCreator\r\n    public PathMetadataMixin(@JsonProperty(\"parent\")  @Nullable Path<?> parent, @JsonProperty(\"element\") Object element, @JsonProperty(\"type\") PathType type ) {\r\n\r\n    }\r\n\r\n}\r\n\r\nWhen I serialize an instance of this PathMetadata class, everything works as expected and it is outputted either as a whole, or with the ref attribute if it is already there. But when I try to deserialize the object, it throws a crypric exception:\r\n\r\nCaused by: java.lang.ArrayStoreException: com.fasterxml.jackson.databind.deser.impl.ObjectIdReferenceProperty\r\n\r\nI have found that this exception is fired here:\r\n\r\n/com/fasterxml/jackson/core/jackson-databind/2.6.0-rc1/jackson-databind-2.6.0-rc1-sources.jar!/com/fasterxml/jackson/databind/deser/BeanDeserializerBase.java:485\r\n\r\nActually, in this line\r\n\r\ncreatorProps[i] = prop;\r\n\r\ncreatorProps is an array of CreatorProperty objects (although it is declared more generally) and prop is an ObjectIdReferenceProperty. Thus it cannot be added to the array.\r\n\r\nHow can I solve this?\r\n\r\n\n\n_Copied from original issue: jsog/jsog-jackson#7_"}}