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

ASF GitHub Bot commented on ZOOKEEPER-2967:
-------------------------------------------

Github user afine commented on a diff in the pull request:

    https://github.com/apache/zookeeper/pull/458#discussion_r168301155
  
    --- Diff: src/java/test/org/apache/zookeeper/test/ClientBase.java ---
    @@ -368,22 +368,37 @@ static void verifyThreadTerminated(Thread thread, 
long millis)
             }
         }
     
    +    public static File createEmptyTestDir() throws IOException {
    +        return createTmpDir(BASETEST, false);
    +    }
     
         public static File createTmpDir() throws IOException {
    -        return createTmpDir(BASETEST);
    +        return createTmpDir(BASETEST, true);
         }
     
    -    static File createTmpDir(File parentDir) throws IOException {
    +    static File createTmpDir(File parentDir, boolean createInitFile) 
throws IOException {
             File tmpFile = File.createTempFile("test", ".junit", parentDir);
             // don't delete tmpFile - this ensures we don't attempt to create
             // a tmpDir with a duplicate name
             File tmpDir = new File(tmpFile + ".dir");
             Assert.assertFalse(tmpDir.exists()); // never true if tmpfile does 
it's job
             Assert.assertTrue(tmpDir.mkdirs());
     
    +        // todo not every tmp directory needs this file
    --- End diff --
    
    why is this todo here?


> Add check to validate dataDir and dataLogDir parameters at startup
> ------------------------------------------------------------------
>
>                 Key: ZOOKEEPER-2967
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-2967
>             Project: ZooKeeper
>          Issue Type: Improvement
>          Components: server
>    Affects Versions: 3.4.11
>            Reporter: Andor Molnar
>            Assignee: Mark Fenes
>            Priority: Major
>              Labels: startup, validation
>             Fix For: 3.5.4, 3.6.0, 3.4.12
>
>
> According to  -ZOOKEEPER-2960- we should at a startup check to validate that 
> dataDir and dataLogDir parameters are set correctly.
> Perhaps we should introduce a check of some kind? If datalogdir is different 
> that datadir and snapshots exist in datalogdir we throw an exception and quit.



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

Reply via email to