-
Notifications
You must be signed in to change notification settings - Fork 7
Closed
Description
Hi,
It seems like the the plugin only detects errors when using the RequestHandler interface. However, when using Spring Cloud Functions you would use the generic java.util.function.Function
interface. This will probably also affect other frameworks that are not using the RequestHandler interface.
Examples:
WORKS with RequestHandler (Detects an issue):
@Component
public class LambdaHandler implements RequestHandler<String, String> {
private final UUID random = UUID.randomUUID();
@Override
public String handleRequest(String event, Context context) {
return random.toString();
}
}
DOES NOT WORK with Function interface (detects no issues):
@Component
public class LambdaHandler implements Function<String, String> {
private final UUID random = UUID.randomUUID();
@Override
public String apply(String event) {
return random.toString();
}
}
Proposal:
I would propose to scan either the entire package or make it configurable.
Metadata
Metadata
Assignees
Labels
No labels