GH-434 Added generic FunctionInvoker for AWS

- Added generic FunctionInvoker capable of handling the request generically without requiring user to implemen specific AWS request handler

Resolves #434
This commit is contained in:
Oleg Zhurakousky
2019-12-05 19:28:54 +01:00
parent 0f38ea47b8
commit 52b0fdea50
15 changed files with 641 additions and 234 deletions

View File

@@ -18,10 +18,6 @@ package example;
import org.junit.Test;
import org.springframework.cloud.function.adapter.aws.SpringBootRequestHandler;
import static org.assertj.core.api.Assertions.assertThat;
/**
* @author Dave Syer
*
@@ -30,16 +26,6 @@ public class MapTests {
@Test
public void test() {
Bar result = new Config(new Properties()).function().apply(new Foo("foo"));
assertThat(result.getValue()).isEqualTo("FOO");
}
@Test
public void start() throws Exception {
SpringBootRequestHandler<Object, Object> handler = new SpringBootRequestHandler<>(
Config.class);
handler.handleRequest(new Foo("foo"), null);
handler.close();
}
}