-
Notifications
You must be signed in to change notification settings - Fork 54
Build time return NullPointerException on get/set prefix method name in entity class #102
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
@chanhengseang3 Thank you for reporting the issue. Could post an example entity class that causes the problem to help me build the test case. Thank you! |
I have the same issue; with 0.3.10-SNAPSHOT it works fine, with 0.3.18-SNAPSHOT (same classes / same JPA model) I get two different issues related to @transient. One of the issues can be traced somewhere around in this method
type is null (and the stacktrace that follows remarks that). With a conditional breakpoint, I found that the problem refers to the following method of one of my entities:
The method above is where propertyDescriptor points then the conditional breakpoint is triggered. I swapped the old version back; let me know if you need more info (and which type of info). |
Fixed in 0.3.18 via fb45d23 |
Updating from 0.3.13 version to 0.3.17 returns
NullPointerException
. When classGraphQLJpaSchemaBuilder
tries to search for@Transient
, classIntrospectionUtils
tries to read all the methods that have name start withget
orset
. Whenever theEntity
class contains methods that have prefixget
orset
then it will try to find that properties. If the properties are not found thenIntrospectionUtils
will returnNullPointerException
.There are cases that method names that start with
get
orset
has nothing to do with properties. For example, with methodgetHello
, it will try to find the property namehello
. But there is nohello
property in this entity.getHello
method is not intended for gethello
properties.We tried to have Beans
@Transient
annotated on the method, but we still gotNullException
error.The text was updated successfully, but these errors were encountered: