Logstash JDBC input plugin - Set database date data timezone

I am using the logstash JDBC plugin to retrieve data from my SQL database to Elasticsearch.

It is working fine except I have the following problem:

I am storing my dates in UTC timezone in my database but when I use logstash, the dates are retrieved using the timezone of my machine.

I didn't see in the documentation how to set the timezone of the retrieved data or how to set Logstash to use UTC as local timezone.

Can anyone help ?

Use the date filter so LS knows :slight_smile:

Yes this is a solution but it seems realy painful for me to apply this, as the dates are retrieved as Ruby date object from database and I can not apply directly the date filter on them, I have to convert all the dates to VARCHAR when getting them from database then apply a filter on each of my date variable to make it works.

define jdbc_default_timezone => "UTC" in jdbc input plugin