January 2019
Intermediate to advanced
490 pages
15h 37m
English
Let us do dependency injection with Guice, which is a lightweight framework suggested by AWS.
<dependency> <groupId>com.google.inject</groupId> <artifactId>guice</artifactId> <version>4.2.0</version></dependency>
public class ApplicationModule extends AbstractModule { protected final void configure() { bind(IAMService.class).to(IAMServiceImpl.class); }}
public final class MyLambdaHandler implements RequestHandler<IAMOperationRequest, IAMOperationResponse> { private static final Injector INJECTOR = Guice.createInjector(new ApplicationModule()); private IAMService service ...
Read now
Unlock full access