package io.mangoo.scheduler;

import java.lang.reflect.InvocationTargetException;
import java.util.Objects;

import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

import io.mangoo.core.Application;
import io.mangoo.enums.Required;

/**
 * Proxy class for executing scheduled tasks
 * 
 * @author svenkubiak
 *
 */
public class Task implements Runnable {
    private static final Logger LOG = LogManager.getLogger(Task.class);
    private Class<?> clazz;
    private String methodName;
    
    public Task(Class<?> clazz, String methodName) {
        this.clazz = Objects.requireNonNull(clazz, Required.CLASS.toString());
        this.methodName = Objects.requireNonNull(methodName, Required.METHOD.toString());
    }

    @Override
    @SuppressWarnings("all")
    public void run() {
        try {
            Object instance = Application.getInstance(clazz);
            instance.getClass().getMethod(methodName).invoke(instance, null);
        } catch (NoSuchMethodException | SecurityException | IllegalAccessException | IllegalArgumentException | InvocationTargetException e) {
            LOG.error("Failed to execute scheduled task on class '" + clazz.getName() + "' with annotated method '" + methodName + "'", e);
        }
    }
}
@@ -761,37 +761,8 @@
 ide%0A
-    @SuppressWarnings(%22all%22)%0A
     
@@ -927,16 +927,27 @@
 nstance,
+ (Class%3C?%3E)
  null);%0A

Build fix