Examples of threads()


Examples of org.easetech.easytest.annotation.Parallel.threads()

    protected void setSchedulingStrategy() {
        Class<?> testClass = getTestClass().getJavaClass();
        super.setScheduler(SchedulerStrategy.getScheduler(testClass , false));
        Parallel parallelAnnotation = testClass.getAnnotation(Parallel.class);
        if(parallelAnnotation != null) {
            int threads = parallelAnnotation.threads();
            System.setProperty(SystemProperties.PARALLEL_THREAD_COUNT.getValue(), String.valueOf(threads));
        }
       
       
    }
View Full Code Here

Examples of org.easetech.easytest.annotation.Parallel.threads()

            } else {
                return new ParallelScheduler(parallelThreads);
            }
        } else {
            if (parallelAnnotation != null) {
                if (parallelAnnotation.threads() <= 0) {
                    return new ParallelScheduler();
                } else {
                    return new ParallelScheduler(parallelAnnotation.threads());
                }
View Full Code Here

Examples of org.easetech.easytest.annotation.Parallel.threads()

        } else {
            if (parallelAnnotation != null) {
                if (parallelAnnotation.threads() <= 0) {
                    return new ParallelScheduler();
                } else {
                    return new ParallelScheduler(parallelAnnotation.threads());
                }

            }
        }
        if(policyApplied) {
View Full Code Here

Examples of org.easetech.easytest.annotation.ParallelSuite.threads()

     * @return an instance of {@link RunnerScheduler}
     */
    public static RunnerScheduler getSchedulerForSuite(Class<?> suiteClass) {
        ParallelSuite parallelSuite = suiteClass.getAnnotation(ParallelSuite.class);
        if(parallelSuite != null) {
            if(parallelSuite.threads() <=0) {
                return new ParallelScheduler();
            } else {
                return new ParallelScheduler(parallelSuite.threads());
            }
        }
View Full Code Here

Examples of org.easetech.easytest.annotation.ParallelSuite.threads()

        ParallelSuite parallelSuite = suiteClass.getAnnotation(ParallelSuite.class);
        if(parallelSuite != null) {
            if(parallelSuite.threads() <=0) {
                return new ParallelScheduler();
            } else {
                return new ParallelScheduler(parallelSuite.threads());
            }
        }
        return new SerialScheduler();
    }
View Full Code Here

Examples of org.elasticsearch.action.admin.cluster.node.hotthreads.NodesHotThreadsRequest.threads()

    @Override
    public void handleRequest(final RestRequest request, final RestChannel channel, final Client client) {
        String[] nodesIds = Strings.splitStringByCommaToArray(request.param("nodeId"));
        NodesHotThreadsRequest nodesHotThreadsRequest = new NodesHotThreadsRequest(nodesIds);
        nodesHotThreadsRequest.threads(request.paramAsInt("threads", nodesHotThreadsRequest.threads()));
        nodesHotThreadsRequest.type(request.param("type", nodesHotThreadsRequest.type()));
        nodesHotThreadsRequest.interval(TimeValue.parseTimeValue(request.param("interval"), nodesHotThreadsRequest.interval()));
        nodesHotThreadsRequest.snapshots(request.paramAsInt("snapshots", nodesHotThreadsRequest.snapshots()));
        client.admin().cluster().nodesHotThreads(nodesHotThreadsRequest, new RestResponseListener<NodesHotThreadsResponse>(channel) {
            @Override
View Full Code Here

Examples of org.elasticsearch.action.admin.cluster.node.hotthreads.NodesHotThreadsRequest.threads()

    @Override
    public void handleRequest(final RestRequest request, final RestChannel channel, final Client client) {
        String[] nodesIds = Strings.splitStringByCommaToArray(request.param("nodeId"));
        NodesHotThreadsRequest nodesHotThreadsRequest = new NodesHotThreadsRequest(nodesIds);
        nodesHotThreadsRequest.threads(request.paramAsInt("threads", nodesHotThreadsRequest.threads()));
        nodesHotThreadsRequest.type(request.param("type", nodesHotThreadsRequest.type()));
        nodesHotThreadsRequest.interval(TimeValue.parseTimeValue(request.param("interval"), nodesHotThreadsRequest.interval()));
        nodesHotThreadsRequest.snapshots(request.paramAsInt("snapshots", nodesHotThreadsRequest.snapshots()));
        client.admin().cluster().nodesHotThreads(nodesHotThreadsRequest, new RestResponseListener<NodesHotThreadsResponse>(channel) {
            @Override
View Full Code Here

Examples of org.jbehave.core.embedder.EmbedderControls.threads()

        assertThat(embedderControls.ignoreFailureInStories(), is(true));
        assertThat(embedderControls.ignoreFailureInView(), is(true));
        assertThat(embedderControls.skip(), is(true));
        assertThat(embedderControls.storyTimeoutInSecs(), equalTo(100L));
        assertThat(embedderControls.failOnStoryTimeout(), is(true));
        assertThat(embedderControls.threads(), equalTo(2));
        assertThat(embedderControls.verboseFailures(), is(true));
        assertThat(embedderControls.verboseFiltering(), is(true));
    }

    @Test
View Full Code Here

Examples of org.jbehave.core.embedder.EmbedderControls.threads()

        EmbedderControls embedderControls = embedder.embedderControls();
        assertThat(embedderControls.batch(), is(false));
        assertThat(embedderControls.generateViewAfterStories(), is(true));
        assertThat(embedderControls.ignoreFailureInStories(), is(false));
        assertThat(embedderControls.ignoreFailureInView(), is(false));
        assertThat(embedderControls.threads(), is(1));
        assertThat(embedderControls.skip(), is(false));
        assertThat(embedderControls.storyTimeoutInSecs(), equalTo(300L));
        assertThat(embedderControls.failOnStoryTimeout(), is(false));
        assertThat(embedderControls.threads(), equalTo(1));
    }
View Full Code Here

Examples of org.jbehave.core.embedder.EmbedderControls.threads()

        assertThat(embedderControls.ignoreFailureInView(), is(false));
        assertThat(embedderControls.threads(), is(1));
        assertThat(embedderControls.skip(), is(false));
        assertThat(embedderControls.storyTimeoutInSecs(), equalTo(300L));
        assertThat(embedderControls.failOnStoryTimeout(), is(false));
        assertThat(embedderControls.threads(), equalTo(1));
    }

    @Test
    public void shouldCreateNewEmbedderWithGivenControls() {
        // Given
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.