Energy saving and predictive event monitoring in Industry 4.0