he had served as superintendent of the state department of corrections for twentyseven years , and in doing so had survived six governors , an army of state legislators , a thousand prisoners ' lawsuits , countless intrusions by the federal courts , and more executions than he cared to remember .