commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <j...@apache.org>
Subject [jira] [Work logged] (COMPRESS-481) Allow passing memory limit for extraction to SevenZFile
Date Tue, 16 Apr 2019 11:59:00 GMT

     [ https://issues.apache.org/jira/browse/COMPRESS-481?focusedWorklogId=228338&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-228338
]

ASF GitHub Bot logged work on COMPRESS-481:
-------------------------------------------

                Author: ASF GitHub Bot
            Created on: 16/Apr/19 11:58
            Start Date: 16/Apr/19 11:58
    Worklog Time Spent: 10m 
      Work Description: theobisproject commented on pull request #76: COMPRESS-481 Allow passing
memory limit to SevenZFile
URL: https://github.com/apache/commons-compress/pull/76#discussion_r275760111
 
 

 ##########
 File path: src/main/java/org/apache/commons/compress/archivers/sevenz/LZMA2Decoder.java
 ##########
 @@ -33,9 +34,12 @@
 
     @Override
     InputStream decode(final String archiveName, final InputStream in, final long uncompressedLength,
-            final Coder coder, final byte[] password) throws IOException {
+            final Coder coder, final byte[] password, int maxMemoryLimitInKb) throws IOException
{
         try {
             final int dictionarySize = getDictionarySize(coder);
+            if ((dictionarySize / 1024) > maxMemoryLimitInKb) {
 
 Review comment:
   Code changed according to your comment.
 
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Issue Time Tracking
-------------------

    Worklog Id:     (was: 228338)
    Time Spent: 1h 50m  (was: 1h 40m)

> Allow passing memory limit for extraction to SevenZFile
> -------------------------------------------------------
>
>                 Key: COMPRESS-481
>                 URL: https://issues.apache.org/jira/browse/COMPRESS-481
>             Project: Commons Compress
>          Issue Type: Improvement
>    Affects Versions: 1.18
>            Reporter: Robin Schimpf
>            Priority: Major
>             Fix For: 1.19
>
>          Time Spent: 1h 50m
>  Remaining Estimate: 0h
>
> I am handling arbitrary 7zip files in my application. The extraction of the files happens
parallelized. To have better control how much memory a single file uses for extraction it
would be good to be able to pass the memory limitation to the SevenZFile.
> This is already possible when using the CompressorStreamFactory.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message