Search in sources :

Example 1 with SamzaRestApplication

use of org.apache.samza.rest.SamzaRestApplication in project samza by apache.

the class TestTasksResource method configure.

@Override
protected Application configure() {
    Map<String, String> configMap = ImmutableMap.of(TaskResourceConfig.CONFIG_TASK_PROXY_FACTORY, MockTaskProxyFactory.class.getName(), SamzaRestConfig.CONFIG_REST_RESOURCE_FACTORIES, MockResourceFactory.class.getName());
    SamzaRestConfig config = new SamzaRestConfig(new MapConfig(configMap));
    return new SamzaRestApplication(config);
}
Also used : SamzaRestConfig(org.apache.samza.rest.SamzaRestConfig) SamzaRestApplication(org.apache.samza.rest.SamzaRestApplication) MapConfig(org.apache.samza.config.MapConfig) MockTaskProxyFactory(org.apache.samza.rest.resources.mock.MockTaskProxyFactory) MockResourceFactory(org.apache.samza.rest.resources.mock.MockResourceFactory)

Example 2 with SamzaRestApplication

use of org.apache.samza.rest.SamzaRestApplication in project samza by apache.

the class TestJobsResource method configure.

@Override
protected Application configure() {
    Map<String, String> configMap = ImmutableMap.of(JobsResourceConfig.CONFIG_JOB_PROXY_FACTORY, MockJobProxyFactory.class.getName(), SamzaRestConfig.CONFIG_REST_RESOURCE_FACTORIES, MockResourceFactory.class.getName());
    SamzaRestConfig config = new SamzaRestConfig(new MapConfig(configMap));
    return new SamzaRestApplication(config);
}
Also used : SamzaRestConfig(org.apache.samza.rest.SamzaRestConfig) SamzaRestApplication(org.apache.samza.rest.SamzaRestApplication) MapConfig(org.apache.samza.config.MapConfig) MockJobProxyFactory(org.apache.samza.rest.resources.mock.MockJobProxyFactory) MockResourceFactory(org.apache.samza.rest.resources.mock.MockResourceFactory)

Aggregations

MapConfig (org.apache.samza.config.MapConfig)2 SamzaRestApplication (org.apache.samza.rest.SamzaRestApplication)2 SamzaRestConfig (org.apache.samza.rest.SamzaRestConfig)2 MockResourceFactory (org.apache.samza.rest.resources.mock.MockResourceFactory)2 MockJobProxyFactory (org.apache.samza.rest.resources.mock.MockJobProxyFactory)1 MockTaskProxyFactory (org.apache.samza.rest.resources.mock.MockTaskProxyFactory)1