Mapping LocalDate as an Integer

62 views
Skip to first unread message

Anna Berruezo

unread,
Apr 8, 2016, 8:13:14 AM4/8/16
to Querydsl
Hi,

I'm trying to use QueryDSL with Lucene but I'm having some issues with mapping.

My document class has LocalDate and LocalDateTime attributes, which is okay with my domain. But I have them as Integers and Longs in Lucene.

Right now I place an annotation on the top of my document class ("@QueryEntity").

@QueryEntity
public class MyDocument{
   
private String id;
   
private String publication;
   
private int pageNumber;
   
private LocalDate date;
   
private LocalDateTime creationTime;
}

Is there any way to force QueryDSL to map LocalDates as Integers (and LocalDateTimes as Longs)?

Thanks!

timowest

unread,
Apr 8, 2016, 1:37:51 PM4/8/16
to Querydsl
Querydsl Lucene doesn't support these types out of the box. Could you create an issue for this?

Anna Berruezo

unread,
Apr 11, 2016, 4:35:59 AM4/11/16
to Querydsl

Anna Berruezo

unread,
Jun 13, 2016, 7:20:31 AM6/13/16
to Querydsl
Any update on this? I created the issue but I think it was pretty much ignored.

I understand that this feature is not a priority but I'd like to know if it will be at least considered someday.

Thanks!


On Friday, April 8, 2016 at 7:37:51 PM UTC+2, timowest wrote:

timowest

unread,
Jun 15, 2016, 2:35:04 PM6/15/16
to Querydsl
AFAIK it's not being worked on. Feel free to start a PR for it, if you want.

Anna Berruezo

unread,
Jun 15, 2016, 4:15:44 PM6/15/16
to Querydsl
Ok! Thanks for the feedback. ;)
Reply all
Reply to author
Forward
0 new messages