Hi all,

I'm investigating a memory consumption issue (leak, so it seems) and was
wondering if it could be related to the way runtime options are handled.
In particular, upon deserializing a PipelineOptions object,
ProxyInvocationHandler.Deserializer
calls ValueProvider.RuntimeValueProvider.setRuntimeOptions(options) which
stores the (newly) deserialized PipelineOptions instance in a static map
inside the RuntimeValueProvider class, where the key is an id obtained by
calling deserializedOptions.getOptionsId().

The thing is, performing a serialize-deserialize cycle on a given
PipelineOptions instance and invoking getOptionsId() yields different
optionsIds. Therefore, multiple deserializations of the same
PipelineOptions instance result in new keys being added to the static
"optionsMap" map inside the ValueProvider.RuntimeValueProvider class.

I wasn't able to identify any removals from this static, long-lived map
(ValueProvider.RuntimeValueProvider#optionsMap), any chance it is
ever-growing?
Am I missing something about the way things interact when a given
PipelineOptions instance gets deserialized numerous times?

Regards,
Stas

Reply via email to