Uploaded image for project: 'Axiom'
  1. Axiom
  2. AXIOM-236

When inlining a DataHandler as Base64, OMTextImpl doesn't stream the data

VotersWatch issueWatchersLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • None
    • 1.2.9
    • None
    • None

    Description

      When converting a DataHandler to Base64, OMTextImpl#writeOutput ends up calling OMTextImpl#getText, meaning that Axiom will construct a single String from the complete DataHandler content. For large contents this will inevitably lead to out of memory errors. The correct strategy would be to stream the data, i.e. to do the conversion in chunks and write several CHARACTER events to the XmlStreamWriter.

      Both LLOM's OMTextImpl and DOOM's TextImpl are affected by this problem.

      Attachments

        Issue Links

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            veithen Andreas Veithen
            veithen Andreas Veithen
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment