HI, XContentBuilder (I assume jsonBuilder() returns it) serialises date using UTC timezone by default. If you’d like to use different format, you’d need to build your own DateTimeFormatter and pass it when you add date type field.
For example, to use ISO date time format with specified timezone: -------- DateTimeFormatter formatter = ISODateTimeFormat.dateTime().withZone(DateTimeZone.forTimeZone(TimeZone.getTimeZone(ZONE_NAME))); : .field("@timestamp", date, formatter) : .field("creation_time", date, formatter) : -------- Masaru On January 5, 2015 at 13:45:19, Subhadip Bagui (i.ba...@gmail.com) wrote: > Hi, > > Please help with suggestions. > > -- > You received this message because you are subscribed to the Google Groups > "elasticsearch" > group. > To unsubscribe from this group and stop receiving emails from it, send an > email to elasticsearch+unsubscr...@googlegroups.com. > To view this discussion on the web visit > https://groups.google.com/d/msgid/elasticsearch/02d96b0a-99a7-43f3-b245-13418dece674%40googlegroups.com. > > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "elasticsearch" group. To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/etPan.54ab8619.6b8b4567.13b%40citra.local. For more options, visit https://groups.google.com/d/optout.