cancel
Showing results for 
Search instead for 
Did you mean: 

audit search

Eric_Ace
Confirmed Champ
Confirmed Champ

I'm working with audit search. Using the AuditQueryBuilder class. In the unit test environment, the following code...

Calendar cal = Calendar.getInstance();
AuditQueryBuilder builder = new AuditQueryBuilder().predicates(Predicates.gte("eventDate", cal.getTime()));
Framework.getService(AuditReader.class).queryLogs(builder);

...throws down in: org.hiberate.type.TimeStampType.toString() with a ClassCastException. The hibernate code is manipulating the Date instance from Nuxeo and then failing when it tries to map the parameter into a query. Does anyone know of a way around this for unit testing? Thanks

1 REPLY 1

Kevin_Leturc
Star Contributor
Star Contributor

Hi,

It looks like hibernate version we use doesn't handle ZonedDateTime, which is the type produced by Literals.valueOf here.

Could you give us the stacktrace in order to create a jira issue ?