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

Jesse Yates commented on HBASE-4448:
------------------------------------

I've got a couple concerns about the patch - is it already applied to trunk or 
can we put it up in RB? 

Off the bat:
(1) A lot of times tests set the conf on the minicluster, before starting it - 
this could lead to some issues when requesting the cluster. Still thinking a 
requestUnique with a conf would be a good addition
(2) If we are going to just reuse the TestingUtility, it would make sense to 
also also some reuse of the dfs and zk clusters.
(3) We probably want to check for utils that haven't been used for the given 
time, rather than waiting for all the possible utils to not be used.

If you want, we can open up sub tickets for these issues. I would be happy to 
help out with any/all of the above.

> HBaseTestingUtilityFactory - pattern for re-using HBaseTestingUtility 
> instances across unit tests
> -------------------------------------------------------------------------------------------------
>
>                 Key: HBASE-4448
>                 URL: https://issues.apache.org/jira/browse/HBASE-4448
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Doug Meil
>            Assignee: Doug Meil
>            Priority: Minor
>         Attachments: HBaseTestingUtilityFactory.java, 
> hbase_hbaseTestingUtility_uses_2011_09_22.xlsx, java_HBASE_4448.patch
>
>
> Setting up and tearing down HBaseTestingUtility instances in unit tests is 
> very expensive.  On my MacBook it takes about 10 seconds to set up a 
> MiniCluster, and 7 seconds to tear it down.  When multiplied by the number of 
> test classes that use this facility, that's a lot of time in the build.
> This factory assumes that the JVM is being re-used across test classes in the 
> build, otherwise this pattern won't work. 
> I don't think this is appropriate for every use, but I think it can be 
> applicable in a great many cases - especially where developers just want a 
> simple MiniCluster with 1 slave.

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

        

Reply via email to