Suspected memory leak in PersistentTranslationService/GoogleTranslatorBackend

Description

@Dependent Instances have to be destroyed[1], but only the @Dependent ones[2], and yet there is no easy way of identifying them (short of using WeldInstance[3]).

We could use WeldInstance, but it makes the code more complex, so I suggest we just ensure the TranslatorBackends are all properly scoped (eg @ApplicationScoped).

[1] https://blog.akquinet.de/2017/01/04/dont-get-trapped-into-a-memory-leak-using-cdi-instance-injection/
[2] https://developer.jboss.org/thread/252712
[3] http://weld.cdi-spec.org/news/2016/05/18/enhanced-instance/

Environment

None

Assignee

Sean Flanigan

Reporter

Sean Flanigan

Labels

None

Sprint

None

Priority

unspecified
Configure