A Brooklyn judge is set to retire, amid a campaign mounted by progressives that targeted his "punitive record" and "unfit judicial temperament."