fixes#2754 improve invokeOnPartitions() method
create method for Partition Set
Merge pull request #2756 from hasancelik/fixes#2754

fixes#2754