Vincent & P.Taylor,

I played with the testing framework for a little bit last night and don't
see any easy way to provide pauses in between the emissions of the mock
tuples. For instance, my sliding window semantics are heavily orchestrated
by time evictions and triggers which mean that I need to be able to time
the tuples being fed into the tests (i.e. emit a tuple every 500ms and run
the test for 25 secons).


On Tue, Aug 5, 2014 at 2:23 PM, P. Taylor Goetz <[email protected]> wrote:

> My guess is that the slowdown you are seeing is a result of the new
> version of ZooKeeper and how it handles IPv4/6.
>
> Try adding the following JVM parameter when running your tests:
>
> -Djava.net.preferIPv4Stack=true
>
> -Taylor
>
> On Aug 4, 2014, at 8:49 PM, Corey Nolet <[email protected]> wrote:
>
> > I'm testing some sliding window algorithms with tuples emitted from a
> mock spout based on a timer but the amount of time it takes the topology to
> fully start up and activate seems to vary from computer to computer.
> Specifically, I just updated from 0.8.2 to 0.9.2-incubating and all of my
> tests are breaking because the time to activate the topology is taking
> longer (because of Netty possibly?). I'd like to make my tests more
> resilient to things like this.
> >
> > Is there something I can look at in LocalCluster where I could do
> "while(!notActive) { Thread.sleep(50) }" ?
> >
> > This is what my test looks like currently:
> >
> >       StormTopology topology = buildTopology(...);
> >       Config conf = new Config();
> >       conf.setNumWorkers(1);
> >
> >       LocalCluster cluster = new LocalCluster();
> >       cluster.submitTopology(getTopologyName(), conf, topology);
> >
> >       try {
> >         Thread.sleep(4000);
> >       } catch (InterruptedException e) {
> >         e.printStackTrace();
> >       }
> >
> >       cluster.shutdown();
> >
> >       assertEquals(4, MockSinkBolt.getEvents().size());
> >
> >
> >
> > Thanks!
> >
> >
>
>

Reply via email to