Sorry for the divergent messages - couldnt find a good way to combine them.
On Fri, Oct 28, 2011 at 11:54 AM, Keith Turner <[email protected]> wrote: > On Fri, Oct 28, 2011 at 11:19 AM, John W Vines <[email protected]> > wrote: > > > > 3. What I want to see us doing, at a very high level, is to have the > ability to mock an entire TServer to the extent where we will use something > to replace Zookeeper (We should probably turn our ZK work with an interface) > with a MockZookeeper (not generated through a Mock util) which is nothing > more than a Map. Same thing with the FileReader, except a SortedMap, the > loggers, and the master. This way we could fully implement a whole TServer > without worry about HDFS and Zookeeper. > To a similar extent I would like to see this done for all core components, > but mocking the various connectors we use to get done what we need to. I see > a few sets of Mock class we will have to create. But with less chance of > divergence in behavior then we currently experience with our MockAccumulo > setup. > > > This sounds like a good goal. Seems like in addition to mocking, we > would need to refactor code to support dependency injection. > With PowerMock we can avoid having to refactor everything since we can catch object creation and return your own mock object. Dependency injection then becomes a moot need unless we start using a configuration framework for launching different elements. -- ------------------- Jesse Yates 240-888-2200 @jesse_yates
