ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 40250] New: - The replace task doesn't work on an arbitrarily large file
Date Mon, 14 Aug 2006 13:58:41 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=40250>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=40250

           Summary: The replace task doesn't work on an arbitrarily large
                    file
           Product: Ant
           Version: 1.6.5
          Platform: Other
        OS/Version: other
            Status: NEW
          Severity: normal
          Priority: P1
         Component: Core tasks
        AssignedTo: dev@ant.apache.org
        ReportedBy: ryan@thebookhauler.com


I'm trying to run the replace task on an 86 MB file and it fails with an
OutOfMemory exception.  I've found the culprit to be in
apache-ant-1.6.5\src\main\org\apache\tools\ant\taskdefs\Replace.java:386  :

            String buf = fileUtils.readFully(br);

Replace should read the file one line at a time and do it's replacement
accordingly.  This might make replace a lot faster as well for the VM won't have
to do as much garbage collection to get entire file in memory.

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

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


Mime
View raw message