[ 
https://issues.apache.org/jira/browse/GEODE-8407?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17172529#comment-17172529
 ] 

ASF subversion and git services commented on GEODE-8407:
--------------------------------------------------------

Commit d6c3b1f20a55c5d867f162a338910d5df7d47de5 in geode's branch 
refs/heads/develop from Bruce Schuchardt
[ https://gitbox.apache.org/repos/asf?p=geode.git;h=d6c3b1f ]

GEODE-8407: MergeLogFiles fails to include files with the same name b… (#5428)

* GEODE-8407: MergeLogFiles fails to include files with the same name but in 
different directories

I modified the upper levels of the merge process to hold a new object
containing the file's display name and its inputStream.  The
logFiles Map now holds the full path of a file and one of these new
objects.  The new test then uses a dirCount of zero to test that
two files with the same name but different parent directories are
properly stored in the Map for processing.

* fix stresstest failure

> MergeLogFiles fails to include files with the same name but in different 
> directories
> ------------------------------------------------------------------------------------
>
>                 Key: GEODE-8407
>                 URL: https://issues.apache.org/jira/browse/GEODE-8407
>             Project: Geode
>          Issue Type: Bug
>          Components: membership, tools
>            Reporter: Bruce J Schuchardt
>            Assignee: Bruce J Schuchardt
>            Priority: Major
>              Labels: pull-request-available
>             Fix For: 1.14.0
>
>
> The default setting for MergeLogFiles is dirCount=0, meaning each line of the 
> merge has the name of the corresponding log file but not its parent directory.
> I tried merging a bunch of files named _system.log_ in different directories 
> and found that, though all of the files were listed in the header only one of 
> them was in the merged output.
> If I set a dirCount of 1 then it works okay.
> I think the flaw is in this line:
> {code:java}
> logFiles.put(logFileName, new FileInputStream(file));
> {code}
>  This is after the dirCount has been applied.  In my case each logFileName is 
> going to be _system.log_ and each will overwrite whatever's already in the 
> map, leaving only one file.
> The full path name of each file should be used as a key in this map and the 
> display name with dirCount applied needs to be held in this map in some other 
> way.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to