You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@synapse.apache.org by "Andreas Veithen (JIRA)" <ji...@apache.org> on 2008/07/28 13:43:31 UTC

[jira] Commented: (SYNAPSE-408) Improve Synapse Memory Footprint under HTTP 1.0

    [ https://issues.apache.org/jira/browse/SYNAPSE-408?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12617410#action_12617410 ] 

Andreas Veithen commented on SYNAPSE-408:
-----------------------------------------

There are other places in the synapse-transports module where I would like to use TemporaryData. So I'm +1 for moving it elsewhere so that it can be used inside synapse-transports.

Note that for the issue about content length calculation, there is also another solution to improve the memory footprint: simply doing the serialization twice, once to calculate the length (without actually storing the stream) and then again later when the response is actually sent.

> Improve Synapse Memory Footprint under HTTP 1.0
> -----------------------------------------------
>
>                 Key: SYNAPSE-408
>                 URL: https://issues.apache.org/jira/browse/SYNAPSE-408
>             Project: Synapse
>          Issue Type: Improvement
>            Reporter: Saliya Ekanayake
>            Priority: Minor
>
> Synapse serializes the SOAP envelope in order to calculate the content length of the message under HTTP 1.0. This serialization is done inside the class Axis2HttpRequest which is inside the transports module. The serialized bytes are then stored in the message context for future use by the streamMessageContents() method inside the same class.
> Thus, the entire content of the SOAP envelope is stored inside the memory leading to a possible out of memory situation when the XML data is large. A solution to this would be to write some of the data to a permanent storage (like hard disk) based on a threshold value. The TemporaryData class inside the core module is a good solution to this kind of work. It would, however, incur a cyclic dependency if used inside the Axis2HttpRequest class. 
> If we can resolve this issue (probably by moving the TemporaryData class to a utility module and then making the core too depend on that) it will of great use in improving the memory footprint of Synapse.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@synapse.apache.org
For additional commands, e-mail: dev-help@synapse.apache.org