THIS IS A TEST INSTANCE. ALL YOUR CHANGES WILL BE LOST!!!!
...
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
/** * TestApplication provides static factory for quick setup of Samza environment for testing High Level Api,. users canUsers can either pass * instance of StreamApplciation or let framework do the initization for them and then configure input * streams and then apply various operators on streams and run the application */ public class TestApplication<T> { // Static factory to config & create runner for High level api public static TestApplication create() {...} public static TestApplication create(StreamApplication app) {...} // Add/Ovveride any custom configs public TestApplication addOverrideConfigs(Map<String,String> config) {...} // Set container mode either single container or multi container public TestApplication setContainerMode(Mode mode) {...} // Multithreading configs for users public TestApplication setTaskMaxConcurrency(Integer value) {...} public TestApplication setTaskCallBackTimeoutMS(Integer value) {...} public TestApplication setTaskMaxConcurrency(Integer value) {...} // Configure any kind of input stream for samza system, and get the handle of message stream to apply operators on public <T> MessageStream<T> getInputStream(EventStream<T> stream) {...} public <T> MessageStream<T> getInputStream(CollectionStream<T> stream) {...} public <T> MessageStream<T> getInputStream(FileStream<T> stream) {...} // Run the app public void run() {...}; } |
...