Online Multi-task Learning with Hard Constraints