Package com.asakusafw.windgate.retryable

Examples of com.asakusafw.windgate.retryable.RetryableProcessProfile


    @Test
    public void convert_simple() throws Exception {
        ProcessProfile profile = profile(
                KEY_RETRY_COUNT, "1",
                KEY_COMPONENT, DummyProcess.class.getName());
        RetryableProcessProfile result = RetryableProcessProfile.convert(profile);
        assertThat(result.getRetryCount(), is(1));
        assertThat(result.getRetryInterval(), is(DEFAULT_RETRY_INTERVAL));
        assertThat(result.getComponent(), instanceOf(DummyProcess.class));
        ProcessProfile inner = ((DummyProcess) result.getComponent()).inner;
        assertThat(inner.getName(), is(not(profile.getName())));
        assertThat(inner.getConfiguration(), is(map()));
    }
View Full Code Here


                KEY_RETRY_INTERVAL, "1000",
                KEY_COMPONENT, DummyProcess.class.getName(),
                PREFIX_COMPONENT + "hello1", "world1",
                PREFIX_COMPONENT + "hello2", "world2",
                PREFIX_COMPONENT + "hello3", "world3");
        RetryableProcessProfile result = RetryableProcessProfile.convert(profile);
        assertThat(result.getRetryCount(), is(10));
        assertThat(result.getRetryInterval(), is(1000L));
        assertThat(result.getComponent(), instanceOf(DummyProcess.class));
        ProcessProfile inner = ((DummyProcess) result.getComponent()).inner;
        assertThat(inner.getName(), is(not(profile.getName())));
        assertThat(inner.getConfiguration(), is(map(
                "hello1", "world1",
                "hello2", "world2",
                "hello3", "world3")));
View Full Code Here

TOP

Related Classes of com.asakusafw.windgate.retryable.RetryableProcessProfile

Copyright © 2018 www.massapicom. 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.