various optimization + fix for trigger on blank nodes
increment data counter at each new log