From 4c40d16dfe01886499f7f2fd3abdbbc1dc51a3f2 Mon Sep 17 00:00:00 2001 From: Thorsten Eckel Date: Wed, 30 Aug 2017 18:42:27 +0200 Subject: [PATCH] Avoid unneeded memory consumption for Zendesk import. --- lib/import/zendesk/requester.rb | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/import/zendesk/requester.rb b/lib/import/zendesk/requester.rb index 7fd433b1d..53b717e4f 100644 --- a/lib/import/zendesk/requester.rb +++ b/lib/import/zendesk/requester.rb @@ -32,6 +32,11 @@ module Import # when hitting the rate limit, sleep automatically, # then retry the request. config.retry = true + + # disable cache to avoid unneeded memory consumption + # since we are using each object only once + # Inspired by: https://medium.com/swiftype-engineering/using-jmat-to-find-analyze-memory-in-jruby-1c4196c1ec72 + config.cache = false end end end