update gearman logic