Skip to content

Install Guide (Lambdas)

Requirements

The NerdVision java agent will run in all currently supported AWS lambda runtimes.

Install Dependency

The first step is to install the NerdVision dependency into your project. We recommend using maven or gradle.

<dependency>
  <groupId>com.nerdvision</groupId>
  <artifactId>nerdvision</artifactId>
  <version>LATEST</version>
</dependency>
implementation 'com.nerdvision:nerdvision:LATEST'

Now you need to configure NerdVision, in your code add a call to

In the lambda config add the environment variable NV_API_KEY to equal your apikey. See our example below.

public class MyLambda implements Function {
    public Object apply(Object incoming) {
        NerdVision.lambda();
    }
}

For an example of using NerdVision in AWS lambdas please see our gitlab repo nerd-vision / examples / aws-lambdas / java-lambda.

Lambdas need to be invoked twice

Currently the java agent is only able to track calls on lambdas on the second invocation after the tracepoint has been installed. The invocation of the lambda does not have to trigger the tracepoint twice, the lambda just needs to run twice.

Lambda Impact

Changes to your lambda runtime can have an effect on the cost of the lambda. We strive to ensure we have as minimal impact as we can. If you see a change to your lambda performance please contact support.