Class HttpFunction
java.lang.Object
io.micronaut.oraclecloud.function.OciFunction
io.micronaut.oraclecloud.function.http.HttpFunction
- All Implemented Interfaces:
- AutoCloseable
A parent HttpFunction for authoring Project.fn gateway functions.
- Since:
- 1.0.0
- Author:
- graemerocher
- 
Constructor SummaryConstructorsModifierConstructorDescriptionDefault constructor.protectedHttpFunction(io.micronaut.context.ApplicationContext applicationContext) Constructor for using a shared application context.
- 
Method SummaryModifier and TypeMethodDescriptionfinal @NonNull io.micronaut.servlet.http.ServletHttpHandler<com.fnproject.fn.api.InputEvent,com.fnproject.fn.api.OutputEvent> com.fnproject.fn.api.OutputEventhandleRequest(com.fnproject.fn.api.httpgateway.HTTPGatewayContext gatewayContext, com.fnproject.fn.api.InputEvent inputEvent) Main entry point for Gateway functions for Project.fn.protected final voidsetup(com.fnproject.fn.api.RuntimeContext ctx) Setup method that can be overridden by users to add customizations.protected voidsetupGateway(@NonNull com.fnproject.fn.api.RuntimeContext ctx) Method that subclasses can override to customize gateway setup.Methods inherited from class io.micronaut.oraclecloud.function.OciFunctionclose, enableSharedJackson, getApplicationContext, newApplicationContextBuilder, setupContext
- 
Constructor Details- 
HttpFunctionpublic HttpFunction()Default constructor.
- 
HttpFunction@Inject protected HttpFunction(io.micronaut.context.ApplicationContext applicationContext) Constructor for using a shared application context.- Parameters:
- applicationContext- The application context
 
 
- 
- 
Method Details- 
setupprotected final void setup(com.fnproject.fn.api.RuntimeContext ctx) Description copied from class:OciFunctionSetup method that can be overridden by users to add customizations.- Overrides:
- setupin class- OciFunction
- Parameters:
- ctx- The runtime context
 
- 
setupGatewayprotected void setupGateway(@NonNull @NonNull com.fnproject.fn.api.RuntimeContext ctx) Method that subclasses can override to customize gateway setup.- Parameters:
- ctx- The context
 
- 
getHttpHandler@NonNull public final @NonNull io.micronaut.servlet.http.ServletHttpHandler<com.fnproject.fn.api.InputEvent,com.fnproject.fn.api.OutputEvent> getHttpHandler()- Returns:
- The HTTP handler.
 
- 
handleRequestpublic com.fnproject.fn.api.OutputEvent handleRequest(com.fnproject.fn.api.httpgateway.HTTPGatewayContext gatewayContext, com.fnproject.fn.api.InputEvent inputEvent) Main entry point for Gateway functions for Project.fn.- Parameters:
- gatewayContext- The gateway context
- inputEvent- The input event
- Returns:
- The output event
 
 
-