[feat] Log  taskschedule method name and declared class
@@ -304,6 +304,8 @@ public class TornadoTaskSchedule implements AbstractTaskGraph {
Providers providers = getTornadoRuntime().getDriver(driverIndex).getProviders();
TornadoSuitesProvider suites = getTornadoRuntime().getDriver(driverIndex).getSuitesProvider();
+ logTaskMethodHandle(task);
+
executionContext.setTask(index, task);
if (task instanceof CompilableTask) {
@@ -322,6 +324,8 @@ public class TornadoTaskSchedule implements AbstractTaskGraph {
Providers providers = getTornadoRuntime().getDriver(driverIndex).getProviders();
TornadoSuitesProvider suites = getTornadoRuntime().getDriver(driverIndex).getSuitesProvider();
+ logTaskMethodHandle(task);
+
int index = executionContext.addTask(task);
if (task instanceof CompilableTask) {
@@ -363,6 +367,13 @@ public class TornadoTaskSchedule implements AbstractTaskGraph {
abstract long time();
}
+ private void logTaskMethodHandle(SchedulableTask task) {
+ if (!(task.getTaskName() == null) && !(task.getId() == null)) {
+ timeProfiler.registerMethodHandle(ProfilerType.METHOD, task.getId(),
+ ((CompilableTask) task).getMethod().getDeclaringClass().getSimpleName() + "." + ((CompilableTask) task).getMethod().getName());
+ }
+ }
+
private static class MillesecTimer extends Timer {
@Override
long time() {
