If the {{AliasToBeanResultTransformer}} can't find both a getter and a setter for a particular property on an object, it just assumes the object is a Map (without checking) and ends up throwing a confusing ClassCastException. "Foo cannot be cast to java.util.Map." (Yes, I knew that!) See [this Stack Overflow question|https://stackoverflow.com/questions/33433345/hibernate-gives-a-strange-classcast-exception-using-transformers].
*Expected Result:*
Some exception is thrown that leads the user to the problem.
*Actual Result:*
A {{ClassCastException}} is thrown.
Pull The linked pull request forthcoming contains a possible fix and a test case . .. |
|