Updated DictionarySerializer
Added a new TaskSpec: "Function". Also added a new state: "FAILURE", and handling of that state