You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@samza.apache.org by "Jakob Homan (JIRA)" <ji...@apache.org> on 2014/05/23 17:45:02 UTC
[jira] [Commented] (SAMZA-269) SerdeManager should pass through
envelope objects if not modified
[ https://issues.apache.org/jira/browse/SAMZA-269?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14007262#comment-14007262 ]
Jakob Homan commented on SAMZA-269:
-----------------------------------
+1
> SerdeManager should pass through envelope objects if not modified
> -----------------------------------------------------------------
>
> Key: SAMZA-269
> URL: https://issues.apache.org/jira/browse/SAMZA-269
> Project: Samza
> Issue Type: Bug
> Affects Versions: 0.7.0
> Reporter: Martin Kleppmann
> Assignee: Martin Kleppmann
> Attachments: SAMZA-269.patch
>
>
> In some cases, it can be useful for a SystemConsumer to define a custom IncomingMessageEnvelope subclass (or conversely, for a SystemProducer to define a custom OutgoingMessageEnvelope subclass) in order to carry system-specific metadata.
> Unfortunately, the current implementation of org.apache.samza.serializers.SerdeManager always unpacks the envelope and creates a new envelope object. This is necessary if a serde is being used (since the key and message need to be replaced with the serialized/deserialized version of the same), but unnecessary if there is no serde. If there is no serde, it would be better to pass through the envelope unmodified.
> This would probably also have a performance benefit, since we only have to allocate one, not two, envelope objects per message.
--
This message was sent by Atlassian JIRA
(v6.2#6252)