SparkContext.
cancelJobGroup
Cancel active jobs for the specified group. See SparkContext.setJobGroup(). for more information.
SparkContext.setJobGroup()