Remove deprecated schedule sorting code
Producer refactoring fixes
Fix election duplication and incorrect ordering