Toward real-time energy-aware automation of the resource scheduling using reinforcement learning