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

Steven Rowe commented on LUCENE-3452:
-------------------------------------

>From #lucene IRC:

{noformat}
sarowe: line #69 of 
lucene/test-framework/o/a/l/util/LuceneJUnitResultFormatter/:
            File lockDir = new File(System.getProperty("java.io.tmpdir"),
                "lucene_junit_lock");
  hoss: right ... i saw that ... i suspect it's for using random factories and 
stuff
        not clera if the goal is to have a dir that all the parallel JVMs agree 
on or what
        even if it is: should be able to put it in the build dir ... right?
sarowe: I think so - the only question in my mind is whether it's used in both 
lucene and solr
        if so, then "the build dir" is not fixed
  hoss: hmmm... good question
        in which case somethine like: "dir = tmp + user.name + md5(path to 
common-build.xml)" would be better, and probably solve the same problem
sarowe: I don't understand the last component
        why md5(c-b.xml path)?
        I mean, why anything at all other than tmp + user.name?
  hoss: think rmuir and his beast box ... multiple copies of lucene checked out 
into diff dirs where he's testing diff patches
sarowe: a (maybe simpler) option would be to always use lucene/build/?
        even when running solr tests, I mean
  hoss: sure .. maybe ... can you opne an issue and we'll figure it out there? 
{noformat}

> The native FS lock used in test-framework's 
> o.a.l.util.LuceneJUnitResultFormatter prohibits testing on a multi-user system
> --------------------------------------------------------------------------------------------------------------------------
>
>                 Key: LUCENE-3452
>                 URL: https://issues.apache.org/jira/browse/LUCENE-3452
>             Project: Lucene - Java
>          Issue Type: Bug
>          Components: general/test
>    Affects Versions: 3.4, 4.0
>            Reporter: Steven Rowe
>            Priority: Minor
>
> {{LuceneJUnitResultFormatter}} uses a lock to buffer test suites' output, so 
> that when run in parallel, they don't interrupt each other when they are 
> displayed on the console.
> The current implementation uses a fixed directory ({{lucene_junit_lock/}} in 
> {{java.io.tmpdir}} (by default {{/tmp/}} on Unix/Linux systems) as the 
> location of this lock.  This functionality was introduced on SOLR-1835.
> As Shawn Heisey reported on SOLR-2739, some tests fail when run as root, but 
> succeed when run as a non-root user.  
> On #lucene IRC today, Shawn wrote:
> {quote}
> (2:06:07 PM) elyograg: Now that I know I can't run the tests as root, I have 
> discovered /tmp/lucene_junit_lock.  Once you run the tests as user A, you 
> cannot run them again as user B until that directory is deleted, and only 
> root or the original user can do so.
> {quote}

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to