You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
log.info("-> " + list.getContent());
java.lang.NullPointerException: Cannot invoke "Object.toString()" because the return value of "java.util.Map.get(Object)" is null
Is RDUser annotated with RedisHash or Document? And to be clear you think this happens in toEntityList when it takes the branch that runs return aggregationResult.getResults().stream().map(h -> (E) ObjectUtils.mapToObject(h, entityClass, mappingConverter)).toList();
Based on that, I'm assuming this is RedisHash annotated entity? For RedisHash we delegate the hydration of the object to the mapping converter which is just an extension of the converter from Spring Data Redis.
In the aggregation, once you call load you have an aggregation results that contains only a String (RDUser$.ID). There is not registered converter to convert a single String to an Object. Gson just happens to be smart enough to handle this case.
A better solution might be to provide a .toEntityList(...) method to explicitly force this behavior.
Hi all
I have a question / use case about the load() query usign some MetamodelField
My goal is to have a model (RDUser in my case) with limited attribute (ID only as shown below)
Is this somtehing possible to have a kind of conversion based on MetamodelField in entry, and a List at the end ?
This work
This is not working
Exception :
This function seems to be the culprit
Workaround :
The text was updated successfully, but these errors were encountered: